|
@@ -1,5 +1,5 @@
|
|
|
import { GenericCrudService } from '@d8d/shared-crud';
|
|
import { GenericCrudService } from '@d8d/shared-crud';
|
|
|
-import { DataSource, Repository, DataSourceOptions, In, Not } from 'typeorm';
|
|
|
|
|
|
|
+import { DataSource, Repository } from 'typeorm';
|
|
|
import { EmploymentOrder } from '../entities/employment-order.entity';
|
|
import { EmploymentOrder } from '../entities/employment-order.entity';
|
|
|
import { OrderPerson } from '../entities/order-person.entity';
|
|
import { OrderPerson } from '../entities/order-person.entity';
|
|
|
import { OrderPersonAsset } from '../entities/order-person-asset.entity';
|
|
import { OrderPersonAsset } from '../entities/order-person-asset.entity';
|
|
@@ -337,6 +337,7 @@ export class OrderService extends GenericCrudService<EmploymentOrder> {
|
|
|
personId: number;
|
|
personId: number;
|
|
|
joinDate: Date;
|
|
joinDate: Date;
|
|
|
salaryDetail: number;
|
|
salaryDetail: number;
|
|
|
|
|
+ workStatus?: WorkStatus;
|
|
|
}>): Promise<{ success: boolean; message: string; addedCount: number }> {
|
|
}>): Promise<{ success: boolean; message: string; addedCount: number }> {
|
|
|
// 验证订单是否存在
|
|
// 验证订单是否存在
|
|
|
const order = await this.repository.findOne({
|
|
const order = await this.repository.findOne({
|
|
@@ -377,7 +378,7 @@ export class OrderService extends GenericCrudService<EmploymentOrder> {
|
|
|
orderId: orderId,
|
|
orderId: orderId,
|
|
|
personId: person.personId,
|
|
personId: person.personId,
|
|
|
joinDate: person.joinDate,
|
|
joinDate: person.joinDate,
|
|
|
- workStatus: WorkStatus.PRE_WORKING,
|
|
|
|
|
|
|
+ workStatus: person.workStatus ?? WorkStatus.PRE_WORKING,
|
|
|
salaryDetail: person.salaryDetail,
|
|
salaryDetail: person.salaryDetail,
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|