fix
This commit is contained in:
parent
3320646521
commit
04344cd4c5
1 changed files with 6 additions and 0 deletions
|
|
@ -1173,9 +1173,12 @@ export class DevelopmentController extends Controller {
|
||||||
await this.developmentAddresssRepository.remove(development.developmentAddresss, {
|
await this.developmentAddresssRepository.remove(development.developmentAddresss, {
|
||||||
data: request,
|
data: request,
|
||||||
});
|
});
|
||||||
|
|
||||||
// const before = structuredClone(development);
|
// const before = structuredClone(development);
|
||||||
await Promise.all(
|
await Promise.all(
|
||||||
requestBody.developmentAddresss.map(async (x) => {
|
requestBody.developmentAddresss.map(async (x) => {
|
||||||
|
if (x.provinceId == "")
|
||||||
|
throw new HttpError(HttpStatusCode.BAD_REQUEST, "กรุณาเลือกจังหวัด");
|
||||||
const data = Object.assign(new DevelopmentAddress(), x);
|
const data = Object.assign(new DevelopmentAddress(), x);
|
||||||
const chkProvince = await this.provinceRepository.findOne({
|
const chkProvince = await this.provinceRepository.findOne({
|
||||||
where: {
|
where: {
|
||||||
|
|
@ -2114,6 +2117,9 @@ export class DevelopmentController extends Controller {
|
||||||
strategyChild3Actual: getDevelopment.strategyChild3ActualId,
|
strategyChild3Actual: getDevelopment.strategyChild3ActualId,
|
||||||
strategyChild4Actual: getDevelopment.strategyChild4ActualId,
|
strategyChild4Actual: getDevelopment.strategyChild4ActualId,
|
||||||
strategyChild5Actual: getDevelopment.strategyChild5ActualId,
|
strategyChild5Actual: getDevelopment.strategyChild5ActualId,
|
||||||
|
dateStart: getDevelopment.dateStart,
|
||||||
|
dateEnd: getDevelopment.dateEnd,
|
||||||
|
totalDate: getDevelopment.totalDate,
|
||||||
developmentAddresss:
|
developmentAddresss:
|
||||||
getDevelopment.developmentAddresss == null
|
getDevelopment.developmentAddresss == null
|
||||||
? null
|
? null
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue