This commit is contained in:
Adisak 2025-10-22 15:57:07 +07:00
parent ad6b6401d4
commit dea973f8d9
2 changed files with 2 additions and 2 deletions

View file

@ -2045,7 +2045,7 @@ export class ProfileEmployeeController extends Controller {
await this.informationHistoryRepository.delete({ profileEmployeeId: id });
await this.profileRepo.remove(result);
} catch {
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่สามารถลบข้อมูลได้");
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่สามารถลบข้อมูลได้ เนื่องจากข้อมูลนี้ถูกใช้งานในระบบอื่น");
}
return new HttpSuccess();
}

View file

@ -1033,7 +1033,7 @@ export class ProfileEmployeeTempController extends Controller {
await this.informationHistoryRepository.delete({ profileEmployeeId: id });
await this.profileRepo.remove(result);
} catch {
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่สามารถลบข้อมูลได้");
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่สามารถลบข้อมูลได้ เนื่องจากข้อมูลนี้ถูกใช้งานในระบบอื่น");
}
return new HttpSuccess();
}