From f2a3e604300e8999797b44e2240db6a5e29eec2e Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Fri, 9 Jan 2026 10:37:33 +0700 Subject: [PATCH 1/2] fix bug return profile id --- src/controllers/OrganizationDotnetController.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/OrganizationDotnetController.ts b/src/controllers/OrganizationDotnetController.ts index b5803029..706cb318 100644 --- a/src/controllers/OrganizationDotnetController.ts +++ b/src/controllers/OrganizationDotnetController.ts @@ -6195,7 +6195,7 @@ export class OrganizationDotnetController extends Controller { }); return { - id: item.id, + id: item.profileId, prefix: item.prefix, firstName: item.firstName, lastName: item.lastName, From 3d34a4c5ef0b325f9cf2d1e1480393c6399de9d0 Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Fri, 9 Jan 2026 10:53:32 +0700 Subject: [PATCH 2/2] migrate table posMaster --- ...7930614165-update_table_posMasterHistory.ts | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/migration/1767930614165-update_table_posMasterHistory.ts diff --git a/src/migration/1767930614165-update_table_posMasterHistory.ts b/src/migration/1767930614165-update_table_posMasterHistory.ts new file mode 100644 index 00000000..d0bec6bf --- /dev/null +++ b/src/migration/1767930614165-update_table_posMasterHistory.ts @@ -0,0 +1,18 @@ +import { MigrationInterface, QueryRunner } from "typeorm"; + +export class UpdateTablePosMasterHistory1767930614165 implements MigrationInterface { + name = 'UpdateTablePosMasterHistory1767930614165' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`profileId\` varchar(40) NULL COMMENT 'คีย์นอก(FK)ของตาราง profile'`); + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`rootDnaId\` varchar(40) NULL COMMENT 'dna ของตาราง orgRoot'`); + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`child1DnaId\` varchar(40) NULL COMMENT 'dna ของตาราง orgChild1'`); + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`child2DnaId\` varchar(40) NULL COMMENT 'dna ของตาราง orgChild2'`); + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`child3DnaId\` varchar(40) NULL COMMENT 'dna ของตาราง orgChild3'`); + await queryRunner.query(`ALTER TABLE \`posMasterHistory\` ADD \`child4DnaId\` varchar(40) NULL COMMENT 'dna ของตาราง orgChild4'`); + } + + public async down(queryRunner: QueryRunner): Promise { + } + +}