build
This commit is contained in:
parent
a8e9f47e7b
commit
5011034f75
20 changed files with 67 additions and 49 deletions
|
|
@ -10,7 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|||
import node_fetch from "cross-fetch";
|
||||
import { respostaComuns } from "p-respostas";
|
||||
import { z } from "zod";
|
||||
import { PREFIXO_PILAO, baseUrlPilao, z_tipo_coluna_base_dados, } from "./variaveis";
|
||||
import { urlPilao, z_tipo_coluna_base_dados, } from "./variaveis";
|
||||
export const zp_registrar_base_dados = z.object({
|
||||
tabela: z.string(),
|
||||
colunas: z.array(z.object({
|
||||
|
|
@ -27,7 +27,7 @@ export const zp_enviar_registros = z.object({
|
|||
}))),
|
||||
});
|
||||
export const enviar_registros = ({ conta, produto, emDesenvolvimento }) => (_a) => __awaiter(void 0, [_a], void 0, function* ({ registros, tabela, }) {
|
||||
const url = new URL(`${baseUrlPilao(emDesenvolvimento)}${PREFIXO_PILAO}/${Object.keys({ enviar_registros })[0]}/${produto}/${conta}`);
|
||||
const url = new URL(`${urlPilao(emDesenvolvimento).api}/${Object.keys({ enviar_registros })[0]}/${produto}/${conta}`);
|
||||
const tamanhoBlocos = 1000;
|
||||
while (registros.length > 0) {
|
||||
const bloco = registros
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue