From 529903cea0ea2d74bd713597b37b5912d364cd15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=98=84=EC=A3=BC?= Date: Thu, 26 Jun 2025 18:08:49 +0900 Subject: [PATCH 01/13] =?UTF-8?q?[BO]=20=EC=9D=BC=EA=B3=84=EB=B6=80=20?= =?UTF-8?q?=EB=93=B1=EB=A1=9D=20=ED=98=84=ED=99=A9=EC=9D=98=20=EC=82=AD?= =?UTF-8?q?=EC=A0=9C=20=EC=B2=98=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../adapters/persistence/RemoveDailyDao.java | 39 ++++++++++++ .../persistence/RemoveDailyMapper.java | 43 +++++++++++++ .../adapters/web/RemoveDailyController.java | 28 +++++++++ .../adapters/web/modal/RemoveDailyReqVO.java | 22 +++++++ .../removeDaily/ports/RemoveDailyPortIn.java | 7 +++ .../removeDaily/ports/RemoveDailyPortOut.java | 7 +++ .../ports/application/RemoveDailyService.java | 26 ++++++++ .../application/domain/RemoveDailyCmd.java | 26 ++++++++ .../persistence/UpdateDailyNoneDao.java | 2 +- .../mappers/household/RemoveDailyMapper.xml | 62 +++++++++++++++++++ .../households/tab/daily-record.html | 38 +++++++++++- .../templates/common/components.html | 2 +- 12 files changed, 297 insertions(+), 5 deletions(-) create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyDao.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyMapper.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/RemoveDailyController.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/modal/RemoveDailyReqVO.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortIn.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortOut.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/RemoveDailyService.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/domain/RemoveDailyCmd.java create mode 100644 admin/src/main/resources/mappers/household/RemoveDailyMapper.xml diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyDao.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyDao.java new file mode 100644 index 00000000..87d7284e --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyDao.java @@ -0,0 +1,39 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.persistence; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.RemoveDailyPortOut; +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application.domain.RemoveDailyCmd; +import app.module.core.config.application.enums.DailySort; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Repository; + +@Slf4j +@Repository +@RequiredArgsConstructor +public class RemoveDailyDao implements RemoveDailyPortOut { + private final RemoveDailyMapper mapper; + + @Override + public void operate(RemoveDailyCmd command) { + if (command.getCurrentStep() != null) { + log.error("[RemoveDaily] cmd: {}", command); + + if (DailySort.INCOME.equals(command.getCurrentStep())) { + mapper.removeDailyIncome(command); + } else if (DailySort.WORK.equals(command.getCurrentStep())) { + mapper.removeDailyWork(command); + } else if (DailySort.EXPENSE.equals(command.getCurrentStep())) { + mapper.removeDailyExpense(command); + } else if (DailySort.POWER.equals(command.getCurrentStep())) { + mapper.removeDailyPower(command); + } else if (DailySort.FORESTRY.equals(command.getCurrentStep())) { + mapper.removeDailyForestry(command); + } else if (DailySort.FARMING.equals(command.getCurrentStep())) { + mapper.removeDailyFarming(command); + } + + } else { + log.error("[RemoveDaily] Current step is null. cmd: {}", command); + } + } +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyMapper.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyMapper.java new file mode 100644 index 00000000..5de04c22 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/persistence/RemoveDailyMapper.java @@ -0,0 +1,43 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.persistence; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application.domain.RemoveDailyCmd; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface RemoveDailyMapper { + /** + * 특정일의 수입 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyIncome(RemoveDailyCmd command); + + /** + * 특정일의 임업노동 투입 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyWork(RemoveDailyCmd command); + + /** + * 특정일의 지출 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyExpense(RemoveDailyCmd command); + + /** + * 동력 사용시간 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyPower(RemoveDailyCmd command); + + /** + * 자가임업 생산물 중 자가소비량 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyForestry(RemoveDailyCmd command); + + /** + * 자가농업 생산물 중 자가소비량 전체 삭제 + * @param command 검색 조건 + */ + void removeDailyFarming(RemoveDailyCmd command); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/RemoveDailyController.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/RemoveDailyController.java new file mode 100644 index 00000000..b4691dfb --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/RemoveDailyController.java @@ -0,0 +1,28 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.web; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.web.modal.RemoveDailyReqVO; +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.RemoveDailyPortIn; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RestController; + +@Slf4j +@RestController +@RequiredArgsConstructor +class RemoveDailyController { + private final RemoveDailyPortIn removeDailyNonePortIn; + + @PostMapping(path = "/api/household/daily/remove") + ResponseEntity remove(@RequestBody RemoveDailyReqVO reqVO) { + log.debug("reqVO: {}", reqVO); + + if (!reqVO.getSelectedIds().isEmpty()) { + removeDailyNonePortIn.operate(reqVO); + } + return ResponseEntity.status(HttpStatus.OK).body(reqVO); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/modal/RemoveDailyReqVO.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/modal/RemoveDailyReqVO.java new file mode 100644 index 00000000..4848c41d --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/adapters/web/modal/RemoveDailyReqVO.java @@ -0,0 +1,22 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.web.modal; + +import app.module.core.config.application.enums.DailySort; +import lombok.Getter; +import lombok.Setter; +import lombok.ToString; + +import java.util.Set; + +@Getter +@Setter +@ToString +public class RemoveDailyReqVO { + /** + * 항목 일련번호 + */ + private Set selectedIds; + /** + * 현재 단계 + */ + private DailySort currentStep; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortIn.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortIn.java new file mode 100644 index 00000000..12d29912 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortIn.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.web.modal.RemoveDailyReqVO; + +public interface RemoveDailyPortIn { + void operate(RemoveDailyReqVO reqVO); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortOut.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortOut.java new file mode 100644 index 00000000..4cd1d147 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/RemoveDailyPortOut.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application.domain.RemoveDailyCmd; + +public interface RemoveDailyPortOut { + void operate(RemoveDailyCmd command); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/RemoveDailyService.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/RemoveDailyService.java new file mode 100644 index 00000000..2a2a1337 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/RemoveDailyService.java @@ -0,0 +1,26 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application; + +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.adapters.web.modal.RemoveDailyReqVO; +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.RemoveDailyPortIn; +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.RemoveDailyPortOut; +import app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application.domain.RemoveDailyCmd; +import app.module.core.config.application.util.AuditUtil; +import lombok.RequiredArgsConstructor; +import org.springframework.stereotype.Service; + +@Service +@RequiredArgsConstructor +public class RemoveDailyService implements RemoveDailyPortIn { + private final RemoveDailyPortOut portOut; + + @Override + public void operate(RemoveDailyReqVO reqVO) { + RemoveDailyCmd command = AuditUtil.update( + new RemoveDailyCmd( + reqVO.getSelectedIds(), + reqVO.getCurrentStep()) + ); + + portOut.operate(command); + } +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/domain/RemoveDailyCmd.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/domain/RemoveDailyCmd.java new file mode 100644 index 00000000..ba12d13d --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/removeDaily/ports/application/domain/RemoveDailyCmd.java @@ -0,0 +1,26 @@ +package app.module.admin.usecase.household.tab.dailyRecord.removeDaily.ports.application.domain; + +import app.module.core.config.adapters.persistence.component.AuditCommand; +import app.module.core.config.application.enums.DailySort; +import app.module.core.config.application.enums.DailyTargetStatus; +import lombok.AllArgsConstructor; +import lombok.Getter; +import lombok.Setter; +import lombok.ToString; + +import java.util.Set; + +@Getter +@Setter +@ToString +@AllArgsConstructor +public class RemoveDailyCmd extends AuditCommand { + /** + * 항목 일련번호 + */ + private Set removeIds; + /** + * 현재 단계 + */ + private DailySort currentStep; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/updateDailyNone/adapters/persistence/UpdateDailyNoneDao.java b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/updateDailyNone/adapters/persistence/UpdateDailyNoneDao.java index 3a3fc5c5..4eccef83 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/updateDailyNone/adapters/persistence/UpdateDailyNoneDao.java +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/dailyRecord/updateDailyNone/adapters/persistence/UpdateDailyNoneDao.java @@ -41,7 +41,7 @@ class UpdateDailyNoneDao implements UpdateDailyNonePortOut { dailyRecordPortIn.updateByStatus(command.getSearchMonth(), command.getGroupNo(), command.getHouseholdSeq(), command.getCurrentStep().name(), command.getCurrentStatus().name()); } else { - log.error("[CreateDailyNone] Current step is null. cmd:{}", command); + log.error("[UpdateDailyNone] Current step is null. cmd: {}", command); } } } \ No newline at end of file diff --git a/admin/src/main/resources/mappers/household/RemoveDailyMapper.xml b/admin/src/main/resources/mappers/household/RemoveDailyMapper.xml new file mode 100644 index 00000000..43415611 --- /dev/null +++ b/admin/src/main/resources/mappers/household/RemoveDailyMapper.xml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/admin/src/main/resources/templates/households/tab/daily-record.html b/admin/src/main/resources/templates/households/tab/daily-record.html index faf8afe0..1bacad11 100644 --- a/admin/src/main/resources/templates/households/tab/daily-record.html +++ b/admin/src/main/resources/templates/households/tab/daily-record.html @@ -502,7 +502,7 @@
@@ -510,7 +510,7 @@ ${ifNullHyphen(item.cropText)} ${ifNullHyphen(item.incomeKind)} ${ifNullHyphen(item.sourcePurpose)} - ${ifNullHyphen(item.quantity)} + ${formatNumberWithComma(item.quantity)} ${ifNullHyphen(item.unitText)} ${formatNumberWithComma(item.price)} ${formatNumberWithComma(item.estimatedValue)} @@ -817,7 +817,39 @@ const currentListId = $(el).data('listId'); console.log('removeDaily', currentStep, currentListId); - alert('TODO : 삭제') + if ($('#'+currentListId).find('input[type="checkbox"]:checked').length === 0) { + alert('삭제내용은 최소 1건은 선택해야 합니다.'); + return; + } else if ($('#'+currentListId).find('input[type="checkbox"]').length === $('#'+currentListId).find('input[type="checkbox"]:checked').length) { + alert('등록내용은 최소 1건이 남아 있어야 합니다.'); + return; + } + + const selectedValues = []; + $('#'+currentListId).find('input[type="checkbox"]:checked').each((idx, item) => { + selectedValues.push($(item).val()); + }); + + const obj = {}; + obj.selectedIds = selectedValues; + obj.currentStep = currentStep; + console.log(obj) + + etUI.dialog.confirm({ + title: '삭제 안내', + message: '선택하신 항목을 삭제하시겠습니까?
삭제한 항목은 복구할 수 없습니다.', + positiveCallback: function () { + ajaxUtil._ajaxAsyncNoWaiting( + '/api/household/daily/remove', + obj, + function () { + alert('데이터 삭제가 완료되었습니다.'); + + getDailyRecordsView(f.dailyId.value, f.groupNo.value, f.dayGroupText.value); + }, + ); + }, + }); } diff --git a/front/src/main/resources/templates/common/components.html b/front/src/main/resources/templates/common/components.html index 63072c51..3198b6d7 100644 --- a/front/src/main/resources/templates/common/components.html +++ b/front/src/main/resources/templates/common/components.html @@ -34,7 +34,7 @@ - + From d923c3352f667001a615a58b8af7fd919e323110 Mon Sep 17 00:00:00 2001 From: kangsunlee Date: Thu, 26 Jun 2025 19:02:09 +0900 Subject: [PATCH 02/13] =?UTF-8?q?[BO]=20=EC=9E=84=EA=B0=80=ED=98=84?= =?UTF-8?q?=ED=99=A9=20-=20=EC=9E=84=EC=82=B0=EB=AC=BC=ED=98=84=ED=99=A9?= =?UTF-8?q?=20=EC=9E=91=EC=97=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../enums/MonthlyInputStatusType.java | 13 ++ .../web}/GetHouseholdStatusUIController.java | 4 +- .../web}/model/GetHouseholdStatusUIReqVO.java | 2 +- .../web}/GetHouseholdsStatusUIController.java | 4 +- .../web}/model/GetHouseholdsUIReqVO.java | 2 +- .../UpdateMonthlyInputStatusDao.java | 19 +++ .../UpdateMonthlyInputStatusMapper.java | 9 ++ .../ports/UpdateMonthlyInputStatusPortIn.java | 7 + .../UpdateMonthlyInputStatusPortOut.java | 7 + .../UpdateMonthlyInputStatusService.java | 18 +++ .../domain/UpdateForestProductStatusCmd.java | 15 ++ .../persistence/RemoveForestProductsDao.java | 33 ++++ .../RemoveForestProductsMapper.java | 10 ++ .../web/RemoveForestProductsController.java | 36 +++++ .../web/model/RemoveForestProductsReqVO.java | 17 +++ .../web/model/RemoveForestProductsResVO.java | 14 ++ .../ports/RemoveForestProductsPortIn.java | 7 + .../ports/RemoveForestProductsPortOut.java | 7 + .../RemoveForestProductsService.java | 18 +++ .../domain/RemoveForestProductsCmd.java | 17 +++ .../persistence/SaveForestProductDao.java | 22 ++- .../persistence/SaveForestProductMapper.java | 1 + .../UpdateForestProductNoneDao.java | 34 +++++ .../UpdateForestProductNoneMapper.java | 9 ++ .../UpdateForestProductNoneController.java | 31 ++++ .../model/UpdateForestProductNoneReqVO.java | 16 ++ .../model/UpdateForestProductNoneResVO.java | 14 ++ .../ports/UpdateForestProductNonePortIn.java | 7 + .../ports/UpdateForestProductNonePortOut.java | 8 + .../UpdateForestProductNoneService.java | 22 +++ .../domain/UpdateForestProductNoneInCmd.java | 13 ++ .../domain/UpdateForestProductNoneOutCmd.java | 14 ++ .../UpdateMonthlyForestProductStatusCmd.java | 15 ++ .../household/RemoveForestProductsMapper.xml | 25 ++++ .../RemoveHouseholdVisitInfosMapper.xml | 18 +-- .../household/SaveForestProductMapper.xml | 7 + .../UpdateForestProductNoneMapper.xml | 13 ++ .../UpdateMonthlyInputStatusMapper.xml | 14 ++ .../resources/messages/operation.properties | 1 + .../templates/common/components.html | 1 + .../modal/modal-forest-product.html | 2 +- .../households/tab/forest-product.html | 141 +++++++++++++++++- 42 files changed, 663 insertions(+), 24 deletions(-) create mode 100644 admin/src/main/java/app/module/admin/config/application/enums/MonthlyInputStatusType.java rename admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/{ => adapters/web}/GetHouseholdStatusUIController.java (89%) rename admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/{ => adapters/web}/model/GetHouseholdStatusUIReqVO.java (93%) rename admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/{ => adapters/web}/GetHouseholdsStatusUIController.java (97%) rename admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/{ => adapters/web}/model/GetHouseholdsUIReqVO.java (98%) create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusDao.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusMapper.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortIn.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortOut.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/UpdateMonthlyInputStatusService.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/domain/UpdateForestProductStatusCmd.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsDao.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsMapper.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/RemoveForestProductsController.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsReqVO.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsResVO.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortIn.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortOut.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/RemoveForestProductsService.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/domain/RemoveForestProductsCmd.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneDao.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneMapper.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/UpdateForestProductNoneController.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneReqVO.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneResVO.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortIn.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortOut.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/UpdateForestProductNoneService.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneInCmd.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneOutCmd.java create mode 100644 admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateMonthlyForestProductStatusCmd.java create mode 100644 admin/src/main/resources/mappers/household/RemoveForestProductsMapper.xml create mode 100644 admin/src/main/resources/mappers/household/UpdateForestProductNoneMapper.xml create mode 100644 admin/src/main/resources/mappers/household/UpdateMonthlyInputStatusMapper.xml diff --git a/admin/src/main/java/app/module/admin/config/application/enums/MonthlyInputStatusType.java b/admin/src/main/java/app/module/admin/config/application/enums/MonthlyInputStatusType.java new file mode 100644 index 00000000..a178d27a --- /dev/null +++ b/admin/src/main/java/app/module/admin/config/application/enums/MonthlyInputStatusType.java @@ -0,0 +1,13 @@ +package app.module.admin.config.application.enums; + +import lombok.Getter; +import lombok.RequiredArgsConstructor; + +@Getter +@RequiredArgsConstructor +public enum MonthlyInputStatusType { + NONE("미등록"), + NOTHING("등록 내용없음"), + REGISTERED("등록완료"); + private final String desc; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/GetHouseholdStatusUIController.java b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/GetHouseholdStatusUIController.java similarity index 89% rename from admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/GetHouseholdStatusUIController.java rename to admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/GetHouseholdStatusUIController.java index 19dd87b5..b003eb9b 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/GetHouseholdStatusUIController.java +++ b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/GetHouseholdStatusUIController.java @@ -1,4 +1,4 @@ -package app.module.admin.usecase.household.getHouseholdStatusUI; +package app.module.admin.usecase.household.getHouseholdStatusUI.adapters.web; import app.module.admin.config.application.util.AdminUtil; import app.module.admin.config.application.util.DateUiUtil; @@ -11,7 +11,7 @@ import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.ModelAttribute; import org.springframework.web.bind.annotation.PathVariable; -import app.module.admin.usecase.household.getHouseholdStatusUI.model.GetHouseholdStatusUIReqVO; +import app.module.admin.usecase.household.getHouseholdStatusUI.adapters.web.model.GetHouseholdStatusUIReqVO; import org.springframework.web.bind.annotation.RequestParam; @Controller diff --git a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/model/GetHouseholdStatusUIReqVO.java b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/model/GetHouseholdStatusUIReqVO.java similarity index 93% rename from admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/model/GetHouseholdStatusUIReqVO.java rename to admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/model/GetHouseholdStatusUIReqVO.java index a49de0a2..bbc62d52 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/model/GetHouseholdStatusUIReqVO.java +++ b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdStatusUI/adapters/web/model/GetHouseholdStatusUIReqVO.java @@ -1,4 +1,4 @@ -package app.module.admin.usecase.household.getHouseholdStatusUI.model; +package app.module.admin.usecase.household.getHouseholdStatusUI.adapters.web.model; import lombok.AllArgsConstructor; import lombok.EqualsAndHashCode; diff --git a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/GetHouseholdsStatusUIController.java b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/GetHouseholdsStatusUIController.java similarity index 97% rename from admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/GetHouseholdsStatusUIController.java rename to admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/GetHouseholdsStatusUIController.java index c7449fb4..0d269c18 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/GetHouseholdsStatusUIController.java +++ b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/GetHouseholdsStatusUIController.java @@ -1,8 +1,8 @@ -package app.module.admin.usecase.household.getHouseholdsStatusUI; +package app.module.admin.usecase.household.getHouseholdsStatusUI.adapters.web; import app.module.admin.config.application.util.AdminUtil; import app.module.admin.config.application.util.DateUiUtil; -import app.module.admin.usecase.household.getHouseholdsStatusUI.model.GetHouseholdsUIReqVO; +import app.module.admin.usecase.household.getHouseholdsStatusUI.adapters.web.model.GetHouseholdsUIReqVO; import app.module.core.config.application.util.CommonUtil; import app.module.core.usecase.admin.view.ports.AdminViewPortIn; import app.module.core.usecase.admin.view.ports.application.domain.AdminView; diff --git a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/model/GetHouseholdsUIReqVO.java b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/model/GetHouseholdsUIReqVO.java similarity index 98% rename from admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/model/GetHouseholdsUIReqVO.java rename to admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/model/GetHouseholdsUIReqVO.java index ee34a95e..8e6124b1 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/model/GetHouseholdsUIReqVO.java +++ b/admin/src/main/java/app/module/admin/usecase/household/getHouseholdsStatusUI/adapters/web/model/GetHouseholdsUIReqVO.java @@ -1,4 +1,4 @@ -package app.module.admin.usecase.household.getHouseholdsStatusUI.model; +package app.module.admin.usecase.household.getHouseholdsStatusUI.adapters.web.model; import app.module.admin.usecase.household.getHouseholdsStatus.ports.application.domain.ProgressType; import lombok.AllArgsConstructor; diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusDao.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusDao.java new file mode 100644 index 00000000..2e332a4e --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusDao.java @@ -0,0 +1,19 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.adapters.persistence; + +import app.module.core.config.application.annotation.UpdateCommand; +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.UpdateMonthlyInputStatusPortOut; +import org.springframework.stereotype.Repository; + +@Repository +@RequiredArgsConstructor +class UpdateMonthlyInputStatusDao implements UpdateMonthlyInputStatusPortOut { + private final UpdateMonthlyInputStatusMapper mapper; + + @Override + @UpdateCommand + public void updateForestProductStatus(UpdateForestProductStatusCmd cmd) { + mapper.updateForestProductStatus(cmd); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusMapper.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusMapper.java new file mode 100644 index 00000000..cdfc03d9 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/adapters/persistence/UpdateMonthlyInputStatusMapper.java @@ -0,0 +1,9 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.adapters.persistence; + +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface UpdateMonthlyInputStatusMapper { + void updateForestProductStatus(UpdateForestProductStatusCmd cmd); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortIn.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortIn.java new file mode 100644 index 00000000..b92d3e34 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortIn.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports; + +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; + +public interface UpdateMonthlyInputStatusPortIn { + void updateForestProductStatus(UpdateForestProductStatusCmd cmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortOut.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortOut.java new file mode 100644 index 00000000..cca72d63 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/UpdateMonthlyInputStatusPortOut.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports; + +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; + +public interface UpdateMonthlyInputStatusPortOut { + void updateForestProductStatus(UpdateForestProductStatusCmd cmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/UpdateMonthlyInputStatusService.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/UpdateMonthlyInputStatusService.java new file mode 100644 index 00000000..d4357e49 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/UpdateMonthlyInputStatusService.java @@ -0,0 +1,18 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application; + +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.UpdateMonthlyInputStatusPortIn; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.UpdateMonthlyInputStatusPortOut; +import org.springframework.stereotype.Service; + +@Service +@RequiredArgsConstructor +class UpdateMonthlyInputStatusService implements UpdateMonthlyInputStatusPortIn { + private final UpdateMonthlyInputStatusPortOut portOut; + + @Override + public void updateForestProductStatus(UpdateForestProductStatusCmd cmd) { + portOut.updateForestProductStatus(cmd); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/domain/UpdateForestProductStatusCmd.java b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/domain/UpdateForestProductStatusCmd.java new file mode 100644 index 00000000..858b5104 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/monthlyInputStatus/updateMonthlyInputStatus/ports/application/domain/UpdateForestProductStatusCmd.java @@ -0,0 +1,15 @@ +package app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain; + +import app.module.core.config.adapters.persistence.component.AuditCommand; +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +public class UpdateForestProductStatusCmd extends AuditCommand { + private Long id; + private String status; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsDao.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsDao.java new file mode 100644 index 00000000..b7bb6694 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsDao.java @@ -0,0 +1,33 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.persistence; + +import app.module.admin.config.application.enums.MonthlyInputStatusType; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.adapters.persistence.UpdateMonthlyInputStatusMapper; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; +import app.module.core.config.application.annotation.DeleteCommand; +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.RemoveForestProductsPortOut; +import org.springframework.stereotype.Repository; +import org.springframework.transaction.annotation.Transactional; + +@Repository +@RequiredArgsConstructor +class RemoveForestProductsDao implements RemoveForestProductsPortOut { + private final RemoveForestProductsMapper removeForestProductsMapper; + private final UpdateMonthlyInputStatusMapper updateMonthlyInputStatusMapper; + + @Override + @DeleteCommand + @Transactional + public void operate(RemoveForestProductsCmd cmd) { + // 임산물 현황 삭제 + removeForestProductsMapper.removeForestProducts(cmd); + + // 임산물 모두 삭제됐을 경우 입력상태 미등록으로 update + if (!removeForestProductsMapper.existsForestProduct(cmd.getMonthlyInputStatusId())) { + updateMonthlyInputStatusMapper.updateForestProductStatus( + new UpdateForestProductStatusCmd(cmd.getMonthlyInputStatusId(), + MonthlyInputStatusType.NONE.name())); + } + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsMapper.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsMapper.java new file mode 100644 index 00000000..1117241a --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/persistence/RemoveForestProductsMapper.java @@ -0,0 +1,10 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.persistence; + +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface RemoveForestProductsMapper { + void removeForestProducts(RemoveForestProductsCmd cmd); + boolean existsForestProduct(Long monthlyInputStatusId); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/RemoveForestProductsController.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/RemoveForestProductsController.java new file mode 100644 index 00000000..5fe5f500 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/RemoveForestProductsController.java @@ -0,0 +1,36 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.web; + +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.RemoveForestProductsPortIn; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; +import app.module.core.config.application.util.MessageUtil; +import jakarta.validation.Valid; +import lombok.RequiredArgsConstructor; +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RestController; +import org.springframework.validation.BindingResult; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.web.model.RemoveForestProductsReqVO; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.web.model.RemoveForestProductsResVO; + +@RestController +@RequiredArgsConstructor +class RemoveForestProductsController { + private final RemoveForestProductsPortIn portIn; + private final MessageUtil messageUtil; + + @DeleteMapping(path = "/api/household/forestProducts/delete") + ResponseEntity operate(@Valid @RequestBody RemoveForestProductsReqVO reqVO, + BindingResult bindingResult) { + if (bindingResult.hasErrors()) { + return ResponseEntity.status(HttpStatus.UNPROCESSABLE_ENTITY).body(bindingResult); + } + + portIn.operate( + new RemoveForestProductsCmd(reqVO.getMonthlyInputStatusId(), reqVO.getForestRemoveIds())); + + return ResponseEntity.status(HttpStatus.OK).body( + new RemoveForestProductsResVO(messageUtil.getMessage("operation.common.remove.done"))); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsReqVO.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsReqVO.java new file mode 100644 index 00000000..9af219a6 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsReqVO.java @@ -0,0 +1,17 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.web.model; + +import java.util.List; +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.NoArgsConstructor; +import lombok.Setter; + +@Getter +@Setter +@NoArgsConstructor +@EqualsAndHashCode +public class RemoveForestProductsReqVO { + private Long monthlyInputStatusId; + private List forestRemoveIds; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsResVO.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsResVO.java new file mode 100644 index 00000000..7d169cf3 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/adapters/web/model/RemoveForestProductsResVO.java @@ -0,0 +1,14 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.adapters.web.model; + +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +@EqualsAndHashCode +public class RemoveForestProductsResVO { + private String message; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortIn.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortIn.java new file mode 100644 index 00000000..91e4899e --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortIn.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports; + +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; + +public interface RemoveForestProductsPortIn { + void operate(RemoveForestProductsCmd cmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortOut.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortOut.java new file mode 100644 index 00000000..d2d1b66b --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/RemoveForestProductsPortOut.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports; + +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; + +public interface RemoveForestProductsPortOut { + void operate(RemoveForestProductsCmd cmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/RemoveForestProductsService.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/RemoveForestProductsService.java new file mode 100644 index 00000000..d06fae44 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/RemoveForestProductsService.java @@ -0,0 +1,18 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application; + +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain.RemoveForestProductsCmd; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.RemoveForestProductsPortIn; +import app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.RemoveForestProductsPortOut; +import org.springframework.stereotype.Service; + +@Service +@RequiredArgsConstructor +class RemoveForestProductsService implements RemoveForestProductsPortIn { + private final RemoveForestProductsPortOut portOut; + + @Override + public void operate(RemoveForestProductsCmd cmd) { + portOut.operate(cmd); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/domain/RemoveForestProductsCmd.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/domain/RemoveForestProductsCmd.java new file mode 100644 index 00000000..672e6872 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/removeForestProducts/ports/application/domain/RemoveForestProductsCmd.java @@ -0,0 +1,17 @@ +package app.module.admin.usecase.household.tab.forestProduct.removeForestProducts.ports.application.domain; + +import app.module.core.config.adapters.persistence.component.AuditCommand; +import java.util.List; +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +@EqualsAndHashCode +public class RemoveForestProductsCmd extends AuditCommand { + private Long monthlyInputStatusId; + private List removeIds; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductDao.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductDao.java index 28b77e34..60b61971 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductDao.java +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductDao.java @@ -1,5 +1,8 @@ package app.module.admin.usecase.household.tab.forestProduct.saveForestProduct.adapters.persistence; +import app.module.admin.config.application.enums.MonthlyInputStatusType; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.adapters.persistence.UpdateMonthlyInputStatusMapper; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; import app.module.admin.usecase.household.tab.forestProduct.saveForestProduct.ports.SaveForestProductPortOut; import app.module.admin.usecase.household.tab.forestProduct.saveForestProduct.ports.application.domain.SaveForestProductCmd; import app.module.core.config.application.util.AuditUtil; @@ -10,15 +13,28 @@ import org.springframework.transaction.annotation.Transactional; @Repository @RequiredArgsConstructor class SaveForestProductDao implements SaveForestProductPortOut { - private final SaveForestProductMapper mapper; + private final SaveForestProductMapper saveForestProductMapper; + private final UpdateMonthlyInputStatusMapper updateMonthlyInputStatusMapper; @Override @Transactional public void operate(SaveForestProductCmd inCmd) { if (inCmd.getForestProductId() == null) { - mapper.createForestProduct(AuditUtil.create(inCmd)); + String status = saveForestProductMapper.getForestProductStatus(inCmd.getMonthlyInputStatusId()); + + // 등록 상태가 "REGISTERED"가 아닐 경우 "REGISTERED"로 update + if(!MonthlyInputStatusType.REGISTERED.name().equals(status)) { + updateMonthlyInputStatusMapper.updateForestProductStatus( + new UpdateForestProductStatusCmd( + inCmd.getMonthlyInputStatusId(), + MonthlyInputStatusType.REGISTERED.name())); + } + + // 임산물 현황 등록 + saveForestProductMapper.createForestProduct(AuditUtil.create(inCmd)); } else { - mapper.updateForestProduct(AuditUtil.update(inCmd)); + // 임산물 현황 update + saveForestProductMapper.updateForestProduct(AuditUtil.update(inCmd)); } } } \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductMapper.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductMapper.java index 95eb3adf..f754e7ed 100644 --- a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductMapper.java +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/saveForestProduct/adapters/persistence/SaveForestProductMapper.java @@ -5,6 +5,7 @@ import org.apache.ibatis.annotations.Mapper; @Mapper public interface SaveForestProductMapper { + String getForestProductStatus(Long monthlyInputStatusId); void createForestProduct(SaveForestProductCmd cmd); void updateForestProduct(SaveForestProductCmd cmd); } diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneDao.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneDao.java new file mode 100644 index 00000000..426f8f9a --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneDao.java @@ -0,0 +1,34 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.persistence; + +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.adapters.persistence.UpdateMonthlyInputStatusMapper; +import app.module.admin.usecase.household.monthlyInputStatus.updateMonthlyInputStatus.ports.application.domain.UpdateForestProductStatusCmd; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneOutCmd; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateMonthlyForestProductStatusCmd; +import app.module.core.config.application.util.AuditUtil; +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneInCmd; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.UpdateForestProductNonePortOut; +import org.springframework.stereotype.Repository; +import org.springframework.transaction.annotation.Transactional; + +@Repository +@RequiredArgsConstructor +class UpdateForestProductNoneDao implements UpdateForestProductNonePortOut { + private final UpdateForestProductNoneMapper updateForestProductNoneMapper; + private final UpdateMonthlyInputStatusMapper updateMonthlyInputStatusMapper; + + @Override + @Transactional + public void operate(UpdateForestProductNoneOutCmd outCmd) { + // 금일 데이터 없음 체크시 데이터 일괄 삭제 + if ("NOTHING".equals(outCmd.getCurrentStatus())) { + updateForestProductNoneMapper.removeForestProduct(AuditUtil.delete(outCmd)); + } + + // 임산물 현황 상태값 변경 + updateMonthlyInputStatusMapper.updateForestProductStatus( + AuditUtil.update(new UpdateForestProductStatusCmd( + outCmd.getMonthlyInputStatusId(), + outCmd.getCurrentStatus()))); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneMapper.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneMapper.java new file mode 100644 index 00000000..53cf5d27 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/persistence/UpdateForestProductNoneMapper.java @@ -0,0 +1,9 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.persistence; + +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneOutCmd; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface UpdateForestProductNoneMapper { + void removeForestProduct(UpdateForestProductNoneOutCmd cmd); +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/UpdateForestProductNoneController.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/UpdateForestProductNoneController.java new file mode 100644 index 00000000..8cd74f22 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/UpdateForestProductNoneController.java @@ -0,0 +1,31 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.web; + +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.UpdateForestProductNonePortIn; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneInCmd; +import app.module.core.config.application.util.MessageUtil; +import lombok.RequiredArgsConstructor; +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.PatchMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.GetMapping; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.web.model.UpdateForestProductNoneReqVO; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.web.model.UpdateForestProductNoneResVO; + +@RestController +@RequiredArgsConstructor +class UpdateForestProductNoneController { + private final UpdateForestProductNonePortIn portIn; + private final MessageUtil messageUtil; + + @PatchMapping(path = "/api/household/forestProduct/nothing") + ResponseEntity operate(@RequestBody UpdateForestProductNoneReqVO reqVO) { + + portIn.operate(new UpdateForestProductNoneInCmd(reqVO.getMonthlyInputStatusId(), + reqVO.getTodayNone())); + + return ResponseEntity.status(HttpStatus.OK).body(new UpdateForestProductNoneResVO( + messageUtil.getMessage("operation.common.update.done"))); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneReqVO.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneReqVO.java new file mode 100644 index 00000000..b38f655e --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneReqVO.java @@ -0,0 +1,16 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.web.model; + +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.NoArgsConstructor; +import lombok.Setter; + +@Getter +@Setter +@NoArgsConstructor +@EqualsAndHashCode +public class UpdateForestProductNoneReqVO { + private Long monthlyInputStatusId; + private String todayNone; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneResVO.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneResVO.java new file mode 100644 index 00000000..9971e271 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/adapters/web/model/UpdateForestProductNoneResVO.java @@ -0,0 +1,14 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.adapters.web.model; + +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +@EqualsAndHashCode +public class UpdateForestProductNoneResVO { + private String message; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortIn.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortIn.java new file mode 100644 index 00000000..c4c973c2 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortIn.java @@ -0,0 +1,7 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports; + +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneInCmd; + +public interface UpdateForestProductNonePortIn { + void operate(UpdateForestProductNoneInCmd inCmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortOut.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortOut.java new file mode 100644 index 00000000..a181922b --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/UpdateForestProductNonePortOut.java @@ -0,0 +1,8 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports; + +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneInCmd; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneOutCmd; + +public interface UpdateForestProductNonePortOut { + void operate(UpdateForestProductNoneOutCmd outCmd); +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/UpdateForestProductNoneService.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/UpdateForestProductNoneService.java new file mode 100644 index 00000000..d998f168 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/UpdateForestProductNoneService.java @@ -0,0 +1,22 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application; + +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneOutCmd; +import lombok.RequiredArgsConstructor; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain.UpdateForestProductNoneInCmd; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.UpdateForestProductNonePortIn; +import app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.UpdateForestProductNonePortOut; +import org.springframework.stereotype.Service; + +@Service +@RequiredArgsConstructor +class UpdateForestProductNoneService implements UpdateForestProductNonePortIn { + private final UpdateForestProductNonePortOut portOut; + + @Override + public void operate(UpdateForestProductNoneInCmd inCmd) { + portOut.operate(new UpdateForestProductNoneOutCmd( + inCmd.getMonthlyInputStatusId(), + "Y".equals(inCmd.getTodayNone()) ? "NOTHING" : "NONE" + )); + } +} \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneInCmd.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneInCmd.java new file mode 100644 index 00000000..0abe0a27 --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneInCmd.java @@ -0,0 +1,13 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain; + +import lombok.AllArgsConstructor; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +public class UpdateForestProductNoneInCmd { + private Long monthlyInputStatusId; + private String todayNone; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneOutCmd.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneOutCmd.java new file mode 100644 index 00000000..1e7444dd --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateForestProductNoneOutCmd.java @@ -0,0 +1,14 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain; + +import app.module.core.config.adapters.persistence.component.AuditCommand; +import lombok.AllArgsConstructor; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +public class UpdateForestProductNoneOutCmd extends AuditCommand { + private Long monthlyInputStatusId; + private String currentStatus; +} diff --git a/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateMonthlyForestProductStatusCmd.java b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateMonthlyForestProductStatusCmd.java new file mode 100644 index 00000000..6ebac2cb --- /dev/null +++ b/admin/src/main/java/app/module/admin/usecase/household/tab/forestProduct/updateForestProductNone/ports/application/domain/UpdateMonthlyForestProductStatusCmd.java @@ -0,0 +1,15 @@ +package app.module.admin.usecase.household.tab.forestProduct.updateForestProductNone.ports.application.domain; + +import app.module.core.config.adapters.persistence.component.AuditCommand; +import lombok.AllArgsConstructor; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +@Getter +@Setter +@AllArgsConstructor +public class UpdateMonthlyForestProductStatusCmd extends AuditCommand { + private Long monthlyInputStatusId; + private String forestProductStatus; +} diff --git a/admin/src/main/resources/mappers/household/RemoveForestProductsMapper.xml b/admin/src/main/resources/mappers/household/RemoveForestProductsMapper.xml new file mode 100644 index 00000000..83329571 --- /dev/null +++ b/admin/src/main/resources/mappers/household/RemoveForestProductsMapper.xml @@ -0,0 +1,25 @@ + + + + + /* removeForestProducts : 임산물현황 삭제*/ + UPDATE forest_product + SET + WHERE id IN + + #{id} + + + + + \ No newline at end of file diff --git a/admin/src/main/resources/mappers/household/RemoveHouseholdVisitInfosMapper.xml b/admin/src/main/resources/mappers/household/RemoveHouseholdVisitInfosMapper.xml index d4a0516a..6a4ae1c6 100644 --- a/admin/src/main/resources/mappers/household/RemoveHouseholdVisitInfosMapper.xml +++ b/admin/src/main/resources/mappers/household/RemoveHouseholdVisitInfosMapper.xml @@ -3,13 +3,13 @@ "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > - - /* removeHouseholdVisitInfos : 임가방문정보 삭제 */ - UPDATE household_visit - SET - WHERE id IN - - #{id} - - + + /* removeHouseholdVisitInfos : 임가방문정보 삭제 */ + UPDATE household_visit + SET + WHERE id IN + + #{id} + + \ No newline at end of file diff --git a/admin/src/main/resources/mappers/household/SaveForestProductMapper.xml b/admin/src/main/resources/mappers/household/SaveForestProductMapper.xml index 477198a2..0f9b4dd7 100644 --- a/admin/src/main/resources/mappers/household/SaveForestProductMapper.xml +++ b/admin/src/main/resources/mappers/household/SaveForestProductMapper.xml @@ -3,6 +3,13 @@ "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > + + /* createForestProduct : 임산물 현황 등록 */ INSERT INTO forest_product diff --git a/admin/src/main/resources/mappers/household/UpdateForestProductNoneMapper.xml b/admin/src/main/resources/mappers/household/UpdateForestProductNoneMapper.xml new file mode 100644 index 00000000..2e95b510 --- /dev/null +++ b/admin/src/main/resources/mappers/household/UpdateForestProductNoneMapper.xml @@ -0,0 +1,13 @@ + + + + + /* removeForestProduct : 임산물 현황 삭제 */ + UPDATE forest_product + SET + WHERE is_deleted = false + AND monthly_input_status_id = #{monthlyInputStatusId} + + \ No newline at end of file diff --git a/admin/src/main/resources/mappers/household/UpdateMonthlyInputStatusMapper.xml b/admin/src/main/resources/mappers/household/UpdateMonthlyInputStatusMapper.xml new file mode 100644 index 00000000..be531bf9 --- /dev/null +++ b/admin/src/main/resources/mappers/household/UpdateMonthlyInputStatusMapper.xml @@ -0,0 +1,14 @@ + + + + + /* updateForestProductStatus : 임산물현황 입력상태 수정 */ + UPDATE monthly_input_status + SET forest_product_status = #{status}, + + WHERE is_deleted = false + AND id = #{id} + + \ No newline at end of file diff --git a/admin/src/main/resources/messages/operation.properties b/admin/src/main/resources/messages/operation.properties index a8608005..6ffc55b0 100644 --- a/admin/src/main/resources/messages/operation.properties +++ b/admin/src/main/resources/messages/operation.properties @@ -19,3 +19,4 @@ operation.uri.move.cannot.before=\uB354\uC774\uC0C1 \uC774\uC804\uC73C\uB85C \uC operation.uri.move.cannot.after=\uB354\uC774\uC0C1 \uB2E4\uC74C\uC73C\uB85C \uC774\uB3D9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. operation.role.save.choose.first=\uC800\uC7A5\uD560 '\uAD00\uB9AC\uC790 \uAD8C\uD55C' \uC744 \uBA3C\uC800 \uC120\uD0DD\uD558\uC138\uC694. operation.orderNo.updated=\uC815\uB82C\uC21C\uC11C\uAC00 \uBCC0\uACBD\uB418\uC5C8\uC2B5\uB2C8\uB2E4. +operation.common.update.done=\uC218\uC815\uB418\uC5C8\uC2B5\uB2C8\uB2E4. diff --git a/admin/src/main/resources/templates/common/components.html b/admin/src/main/resources/templates/common/components.html index 842c3d97..c1286df0 100644 --- a/admin/src/main/resources/templates/common/components.html +++ b/admin/src/main/resources/templates/common/components.html @@ -25,6 +25,7 @@ + diff --git a/admin/src/main/resources/templates/households/modal/modal-forest-product.html b/admin/src/main/resources/templates/households/modal/modal-forest-product.html index 6393ddb7..a8f63ae9 100644 --- a/admin/src/main/resources/templates/households/modal/modal-forest-product.html +++ b/admin/src/main/resources/templates/households/modal/modal-forest-product.html @@ -364,7 +364,7 @@ ajaxUtil._ajaxMethod( '/api/forestProduct/save', JSON.stringify(dataOj), - (response) => { // 성공 + () => { // 성공 alert("등록이 완료되었습니다."); document.querySelector(".modal-forest-product").ui.close(); diff --git a/admin/src/main/resources/templates/households/tab/forest-product.html b/admin/src/main/resources/templates/households/tab/forest-product.html index 3fd9cb03..0e8bc902 100644 --- a/admin/src/main/resources/templates/households/tab/forest-product.html +++ b/admin/src/main/resources/templates/households/tab/forest-product.html @@ -13,12 +13,19 @@
- -
@@ -73,8 +80,14 @@ // 임산물 현황 등록 상태 id set f.monthlyInputStatusId.value = response.monthlyStatus.id; - const tbody = $('.tab-content.forest-product tbody'); + // 이번달 등록내용 없음 체크 - NONE : 미등록, NOTHING : 이번달 등록내용 없음 , REGISTERED : 등록완료 + $('#forestProductStatus').attr('checked', response.monthlyStatus.forestStatus === 'NOTHING'); + + // 이번달 등록내용 없음 에 따라 버튼 hide 처리 + showForestProductNoneBtn(); + + const tbody = $('.tab-content.forest-product tbody'); tbody.empty(); if(response.forestProducts.length === 0) { @@ -90,7 +103,7 @@
@@ -123,6 +136,124 @@ 'json' ); } + + // 금일 데이터 없음에 따라 버튼 hide/show 처리 + const showForestProductNoneBtn = () => { + $('.table-tit-group').each(function(index, item) { + let checkedIndex = false; + $(item).find('[type="button"]').each(function(indexBtn, itemBtn) { + let $chkBox = $(itemBtn).find('input[type="checkbox"]'); + if (($chkBox.length !== 0 && $chkBox.is(':disabled'))) { + checkedIndex = true; + } + + if (checkedIndex) { + $(itemBtn).hide(); + } else { + $(itemBtn).show(); + } + + if ($chkBox.length !== 0) { + checkedIndex = $chkBox.is(':checked') || $chkBox.is(':disabled'); + } + }); + }); + } + + // 데이터 초기화 Confirm + const showForestProductNoneConfirm = (el) => { + const todayNone = $(el).is(':checked') ? 'Y' : 'N'; + + const obj = $(f).serializeObject(); + obj.todayNone = todayNone; + + if (todayNone === 'Y') { + etUI.dialog.confirm({ + title: '초기화 안내', + message: '등록하신 모든 내용을 삭제하시겠어요?
삭제된 내용은 복구할 수 없습니다.', + negativeCallback: function () { + $(el).prop('checked', todayNone !== 'Y'); + }, + positiveCallback: function () { + updateForestProductNone(obj); + }, + }); + + } else { + updateForestProductNone(obj); + } + } + + // 이번달 등록내용 없음 수정 처리 + const updateForestProductNone = (obj) => { + console.log(obj); + ajaxUtil._ajaxMethod( + '/api/household/forestProduct/nothing', + JSON.stringify(obj), + () => { + if (obj.todayNone === 'Y') { + alert('데이터 초기화가 완료되었습니다.'); + } else { + alert('등록 상태가 변경되었습니다.'); + } + + getForestProductsStatus(); + }, + function (code, rstData) { + + }, + 'patch', + 'json', + { handle422Type: 'alert' } + ); + } + + // 임산물현황 삭제 Confirm + const showDeleteForestProductConfirm = () => { + const checkedIds = Array.from( + document.querySelectorAll('input[name="forestRemoveIds"]:checked') + ).map(el => Number(el.value)); + + if(checkedIds.length <= 0) { + alert("임산물을 선택해주세요."); + return + } + + etUI.dialog.confirm({ + title: '삭제 안내', + message: '선택하신 내용을 삭제하시겠습니까?
삭제한 항목은 복구할 수 없습니다.', + negativeCallback: function () { + + }, + positiveCallback: function () { + goDeleteForestProduct(checkedIds); + }, + }); + } + + // 임산물현황 삭제 + const goDeleteForestProduct = (checkedIds) => { + const f = document.reqForm; + console.log("f.monthlyInputStatusId.value", f.monthlyInputStatusId.value); + + ajaxUtil._ajaxMethod( + '/api/household/forestProducts/delete', + JSON.stringify({ + monthlyInputStatusId: f.monthlyInputStatusId.value, + forestRemoveIds: checkedIds + }), + () => { // 성공 + alert("임산물현황이 삭제되었습니다."); + getForestProductsStatus(); + }, + function (code, rstData) { + if(code == 422) alert(rstData.responseText); + }, + 'delete', + 'json', + { handle422Type: 'alert' } + ); + }
\ No newline at end of file From d19d948cae96055fd1ab88764487318bd1f113db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A3=BC=EC=88=98=ED=98=84?= Date: Fri, 27 Jun 2025 09:12:49 +0900 Subject: [PATCH 03/13] =?UTF-8?q?=EC=A1=B0=EC=82=AC=EC=9B=90=20=EC=A0=84?= =?UTF-8?q?=EC=B2=B4=20=EA=B2=80=EC=83=89=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/mappers/researcher/ResearcherMapper.xml | 3 +++ .../src/main/resources/templates/researcher/researchers.html | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/admin/src/main/resources/mappers/researcher/ResearcherMapper.xml b/admin/src/main/resources/mappers/researcher/ResearcherMapper.xml index 38a44745..d3ee37ca 100644 --- a/admin/src/main/resources/mappers/researcher/ResearcherMapper.xml +++ b/admin/src/main/resources/mappers/researcher/ResearcherMapper.xml @@ -19,6 +19,9 @@ left join household h ON h.seq = rhh.household_seq AND h.is_panel IS true and h.is_deleted = false where ahr.role_id = 'ROLE_RESEARCHER' + + and ( a.name LIKE CONCAT('%', #{searchValue}, '%') or a.phone LIKE CONCAT('%', #{searchValue}, '%') ) + and a.name LIKE CONCAT('%', #{searchValue}, '%') diff --git a/admin/src/main/resources/templates/researcher/researchers.html b/admin/src/main/resources/templates/researcher/researchers.html index 493ec830..a2614f5a 100644 --- a/admin/src/main/resources/templates/researcher/researchers.html +++ b/admin/src/main/resources/templates/researcher/researchers.html @@ -25,7 +25,7 @@
- +
@@ -181,6 +181,8 @@ f.searchValue.value = ''; f.searchArea.value = ''; f.searchAccountDisabled.value = ''; + f.method = 'GET'; + f.submit(); } // 상세페이지 이동 function goDetail(seq) { From 4a97d8316d4b43173e55464f7fd4f01f7358b18f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=98=84=EC=A3=BC?= Date: Fri, 27 Jun 2025 09:13:38 +0900 Subject: [PATCH 04/13] =?UTF-8?q?[FO]=20=EC=9D=BC=EA=B3=84=EB=B6=80=20?= =?UTF-8?q?=ED=85=8C=EC=8A=A4=ED=8A=B8=20=EB=8D=B0=EC=9D=B4=ED=84=B0=20?= =?UTF-8?q?=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/templates/record/farming/index.html | 8 -------- .../src/main/resources/templates/record/income/index.html | 7 ------- 2 files changed, 15 deletions(-) diff --git a/front/src/main/resources/templates/record/farming/index.html b/front/src/main/resources/templates/record/farming/index.html index 3e272f2e..69149ba5 100644 --- a/front/src/main/resources/templates/record/farming/index.html +++ b/front/src/main/resources/templates/record/farming/index.html @@ -3,19 +3,11 @@ xmlns:th="http://www.thymeleaf.org" lang="ko">
- [[${dailyRecord.registrable}]] - [[${moveStep}]], - [[${dailyRecord.modifiable}]] - -- - [[${(not dailyRecord.modifiable)}]] -
- - [[${btnActive}]], [[${btnDisabled}]], [[${btnIcoClass}]]

diff --git a/front/src/main/resources/templates/record/income/index.html b/front/src/main/resources/templates/record/income/index.html index b1b76628..c998170c 100644 --- a/front/src/main/resources/templates/record/income/index.html +++ b/front/src/main/resources/templates/record/income/index.html @@ -10,13 +10,6 @@
detail: [[${dailyRecord}]]
-
- [[${dailyRecord.registrable}]] - [[${moveStep}]], - [[${dailyRecord.modifiable}]] -
- //http://localhost:8080/record/income/202505/12?type=step1&target=income -
4) { - errors.rejectValue("name", "error.name", "이름은 4자리까지 입력가능합니다."); + if (vo.getName().length() > 5) { + errors.rejectValue("name", "error.name", "이름은 5자리까지 입력가능합니다."); } if (vo.getPhone1() == null || vo.getPhone1().isBlank()) { errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요."); diff --git a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java index c6224ddd..234e92db 100644 --- a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java +++ b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java @@ -34,8 +34,8 @@ public class AdminUpdateValidator implements Validator { if (vo.getName() == null || vo.getName().isBlank()) { errors.rejectValue("name", "error.name", "이름을 입력해주세요."); } - if (vo.getName().length() > 4) { - errors.rejectValue("name", "error.name", "이름은 4자리까지 입력가능합니다."); + if (vo.getName().length() > 5) { + errors.rejectValue("name", "error.name", "이름은 5자리까지 입력가능합니다."); } if (vo.getPhone1() == null || vo.getPhone1().isBlank()) { errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요."); diff --git a/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/persistence/ResearcherDao.java b/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/persistence/ResearcherDao.java index 4b9a68a9..384afe87 100644 --- a/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/persistence/ResearcherDao.java +++ b/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/persistence/ResearcherDao.java @@ -115,4 +115,5 @@ public class ResearcherDao implements ResearcherPortOut { } return i; } + } diff --git a/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/web/ResearcherApiController.java b/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/web/ResearcherApiController.java index b96e643f..c62fedb7 100644 --- a/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/web/ResearcherApiController.java +++ b/admin/src/main/java/app/module/admin/usecase/researcher/adpaters/web/ResearcherApiController.java @@ -17,6 +17,7 @@ import java.util.Objects; @RequiredArgsConstructor @RequestMapping(path = "/api/researcher") class ResearcherApiController { + private final ResearcherPortIn researcherPortIn; @GetMapping(path = "/list") @@ -63,4 +64,5 @@ class ResearcherApiController { ResponseEntity updateMappingHousehold(@RequestBody MappingHouseholdListReqVO reqVO ) { return ResponseEntity.status(HttpStatus.OK).body(researcherPortIn.updateMappingHousehold(reqVO)); } + } \ No newline at end of file diff --git a/admin/src/main/java/app/module/admin/usecase/researcher/ports/ResearcherPortIn.java b/admin/src/main/java/app/module/admin/usecase/researcher/ports/ResearcherPortIn.java index 3ac93585..33922633 100644 --- a/admin/src/main/java/app/module/admin/usecase/researcher/ports/ResearcherPortIn.java +++ b/admin/src/main/java/app/module/admin/usecase/researcher/ports/ResearcherPortIn.java @@ -7,6 +7,7 @@ import org.springframework.data.domain.Page; import java.util.List; public interface ResearcherPortIn { + Page list(ResearchersListReqVO reqVO); ResearchersDto detail(Integer adminSeq); Page mappingHouseholdList(ResearchersDetailReqVO reqVO); @@ -17,4 +18,5 @@ public interface ResearcherPortIn { Integer visitHouseholdDelete(List selectIds); Page searchMappingHousehold(HouseholdSearchReqVO reqVO); Integer updateMappingHousehold(MappingHouseholdListReqVO reqVO); + } \ No newline at end of file diff --git a/admin/src/main/resources/templates/admin/adminList.html b/admin/src/main/resources/templates/admin/adminList.html index 9621a528..5514f9a3 100644 --- a/admin/src/main/resources/templates/admin/adminList.html +++ b/admin/src/main/resources/templates/admin/adminList.html @@ -165,7 +165,6 @@ f.searchDisabled.value = ''; } - function goUpdate(adminId) { location.href = '/settings/admins/update/' + adminId; // 쿼리 파라미터 없이 이동 } From 7a3b8e3d244612aa3865d687d243ae096a27a083 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=98=84=EC=A3=BC?= Date: Fri, 27 Jun 2025 10:13:57 +0900 Subject: [PATCH 07/13] =?UTF-8?q?[FO]=20=EC=84=B8=EC=85=98=20=EB=A7=8C?= =?UTF-8?q?=EB=A3=8C=EC=8B=9C=20=EB=A1=9C=EA=B7=B8=EC=9D=B8=20=ED=8E=98?= =?UTF-8?q?=EC=9D=B4=EC=A7=80=EB=A1=9C=20=EC=9D=B4=EB=8F=99=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../config/application/security/FrontSecurityConfig.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/front/src/main/java/app/module/front/config/application/security/FrontSecurityConfig.java b/front/src/main/java/app/module/front/config/application/security/FrontSecurityConfig.java index 5e6565b7..5fc37dc2 100644 --- a/front/src/main/java/app/module/front/config/application/security/FrontSecurityConfig.java +++ b/front/src/main/java/app/module/front/config/application/security/FrontSecurityConfig.java @@ -101,7 +101,9 @@ public class FrontSecurityConfig { .clearAuthentication(true) .logoutRequestMatcher(new AntPathRequestMatcher("/logout"))) .sessionManagement( - session -> session.maximumSessions(maxSessionNum).maxSessionsPreventsLogin(false)) + session -> session.maximumSessions(maxSessionNum).maxSessionsPreventsLogin(false).expiredUrl("/login")) + .sessionManagement( + session -> session.invalidSessionUrl("/login")) .oauth2Login( config -> config From bf2549afbae21dd5340ea510b8eb2ff87bec69b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A3=BC=EC=88=98=ED=98=84?= Date: Fri, 27 Jun 2025 10:19:24 +0900 Subject: [PATCH 08/13] =?UTF-8?q?=EC=9D=B4=EB=A6=84=2010=EC=9E=90=EA=B9=8C?= =?UTF-8?q?=EC=A7=80=EB=A1=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../adapters/web/validator/AdminCreateValidator.java | 4 ++-- .../adapters/web/validator/AdminUpdateValidator.java | 4 ++-- .../src/main/resources/templates/admin/adminCreateForm.html | 6 +++--- .../src/main/resources/templates/admin/adminUpdateForm.html | 6 +++--- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminCreateValidator.java b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminCreateValidator.java index a31772eb..b3a169af 100644 --- a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminCreateValidator.java +++ b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminCreateValidator.java @@ -48,8 +48,8 @@ public class AdminCreateValidator implements Validator { if (vo.getName() == null || vo.getName().isBlank()) { errors.rejectValue("name", "error.name", "이름을 입력해주세요."); } - if (vo.getName().length() > 5) { - errors.rejectValue("name", "error.name", "이름은 5자리까지 입력가능합니다."); + if (vo.getName().length() > 10) { + errors.rejectValue("name", "error.name", "이름은 10자까지 입력가능합니다."); } if (vo.getPhone1() == null || vo.getPhone1().isBlank()) { errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요."); diff --git a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java index 234e92db..784e068f 100644 --- a/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java +++ b/admin/src/main/java/app/module/admin/usecase/admin/saveAdmin/adapters/web/validator/AdminUpdateValidator.java @@ -34,8 +34,8 @@ public class AdminUpdateValidator implements Validator { if (vo.getName() == null || vo.getName().isBlank()) { errors.rejectValue("name", "error.name", "이름을 입력해주세요."); } - if (vo.getName().length() > 5) { - errors.rejectValue("name", "error.name", "이름은 5자리까지 입력가능합니다."); + if (vo.getName().length() > 10) { + errors.rejectValue("name", "error.name", "이름은 10자까지 입력가능합니다."); } if (vo.getPhone1() == null || vo.getPhone1().isBlank()) { errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요."); diff --git a/admin/src/main/resources/templates/admin/adminCreateForm.html b/admin/src/main/resources/templates/admin/adminCreateForm.html index c90a34b1..75357bdf 100644 --- a/admin/src/main/resources/templates/admin/adminCreateForm.html +++ b/admin/src/main/resources/templates/admin/adminCreateForm.html @@ -79,7 +79,7 @@
+ th:field="*{name}" maxlength="10"/>
에러 메세지 @@ -97,12 +97,12 @@
- +
- +
diff --git a/admin/src/main/resources/templates/admin/adminUpdateForm.html b/admin/src/main/resources/templates/admin/adminUpdateForm.html index 0ae44a50..b460a668 100644 --- a/admin/src/main/resources/templates/admin/adminUpdateForm.html +++ b/admin/src/main/resources/templates/admin/adminUpdateForm.html @@ -71,7 +71,7 @@
+ th:field="*{name}" maxlength="10" />
에러 메세지 @@ -89,7 +89,7 @@
-
@@ -99,7 +99,7 @@
-
From 38451478e4dd1adbc03199e776dac5d06d044084 Mon Sep 17 00:00:00 2001 From: kangsunlee Date: Fri, 27 Jun 2025 10:58:40 +0900 Subject: [PATCH 09/13] =?UTF-8?q?[FO]=20=EB=A7=88=EC=9D=B4=ED=8E=98?= =?UTF-8?q?=EC=9D=B4=EC=A7=80=20=EC=88=98=EC=A0=95=EC=82=AC=ED=95=AD=20?= =?UTF-8?q?=EB=B0=98=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../households/modal/modal-visit-info.html | 5 +- .../households/tab/forest-product.html | 4 -- .../households/tab/household-visit.html | 57 +++++++++++-------- .../adapters/web/model/UpdateUserReqVO.java | 8 +-- .../resources/templates/info/bank/input.html | 5 +- .../templates/info/bank/inputForm.html | 9 ++- .../resources/templates/info/bank/output.html | 5 +- .../templates/info/bank/outputForm.html | 1 - 8 files changed, 52 insertions(+), 42 deletions(-) diff --git a/admin/src/main/resources/templates/households/modal/modal-visit-info.html b/admin/src/main/resources/templates/households/modal/modal-visit-info.html index 1420a0af..5f5f997e 100644 --- a/admin/src/main/resources/templates/households/modal/modal-visit-info.html +++ b/admin/src/main/resources/templates/households/modal/modal-visit-info.html @@ -145,6 +145,7 @@ (response) => { console.log("임가방문정보 상세 응답값 : ", response); setVisitFormData(response); + document.querySelector(".modal-visit-info").ui.open(); }, function (code, rstData) { console.log("error : ", code); @@ -152,9 +153,9 @@ 'get', 'json' ); + } else { + document.querySelector(".modal-visit-info").ui.open(); } - - document.querySelector(".modal-visit-info").ui.open(); } // 임가방문정보 상세 값 set diff --git a/admin/src/main/resources/templates/households/tab/forest-product.html b/admin/src/main/resources/templates/households/tab/forest-product.html index 0e8bc902..7d54dc4c 100644 --- a/admin/src/main/resources/templates/households/tab/forest-product.html +++ b/admin/src/main/resources/templates/households/tab/forest-product.html @@ -222,9 +222,6 @@ etUI.dialog.confirm({ title: '삭제 안내', message: '선택하신 내용을 삭제하시겠습니까?
삭제한 항목은 복구할 수 없습니다.', - negativeCallback: function () { - - }, positiveCallback: function () { goDeleteForestProduct(checkedIds); }, @@ -234,7 +231,6 @@ // 임산물현황 삭제 const goDeleteForestProduct = (checkedIds) => { const f = document.reqForm; - console.log("f.monthlyInputStatusId.value", f.monthlyInputStatusId.value); ajaxUtil._ajaxMethod( '/api/household/forestProducts/delete', diff --git a/admin/src/main/resources/templates/households/tab/household-visit.html b/admin/src/main/resources/templates/households/tab/household-visit.html index e7545c37..f286fb36 100644 --- a/admin/src/main/resources/templates/households/tab/household-visit.html +++ b/admin/src/main/resources/templates/households/tab/household-visit.html @@ -10,7 +10,7 @@

-
diff --git a/front/src/main/java/app/module/front/usecase/info/userUI/updateUserUI/adapters/web/model/UpdateUserReqVO.java b/front/src/main/java/app/module/front/usecase/info/userUI/updateUserUI/adapters/web/model/UpdateUserReqVO.java index 2a87c84c..041b0c64 100644 --- a/front/src/main/java/app/module/front/usecase/info/userUI/updateUserUI/adapters/web/model/UpdateUserReqVO.java +++ b/front/src/main/java/app/module/front/usecase/info/userUI/updateUserUI/adapters/web/model/UpdateUserReqVO.java @@ -11,7 +11,7 @@ import lombok.NoArgsConstructor; public class UpdateUserReqVO { @NotBlank(message = "이름을 입력해주세요.")//"이름은 필수 항목입니다.") - @Pattern(regexp = "^[가-힣]{2,10}$", message = "이름을 입력해주세요.")//"이름은 2~10자의 한글이어야 합니다.") + @Pattern(regexp = "^[가-힣0-9()]{2,10}$", message = "이름을 입력해주세요.")//"이름은 2~10자의 한글이어야 합니다.") private String ownerName; @NotNull(message = "나이를 입력해주세요.") @@ -19,13 +19,13 @@ public class UpdateUserReqVO { @Max(value = 120, message = "나이를 입력해주세요.")//"나이는 120세 이하이어야 합니다.") private Integer ownerAge; - @Pattern(regexp = "^\\d{2,3}$", message = "가구 연락처를 입력해주세요.")//"가구 연락처는 2~3자리 숫자여야 합니다.") + @Pattern(regexp = "^$|^\\d{2,3}$", message = "가구 연락처를 입력해주세요.")//"가구 연락처는 2~3자리 숫자여야 합니다.") private String tel1; - @Pattern(regexp = "^\\d{3,4}$", message = "가구 연락처를 입력해주세요.")//"가운데 번호는 3~4자리 숫자여야 합니다.") + @Pattern(regexp = "^$|^\\d{3,4}$", message = "가구 연락처를 입력해주세요.")//"가운데 번호는 3~4자리 숫자여야 합니다.") private String tel2; - @Pattern(regexp = "^\\d{4}$", message = "가구 연락처를 입력해주세요.")//"끝 번호는 4자리 숫자여야 합니다.") + @Pattern(regexp = "^$|^\\d{4}$", message = "가구 연락처를 입력해주세요.")//"끝 번호는 4자리 숫자여야 합니다.") private String tel3; @Pattern(regexp = "^\\d{2,3}$", message = "휴대폰 번호를 입력해주세요.")//"휴대폰 번호는 2~3자리 숫자여야 합니다.") diff --git a/front/src/main/resources/templates/info/bank/input.html b/front/src/main/resources/templates/info/bank/input.html index 83002cc4..488a7b19 100644 --- a/front/src/main/resources/templates/info/bank/input.html +++ b/front/src/main/resources/templates/info/bank/input.html @@ -369,7 +369,6 @@ errors.push({field: form.transferCategoryCode.value+"_value", message: '수입대상을 입력해주세요.'}); } } - if (!form.sourcePurpose.value) errors.push({field: 'sourcePurpose', message: '수입원을 입력해주세요.'}); if(form.count.value){ if(!form.unitCode.value){ @@ -559,7 +558,9 @@
  • 재배형태

    ${getCrop(product.cropCode)}
  • -
  • 수입원

    ${product.sourcePurpose}
  • + ${product.sourcePurpose != null && product.sourcePurpose != '' + ? `
  • 수입원

    ${product.sourcePurpose}
  • ` + : ''} ${tagCount}
  • 현금

    ${format(product.price)}원
diff --git a/front/src/main/resources/templates/info/bank/inputForm.html b/front/src/main/resources/templates/info/bank/inputForm.html index ae59b020..f4b0c739 100644 --- a/front/src/main/resources/templates/info/bank/inputForm.html +++ b/front/src/main/resources/templates/info/bank/inputForm.html @@ -86,12 +86,16 @@
-
- +
+
+
+
@@ -100,7 +104,6 @@
diff --git a/front/src/main/resources/templates/info/bank/output.html b/front/src/main/resources/templates/info/bank/output.html index 7a6a27dd..b72e077b 100644 --- a/front/src/main/resources/templates/info/bank/output.html +++ b/front/src/main/resources/templates/info/bank/output.html @@ -361,7 +361,6 @@ } } - if (!form.sourcePurpose.value) errors.push({field: 'sourcePurpose', message: '용도 입력해주세요.'}); if(form.count.value){ if(!form.unitCode.value){ errors.push({ @@ -552,7 +551,9 @@ ${buttonGroupHtml}
    -
  • 용도

    ${product.sourcePurpose}
  • + ${product.sourcePurpose != null && product.sourcePurpose != '' + ? `
  • 용도

    ${product.sourcePurpose}
  • ` + : ''} ${tagCount}
  • 현금

    ${format(product.price)}원
diff --git a/front/src/main/resources/templates/info/bank/outputForm.html b/front/src/main/resources/templates/info/bank/outputForm.html index 9b6461ff..7abf796c 100644 --- a/front/src/main/resources/templates/info/bank/outputForm.html +++ b/front/src/main/resources/templates/info/bank/outputForm.html @@ -63,7 +63,6 @@
From f4496934df2ae6afb43364e88a5fc9f89a0dc1d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=98=84=EC=A3=BC?= Date: Fri, 27 Jun 2025 11:12:46 +0900 Subject: [PATCH 10/13] =?UTF-8?q?[FO]=20=EB=B9=84=EB=B0=80=EB=B2=88?= =?UTF-8?q?=ED=98=B8=20inputmode,=20=EB=85=B8=EB=8F=99=EC=9D=98=20?= =?UTF-8?q?=ED=95=84=EC=88=98=EC=9E=85=EB=A0=A5=20=EC=88=98=EC=A0=95,=20fo?= =?UTF-8?q?rmContrl.init=20=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../config/constants/CommonConstants.java | 5 ++++ .../CreateDailyFarmingValidator.java | 3 +- .../validator/CreateDailyWorkValidator.java | 29 +++++++++++++++---- .../src/main/resources/static/ui/ajaxUtil.js | 2 +- .../resources/static/ui/page/daily-record.js | 2 -- .../templates/record/expense/index.html | 6 +--- .../templates/record/farming/index.html | 4 --- .../templates/record/forestry/index.html | 4 --- .../templates/record/income/index.html | 4 --- .../templates/record/power/index.html | 4 --- .../resources/templates/record/work/form.html | 5 ++-- .../templates/record/work/index.html | 4 --- .../resources/templates/security/login.html | 2 +- 13 files changed, 36 insertions(+), 38 deletions(-) diff --git a/front/src/main/java/app/module/front/config/constants/CommonConstants.java b/front/src/main/java/app/module/front/config/constants/CommonConstants.java index edb03e6a..d961abbb 100644 --- a/front/src/main/java/app/module/front/config/constants/CommonConstants.java +++ b/front/src/main/java/app/module/front/config/constants/CommonConstants.java @@ -9,4 +9,9 @@ public class CommonConstants { * 단위의 직접입력 코드 */ public static final String UNIT_CODE_SELF = "code.record.unit.self"; + + /** + * 작업 면적의 직접입력 코드 + */ + public static final String AREA_CODE_OTHER = "code.record.area.self"; } diff --git a/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java b/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java index 4b6c7271..67b37635 100644 --- a/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java @@ -1,5 +1,6 @@ package app.module.front.usecase.daily.farming.adapters.web.validator; +import app.module.front.config.constants.CommonConstants; import app.module.front.usecase.daily.farming.adapters.web.model.CreateDailyFarmingReqVO; import lombok.RequiredArgsConstructor; import org.apache.tika.utils.StringUtils; @@ -20,7 +21,7 @@ public class CreateDailyFarmingValidator implements Validator { public void validate(Object target, Errors errors) { CreateDailyFarmingReqVO vo = (CreateDailyFarmingReqVO) target; - if ("SELF".equals(vo.getProductCode()) && StringUtils.isBlank(vo.getProductSelf())) { + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getProductCode()) && StringUtils.isBlank(vo.getProductSelf())) { errors.rejectValue( "categorySelf", "valid.common.required", "생산물을 입력해 주세요."); diff --git a/front/src/main/java/app/module/front/usecase/daily/work/adapters/web/validator/CreateDailyWorkValidator.java b/front/src/main/java/app/module/front/usecase/daily/work/adapters/web/validator/CreateDailyWorkValidator.java index 4cdce78c..1d01ff9d 100644 --- a/front/src/main/java/app/module/front/usecase/daily/work/adapters/web/validator/CreateDailyWorkValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/work/adapters/web/validator/CreateDailyWorkValidator.java @@ -1,5 +1,6 @@ package app.module.front.usecase.daily.work.adapters.web.validator; +import app.module.front.config.constants.CommonConstants; import app.module.front.usecase.daily.work.adapters.web.model.CreateDailyWorkReqVO; import lombok.RequiredArgsConstructor; import org.apache.tika.utils.StringUtils; @@ -20,19 +21,37 @@ public class CreateDailyWorkValidator implements Validator { public void validate(Object target, Errors errors) { CreateDailyWorkReqVO vo = (CreateDailyWorkReqVO) target; - if (vo.getHarvestQuantity() == null) { + if (vo.getWorkLandArea() == null && !StringUtils.isBlank(vo.getAreaUnitCode())) { errors.rejectValue( - "harvestQuantity", "valid.common.required", - "수확량을 입력해 주세요."); + "workLandArea", "valid.common.required", + "작업 면적을 입력해 주세요."); } - if ("SELF".equals(vo.getAreaUnitCode()) && StringUtils.isBlank(vo.getAreaUnitSelf())) { + if (vo.getWorkLandArea() != null && StringUtils.isBlank(vo.getAreaUnitCode())) { + errors.rejectValue( + "areaUnitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.AREA_CODE_OTHER.equals(vo.getAreaUnitCode()) && StringUtils.isBlank(vo.getAreaUnitSelf())) { errors.rejectValue( "areaUnitSelf", "valid.common.required", "단위를 입력해 주세요."); } - if ("SELF".equals(vo.getHarvestUnitCode()) && StringUtils.isBlank(vo.getHarvestUnitSelf())) { + if (vo.getHarvestQuantity() == null && !StringUtils.isBlank(vo.getHarvestUnitCode())) { + errors.rejectValue( + "harvestQuantity", "valid.common.required", + "수확량을 입력해 주세요."); + } + + if (vo.getHarvestQuantity() != null && StringUtils.isBlank(vo.getHarvestUnitCode())) { + errors.rejectValue( + "harvestUnitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getHarvestUnitCode()) && StringUtils.isBlank(vo.getHarvestUnitSelf())) { errors.rejectValue( "harvestUnitSelf", "valid.common.required", "단위를 입력해 주세요."); diff --git a/front/src/main/resources/static/ui/ajaxUtil.js b/front/src/main/resources/static/ui/ajaxUtil.js index 87bbe7cb..bfa4aa42 100644 --- a/front/src/main/resources/static/ui/ajaxUtil.js +++ b/front/src/main/resources/static/ui/ajaxUtil.js @@ -223,7 +223,7 @@ var ajaxUtil = { infoBox = $('
    ').appendTo(component); } - infoBox.html('
  • ' + oj.message + '1111
  • '); + infoBox.html('
  • ' + oj.message + '
  • '); } } diff --git a/front/src/main/resources/static/ui/page/daily-record.js b/front/src/main/resources/static/ui/page/daily-record.js index 353d3640..b5347fe0 100644 --- a/front/src/main/resources/static/ui/page/daily-record.js +++ b/front/src/main/resources/static/ui/page/daily-record.js @@ -95,8 +95,6 @@ krip.daily.baseBindUI = function() { //document.reqForm.todayNone.value = 'N'; $noneWrap.val('N'); } - // TODO 2번 이벤트 발생하는 원인 찾기 - console.log(1111) krip.daily.todayNone(ENV.month, ENV.groupNo, $noneWrap.data('type'), checked); }); diff --git a/front/src/main/resources/templates/record/expense/index.html b/front/src/main/resources/templates/record/expense/index.html index a339c6d6..95b8b5c9 100644 --- a/front/src/main/resources/templates/record/expense/index.html +++ b/front/src/main/resources/templates/record/expense/index.html @@ -20,7 +20,7 @@ 지출 내역 [[${#lists.isEmpty(expenseList) ? 0 : #lists.size(expenseList)}]]건 등록
    되었습니다.

    -

    지출 내역을 등록해 주세요..

    +

    지출 내역을 등록해 주세요.

    등록 내용을 확인하거나 다음 단계로 이동하세요.

    @@ -140,10 +140,6 @@
    From b441837da625c1096f55cfe15e5c4bb1bb643d06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=98=84=EC=A3=BC?= Date: Fri, 27 Jun 2025 11:45:42 +0900 Subject: [PATCH 13/13] =?UTF-8?q?[FO]=20=EC=88=98=EB=9F=89=EA=B3=BC=20?= =?UTF-8?q?=EB=8B=A8=EC=9C=84=EC=9D=98=20valid=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CreateDailyExpenseValidator.java | 24 ++++++++++++++----- .../CreateDailyFarmingValidator.java | 18 ++++++++++++++ .../CreateDailyForestryValidator.java | 19 +++++++++++++++ .../validator/CreateDailyIncomeValidator.java | 24 ++++++++++++++----- .../src/main/resources/static/ui/ajaxUtil.js | 2 +- .../templates/record/expense/form.html | 2 +- .../templates/record/farming/form.html | 2 +- .../templates/record/forestry/form.html | 2 +- .../templates/record/income/form.html | 2 +- 9 files changed, 78 insertions(+), 17 deletions(-) diff --git a/front/src/main/java/app/module/front/usecase/daily/expense/adapters/web/validator/CreateDailyExpenseValidator.java b/front/src/main/java/app/module/front/usecase/daily/expense/adapters/web/validator/CreateDailyExpenseValidator.java index 9bdfedc1..a67f79c1 100644 --- a/front/src/main/java/app/module/front/usecase/daily/expense/adapters/web/validator/CreateDailyExpenseValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/expense/adapters/web/validator/CreateDailyExpenseValidator.java @@ -21,6 +21,24 @@ public class CreateDailyExpenseValidator implements Validator { public void validate(Object target, Errors errors) { CreateDailyExpenseReqVO vo = (CreateDailyExpenseReqVO) target; + if (vo.getQuantity() == null && !StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "quantity", "valid.common.required", + "수량을 입력해 주세요."); + } + + if (vo.getQuantity() != null && StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "unitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { + errors.rejectValue( + "unitSelf", "valid.common.required", + "단위를 입력해 주세요."); + } + if (vo.getPrice() == null && vo.getEstimatedValue() == null) { errors.rejectValue( "price", "valid.common.required", @@ -29,11 +47,5 @@ public class CreateDailyExpenseValidator implements Validator { "estimatedValue", "valid.common.required", "현금 또는 현물평가액을 입력해 주세요."); } - - if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { - errors.rejectValue( - "unitSelf", "valid.common.required", - "단위를 입력해 주세요."); - } } } diff --git a/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java b/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java index 67b37635..e112ce1f 100644 --- a/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/farming/adapters/web/validator/CreateDailyFarmingValidator.java @@ -27,6 +27,24 @@ public class CreateDailyFarmingValidator implements Validator { "생산물을 입력해 주세요."); } + if (vo.getQuantity() == null && !StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "quantity", "valid.common.required", + "수량을 입력해 주세요."); + } + + if (vo.getQuantity() != null && StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "unitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { + errors.rejectValue( + "unitSelf", "valid.common.required", + "단위를 입력해 주세요."); + } + if (vo.getEstimatedValue() == null) { errors.rejectValue( "estimatedValue", "valid.common.required", diff --git a/front/src/main/java/app/module/front/usecase/daily/forestry/adapters/web/validator/CreateDailyForestryValidator.java b/front/src/main/java/app/module/front/usecase/daily/forestry/adapters/web/validator/CreateDailyForestryValidator.java index 5d198bbd..1ca14c4a 100644 --- a/front/src/main/java/app/module/front/usecase/daily/forestry/adapters/web/validator/CreateDailyForestryValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/forestry/adapters/web/validator/CreateDailyForestryValidator.java @@ -1,5 +1,6 @@ package app.module.front.usecase.daily.forestry.adapters.web.validator; +import app.module.front.config.constants.CommonConstants; import app.module.front.usecase.daily.forestry.adapters.web.model.CreateDailyForestryReqVO; import lombok.RequiredArgsConstructor; import org.apache.tika.utils.StringUtils; @@ -20,6 +21,24 @@ public class CreateDailyForestryValidator implements Validator { public void validate(Object target, Errors errors) { CreateDailyForestryReqVO vo = (CreateDailyForestryReqVO) target; + if (vo.getQuantity() == null && !StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "quantity", "valid.common.required", + "수량을 입력해 주세요."); + } + + if (vo.getQuantity() != null && StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "unitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { + errors.rejectValue( + "unitSelf", "valid.common.required", + "단위를 입력해 주세요."); + } + if (vo.getEstimatedValue() == null) { errors.rejectValue( "estimatedValue", "valid.common.required", diff --git a/front/src/main/java/app/module/front/usecase/daily/income/adapters/web/validator/CreateDailyIncomeValidator.java b/front/src/main/java/app/module/front/usecase/daily/income/adapters/web/validator/CreateDailyIncomeValidator.java index e8667e4f..8983829a 100644 --- a/front/src/main/java/app/module/front/usecase/daily/income/adapters/web/validator/CreateDailyIncomeValidator.java +++ b/front/src/main/java/app/module/front/usecase/daily/income/adapters/web/validator/CreateDailyIncomeValidator.java @@ -21,6 +21,24 @@ public class CreateDailyIncomeValidator implements Validator { public void validate(Object target, Errors errors) { CreateDailyIncomeReqVO vo = (CreateDailyIncomeReqVO) target; + if (vo.getQuantity() == null && !StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "quantity", "valid.common.required", + "수량을 입력해 주세요."); + } + + if (vo.getQuantity() != null && StringUtils.isBlank(vo.getUnitCode())) { + errors.rejectValue( + "unitCode", "valid.common.required", + "단위를 선택해 주세요."); + } + + if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { + errors.rejectValue( + "unitSelf", "valid.common.required", + "단위를 입력해 주세요."); + } + if (vo.getPrice() == null && vo.getEstimatedValue() == null) { errors.rejectValue( "price", "valid.common.required", @@ -29,11 +47,5 @@ public class CreateDailyIncomeValidator implements Validator { "estimatedValue", "valid.common.required", "현금 또는 현물평가액을 입력해 주세요."); } - - if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) { - errors.rejectValue( - "unitSelf", "valid.common.required", - "단위를 입력해 주세요."); - } } } diff --git a/front/src/main/resources/static/ui/ajaxUtil.js b/front/src/main/resources/static/ui/ajaxUtil.js index 7a498220..65508942 100644 --- a/front/src/main/resources/static/ui/ajaxUtil.js +++ b/front/src/main/resources/static/ui/ajaxUtil.js @@ -180,7 +180,7 @@ var ajaxUtil = { if (formElement.length > 0) { $(formElement).find('.component-input').removeClass('input-invalid'); $(formElement).find('.input-flex-group').removeClass('invalid'); - $(formElement).find('.select-group').removeClass('input-invalid'); + $(formElement).find('.select-group').removeClass('select-invalid'); $(formElement).find('.input-info').each(function () { $(this).remove(); }); diff --git a/front/src/main/resources/templates/record/expense/form.html b/front/src/main/resources/templates/record/expense/form.html index a40636c3..b9d87fa9 100644 --- a/front/src/main/resources/templates/record/expense/form.html +++ b/front/src/main/resources/templates/record/expense/form.html @@ -93,7 +93,7 @@

    - + diff --git a/front/src/main/resources/templates/record/farming/form.html b/front/src/main/resources/templates/record/farming/form.html index e3bce5d6..ea11e632 100644 --- a/front/src/main/resources/templates/record/farming/form.html +++ b/front/src/main/resources/templates/record/farming/form.html @@ -80,7 +80,7 @@

    - + diff --git a/front/src/main/resources/templates/record/forestry/form.html b/front/src/main/resources/templates/record/forestry/form.html index 1cd4749b..db4bbca8 100644 --- a/front/src/main/resources/templates/record/forestry/form.html +++ b/front/src/main/resources/templates/record/forestry/form.html @@ -55,7 +55,7 @@

    - + diff --git a/front/src/main/resources/templates/record/income/form.html b/front/src/main/resources/templates/record/income/form.html index 9baacbdd..a7a8cf04 100644 --- a/front/src/main/resources/templates/record/income/form.html +++ b/front/src/main/resources/templates/record/income/form.html @@ -123,7 +123,7 @@

    - +