import { MigrationInterface, QueryRunner } from "typeorm"; export class UpdateTableProfileempAddDutyTimeId1730964715891 implements MigrationInterface { name = 'UpdateTableProfileempAddDutyTimeId1730964715891' public async up(queryRunner: QueryRunner): Promise { await queryRunner.query(`ALTER TABLE \`profileEmployee\` ADD \`dutyTimeId\` varchar(40) NULL COMMENT 'ไอดีรอบลงเวลาล่าสุด'`); await queryRunner.query(`ALTER TABLE \`profileEmployee\` ADD \`dutyTimeEffectiveDate\` datetime NULL COMMENT 'รอบลงเวลาล่าสุด'`); await queryRunner.query(`ALTER TABLE \`profileEmployeeHistory\` ADD \`dutyTimeId\` varchar(40) NULL COMMENT 'ไอดีรอบลงเวลาล่าสุด'`); await queryRunner.query(`ALTER TABLE \`profileEmployeeHistory\` ADD \`dutyTimeEffectiveDate\` datetime NULL COMMENT 'รอบลงเวลาล่าสุด'`); } public async down(queryRunner: QueryRunner): Promise { await queryRunner.query(`ALTER TABLE \`profileEmployeeHistory\` DROP COLUMN \`dutyTimeEffectiveDate\``); await queryRunner.query(`ALTER TABLE \`profileEmployeeHistory\` DROP COLUMN \`dutyTimeId\``); await queryRunner.query(`ALTER TABLE \`profileEmployee\` DROP COLUMN \`dutyTimeEffectiveDate\``); await queryRunner.query(`ALTER TABLE \`profileEmployee\` DROP COLUMN \`dutyTimeId\``); } }