build
This commit is contained in:
parent
87309f5b39
commit
da828ddf4f
120 changed files with 2482 additions and 4328 deletions
3
dist-import/NPS/index.d.ts
vendored
3
dist-import/NPS/index.d.ts
vendored
|
|
@ -1,3 +0,0 @@
|
|||
import type { tipo_proxima_avaliacao } from "./tipos_nps";
|
||||
export declare const abrirNps: (emDesenvolvimento: boolean) => (parametros: tipo_proxima_avaliacao["parametros"]) => Promise<void>;
|
||||
export type { tipo_proxima_avaliacao };
|
||||
|
|
@ -1,50 +0,0 @@
|
|||
// npm run build produz um arquivo abrirNps.js que é copiado para a pasta public
|
||||
import { respostaComuns } from "p-respostas";
|
||||
// exibe o iframe em tela cheia
|
||||
export const abrirNps = (emDesenvolvimento) => async (parametros) => {
|
||||
const base_site = emDesenvolvimento
|
||||
? "http://localhost:5040/nps"
|
||||
: "https://carro-de-boi.idz.one/nps";
|
||||
const base_api = `${base_site}/api`;
|
||||
const { sistema, codigo_organizacao, codigo_usuario } = parametros;
|
||||
const nome_local_storage_proxima = `nps_proxima_avaliacao_${sistema}_${codigo_usuario}_${codigo_organizacao}_0`;
|
||||
const proxima_avaliacao = localStorage.getItem(nome_local_storage_proxima);
|
||||
if (!proxima_avaliacao) {
|
||||
const url_proxima_avaliacao = new URL(`${base_api}/${sistema}/proxima_avaliacao`);
|
||||
for (const [chave, valor] of Object.entries(parametros)) {
|
||||
url_proxima_avaliacao.searchParams.append(chave, valor);
|
||||
}
|
||||
const response = await fetch(url_proxima_avaliacao.href)
|
||||
.then((resposta) => resposta.json())
|
||||
.catch((error) => respostaComuns.erro(error.message));
|
||||
const proxima_avaliacao = response.valor;
|
||||
proxima_avaliacao &&
|
||||
localStorage.setItem(nome_local_storage_proxima, proxima_avaliacao);
|
||||
}
|
||||
const abrir_modal = proxima_avaliacao &&
|
||||
new Date().toISOString().slice(0, 10) >= proxima_avaliacao;
|
||||
if (!abrir_modal) {
|
||||
return;
|
||||
}
|
||||
localStorage.removeItem(nome_local_storage_proxima);
|
||||
const urlIfrma = new URL(base_site);
|
||||
for (const [chave, valor] of Object.entries(parametros)) {
|
||||
urlIfrma.searchParams.append(chave, valor);
|
||||
}
|
||||
const iframe = document.createElement("iframe");
|
||||
iframe.src = urlIfrma.href;
|
||||
iframe.style.position = "fixed";
|
||||
iframe.style.top = "0";
|
||||
iframe.style.left = "0";
|
||||
iframe.style.width = "100%";
|
||||
iframe.style.height = "100%";
|
||||
iframe.style.border = "none";
|
||||
iframe.style.zIndex = "999999";
|
||||
document.body.appendChild(iframe);
|
||||
// receber mensagem do iframe
|
||||
window.addEventListener("message", (event) => {
|
||||
if (event.data === "fechar") {
|
||||
document.body.removeChild(iframe);
|
||||
}
|
||||
});
|
||||
};
|
||||
13
dist-import/NPS/tipos_nps.d.ts
vendored
13
dist-import/NPS/tipos_nps.d.ts
vendored
|
|
@ -1,13 +0,0 @@
|
|||
import type { tipoResposta } from "p-respostas";
|
||||
export type tipo_proxima_avaliacao = {
|
||||
parametros: {
|
||||
sistema: string;
|
||||
codigo_organizacao: string;
|
||||
codigo_usuario: string;
|
||||
nome_organizacao: string;
|
||||
nome_usuario: string;
|
||||
contatos_usuario: string;
|
||||
data_criacao_conta: string;
|
||||
};
|
||||
retorno: tipoResposta<string>;
|
||||
};
|
||||
|
|
@ -1 +0,0 @@
|
|||
export {};
|
||||
11
dist-import/autenticacao/_codigoContaSite.d.ts
vendored
11
dist-import/autenticacao/_codigoContaSite.d.ts
vendored
|
|
@ -1,11 +0,0 @@
|
|||
import { type tipoResposta } from "p-respostas";
|
||||
import type { z } from "zod";
|
||||
import type { zAmbiente } from "../ts/ambiente";
|
||||
type tipoPostCodigoContaSite = {
|
||||
site: string;
|
||||
};
|
||||
export declare const codigoContaSite: ({ ambiente, post, }: {
|
||||
ambiente: z.infer<typeof zAmbiente>;
|
||||
post: tipoPostCodigoContaSite;
|
||||
}) => Promise<tipoResposta<string>>;
|
||||
export {};
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
import { respostaComuns } from "p-respostas";
|
||||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
import node_fetch from "cross-fetch";
|
||||
export const codigoContaSite = async ({ ambiente, post, }) => {
|
||||
const url = `${urlAutenticacao(ambiente)}/api/codigo_prefeitura_site`;
|
||||
try {
|
||||
const resp = await node_fetch(url, {
|
||||
method: "POST",
|
||||
body: JSON.stringify(post),
|
||||
headers: { "Content-Type": "application/json" },
|
||||
})
|
||||
.then((r) => r.json())
|
||||
.catch((e) => respostaComuns.erro("Erro ao enviar registros", [e.message]))
|
||||
.then((r) => r);
|
||||
return resp;
|
||||
}
|
||||
catch (e) {
|
||||
return respostaComuns.erro(`erro ao buscar código do site: ${e}`);
|
||||
}
|
||||
};
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
import type { z } from "zod";
|
||||
import type { zAmbiente } from "../ts/ambiente";
|
||||
export declare const urlAutenticacao: (ambiente: z.infer<typeof zAmbiente>) => string;
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
export const urlAutenticacao = (ambiente) => `${ambiente == "producao"
|
||||
? "https://carro-de-boi.idz.one"
|
||||
: "http://localhost:5030"}/autenticacao`;
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
import { type tipoResposta } from "p-respostas";
|
||||
import type { z } from "zod";
|
||||
import type { zAmbiente } from "../ts/ambiente";
|
||||
export type tipoUsuarioExterno = {
|
||||
nome: string;
|
||||
email: string;
|
||||
telefone: string;
|
||||
vinculo: string;
|
||||
codigo_conta: string;
|
||||
chave_produto: string;
|
||||
};
|
||||
export declare const usuarios_quipo_governo: ({ token_produto, ambiente, }: {
|
||||
ambiente: z.infer<typeof zAmbiente>;
|
||||
token_produto: string;
|
||||
}) => Promise<tipoResposta<tipoUsuarioExterno[]>>;
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
import node_fetch from "cross-fetch";
|
||||
import { respostaComuns } from "p-respostas";
|
||||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
export const usuarios_quipo_governo = async ({ token_produto, ambiente, }) => {
|
||||
const url = `${urlAutenticacao(ambiente)}/api/usuarios_quipo_governo`;
|
||||
if (!token_produto)
|
||||
return respostaComuns.erro("token_produto não informado");
|
||||
const headers = {
|
||||
token: token_produto,
|
||||
};
|
||||
return node_fetch(url, {
|
||||
headers,
|
||||
})
|
||||
.then((r) => r.json())
|
||||
.catch((e) => respostaComuns.erro(`Erro ao buscar usuários quipo governo ${e.message}`))
|
||||
.then((r) => r);
|
||||
};
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
import { type tipoResposta } from "p-respostas";
|
||||
import type { z } from "zod";
|
||||
import type { zAmbiente } from "../ts/ambiente";
|
||||
export declare const usuarios_quipo_vincular: ({ token_produto, ambiente, conta, vinculo, codigo_usuario, email, }: {
|
||||
ambiente: z.infer<typeof zAmbiente>;
|
||||
token_produto: string;
|
||||
conta: string;
|
||||
vinculo: string;
|
||||
codigo_usuario?: string;
|
||||
email: string;
|
||||
}) => Promise<tipoResposta<string>>;
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
import node_fetch from "cross-fetch";
|
||||
import { respostaComuns } from "p-respostas";
|
||||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
export const usuarios_quipo_vincular = async ({ token_produto, ambiente, conta, vinculo, codigo_usuario, email, }) => {
|
||||
const url = `${urlAutenticacao(ambiente)}/api/vinculos__criar`;
|
||||
if (!token_produto)
|
||||
return respostaComuns.erro("token_produto não informado");
|
||||
const headers = {
|
||||
token: token_produto,
|
||||
"Content-Type": "application/json",
|
||||
};
|
||||
const parametros = {
|
||||
vinculos: { codigo_conta: conta, codigo_usuario, vinculo },
|
||||
email: email,
|
||||
};
|
||||
return await node_fetch(url, {
|
||||
headers,
|
||||
body: JSON.stringify(parametros),
|
||||
method: "POST",
|
||||
})
|
||||
.then(async (r) => await r.json())
|
||||
.catch((e) => respostaComuns.erro(`Erro ao criar vinculo de usuario ${e.message}`));
|
||||
};
|
||||
11
dist-import/autenticacao/_validarToken.d.ts
vendored
11
dist-import/autenticacao/_validarToken.d.ts
vendored
|
|
@ -1,11 +0,0 @@
|
|||
type tipoPostValidarTokem = {
|
||||
token: string;
|
||||
};
|
||||
import type { z } from "zod";
|
||||
import type { zAmbiente } from "../ts/ambiente";
|
||||
/** faz a validação do token */
|
||||
export declare const validarToken: ({ ambiente, post, }: {
|
||||
ambiente: z.infer<typeof zAmbiente>;
|
||||
post: tipoPostValidarTokem;
|
||||
}) => Promise<"valido" | "erro">;
|
||||
export {};
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
import node_fetch from "cross-fetch";
|
||||
/** faz a validação do token */
|
||||
export const validarToken = async ({ ambiente, post, }) => {
|
||||
const url = `${urlAutenticacao(ambiente)}/api/validar_token`;
|
||||
try {
|
||||
const resposta = await node_fetch(url, {
|
||||
method: "POST",
|
||||
body: JSON.stringify(post),
|
||||
headers: { "Content-Type": "application/json" },
|
||||
})
|
||||
.then((r) => r.json())
|
||||
.then((r) => r)
|
||||
.then((resposta) => resposta.eCerto ? "valido" : "erro")
|
||||
.catch(() => "erro");
|
||||
return resposta;
|
||||
}
|
||||
catch (_e) {
|
||||
return "erro";
|
||||
}
|
||||
};
|
||||
30
dist-import/autenticacao/index.d.ts
vendored
30
dist-import/autenticacao/index.d.ts
vendored
|
|
@ -1,30 +0,0 @@
|
|||
import { type tipoUsuarioExterno } from "./_usuarios_quipo_governo";
|
||||
export type { tipoUsuarioExterno };
|
||||
/** todas as rotas de comunicação com autenticador partem dessa variável */
|
||||
export declare const pAutenticacao: {
|
||||
validarToken: ({ ambiente, post, }: {
|
||||
ambiente: import("zod").TypeOf<typeof import("../ts/ambiente").zAmbiente>;
|
||||
post: {
|
||||
token: string;
|
||||
};
|
||||
}) => Promise<"valido" | "erro">;
|
||||
urlAutenticacao: (ambiente: import("zod").TypeOf<typeof import("../ts/ambiente").zAmbiente>) => string;
|
||||
codigoContaSite: ({ ambiente, post, }: {
|
||||
ambiente: import("zod").TypeOf<typeof import("../ts/ambiente").zAmbiente>;
|
||||
post: {
|
||||
site: string;
|
||||
};
|
||||
}) => Promise<import("p-respostas").tipoResposta<string>>;
|
||||
usuarios_quipo_governo: ({ token_produto, ambiente, }: {
|
||||
ambiente: import("zod").TypeOf<typeof import("../ts/ambiente").zAmbiente>;
|
||||
token_produto: string;
|
||||
}) => Promise<import("p-respostas").tipoResposta<tipoUsuarioExterno[]>>;
|
||||
usuarios_quipo_vincular: ({ token_produto, ambiente, conta, vinculo, codigo_usuario, email, }: {
|
||||
ambiente: import("zod").TypeOf<typeof import("../ts/ambiente").zAmbiente>;
|
||||
token_produto: string;
|
||||
conta: string;
|
||||
vinculo: string;
|
||||
codigo_usuario?: string;
|
||||
email: string;
|
||||
}) => Promise<import("p-respostas").tipoResposta<string>>;
|
||||
};
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
import { codigoContaSite } from "./_codigoContaSite";
|
||||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
import { usuarios_quipo_governo, } from "./_usuarios_quipo_governo";
|
||||
import { usuarios_quipo_vincular } from "./_usuarios_quipo_vincular";
|
||||
import { validarToken } from "./_validarToken";
|
||||
/** todas as rotas de comunicação com autenticador partem dessa variável */
|
||||
export const pAutenticacao = {
|
||||
validarToken,
|
||||
urlAutenticacao,
|
||||
codigoContaSite,
|
||||
usuarios_quipo_governo,
|
||||
usuarios_quipo_vincular,
|
||||
};
|
||||
706
dist-import/index.d.mts
Normal file
706
dist-import/index.d.mts
Normal file
|
|
@ -0,0 +1,706 @@
|
|||
import * as zod from 'zod';
|
||||
import { z } from 'zod';
|
||||
import * as p_respostas from 'p-respostas';
|
||||
import { tipoResposta } from 'p-respostas';
|
||||
|
||||
declare const tipos_acesso_quipo: z.ZodEnum<["publico", "governo", "sociedade"]>;
|
||||
declare const ztokenQuipo: z.ZodObject<{
|
||||
provedor: z.ZodString;
|
||||
codigo_usuario: z.ZodString;
|
||||
nome_usuario: z.ZodString;
|
||||
codigo_conta: z.ZodString;
|
||||
nome_conta: z.ZodString;
|
||||
codigo_acesso_produto: z.ZodString;
|
||||
codigo_autenticacao: z.ZodString;
|
||||
chave_produto: z.ZodEnum<["betha-meio-ambiente", "e-licencie-gov"]>;
|
||||
tipo_de_acesso: z.ZodEnum<["publico", "governo", "sociedade"]>;
|
||||
exp: z.ZodOptional<z.ZodNumber>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
provedor: string;
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
codigo_conta: string;
|
||||
nome_conta: string;
|
||||
codigo_acesso_produto: string;
|
||||
codigo_autenticacao: string;
|
||||
chave_produto: "betha-meio-ambiente" | "e-licencie-gov";
|
||||
tipo_de_acesso: "publico" | "governo" | "sociedade";
|
||||
exp?: number | undefined;
|
||||
}, {
|
||||
provedor: string;
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
codigo_conta: string;
|
||||
nome_conta: string;
|
||||
codigo_acesso_produto: string;
|
||||
codigo_autenticacao: string;
|
||||
chave_produto: "betha-meio-ambiente" | "e-licencie-gov";
|
||||
tipo_de_acesso: "publico" | "governo" | "sociedade";
|
||||
exp?: number | undefined;
|
||||
}>;
|
||||
type tipos_de_acesso_quipo = z.infer<typeof ztokenQuipo>["tipo_de_acesso"];
|
||||
type tipoTokenQuipo = z.infer<typeof ztokenQuipo>;
|
||||
|
||||
declare const zAmbiente: z.ZodEnum<["desenvolvimento", "producao"]>;
|
||||
|
||||
type tipoUsuarioExterno = {
|
||||
nome: string;
|
||||
email: string;
|
||||
telefone: string;
|
||||
vinculo: string;
|
||||
codigo_conta: string;
|
||||
chave_produto: string;
|
||||
};
|
||||
|
||||
/** todas as rotas de comunicação com autenticador partem dessa variável */
|
||||
declare const pAutenticacao: {
|
||||
validarToken: ({ ambiente, post, }: {
|
||||
ambiente: zod.TypeOf<typeof zAmbiente>;
|
||||
post: {
|
||||
token: string;
|
||||
};
|
||||
}) => Promise<"valido" | "erro">;
|
||||
urlAutenticacao: (ambiente: zod.TypeOf<typeof zAmbiente>) => string;
|
||||
codigoContaSite: ({ ambiente, post, }: {
|
||||
ambiente: zod.TypeOf<typeof zAmbiente>;
|
||||
post: {
|
||||
site: string;
|
||||
};
|
||||
}) => Promise<p_respostas.tipoResposta<string>>;
|
||||
usuarios_quipo_governo: ({ token_produto, ambiente, }: {
|
||||
ambiente: zod.TypeOf<typeof zAmbiente>;
|
||||
token_produto: string;
|
||||
}) => Promise<p_respostas.tipoResposta<tipoUsuarioExterno[]>>;
|
||||
usuarios_quipo_vincular: ({ token_produto, ambiente, conta, vinculo, codigo_usuario, email, }: {
|
||||
ambiente: zod.TypeOf<typeof zAmbiente>;
|
||||
token_produto: string;
|
||||
conta: string;
|
||||
vinculo: string;
|
||||
codigo_usuario?: string;
|
||||
email: string;
|
||||
}) => Promise<p_respostas.tipoResposta<string>>;
|
||||
};
|
||||
|
||||
declare const chaves_produto: z.ZodEnum<["suporte", "betha-meio-ambiente", "e-licencie-gov", "e-licencie"]>;
|
||||
|
||||
/** aplica a todas as consultas */
|
||||
declare const z_padroes: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
declare const visoes_pilao: {
|
||||
z_contagem_em_barra_vertical: z.ZodObject<{
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: z.ZodObject<{
|
||||
classes: z.ZodString;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
classes: string;
|
||||
}, {
|
||||
classes: string;
|
||||
}>;
|
||||
z_tabela: z.ZodObject<{
|
||||
colunas: z.ZodArray<z.ZodString, "many">;
|
||||
coluna_ordem: z.ZodOptional<z.ZodString>;
|
||||
direcao_ordem: z.ZodOptional<z.ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: z.ZodObject<{
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaSoma: z.ZodString;
|
||||
unidadeSoma: z.ZodOptional<z.ZodString>;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
};
|
||||
|
||||
declare const z_tipos_campos_reg_grafico: z.ZodEnum<["tabela", "coluna", "texto", "lista_colunas", "lista_filtros", "ordem"]>;
|
||||
type tipo_estrutura_visao_grafico<T extends keyof typeof visoes_pilao> = {
|
||||
/** Nome da Visão */
|
||||
visao: T;
|
||||
/** Rotulo */
|
||||
rotulo: string;
|
||||
/** Retorna a tabela Referente ao Registro */
|
||||
tabela: (_: z.infer<(typeof visoes_pilao)[T]> & z.infer<typeof z_padroes>) => string;
|
||||
/** Descrição */
|
||||
descricao: (_: z.infer<(typeof visoes_pilao)[T]> & z.infer<typeof z_padroes>) => string;
|
||||
/** Lista os campos e suas configurações */
|
||||
campos: {
|
||||
[c in keyof Required<z.infer<(typeof visoes_pilao)[T]> & z.infer<typeof z_padroes>>]: {
|
||||
rotulo: string;
|
||||
tipo_campo: z.infer<typeof z_tipos_campos_reg_grafico>;
|
||||
order: number;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
declare const zp_deletar_registros: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
codigos: z.ZodArray<z.ZodString, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}>;
|
||||
declare const PREFIXO_PILAO = "/pilao-de-dados";
|
||||
declare const urlPilao: (emDesenvolvimento?: boolean | null | undefined) => {
|
||||
api: string;
|
||||
site: string;
|
||||
};
|
||||
|
||||
declare const zp_registrar_base_dados: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colunas: z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
tipo: z.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}>, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}>;
|
||||
declare const zp_enviar_registros: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
registros: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
||||
valor: z.ZodAny;
|
||||
tipo: z.ZodNullable<z.ZodOptional<z.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>>>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>>, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}>;
|
||||
|
||||
/**
|
||||
* {
|
||||
* 'rota':{
|
||||
* pr:{}// paramentros de entrada
|
||||
* rs:{}// resposta
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
type tipo_pilao_api = {
|
||||
/** retorna da data e hora do servido em formato iso */
|
||||
estado_servidor: {
|
||||
pr: {};
|
||||
rs: {
|
||||
data_hora: string;
|
||||
};
|
||||
};
|
||||
tabelas: {
|
||||
pr: {};
|
||||
rs: z.infer<typeof zp_registrar_base_dados>[];
|
||||
};
|
||||
unicos: {
|
||||
pr: {
|
||||
tabela: string;
|
||||
coluna: string;
|
||||
};
|
||||
rs: any[];
|
||||
};
|
||||
};
|
||||
|
||||
type tipoConstrutorPilao = {
|
||||
produto: string;
|
||||
conta: string;
|
||||
};
|
||||
type tipoRetornoSerieconsulta<T extends keyof typeof visoes_pilao> = {
|
||||
registros: any[];
|
||||
legenda: string;
|
||||
serie: z.infer<(typeof visoes_pilao)[T]> & z.infer<typeof z_padroes>;
|
||||
};
|
||||
|
||||
/** Drive completo do piilão de dados */
|
||||
|
||||
declare class ClassPilao {
|
||||
#private;
|
||||
constructor({ conta, produto, emDesenvolvimento, ver_log, }: tipoConstrutorPilao & {
|
||||
ver_log?: boolean;
|
||||
emDesenvolvimento?: boolean;
|
||||
});
|
||||
rotaEnviarRegistros(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaDeletarRegistro(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaConsultarSerie(tipoVisao: keyof typeof visoes_pilao | ":tipoVisao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaIframeSerie(tipoVisao: keyof typeof visoes_pilao | ":tipoVisao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaFuncaoApi(funcao: keyof tipo_pilao_api | ":funcao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
consultarApi<T extends keyof tipo_pilao_api>(funcao: T, parametros: tipo_pilao_api[T]["pr"]): Promise<tipoResposta<tipo_pilao_api[T]["rs"]>>;
|
||||
get baseUrlApi(): "https://carro-de-boi.idz.one" | "http://localhost:5080";
|
||||
get baseUrlSite(): "https://carro-de-boi.idz.one" | "http://localhost:5081";
|
||||
validarCliente(_: any): tipoResposta<tipoConstrutorPilao>;
|
||||
adicionarRegistroParaEnviar(tabela: string, ...registros: z.infer<typeof zp_enviar_registros>["registros"]): this;
|
||||
adicionarCodigoParaDeletar(tabela: string, ...codigos: z.infer<typeof zp_deletar_registros>["codigos"]): this;
|
||||
private processarRegistros;
|
||||
salvarRegistros(): Promise<tipoResposta<true>>;
|
||||
serieConsultar<T extends keyof typeof visoes_pilao>(tipoVisao: T, parametros: z.infer<(typeof visoes_pilao)[T]> & z.infer<typeof z_padroes>): {
|
||||
dados: () => Promise<tipoResposta<tipoRetornoSerieconsulta<T>>>;
|
||||
url: () => string;
|
||||
};
|
||||
urlLaboratorio(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
}
|
||||
declare const Pilao: (_: tipoConstrutorPilao & {
|
||||
ver_log?: boolean;
|
||||
emDesenvolvimento?: boolean;
|
||||
}) => ClassPilao;
|
||||
|
||||
declare const pPilao: {
|
||||
extruturas_de_campos: {
|
||||
z_contagem_em_barra_vertical: tipo_estrutura_visao_grafico<"z_contagem_em_barra_vertical">;
|
||||
z_contagem_em_pizza: tipo_estrutura_visao_grafico<"z_contagem_em_pizza">;
|
||||
z_tabela: tipo_estrutura_visao_grafico<"z_tabela">;
|
||||
z_soma_em_barra_vertical: tipo_estrutura_visao_grafico<"z_soma_em_barra_vertical">;
|
||||
};
|
||||
z_contagem_em_barra_vertical: zod.ZodObject<{
|
||||
colanuEixoX: zod.ZodString;
|
||||
colunaAgrupamento: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: zod.ZodObject<{
|
||||
classes: zod.ZodString;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
classes: string;
|
||||
}, {
|
||||
classes: string;
|
||||
}>;
|
||||
z_tabela: zod.ZodObject<{
|
||||
colunas: zod.ZodArray<zod.ZodString, "many">;
|
||||
coluna_ordem: zod.ZodOptional<zod.ZodString>;
|
||||
direcao_ordem: zod.ZodOptional<zod.ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: zod.ZodObject<{
|
||||
colanuEixoX: zod.ZodString;
|
||||
colunaSoma: zod.ZodString;
|
||||
unidadeSoma: zod.ZodOptional<zod.ZodString>;
|
||||
colunaAgrupamento: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
zp_deletar_registros: zod.ZodObject<{
|
||||
tabela: zod.ZodString;
|
||||
codigos: zod.ZodArray<zod.ZodString, "many">;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}>;
|
||||
zp_registrar_base_dados: zod.ZodObject<{
|
||||
tabela: zod.ZodString;
|
||||
colunas: zod.ZodArray<zod.ZodObject<{
|
||||
coluna: zod.ZodString;
|
||||
tipo: zod.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}>, "many">;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}>;
|
||||
z_tipos_dados_registro: zod.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
zp_enviar_registros: zod.ZodObject<{
|
||||
tabela: zod.ZodString;
|
||||
registros: zod.ZodArray<zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
||||
valor: zod.ZodAny;
|
||||
tipo: zod.ZodNullable<zod.ZodOptional<zod.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>>>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>>, "many">;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}>;
|
||||
zp_produto_conta: zod.ZodObject<{
|
||||
produto: zod.ZodString;
|
||||
conta: zod.ZodString;
|
||||
emDesenvolvimento: zod.ZodOptional<zod.ZodBoolean>;
|
||||
ver_log: zod.ZodOptional<zod.ZodBoolean>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}>;
|
||||
validarZ: <T>(zodType: zod.ZodType<T, any>, objeto: any, mensagem: string) => p_respostas.tipoRespostaErro | p_respostas.tipoRespostaSucesso<T>;
|
||||
operadores_pilao: zod.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
operadores_permitidos_por_tipo: {
|
||||
texto: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
numero: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
confirmacao: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_texto: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_numero: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_mes: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_data: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
mes: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
data: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
};
|
||||
z_filtro: zod.ZodObject<{
|
||||
coluna: zod.ZodString;
|
||||
valor: zod.ZodAny;
|
||||
operador: zod.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>;
|
||||
visoes_pilao: {
|
||||
z_contagem_em_barra_vertical: zod.ZodObject<{
|
||||
colanuEixoX: zod.ZodString;
|
||||
colunaAgrupamento: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: zod.ZodObject<{
|
||||
classes: zod.ZodString;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
classes: string;
|
||||
}, {
|
||||
classes: string;
|
||||
}>;
|
||||
z_tabela: zod.ZodObject<{
|
||||
colunas: zod.ZodArray<zod.ZodString, "many">;
|
||||
coluna_ordem: zod.ZodOptional<zod.ZodString>;
|
||||
direcao_ordem: zod.ZodOptional<zod.ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
colunas: string[];
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: zod.ZodObject<{
|
||||
colanuEixoX: zod.ZodString;
|
||||
colunaSoma: zod.ZodString;
|
||||
unidadeSoma: zod.ZodOptional<zod.ZodString>;
|
||||
colunaAgrupamento: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
||||
}, "strip", zod.ZodTypeAny, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
};
|
||||
};
|
||||
|
||||
/** Estrutura que deve ser aplicada para solictação de autenticação, deve ser feito via back */
|
||||
declare const zAuntenticacaoResiduosSolicitar: z.ZodObject<{
|
||||
codigo_token: z.ZodOptional<z.ZodString>;
|
||||
codigo_usuario: z.ZodString;
|
||||
nome_usuario: z.ZodString;
|
||||
email_usuario: z.ZodString;
|
||||
documento_usuario: z.ZodString;
|
||||
organizacao: z.ZodString;
|
||||
rotas: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
||||
url_usuarios: z.ZodString;
|
||||
url_empreendedores: z.ZodString;
|
||||
url_empreendimentos: z.ZodString;
|
||||
tipo_usuario: z.ZodString;
|
||||
sistema: z.ZodString;
|
||||
sistema_cor: z.ZodString;
|
||||
sistema_nome: z.ZodString;
|
||||
sistema_logo: z.ZodString;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
email_usuario: string;
|
||||
documento_usuario: string;
|
||||
organizacao: string;
|
||||
rotas: {};
|
||||
url_usuarios: string;
|
||||
url_empreendedores: string;
|
||||
url_empreendimentos: string;
|
||||
tipo_usuario: string;
|
||||
sistema: string;
|
||||
sistema_cor: string;
|
||||
sistema_nome: string;
|
||||
sistema_logo: string;
|
||||
codigo_token?: string | undefined;
|
||||
}, {
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
email_usuario: string;
|
||||
documento_usuario: string;
|
||||
organizacao: string;
|
||||
rotas: {};
|
||||
url_usuarios: string;
|
||||
url_empreendedores: string;
|
||||
url_empreendimentos: string;
|
||||
tipo_usuario: string;
|
||||
sistema: string;
|
||||
sistema_cor: string;
|
||||
sistema_nome: string;
|
||||
sistema_logo: string;
|
||||
codigo_token?: string | undefined;
|
||||
}>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
declare const zUsuarioSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
permicoes: z.ZodRecord<z.ZodString, z.ZodAny>;
|
||||
versao: z.ZodNumber;
|
||||
credenciais_sinir: z.ZodOptional<z.ZodObject<{
|
||||
login: z.ZodString;
|
||||
senha: z.ZodString;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
login: string;
|
||||
senha: string;
|
||||
}, {
|
||||
login: string;
|
||||
senha: string;
|
||||
}>>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
permicoes: Record<string, any>;
|
||||
versao: number;
|
||||
credenciais_sinir?: {
|
||||
login: string;
|
||||
senha: string;
|
||||
} | undefined;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
permicoes: Record<string, any>;
|
||||
versao: number;
|
||||
credenciais_sinir?: {
|
||||
login: string;
|
||||
senha: string;
|
||||
} | undefined;
|
||||
}>;
|
||||
type tipo_zUsuarioSincronizar = z.infer<typeof zUsuarioSincronizar>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
declare const zEmpreendedorSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
versao: z.ZodNumber;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
}>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
declare const zEmpreendimentoSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
codigo_empreendedor: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
unidade_sinir: z.ZodString;
|
||||
versao: z.ZodNumber;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
codigo_empreendedor: string;
|
||||
unidade_sinir: string;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
codigo_empreendedor: string;
|
||||
unidade_sinir: string;
|
||||
}>;
|
||||
declare const nomesSincronizacoes: z.ZodEnum<["usuarios", "empreendedores", "empreendimentos"]>;
|
||||
|
||||
type tipo_proxima_avaliacao = {
|
||||
parametros: {
|
||||
sistema: string;
|
||||
codigo_organizacao: string;
|
||||
codigo_usuario: string;
|
||||
nome_organizacao: string;
|
||||
nome_usuario: string;
|
||||
contatos_usuario: string;
|
||||
data_criacao_conta: string;
|
||||
};
|
||||
retorno: tipoResposta<string>;
|
||||
};
|
||||
|
||||
declare const abrirNps: (emDesenvolvimento: boolean) => (parametros: tipo_proxima_avaliacao["parametros"]) => Promise<void>;
|
||||
|
||||
export { PREFIXO_PILAO, Pilao, abrirNps, chaves_produto, nomesSincronizacoes, pAutenticacao, pPilao, type tipoConstrutorPilao, type tipoRetornoSerieconsulta, type tipoTokenQuipo, type tipoUsuarioExterno, type tipo_pilao_api, type tipo_proxima_avaliacao, type tipo_zUsuarioSincronizar, tipos_acesso_quipo, type tipos_de_acesso_quipo, urlPilao, zAuntenticacaoResiduosSolicitar, zEmpreendedorSincronizar, zEmpreendimentoSincronizar, zUsuarioSincronizar, ztokenQuipo };
|
||||
6
dist-import/index.d.ts
vendored
6
dist-import/index.d.ts
vendored
|
|
@ -1,6 +0,0 @@
|
|||
export * from "./tokenQuipo";
|
||||
export * from "./autenticacao";
|
||||
export * from "./produtos";
|
||||
export * from "./pilao-de-dados";
|
||||
export * from "./residuos";
|
||||
export * from "./NPS";
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
export * from "./tokenQuipo";
|
||||
export * from "./autenticacao";
|
||||
export * from "./produtos";
|
||||
export * from "./pilao-de-dados";
|
||||
export * from "./residuos";
|
||||
export * from "./NPS";
|
||||
1
dist-import/index.mjs
Normal file
1
dist-import/index.mjs
Normal file
File diff suppressed because one or more lines are too long
56
dist-import/pilao-de-dados/Pilao/index.d.ts
vendored
56
dist-import/pilao-de-dados/Pilao/index.d.ts
vendored
|
|
@ -1,56 +0,0 @@
|
|||
/** Drive completo do piilão de dados */
|
||||
import { type tipoResposta } from "p-respostas";
|
||||
import type { z } from "zod";
|
||||
import type { zp_enviar_registros } from "../_enviar_registros";
|
||||
import { type zp_deletar_registros } from "../variaveis";
|
||||
import type { visoes_pilao } from "../visoes/listaDeVisoes";
|
||||
import type { tipo_pilao_api } from "./pilao-api.ts";
|
||||
import type { tipoConstrutorPilao, tipoRetornoSerieconsulta } from "./tipagem";
|
||||
declare class ClassPilao {
|
||||
#private;
|
||||
constructor({ conta, produto, emDesenvolvimento, ver_log, }: tipoConstrutorPilao & {
|
||||
ver_log?: boolean;
|
||||
emDesenvolvimento?: boolean;
|
||||
});
|
||||
rotaEnviarRegistros(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaDeletarRegistro(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaConsultarSerie(tipoVisao: keyof typeof visoes_pilao | ":tipoVisao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaIframeSerie(tipoVisao: keyof typeof visoes_pilao | ":tipoVisao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
rotaFuncaoApi(funcao: keyof tipo_pilao_api | ":funcao"): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
consultarApi<T extends keyof tipo_pilao_api>(funcao: T, parametros: tipo_pilao_api[T]["pr"]): Promise<tipoResposta<tipo_pilao_api[T]["rs"]>>;
|
||||
get baseUrlApi(): "https://carro-de-boi.idz.one" | "http://localhost:5080";
|
||||
get baseUrlSite(): "https://carro-de-boi.idz.one" | "http://localhost:5081";
|
||||
validarCliente(_: any): tipoResposta<tipoConstrutorPilao>;
|
||||
adicionarRegistroParaEnviar(tabela: string, ...registros: z.infer<typeof zp_enviar_registros>["registros"]): this;
|
||||
adicionarCodigoParaDeletar(tabela: string, ...codigos: z.infer<typeof zp_deletar_registros>["codigos"]): this;
|
||||
private processarRegistros;
|
||||
salvarRegistros(): Promise<tipoResposta<true>>;
|
||||
serieConsultar<T extends keyof typeof visoes_pilao>(tipoVisao: T, parametros: z.infer<(typeof visoes_pilao)[T]>): {
|
||||
dados: () => Promise<tipoResposta<tipoRetornoSerieconsulta<T>>>;
|
||||
url: () => string;
|
||||
};
|
||||
urlLaboratorio(): {
|
||||
rota: string;
|
||||
url: string;
|
||||
};
|
||||
}
|
||||
export declare const Pilao: (_: tipoConstrutorPilao & {
|
||||
ver_log?: boolean;
|
||||
emDesenvolvimento?: boolean;
|
||||
}) => ClassPilao;
|
||||
export {};
|
||||
|
|
@ -1,211 +0,0 @@
|
|||
/** Drive completo do piilão de dados */
|
||||
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
||||
if (kind === "m") throw new TypeError("Private method is not writable");
|
||||
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
||||
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
||||
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
||||
};
|
||||
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
||||
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
||||
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
||||
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
||||
};
|
||||
var _ClassPilao_instances, _ClassPilao_produto, _ClassPilao_conta, _ClassPilao_emDesenvolvimento, _ClassPilao_ver_log, _ClassPilao_registrosParaEnvio, _ClassPilao_codigosParaDeletar, _ClassPilao_gerarUrl, _ClassPilao_salvarEnviarRegistros, _ClassPilao_salvarDeletarRegistros;
|
||||
import crossFetch from "cross-fetch";
|
||||
import { nomeVariavel } from "p-comuns";
|
||||
import { respostaComuns } from "p-respostas";
|
||||
import { PREFIXO_PILAO } from "../variaveis";
|
||||
class ClassPilao {
|
||||
constructor({ conta, produto, emDesenvolvimento = false, ver_log = false, }) {
|
||||
_ClassPilao_instances.add(this);
|
||||
_ClassPilao_produto.set(this, void 0);
|
||||
_ClassPilao_conta.set(this, void 0);
|
||||
_ClassPilao_emDesenvolvimento.set(this, void 0);
|
||||
_ClassPilao_ver_log.set(this, void 0);
|
||||
_ClassPilao_registrosParaEnvio.set(this, {});
|
||||
_ClassPilao_codigosParaDeletar.set(this, {});
|
||||
__classPrivateFieldSet(this, _ClassPilao_produto, produto, "f");
|
||||
__classPrivateFieldSet(this, _ClassPilao_conta, conta, "f");
|
||||
__classPrivateFieldSet(this, _ClassPilao_emDesenvolvimento, emDesenvolvimento, "f");
|
||||
__classPrivateFieldSet(this, _ClassPilao_ver_log, ver_log, "f");
|
||||
}
|
||||
rotaEnviarRegistros() {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_gerarUrl).call(this, "enviar-registros");
|
||||
}
|
||||
rotaDeletarRegistro() {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_gerarUrl).call(this, "deletar-registros");
|
||||
}
|
||||
rotaConsultarSerie(tipoVisao) {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_gerarUrl).call(this, "consultar-serie", tipoVisao);
|
||||
}
|
||||
rotaIframeSerie(tipoVisao) {
|
||||
const rota = `${PREFIXO_PILAO}/consultar-serie/${__classPrivateFieldGet(this, _ClassPilao_produto, "f")}/${__classPrivateFieldGet(this, _ClassPilao_conta, "f")}/${tipoVisao}`;
|
||||
const url = `${this.baseUrlSite}${rota}`;
|
||||
return { rota, url };
|
||||
}
|
||||
rotaFuncaoApi(funcao) {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_gerarUrl).call(this, "API", funcao);
|
||||
}
|
||||
async consultarApi(funcao, parametros) {
|
||||
try {
|
||||
const response = await crossFetch(this.rotaFuncaoApi(funcao).url, {
|
||||
body: JSON.stringify(parametros),
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
});
|
||||
const texto = await response.text();
|
||||
try {
|
||||
const json = JSON.parse(texto);
|
||||
return json;
|
||||
}
|
||||
catch {
|
||||
return respostaComuns.erro("Consulta não retornou json válido", [texto]);
|
||||
}
|
||||
}
|
||||
catch (erro) {
|
||||
console.error(erro);
|
||||
return respostaComuns.erroInterno({
|
||||
erro,
|
||||
local: nomeVariavel({ ClassPilao }),
|
||||
});
|
||||
}
|
||||
}
|
||||
get baseUrlApi() {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_emDesenvolvimento, "f")
|
||||
? "http://localhost:5080"
|
||||
: "https://carro-de-boi.idz.one";
|
||||
}
|
||||
get baseUrlSite() {
|
||||
return __classPrivateFieldGet(this, _ClassPilao_emDesenvolvimento, "f")
|
||||
? "http://localhost:5081"
|
||||
: "https://carro-de-boi.idz.one";
|
||||
}
|
||||
validarCliente(_) {
|
||||
if (!_?.conta)
|
||||
return respostaComuns.erro("Conta não informada");
|
||||
if (!_?.produto)
|
||||
return respostaComuns.erro("Produto não informado");
|
||||
return respostaComuns.valor(_);
|
||||
}
|
||||
adicionarRegistroParaEnviar(tabela, ...registros) {
|
||||
__classPrivateFieldGet(this, _ClassPilao_registrosParaEnvio, "f")[tabela] = [
|
||||
...(__classPrivateFieldGet(this, _ClassPilao_registrosParaEnvio, "f")[tabela] || []),
|
||||
...registros,
|
||||
];
|
||||
return this;
|
||||
}
|
||||
adicionarCodigoParaDeletar(tabela, ...codigos) {
|
||||
__classPrivateFieldGet(this, _ClassPilao_codigosParaDeletar, "f")[tabela] = [
|
||||
...(__classPrivateFieldGet(this, _ClassPilao_codigosParaDeletar, "f")[tabela] || []),
|
||||
...codigos,
|
||||
];
|
||||
return this;
|
||||
}
|
||||
async processarRegistros(url, registros, tabela, acao) {
|
||||
const tamanhoBlocos = 1000;
|
||||
while (registros.length > 0) {
|
||||
const bloco = registros
|
||||
.splice(0, tamanhoBlocos)
|
||||
.map((r) => Object.fromEntries(Object.entries(r).map(([k, v]) => [k, v === undefined ? null : v])));
|
||||
const resp = await crossFetch(url, {
|
||||
method: "POST",
|
||||
body: JSON.stringify({ tabela, registros: bloco }),
|
||||
headers: { "Content-Type": "application/json" },
|
||||
})
|
||||
.then(async (r) => {
|
||||
const texto = await r.text();
|
||||
try {
|
||||
const json = JSON.parse(texto);
|
||||
return json;
|
||||
}
|
||||
catch {
|
||||
return respostaComuns.erro("Consulta não retornou json válido", [
|
||||
texto,
|
||||
]);
|
||||
}
|
||||
})
|
||||
.catch((e) => respostaComuns.erro(`Erro ao ${acao} registros`, [e.message]));
|
||||
if (resp.eErro)
|
||||
return resp;
|
||||
}
|
||||
return respostaComuns.valor(true);
|
||||
}
|
||||
async salvarRegistros() {
|
||||
const re = await __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_salvarEnviarRegistros).call(this);
|
||||
if (re.eErro)
|
||||
return re;
|
||||
const rd = await __classPrivateFieldGet(this, _ClassPilao_instances, "m", _ClassPilao_salvarDeletarRegistros).call(this);
|
||||
if (rd.eErro)
|
||||
return rd;
|
||||
return respostaComuns.valor(true);
|
||||
}
|
||||
serieConsultar(tipoVisao, parametros) {
|
||||
const dados = async () => {
|
||||
const url = this.rotaConsultarSerie(tipoVisao).url;
|
||||
const resp = await crossFetch(url.toString(), {
|
||||
method: "POST",
|
||||
body: JSON.stringify(parametros),
|
||||
headers: { "Content-Type": "application/json" },
|
||||
})
|
||||
.then(async (r) => {
|
||||
const texto = await r.text();
|
||||
try {
|
||||
const json = JSON.parse(texto);
|
||||
return json;
|
||||
}
|
||||
catch {
|
||||
return respostaComuns.erro("Consulta não retornou json válido", [
|
||||
texto,
|
||||
]);
|
||||
}
|
||||
})
|
||||
.catch((e) => respostaComuns.erro("Erro ao enviar registros", [e.message]));
|
||||
if (__classPrivateFieldGet(this, _ClassPilao_ver_log, "f"))
|
||||
console.log(`[PILÃO]: buscar dados de "${JSON.stringify(parametros)}" para "${url}".`);
|
||||
return resp;
|
||||
};
|
||||
const url = () => {
|
||||
const vUrl = this.rotaIframeSerie(tipoVisao).url;
|
||||
const serie = encodeURIComponent(JSON.stringify(parametros, null, 2));
|
||||
if (__classPrivateFieldGet(this, _ClassPilao_ver_log, "f"))
|
||||
console.log(`[PILÃO]: Serie Consultar url de "${JSON.stringify(serie)}" para "${vUrl}".`);
|
||||
return `${vUrl}?serie=${serie}`;
|
||||
};
|
||||
return {
|
||||
dados,
|
||||
url,
|
||||
};
|
||||
}
|
||||
urlLaboratorio() {
|
||||
const rota = `${PREFIXO_PILAO}/laboratório/${__classPrivateFieldGet(this, _ClassPilao_produto, "f")}/${__classPrivateFieldGet(this, _ClassPilao_conta, "f")}`;
|
||||
const url = `${this.baseUrlSite}${rota}`;
|
||||
return { rota, url };
|
||||
}
|
||||
}
|
||||
_ClassPilao_produto = new WeakMap(), _ClassPilao_conta = new WeakMap(), _ClassPilao_emDesenvolvimento = new WeakMap(), _ClassPilao_ver_log = new WeakMap(), _ClassPilao_registrosParaEnvio = new WeakMap(), _ClassPilao_codigosParaDeletar = new WeakMap(), _ClassPilao_instances = new WeakSet(), _ClassPilao_gerarUrl = function _ClassPilao_gerarUrl(acao, extraPath) {
|
||||
const rota = `${PREFIXO_PILAO}/api/${acao}/${__classPrivateFieldGet(this, _ClassPilao_produto, "f")}/${__classPrivateFieldGet(this, _ClassPilao_conta, "f")}${extraPath ? `/${extraPath}` : ""}`;
|
||||
const url = `${this.baseUrlApi}${rota}`;
|
||||
return { rota, url };
|
||||
}, _ClassPilao_salvarEnviarRegistros = async function _ClassPilao_salvarEnviarRegistros() {
|
||||
for (const tabela of Object.keys(__classPrivateFieldGet(this, _ClassPilao_registrosParaEnvio, "f"))) {
|
||||
const registros = __classPrivateFieldGet(this, _ClassPilao_registrosParaEnvio, "f")[tabela] || [];
|
||||
const url = this.rotaEnviarRegistros().url;
|
||||
if (__classPrivateFieldGet(this, _ClassPilao_ver_log, "f"))
|
||||
console.log(`[PILÃO]: Enviando ${registros.length} registros na tabela "${tabela}" para "${url}".`);
|
||||
const resp = await this.processarRegistros(url, registros, tabela, "enviar");
|
||||
if (resp.eErro)
|
||||
return resp;
|
||||
__classPrivateFieldGet(this, _ClassPilao_registrosParaEnvio, "f")[tabela] = [];
|
||||
}
|
||||
return respostaComuns.valor(true);
|
||||
}, _ClassPilao_salvarDeletarRegistros = async function _ClassPilao_salvarDeletarRegistros() {
|
||||
for (const tabela of Object.keys(__classPrivateFieldGet(this, _ClassPilao_codigosParaDeletar, "f"))) {
|
||||
const codigos = [...(__classPrivateFieldGet(this, _ClassPilao_codigosParaDeletar, "f")[tabela] || [])];
|
||||
const url = this.rotaDeletarRegistro().url;
|
||||
const resp = await this.processarRegistros(url, codigos, tabela, "deletar");
|
||||
if (resp.eErro)
|
||||
return resp;
|
||||
}
|
||||
return respostaComuns.valor(true);
|
||||
};
|
||||
export const Pilao = (_) => new ClassPilao(_);
|
||||
30
dist-import/pilao-de-dados/Pilao/pilao-api.d.ts
vendored
30
dist-import/pilao-de-dados/Pilao/pilao-api.d.ts
vendored
|
|
@ -1,30 +0,0 @@
|
|||
import type { z } from "zod";
|
||||
import type { zp_registrar_base_dados } from "../_enviar_registros";
|
||||
/**
|
||||
* {
|
||||
* 'rota':{
|
||||
* pr:{}// paramentros de entrada
|
||||
* rs:{}// resposta
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
export type tipo_pilao_api = {
|
||||
/** retorna da data e hora do servido em formato iso */
|
||||
estado_servidor: {
|
||||
pr: {};
|
||||
rs: {
|
||||
data_hora: string;
|
||||
};
|
||||
};
|
||||
tabelas: {
|
||||
pr: {};
|
||||
rs: z.infer<typeof zp_registrar_base_dados>[];
|
||||
};
|
||||
unicos: {
|
||||
pr: {
|
||||
tabela: string;
|
||||
coluna: string;
|
||||
};
|
||||
rs: any[];
|
||||
};
|
||||
};
|
||||
|
|
@ -1 +0,0 @@
|
|||
export {};
|
||||
11
dist-import/pilao-de-dados/Pilao/tipagem.d.ts
vendored
11
dist-import/pilao-de-dados/Pilao/tipagem.d.ts
vendored
|
|
@ -1,11 +0,0 @@
|
|||
import type { z } from "zod";
|
||||
import type { visoes_pilao } from "../visoes/listaDeVisoes";
|
||||
export type tipoConstrutorPilao = {
|
||||
produto: string;
|
||||
conta: string;
|
||||
};
|
||||
export type tipoRetornoSerieconsulta<T extends keyof typeof visoes_pilao> = {
|
||||
registros: any[];
|
||||
legenda: string;
|
||||
serie: z.infer<(typeof visoes_pilao)[T]>;
|
||||
};
|
||||
|
|
@ -1 +0,0 @@
|
|||
export {};
|
||||
|
|
@ -1,51 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const zp_registrar_base_dados: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colunas: z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
tipo: z.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}>, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}>;
|
||||
export declare const zp_enviar_registros: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
registros: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodObject<{
|
||||
valor: z.ZodAny;
|
||||
tipo: z.ZodNullable<z.ZodOptional<z.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>>>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>>, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}>;
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
import { z } from "zod";
|
||||
import { z_tipos_dados_registro } from "./variaveis";
|
||||
export const zp_registrar_base_dados = z.object({
|
||||
tabela: z.string(),
|
||||
colunas: z.array(z.object({
|
||||
coluna: z.string(),
|
||||
tipo: z_tipos_dados_registro,
|
||||
})),
|
||||
});
|
||||
//enviar registros para base de dados
|
||||
export const zp_enviar_registros = z.object({
|
||||
tabela: z.string(),
|
||||
registros: z.array(z.record(z.string(), z.object({
|
||||
valor: z.any(),
|
||||
tipo: z_tipos_dados_registro.optional().nullable(),
|
||||
}))),
|
||||
});
|
||||
14
dist-import/pilao-de-dados/_serie_consultar.d.ts
vendored
14
dist-import/pilao-de-dados/_serie_consultar.d.ts
vendored
|
|
@ -1,14 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const z_filtro: z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>;
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
import { z } from "zod";
|
||||
import { operadores_pilao } from "./variaveis";
|
||||
export const z_filtro = z.object({
|
||||
coluna: z.string(),
|
||||
valor: z.any(),
|
||||
operador: operadores_pilao,
|
||||
});
|
||||
441
dist-import/pilao-de-dados/index.d.ts
vendored
441
dist-import/pilao-de-dados/index.d.ts
vendored
|
|
@ -1,441 +0,0 @@
|
|||
export { PREFIXO_PILAO, urlPilao } from "./variaveis";
|
||||
export * from "./Pilao";
|
||||
export * from "./Pilao/pilao-api";
|
||||
export * from "./Pilao/tipagem";
|
||||
export declare const pPilao: {
|
||||
extruturas_de_campos: {
|
||||
z_contagem_em_barra_vertical: import("./visoes/tipagem").tipo_estrutura_visao_grafico<"z_contagem_em_barra_vertical">;
|
||||
z_contagem_em_pizza: import("./visoes/tipagem").tipo_estrutura_visao_grafico<"z_contagem_em_pizza">;
|
||||
z_tabela: import("./visoes/tipagem").tipo_estrutura_visao_grafico<"z_tabela">;
|
||||
z_soma_em_barra_vertical: import("./visoes/tipagem").tipo_estrutura_visao_grafico<"z_soma_em_barra_vertical">;
|
||||
};
|
||||
z_contagem_em_barra_vertical: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colanuEixoX: import("zod").ZodString;
|
||||
colunaAgrupamento: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
classes: import("zod").ZodString;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_tabela: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colunas: import("zod").ZodArray<import("zod").ZodString, "many">;
|
||||
coluna_ordem: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
direcao_ordem: import("zod").ZodOptional<import("zod").ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colanuEixoX: import("zod").ZodString;
|
||||
colunaSoma: import("zod").ZodString;
|
||||
unidadeSoma: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
colunaAgrupamento: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
zp_deletar_registros: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
codigos: import("zod").ZodArray<import("zod").ZodString, "many">;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}>;
|
||||
zp_registrar_base_dados: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colunas: import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
tipo: import("zod").ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}, {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}>, "many">;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: {
|
||||
coluna: string;
|
||||
tipo: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data";
|
||||
}[];
|
||||
}>;
|
||||
z_tipos_dados_registro: import("zod").ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
zp_enviar_registros: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
registros: import("zod").ZodArray<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodObject<{
|
||||
valor: import("zod").ZodAny;
|
||||
tipo: import("zod").ZodNullable<import("zod").ZodOptional<import("zod").ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>>>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>>, "many">;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}, {
|
||||
tabela: string;
|
||||
registros: Record<string, {
|
||||
valor?: any;
|
||||
tipo?: "texto" | "numero" | "confirmacao" | "lista_texto" | "lista_numero" | "lista_mes" | "lista_data" | "mes" | "data" | null | undefined;
|
||||
}>[];
|
||||
}>;
|
||||
zp_produto_conta: import("zod").ZodObject<{
|
||||
produto: import("zod").ZodString;
|
||||
conta: import("zod").ZodString;
|
||||
emDesenvolvimento: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
||||
ver_log: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}>;
|
||||
validarZ: <T>(zodType: import("zod").ZodType<T, any>, objeto: any, mensagem: string) => import("p-respostas").tipoRespostaErro | import("p-respostas").tipoRespostaSucesso<T>;
|
||||
operadores_pilao: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
operadores_permitidos_por_tipo: {
|
||||
texto: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
numero: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
confirmacao: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_texto: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_numero: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_mes: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
lista_data: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
mes: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
data: ("=" | "!=" | ">" | "<" | ">=" | "<=" | "∩")[];
|
||||
};
|
||||
z_filtro: import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>;
|
||||
visoes_pilao: {
|
||||
z_contagem_em_barra_vertical: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colanuEixoX: import("zod").ZodString;
|
||||
colunaAgrupamento: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
classes: import("zod").ZodString;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_tabela: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colunas: import("zod").ZodArray<import("zod").ZodString, "many">;
|
||||
coluna_ordem: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
direcao_ordem: import("zod").ZodOptional<import("zod").ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: import("zod").ZodObject<{
|
||||
tabela: import("zod").ZodString;
|
||||
colanuEixoX: import("zod").ZodString;
|
||||
colunaSoma: import("zod").ZodString;
|
||||
unidadeSoma: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
colunaAgrupamento: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
||||
filtros: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
||||
coluna: import("zod").ZodString;
|
||||
valor: import("zod").ZodAny;
|
||||
operador: import("zod").ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: import("zod").ZodOptional<import("zod").ZodString>;
|
||||
}, "strip", import("zod").ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
};
|
||||
};
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
export { PREFIXO_PILAO, urlPilao } from "./variaveis";
|
||||
import { zp_enviar_registros, zp_registrar_base_dados, } from "./_enviar_registros";
|
||||
import { operadores_permitidos_por_tipo, operadores_pilao, validarZ, z_tipos_dados_registro, zp_deletar_registros, zp_produto_conta, } from "./variaveis";
|
||||
export * from "./Pilao";
|
||||
export * from "./Pilao/pilao-api";
|
||||
export * from "./Pilao/tipagem";
|
||||
import { z_filtro } from "./_serie_consultar";
|
||||
import { extruturas_de_campos } from "./visoes";
|
||||
import { visoes_pilao } from "./visoes/listaDeVisoes";
|
||||
export const pPilao = {
|
||||
zp_deletar_registros,
|
||||
zp_registrar_base_dados,
|
||||
z_tipos_dados_registro,
|
||||
zp_enviar_registros,
|
||||
zp_produto_conta,
|
||||
validarZ,
|
||||
operadores_pilao,
|
||||
operadores_permitidos_por_tipo,
|
||||
z_filtro,
|
||||
visoes_pilao,
|
||||
...visoes_pilao,
|
||||
extruturas_de_campos,
|
||||
};
|
||||
46
dist-import/pilao-de-dados/variaveis.d.ts
vendored
46
dist-import/pilao-de-dados/variaveis.d.ts
vendored
|
|
@ -1,46 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const zp_deletar_registros: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
codigos: z.ZodArray<z.ZodString, "many">;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}, {
|
||||
tabela: string;
|
||||
codigos: string[];
|
||||
}>;
|
||||
export declare const zAmbiente: z.ZodEnum<["desenvolvimento", "producao"]>;
|
||||
export declare const PREFIXO_PILAO = "/pilao-de-dados";
|
||||
export declare const validarZ: <T>(zodType: z.ZodType<T, any>, objeto: any, mensagem: string) => import("p-respostas").tipoRespostaErro | import("p-respostas").tipoRespostaSucesso<T>;
|
||||
export declare const zp_produto_conta: z.ZodObject<{
|
||||
produto: z.ZodString;
|
||||
conta: z.ZodString;
|
||||
emDesenvolvimento: z.ZodOptional<z.ZodBoolean>;
|
||||
ver_log: z.ZodOptional<z.ZodBoolean>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}, {
|
||||
conta: string;
|
||||
produto: string;
|
||||
emDesenvolvimento?: boolean | undefined;
|
||||
ver_log?: boolean | undefined;
|
||||
}>;
|
||||
export declare const z_tipos_dados_registro: z.ZodEnum<["texto", "numero", "confirmacao", "lista_texto", "lista_numero", "lista_mes", "lista_data", "mes", "data"]>;
|
||||
export declare const operadores_pilao: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
export declare const operadores_permitidos_por_tipo: {
|
||||
[key in z.infer<typeof z_tipos_dados_registro>]: z.infer<typeof operadores_pilao>[];
|
||||
};
|
||||
export declare const z_validar_colunna_base_dados: {
|
||||
texto: z.ZodNullable<z.ZodString>;
|
||||
numero: z.ZodNullable<z.ZodNumber>;
|
||||
confirmacao: z.ZodNullable<z.ZodBoolean>;
|
||||
lista_texto: z.ZodNullable<z.ZodArray<z.ZodString, "many">>;
|
||||
lista_numero: z.ZodNullable<z.ZodArray<z.ZodNumber, "many">>;
|
||||
};
|
||||
export declare const urlPilao: (emDesenvolvimento?: boolean | null | undefined) => {
|
||||
api: string;
|
||||
site: string;
|
||||
};
|
||||
|
|
@ -1,59 +0,0 @@
|
|||
import { respostaComuns } from "p-respostas";
|
||||
import { z } from "zod";
|
||||
export const zp_deletar_registros = z.object({
|
||||
tabela: z.string(),
|
||||
codigos: z.array(z.string()),
|
||||
});
|
||||
export const zAmbiente = z.enum(["desenvolvimento", "producao"]);
|
||||
export const PREFIXO_PILAO = "/pilao-de-dados";
|
||||
export const validarZ = (zodType, objeto, mensagem) => {
|
||||
const validar = zodType.safeParse(objeto);
|
||||
if (!validar.success) {
|
||||
return respostaComuns.erro(mensagem, validar.error.errors.map((e) => `${e.path} ${e.message}`));
|
||||
}
|
||||
return respostaComuns.valor(validar.data);
|
||||
};
|
||||
export const zp_produto_conta = z.object({
|
||||
produto: z.string(),
|
||||
conta: z.string(),
|
||||
emDesenvolvimento: z.boolean().optional(),
|
||||
ver_log: z.boolean().optional(),
|
||||
});
|
||||
export const z_tipos_dados_registro = z.enum([
|
||||
"texto",
|
||||
"numero",
|
||||
"confirmacao",
|
||||
"lista_texto",
|
||||
"lista_numero",
|
||||
"lista_mes",
|
||||
"lista_data",
|
||||
"mes",
|
||||
"data",
|
||||
]);
|
||||
export const operadores_pilao = z.enum(["=", "!=", ">", "<", ">=", "<=", "∩"]);
|
||||
export const operadores_permitidos_por_tipo = {
|
||||
confirmacao: ["=", "!="],
|
||||
data: ["=", "!=", ">", "<", ">=", "<="],
|
||||
lista_numero: ["∩"],
|
||||
lista_texto: ["∩"],
|
||||
lista_mes: ["∩"],
|
||||
lista_data: ["∩"],
|
||||
mes: ["=", "!=", ">", "<", ">=", "<="],
|
||||
numero: ["=", "!=", ">", "<", ">=", "<="],
|
||||
texto: ["=", "!="],
|
||||
};
|
||||
export const z_validar_colunna_base_dados = {
|
||||
texto: z.string().nullable(),
|
||||
numero: z.number().nullable(),
|
||||
confirmacao: z.boolean().nullable(),
|
||||
lista_texto: z.array(z.string()).nullable(),
|
||||
lista_numero: z.array(z.number()).nullable(),
|
||||
};
|
||||
export const urlPilao = (emDesenvolvimento) => ({
|
||||
api: (emDesenvolvimento
|
||||
? "http://127.0.0.1:5080"
|
||||
: "https://carro-de-boi.idz.one") + PREFIXO_PILAO,
|
||||
site: (emDesenvolvimento
|
||||
? "http://127.0.0.1:5081"
|
||||
: "https://carro-de-boi.idz.one") + PREFIXO_PILAO,
|
||||
});
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
import type { visoes_pilao } from "../listaDeVisoes";
|
||||
import type { tipo_estrutura_visao_grafico } from "../tipagem";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export declare const extruturas_de_campos: {
|
||||
[T in keyof typeof visoes_pilao]: tipo_estrutura_visao_grafico<T>;
|
||||
};
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
import { z_contagem_em_barra_vertical } from "./z_contagem_em_barra_vertical";
|
||||
import { z_contagem_em_pizza } from "./z_contagem_em_pizza";
|
||||
import { z_soma_em_barra_vertical } from "./z_soma_em_barra_vertical";
|
||||
import { z_tabela } from "./z_tabela";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export const extruturas_de_campos = {
|
||||
z_contagem_em_barra_vertical,
|
||||
z_contagem_em_pizza,
|
||||
z_soma_em_barra_vertical,
|
||||
z_tabela,
|
||||
};
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
import type { tipo_estrutura_visao_grafico } from "../tipagem";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export declare const z_contagem_em_barra_vertical: tipo_estrutura_visao_grafico<"z_contagem_em_barra_vertical">;
|
||||
|
|
@ -1,37 +0,0 @@
|
|||
// usar describe para definir o tipo de campo para render do componente
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export const z_contagem_em_barra_vertical = {
|
||||
visao: "z_contagem_em_barra_vertical",
|
||||
rotulo: "Contagem em Barra Vertical",
|
||||
tabela: ({ tabela }) => tabela,
|
||||
descricao: ({ tabela, descricao_pelo_usuario, colanuEixoX, filtros, colunaAgrupamento, }) => {
|
||||
if (String(descricao_pelo_usuario || "").trim())
|
||||
return String(descricao_pelo_usuario || "").trim();
|
||||
return `Contagem de ${tabela} por ${colanuEixoX}${!filtros?.length
|
||||
? ""
|
||||
: `, quando ${filtros
|
||||
.map(({ coluna, operador, valor }) => `${coluna} ${operador} ${valor}`)
|
||||
.join(", ")}`}${!colunaAgrupamento?.length
|
||||
? ""
|
||||
: `, agrupado por ${colunaAgrupamento.join(", ")}`}.`;
|
||||
},
|
||||
campos: {
|
||||
tabela: { rotulo: "Tabela", tipo_campo: "tabela", order: 1 },
|
||||
colanuEixoX: {
|
||||
rotulo: "Coluna do Eixo X",
|
||||
tipo_campo: "coluna",
|
||||
order: 2,
|
||||
},
|
||||
colunaAgrupamento: {
|
||||
rotulo: "Colunas de Agrupamento",
|
||||
tipo_campo: "lista_colunas",
|
||||
order: 3,
|
||||
},
|
||||
descricao_pelo_usuario: {
|
||||
rotulo: "Descrição (opcional)",
|
||||
tipo_campo: "texto",
|
||||
order: 4,
|
||||
},
|
||||
filtros: { rotulo: "Filtros", tipo_campo: "lista_filtros", order: 5 },
|
||||
},
|
||||
};
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
import type { tipo_estrutura_visao_grafico } from "../tipagem";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export declare const z_contagem_em_pizza: tipo_estrutura_visao_grafico<"z_contagem_em_pizza">;
|
||||
|
|
@ -1,26 +0,0 @@
|
|||
// usar describe para definir o tipo de campo para render do componente
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export const z_contagem_em_pizza = {
|
||||
visao: "z_contagem_em_pizza",
|
||||
rotulo: "Contagem em Pizza",
|
||||
tabela: ({ tabela }) => tabela,
|
||||
descricao: ({ tabela, descricao_pelo_usuario, classes, filtros }) => {
|
||||
if (String(descricao_pelo_usuario || "").trim())
|
||||
return String(descricao_pelo_usuario || "").trim();
|
||||
return `Contagem de ${tabela} por ${classes}${!filtros?.length
|
||||
? ""
|
||||
: `, quando ${filtros
|
||||
.map(({ coluna, operador, valor }) => `${coluna} ${operador} ${valor}`)
|
||||
.join(", ")}`}.`;
|
||||
},
|
||||
campos: {
|
||||
tabela: { rotulo: "Tabela", tipo_campo: "tabela", order: 1 },
|
||||
classes: { rotulo: "Classes", tipo_campo: "coluna", order: 2 },
|
||||
descricao_pelo_usuario: {
|
||||
rotulo: "Descrição (opcional)",
|
||||
tipo_campo: "texto",
|
||||
order: 3,
|
||||
},
|
||||
filtros: { rotulo: "Filtros", tipo_campo: "lista_filtros", order: 4 },
|
||||
},
|
||||
};
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
import type { tipo_estrutura_visao_grafico } from "../tipagem";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export declare const z_soma_em_barra_vertical: tipo_estrutura_visao_grafico<"z_soma_em_barra_vertical">;
|
||||
|
|
@ -1,47 +0,0 @@
|
|||
// usar describe para definir o tipo de campo para render do componente
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export const z_soma_em_barra_vertical = {
|
||||
visao: "z_soma_em_barra_vertical",
|
||||
rotulo: "Soma em Barra Vertical",
|
||||
tabela: ({ tabela }) => tabela,
|
||||
descricao: ({ descricao_pelo_usuario, colanuEixoX, filtros, colunaAgrupamento, colunaSoma, }) => {
|
||||
if (String(descricao_pelo_usuario || "").trim())
|
||||
return String(descricao_pelo_usuario || "").trim();
|
||||
return `Soma de ${colunaSoma} por ${colanuEixoX}${!filtros?.length
|
||||
? ""
|
||||
: `, quando ${filtros
|
||||
.map(({ coluna, operador, valor }) => `${coluna} ${operador} ${valor}`)
|
||||
.join(", ")}`}${!colunaAgrupamento?.length
|
||||
? ""
|
||||
: `, agrupado por ${colunaAgrupamento.join(", ")}`}.`;
|
||||
},
|
||||
campos: {
|
||||
tabela: { rotulo: "Tabela", tipo_campo: "tabela", order: 1 },
|
||||
colunaSoma: {
|
||||
rotulo: "Coluna de Somatória",
|
||||
tipo_campo: "coluna",
|
||||
order: 2,
|
||||
},
|
||||
unidadeSoma: {
|
||||
rotulo: "Unidade de Somatória",
|
||||
tipo_campo: "texto",
|
||||
order: 3,
|
||||
},
|
||||
colanuEixoX: {
|
||||
rotulo: "Coluna do Eixo X",
|
||||
tipo_campo: "coluna",
|
||||
order: 4,
|
||||
},
|
||||
colunaAgrupamento: {
|
||||
rotulo: "Colunas de Agrupamento",
|
||||
tipo_campo: "lista_colunas",
|
||||
order: 5,
|
||||
},
|
||||
descricao_pelo_usuario: {
|
||||
rotulo: "Descrição (opcional)",
|
||||
tipo_campo: "texto",
|
||||
order: 6,
|
||||
},
|
||||
filtros: { rotulo: "Filtros", tipo_campo: "lista_filtros", order: 5 },
|
||||
},
|
||||
};
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
import type { tipo_estrutura_visao_grafico } from "../tipagem";
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export declare const z_tabela: tipo_estrutura_visao_grafico<"z_tabela">;
|
||||
|
|
@ -1,36 +0,0 @@
|
|||
// usar describe para definir o tipo de campo para render do componente
|
||||
/** Cria a estrutura de campos para insersão de dados */
|
||||
export const z_tabela = {
|
||||
visao: "z_tabela",
|
||||
rotulo: "Tabela",
|
||||
tabela: ({ tabela }) => tabela,
|
||||
descricao: ({ tabela, descricao_pelo_usuario, filtros }) => {
|
||||
if (String(descricao_pelo_usuario || "").trim())
|
||||
return String(descricao_pelo_usuario || "").trim();
|
||||
return `Consulta na ${tabela} ${!filtros?.length
|
||||
? ""
|
||||
: `, quando ${filtros
|
||||
.map(({ coluna, operador, valor }) => `${coluna} ${operador} ${valor}`)
|
||||
.join(", ")}`}.`;
|
||||
},
|
||||
campos: {
|
||||
tabela: { rotulo: "Tabela", tipo_campo: "tabela", order: 1 },
|
||||
colunas: { rotulo: "Colunas", tipo_campo: "lista_colunas", order: 2 },
|
||||
descricao_pelo_usuario: {
|
||||
rotulo: "Descrição (opcional)",
|
||||
tipo_campo: "texto",
|
||||
order: 3,
|
||||
},
|
||||
coluna_ordem: {
|
||||
rotulo: "Coluna de Ordem",
|
||||
tipo_campo: "coluna",
|
||||
order: 4,
|
||||
},
|
||||
direcao_ordem: {
|
||||
rotulo: "Direção de Ordem",
|
||||
tipo_campo: "ordem",
|
||||
order: 5,
|
||||
},
|
||||
filtros: { rotulo: "Filtros", tipo_campo: "lista_filtros", order: 6 },
|
||||
},
|
||||
};
|
||||
1
dist-import/pilao-de-dados/visoes/index.d.ts
vendored
1
dist-import/pilao-de-dados/visoes/index.d.ts
vendored
|
|
@ -1 +0,0 @@
|
|||
export * from "./estrutura_de_campos";
|
||||
|
|
@ -1 +0,0 @@
|
|||
export * from "./estrutura_de_campos";
|
||||
327
dist-import/pilao-de-dados/visoes/listaDeVisoes.d.ts
vendored
327
dist-import/pilao-de-dados/visoes/listaDeVisoes.d.ts
vendored
|
|
@ -1,327 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const z_contagem_em_barra_vertical: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
export declare const z_soma_em_barra_vertical: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaSoma: z.ZodString;
|
||||
unidadeSoma: z.ZodOptional<z.ZodString>;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
export declare const z_contagem_em_pizza: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
classes: z.ZodString;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
export declare const z_tabela: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colunas: z.ZodArray<z.ZodString, "many">;
|
||||
coluna_ordem: z.ZodOptional<z.ZodString>;
|
||||
direcao_ordem: z.ZodOptional<z.ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
export declare const visoes_pilao: {
|
||||
z_contagem_em_barra_vertical: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_contagem_em_pizza: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
classes: z.ZodString;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
classes: string;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
}>;
|
||||
z_tabela: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colunas: z.ZodArray<z.ZodString, "many">;
|
||||
coluna_ordem: z.ZodOptional<z.ZodString>;
|
||||
direcao_ordem: z.ZodOptional<z.ZodEnum<["asc", "desc", "1", "-1"]>>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colunas: string[];
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
coluna_ordem?: string | undefined;
|
||||
direcao_ordem?: "1" | "asc" | "desc" | "-1" | undefined;
|
||||
}>;
|
||||
z_soma_em_barra_vertical: z.ZodObject<{
|
||||
tabela: z.ZodString;
|
||||
colanuEixoX: z.ZodString;
|
||||
colunaSoma: z.ZodString;
|
||||
unidadeSoma: z.ZodOptional<z.ZodString>;
|
||||
colunaAgrupamento: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
||||
filtros: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
||||
coluna: z.ZodString;
|
||||
valor: z.ZodAny;
|
||||
operador: z.ZodEnum<["=", "!=", ">", "<", ">=", "<=", "∩"]>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}, {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}>, "many">>;
|
||||
descricao_pelo_usuario: z.ZodOptional<z.ZodString>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}, {
|
||||
tabela: string;
|
||||
colanuEixoX: string;
|
||||
colunaSoma: string;
|
||||
colunaAgrupamento?: string[] | undefined;
|
||||
filtros?: {
|
||||
coluna: string;
|
||||
operador: "=" | "!=" | ">" | "<" | ">=" | "<=" | "∩";
|
||||
valor?: any;
|
||||
}[] | undefined;
|
||||
descricao_pelo_usuario?: string | undefined;
|
||||
unidadeSoma?: string | undefined;
|
||||
}>;
|
||||
};
|
||||
|
|
@ -1,38 +0,0 @@
|
|||
import { z } from "zod";
|
||||
import { z_filtro } from "../_serie_consultar";
|
||||
export const z_contagem_em_barra_vertical = z.object({
|
||||
tabela: z.string(),
|
||||
colanuEixoX: z.string(),
|
||||
colunaAgrupamento: z.string().array().optional(),
|
||||
filtros: z_filtro.array().optional(),
|
||||
descricao_pelo_usuario: z.string().optional(),
|
||||
});
|
||||
export const z_soma_em_barra_vertical = z.object({
|
||||
tabela: z.string(),
|
||||
colanuEixoX: z.string(),
|
||||
colunaSoma: z.string(),
|
||||
unidadeSoma: z.string().optional(),
|
||||
colunaAgrupamento: z.string().array().optional(),
|
||||
filtros: z_filtro.array().optional(),
|
||||
descricao_pelo_usuario: z.string().optional(),
|
||||
});
|
||||
export const z_contagem_em_pizza = z.object({
|
||||
tabela: z.string(),
|
||||
classes: z.string(),
|
||||
filtros: z_filtro.array().optional(),
|
||||
descricao_pelo_usuario: z.string().optional(),
|
||||
});
|
||||
export const z_tabela = z.object({
|
||||
tabela: z.string(),
|
||||
colunas: z.string().array(),
|
||||
coluna_ordem: z.string().optional(),
|
||||
direcao_ordem: z.enum(["asc", "desc", "1", "-1"]).optional(),
|
||||
filtros: z_filtro.array().optional(),
|
||||
descricao_pelo_usuario: z.string().optional(),
|
||||
});
|
||||
export const visoes_pilao = {
|
||||
z_contagem_em_barra_vertical,
|
||||
z_contagem_em_pizza,
|
||||
z_tabela,
|
||||
z_soma_em_barra_vertical,
|
||||
};
|
||||
21
dist-import/pilao-de-dados/visoes/tipagem.d.ts
vendored
21
dist-import/pilao-de-dados/visoes/tipagem.d.ts
vendored
|
|
@ -1,21 +0,0 @@
|
|||
import { z } from "zod";
|
||||
import type { visoes_pilao } from "./listaDeVisoes";
|
||||
export declare const z_tipos_campos_reg_grafico: z.ZodEnum<["tabela", "coluna", "texto", "lista_colunas", "lista_filtros", "ordem"]>;
|
||||
export type tipo_estrutura_visao_grafico<T extends keyof typeof visoes_pilao> = {
|
||||
/** Nome da Visão */
|
||||
visao: T;
|
||||
/** Rotulo */
|
||||
rotulo: string;
|
||||
/** Retorna a tabela Referente ao Registro */
|
||||
tabela: (_: z.infer<(typeof visoes_pilao)[T]>) => string;
|
||||
/** Descrição */
|
||||
descricao: (_: z.infer<(typeof visoes_pilao)[T]>) => string;
|
||||
/** Lista os campos e suas configurações */
|
||||
campos: {
|
||||
[c in keyof Required<z.infer<(typeof visoes_pilao)[T]>>]: {
|
||||
rotulo: string;
|
||||
tipo_campo: z.infer<typeof z_tipos_campos_reg_grafico>;
|
||||
order: number;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export const z_tipos_campos_reg_grafico = z.enum([
|
||||
"tabela",
|
||||
"coluna",
|
||||
"texto",
|
||||
"lista_colunas",
|
||||
"lista_filtros",
|
||||
"ordem",
|
||||
]);
|
||||
2
dist-import/produtos/index.d.ts
vendored
2
dist-import/produtos/index.d.ts
vendored
|
|
@ -1,2 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const chaves_produto: z.ZodEnum<["suporte", "betha-meio-ambiente", "e-licencie-gov", "e-licencie"]>;
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export const chaves_produto = z.enum([
|
||||
"suporte",
|
||||
"betha-meio-ambiente",
|
||||
"e-licencie-gov",
|
||||
"e-licencie",
|
||||
]);
|
||||
140
dist-import/residuos/index.d.ts
vendored
140
dist-import/residuos/index.d.ts
vendored
|
|
@ -1,140 +0,0 @@
|
|||
import { z } from "zod";
|
||||
/** Estrutura que deve ser aplicada para solictação de autenticação, deve ser feito via back */
|
||||
export declare const zAuntenticacaoResiduosSolicitar: z.ZodObject<{
|
||||
codigo_token: z.ZodOptional<z.ZodString>;
|
||||
codigo_usuario: z.ZodString;
|
||||
nome_usuario: z.ZodString;
|
||||
email_usuario: z.ZodString;
|
||||
documento_usuario: z.ZodString;
|
||||
organizacao: z.ZodString;
|
||||
rotas: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
||||
url_usuarios: z.ZodString;
|
||||
url_empreendedores: z.ZodString;
|
||||
url_empreendimentos: z.ZodString;
|
||||
tipo_usuario: z.ZodString;
|
||||
sistema: z.ZodString;
|
||||
sistema_cor: z.ZodString;
|
||||
sistema_nome: z.ZodString;
|
||||
sistema_logo: z.ZodString;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
email_usuario: string;
|
||||
documento_usuario: string;
|
||||
organizacao: string;
|
||||
rotas: {};
|
||||
url_usuarios: string;
|
||||
url_empreendedores: string;
|
||||
url_empreendimentos: string;
|
||||
tipo_usuario: string;
|
||||
sistema: string;
|
||||
sistema_cor: string;
|
||||
sistema_nome: string;
|
||||
sistema_logo: string;
|
||||
codigo_token?: string | undefined;
|
||||
}, {
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
email_usuario: string;
|
||||
documento_usuario: string;
|
||||
organizacao: string;
|
||||
rotas: {};
|
||||
url_usuarios: string;
|
||||
url_empreendedores: string;
|
||||
url_empreendimentos: string;
|
||||
tipo_usuario: string;
|
||||
sistema: string;
|
||||
sistema_cor: string;
|
||||
sistema_nome: string;
|
||||
sistema_logo: string;
|
||||
codigo_token?: string | undefined;
|
||||
}>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export declare const zUsuarioSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
permicoes: z.ZodRecord<z.ZodString, z.ZodAny>;
|
||||
versao: z.ZodNumber;
|
||||
credenciais_sinir: z.ZodOptional<z.ZodObject<{
|
||||
login: z.ZodString;
|
||||
senha: z.ZodString;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
login: string;
|
||||
senha: string;
|
||||
}, {
|
||||
login: string;
|
||||
senha: string;
|
||||
}>>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
permicoes: Record<string, any>;
|
||||
versao: number;
|
||||
credenciais_sinir?: {
|
||||
login: string;
|
||||
senha: string;
|
||||
} | undefined;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
permicoes: Record<string, any>;
|
||||
versao: number;
|
||||
credenciais_sinir?: {
|
||||
login: string;
|
||||
senha: string;
|
||||
} | undefined;
|
||||
}>;
|
||||
export type tipo_zUsuarioSincronizar = z.infer<typeof zUsuarioSincronizar>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export declare const zEmpreendedorSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
versao: z.ZodNumber;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
}>;
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export declare const zEmpreendimentoSincronizar: z.ZodObject<{
|
||||
codigo: z.ZodString;
|
||||
codigo_empreendedor: z.ZodString;
|
||||
documento: z.ZodString;
|
||||
excluido: z.ZodBoolean;
|
||||
nome: z.ZodString;
|
||||
unidade_sinir: z.ZodString;
|
||||
versao: z.ZodNumber;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
codigo_empreendedor: string;
|
||||
unidade_sinir: string;
|
||||
}, {
|
||||
codigo: string;
|
||||
documento: string;
|
||||
excluido: boolean;
|
||||
nome: string;
|
||||
versao: number;
|
||||
codigo_empreendedor: string;
|
||||
unidade_sinir: string;
|
||||
}>;
|
||||
export declare const nomesSincronizacoes: z.ZodEnum<["usuarios", "empreendedores", "empreendimentos"]>;
|
||||
|
|
@ -1,72 +0,0 @@
|
|||
import { z } from "zod";
|
||||
/** Estrutura que deve ser aplicada para solictação de autenticação, deve ser feito via back */
|
||||
export const zAuntenticacaoResiduosSolicitar = z.object({
|
||||
// codigo_token: "aaaaaaaa-bbbb-1ccc-8ddd-eeeeeeeeeeee",
|
||||
codigo_token: z.string().optional(),
|
||||
//codigo_usuario: "aaaaaaaa-bbbb-1ccc-8ddd-eeeeeeeeeeef",
|
||||
codigo_usuario: z.string().uuid(),
|
||||
//nome_usuario: "Jaci Tupi",
|
||||
nome_usuario: z.string(),
|
||||
//email_usuario: "jaci@maillinator.com",
|
||||
email_usuario: z.string(),
|
||||
//documento_usuario: "111.111.111-11",
|
||||
documento_usuario: z.string(),
|
||||
//organizacao: "aaaaaaaa-bbbb-1ccc-8ddd-eeeeeeeeeeee",
|
||||
organizacao: z.string(),
|
||||
//rotas: {},
|
||||
rotas: z.object({}),
|
||||
//url_usuarios: "http://127.0.0.1:5010/residuos/exemplos/usuarios",
|
||||
url_usuarios: z.string().url(),
|
||||
//url_empreendedores: "http://127.0.0.1:5010/residuos/exemplos/empreendedores",
|
||||
url_empreendedores: z.string().url(),
|
||||
//url_empreendimentos: "http://127.0.0.1:5010/residuos/exemplos/empreendimentos",
|
||||
url_empreendimentos: z.string().url(),
|
||||
//tipo_usuario: "usuario",
|
||||
tipo_usuario: z.string(),
|
||||
//sistema: "gov-criciuma",
|
||||
sistema: z.string(),
|
||||
//sistema_cor: "#688c00",
|
||||
sistema_cor: z.string(),
|
||||
//sistema_nome: "e-licencie",
|
||||
sistema_nome: z.string(),
|
||||
//sistema_logo: "http://0.0.0.0:5020/estaticos/logos/e-licencie/branco-branco.png",
|
||||
sistema_logo: z.string(),
|
||||
});
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export const zUsuarioSincronizar = z.object({
|
||||
codigo: z.string().uuid(),
|
||||
documento: z.string(),
|
||||
excluido: z.boolean(),
|
||||
nome: z.string(),
|
||||
permicoes: z.record(z.any()),
|
||||
versao: z.number().int(),
|
||||
credenciais_sinir: z
|
||||
.object({
|
||||
login: z.string(),
|
||||
senha: z.string(),
|
||||
})
|
||||
.optional(),
|
||||
});
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export const zEmpreendedorSincronizar = z.object({
|
||||
codigo: z.string().uuid(),
|
||||
documento: z.string(),
|
||||
excluido: z.boolean(),
|
||||
nome: z.string(),
|
||||
versao: z.number().int(),
|
||||
});
|
||||
/** Tipagem usada para o processo de sincronização entre modulos */
|
||||
export const zEmpreendimentoSincronizar = z.object({
|
||||
codigo: z.string().uuid(),
|
||||
codigo_empreendedor: z.string().uuid(),
|
||||
documento: z.string(),
|
||||
excluido: z.boolean(),
|
||||
nome: z.string(),
|
||||
unidade_sinir: z.string(),
|
||||
versao: z.number().int(),
|
||||
});
|
||||
export const nomesSincronizacoes = z.enum([
|
||||
"usuarios",
|
||||
"empreendedores",
|
||||
"empreendimentos",
|
||||
]);
|
||||
38
dist-import/tokenQuipo.d.ts
vendored
38
dist-import/tokenQuipo.d.ts
vendored
|
|
@ -1,38 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const tipos_acesso_quipo: z.ZodEnum<["publico", "governo", "sociedade"]>;
|
||||
export declare const ztokenQuipo: z.ZodObject<{
|
||||
provedor: z.ZodString;
|
||||
codigo_usuario: z.ZodString;
|
||||
nome_usuario: z.ZodString;
|
||||
codigo_conta: z.ZodString;
|
||||
nome_conta: z.ZodString;
|
||||
codigo_acesso_produto: z.ZodString;
|
||||
codigo_autenticacao: z.ZodString;
|
||||
chave_produto: z.ZodEnum<["betha-meio-ambiente", "e-licencie-gov"]>;
|
||||
tipo_de_acesso: z.ZodEnum<["publico", "governo", "sociedade"]>;
|
||||
exp: z.ZodOptional<z.ZodNumber>;
|
||||
}, "strip", z.ZodTypeAny, {
|
||||
provedor: string;
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
codigo_conta: string;
|
||||
nome_conta: string;
|
||||
codigo_acesso_produto: string;
|
||||
codigo_autenticacao: string;
|
||||
chave_produto: "betha-meio-ambiente" | "e-licencie-gov";
|
||||
tipo_de_acesso: "publico" | "governo" | "sociedade";
|
||||
exp?: number | undefined;
|
||||
}, {
|
||||
provedor: string;
|
||||
codigo_usuario: string;
|
||||
nome_usuario: string;
|
||||
codigo_conta: string;
|
||||
nome_conta: string;
|
||||
codigo_acesso_produto: string;
|
||||
codigo_autenticacao: string;
|
||||
chave_produto: "betha-meio-ambiente" | "e-licencie-gov";
|
||||
tipo_de_acesso: "publico" | "governo" | "sociedade";
|
||||
exp?: number | undefined;
|
||||
}>;
|
||||
export type tipos_de_acesso_quipo = z.infer<typeof ztokenQuipo>["tipo_de_acesso"];
|
||||
export type tipoTokenQuipo = z.infer<typeof ztokenQuipo>;
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
import { z } from "zod";
|
||||
import { chaves_produto } from "./produtos";
|
||||
export const tipos_acesso_quipo = z.enum(["publico", "governo", "sociedade"]);
|
||||
export const ztokenQuipo = z.object({
|
||||
provedor: z.string(),
|
||||
codigo_usuario: z.string(),
|
||||
nome_usuario: z.string(),
|
||||
codigo_conta: z.string(),
|
||||
nome_conta: z.string(),
|
||||
codigo_acesso_produto: z.string(),
|
||||
codigo_autenticacao: z.string(),
|
||||
chave_produto: z.enum([
|
||||
chaves_produto.enum["betha-meio-ambiente"],
|
||||
chaves_produto.enum["e-licencie-gov"],
|
||||
]),
|
||||
tipo_de_acesso: tipos_acesso_quipo,
|
||||
exp: z.number().optional(),
|
||||
});
|
||||
2
dist-import/ts/ambiente.d.ts
vendored
2
dist-import/ts/ambiente.d.ts
vendored
|
|
@ -1,2 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export declare const zAmbiente: z.ZodEnum<["desenvolvimento", "producao"]>;
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
import { z } from "zod";
|
||||
export const zAmbiente = z.enum(["desenvolvimento", "producao"]);
|
||||
Loading…
Add table
Add a link
Reference in a new issue