export { CoreService } from "./service/coreService"; export { RuntimeService } from "./service/runtimeService"; export { getTransaction,commitTransaction,rollbackTransaction } from "./database/knexClient"; // import loadEnv from "./utils/loadEnv"; // loadEnv(); // import { OrderBy } from "./utils/enum"; // import { CoreService } from "./service/coreService"; // import { RuntimeService } from "./service/RuntimeService"; // import { BASELINE_VERSION_ID, INSTANCE_ID, TENANT_ID, WORKPAGE_ID } from "./utils/globals"; // CoreService.getVisualizations({ params: ["Id"], filter: [], skip: 0, top: 10, instanceId: "1d59c4d7-5985-4f21-ad3c-1ac66bf14d2b", orderById: OrderBy.Ascending, zoneId: "9f77a69d-5d71-48b4-b759-93616a3d60f6"}).then(async (vizsResponse)=>{ // console.log("Vizs:", vizsResponse.nodes); // console.log("Vizs total count:", vizsResponse.totalCount); // const getWorkPageResponse = await RuntimeService.getWorkPage({ params: ["Id"], zoneId: "9f77a69d-5d71-48b4-b759-93616a3d60f6", workPageId: "70b3aa12-ce74-4b22-83c3-f6e1f801adbf", instanceId: "1d59c4d7-5985-4f21-ad3c-1ac66bf14d2b"}); // console.log("Workpage: ", getWorkPageResponse); // const resp = await RuntimeService.getWorkPageVersionDataLoader( // { // params: ["Id"], // workpageConditionsColumns: [WORKPAGE_ID, TENANT_ID, INSTANCE_ID,BASELINE_VERSION_ID], // workpageConditions: [ // ['b05b53e8-1248-4191-9bbf-9a8f7374cf99','9f77a69d-5d71-48b4-b759-93616a3d60f6', '1d59c4d7-5985-4f21-ad3c-1ac66bf14d2b', '3']] // }); // console.log("version dataloader response:", resp); // }); // CoreService.getVisualizations({params: ['Id',''],skip: 0, top: 0, orederById: '', filter: "", zoneId: ""}); // const transaction =[ // { // method: "createBusinessApp", // data: { // TenantId: '9f77a69d-5d71-48b4-b759-93616a3d60f6', // Descriptor: '{}', // DescriptorSchemaVersion: '1.0', // DescriptorSchemaId: null // } // }, // { // method: "createBusinessApp", // data: { // TenantId: '9f77a69d-5d71-48b4-b759-93616a3d60f6', // Descriptor: '{}', // DescriptorSchemaVersion: '1.0', // DescriptorSchemaId: null // } // }, // { // method: "createBusinessApp", // data: { // TenantId: null, // Descriptor: '{}', // DescriptorSchemaVersion: '1.0', // DescriptorSchemaId: null // } // } // ] // CoreService.runAsTransaction(transaction).then((response)=>{ // console.log(response); // }) // await this.runInTransaction(async trx => { // // actiavetRole // await this.runInTransaction(trx2 => { // // activate businessApp // }, trx) // }) // const dbClient:Knex = await getDatabaseClient(RUNTIME); // dbClient // .select(params) // .from('users') // .on('query', function(data:any) { // console.log(data); // }) // .on('query-error', function(error:any, obj:any) { // console.log(error); // }) // .then(function() { /* ... */ }) // .catch(function(error) { // // Same error object as the query-error event provides. // });