Merge branch 'dev' into 'deploy-dev-admin'
Dev See merge request korea-research/korea-research!59
This commit is contained in:
@@ -145,6 +145,7 @@
|
|||||||
(response) => {
|
(response) => {
|
||||||
console.log("임가방문정보 상세 응답값 : ", response);
|
console.log("임가방문정보 상세 응답값 : ", response);
|
||||||
setVisitFormData(response);
|
setVisitFormData(response);
|
||||||
|
document.querySelector(".modal-visit-info").ui.open();
|
||||||
},
|
},
|
||||||
function (code, rstData) {
|
function (code, rstData) {
|
||||||
console.log("error : ", code);
|
console.log("error : ", code);
|
||||||
@@ -152,9 +153,9 @@
|
|||||||
'get',
|
'get',
|
||||||
'json'
|
'json'
|
||||||
);
|
);
|
||||||
|
} else {
|
||||||
|
document.querySelector(".modal-visit-info").ui.open();
|
||||||
}
|
}
|
||||||
|
|
||||||
document.querySelector(".modal-visit-info").ui.open();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 임가방문정보 상세 값 set
|
// 임가방문정보 상세 값 set
|
||||||
|
|||||||
@@ -222,9 +222,6 @@
|
|||||||
etUI.dialog.confirm({
|
etUI.dialog.confirm({
|
||||||
title: '삭제 안내',
|
title: '삭제 안내',
|
||||||
message: '선택하신 내용을 삭제하시겠습니까?<br>삭제한 항목은 복구할 수 없습니다.',
|
message: '선택하신 내용을 삭제하시겠습니까?<br>삭제한 항목은 복구할 수 없습니다.',
|
||||||
negativeCallback: function () {
|
|
||||||
|
|
||||||
},
|
|
||||||
positiveCallback: function () {
|
positiveCallback: function () {
|
||||||
goDeleteForestProduct(checkedIds);
|
goDeleteForestProduct(checkedIds);
|
||||||
},
|
},
|
||||||
@@ -234,7 +231,6 @@
|
|||||||
// 임산물현황 삭제
|
// 임산물현황 삭제
|
||||||
const goDeleteForestProduct = (checkedIds) => {
|
const goDeleteForestProduct = (checkedIds) => {
|
||||||
const f = document.reqForm;
|
const f = document.reqForm;
|
||||||
console.log("f.monthlyInputStatusId.value", f.monthlyInputStatusId.value);
|
|
||||||
|
|
||||||
ajaxUtil._ajaxMethod(
|
ajaxUtil._ajaxMethod(
|
||||||
'/api/household/forestProducts/delete',
|
'/api/household/forestProducts/delete',
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
<h3></h3>
|
<h3></h3>
|
||||||
<div class="component-btns bottom-btn-group">
|
<div class="component-btns bottom-btn-group">
|
||||||
<div class="btns-row align-right">
|
<div class="btns-row align-right">
|
||||||
<button type="button" class="btn small btn-secondary" onclick="goDeleteVisitInfo();">
|
<button type="button" class="btn small btn-secondary" onclick="showDeleteVisitInfoConfirm();">
|
||||||
<span class=" btn-txt">삭제</span>
|
<span class=" btn-txt">삭제</span>
|
||||||
</button>
|
</button>
|
||||||
<button type="button" class="btn small btn-primary" onclick="showVisitInfoModal();">
|
<button type="button" class="btn small btn-primary" onclick="showVisitInfoModal();">
|
||||||
@@ -94,38 +94,47 @@
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 임가방문정보 삭제
|
// 임가방문정보 삭제 confirm
|
||||||
const goDeleteVisitInfo = () => {
|
const showDeleteVisitInfoConfirm = () => {
|
||||||
const checkedIds = Array.from(
|
const checkedIds = Array.from(
|
||||||
document.querySelectorAll('input[name="visitRemoveIds"]:checked')
|
document.querySelectorAll('input[name="visitRemoveIds"]:checked')
|
||||||
).map(el => Number(el.value));
|
).map(el => Number(el.value));
|
||||||
|
|
||||||
if(checkedIds.length <= 0) {
|
if(checkedIds.length <= 0) {
|
||||||
alert("임가방문정보를 선택해주세요.");
|
alert("임가방문정보를 선택해주세요.");
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(confirm("선택하신 내용을 삭제하시겠습니까? 삭제한 항목은 복구할 수 없습니다.")) {
|
etUI.dialog.confirm({
|
||||||
const f = document.reqForm;
|
title: '삭제 안내',
|
||||||
|
message: '선택하신 내용을 삭제하시겠습니까?<br>삭제한 항목은 복구할 수 없습니다.',
|
||||||
|
positiveCallback: function () {
|
||||||
|
goDeleteVisitInfo(checkedIds);
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
ajaxUtil._ajaxMethod(
|
// 임가방문정보 삭제
|
||||||
'/api/visitInfo/remove',
|
const goDeleteVisitInfo = (checkedIds) => {
|
||||||
JSON.stringify({
|
const f = document.reqForm;
|
||||||
householdSeq: f.householdSeq.value,
|
|
||||||
visitRemoveIds: checkedIds
|
ajaxUtil._ajaxMethod(
|
||||||
}),
|
'/api/visitInfo/remove',
|
||||||
(response) => { // 성공
|
JSON.stringify({
|
||||||
alert("방문정보가 삭제되었습니다.");
|
householdSeq: f.householdSeq.value,
|
||||||
getVisitInfo();
|
visitRemoveIds: checkedIds
|
||||||
},
|
}),
|
||||||
function (code, rstData) {
|
() => { // 성공
|
||||||
if(code == 422) alert(rstData.responseText);
|
alert("방문정보가 삭제되었습니다.");
|
||||||
},
|
getVisitInfo();
|
||||||
'delete',
|
},
|
||||||
'json',
|
function (code, rstData) {
|
||||||
{ handle422Type: 'alert' }
|
if(code == 422) alert(rstData.responseText);
|
||||||
);
|
},
|
||||||
}
|
'delete',
|
||||||
|
'json',
|
||||||
|
{ handle422Type: 'alert' }
|
||||||
|
);
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -9,4 +9,9 @@ public class CommonConstants {
|
|||||||
* 단위의 직접입력 코드
|
* 단위의 직접입력 코드
|
||||||
*/
|
*/
|
||||||
public static final String UNIT_CODE_SELF = "code.record.unit.self";
|
public static final String UNIT_CODE_SELF = "code.record.unit.self";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 작업 면적의 직접입력 코드
|
||||||
|
*/
|
||||||
|
public static final String AREA_CODE_OTHER = "code.record.area.self";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,6 +21,24 @@ public class CreateDailyExpenseValidator implements Validator {
|
|||||||
public void validate(Object target, Errors errors) {
|
public void validate(Object target, Errors errors) {
|
||||||
CreateDailyExpenseReqVO vo = (CreateDailyExpenseReqVO) target;
|
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) {
|
if (vo.getPrice() == null && vo.getEstimatedValue() == null) {
|
||||||
errors.rejectValue(
|
errors.rejectValue(
|
||||||
"price", "valid.common.required",
|
"price", "valid.common.required",
|
||||||
@@ -29,11 +47,5 @@ public class CreateDailyExpenseValidator implements Validator {
|
|||||||
"estimatedValue", "valid.common.required",
|
"estimatedValue", "valid.common.required",
|
||||||
"현금 또는 현물평가액을 입력해 주세요.");
|
"현금 또는 현물평가액을 입력해 주세요.");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) {
|
|
||||||
errors.rejectValue(
|
|
||||||
"unitSelf", "valid.common.required",
|
|
||||||
"단위를 입력해 주세요.");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package app.module.front.usecase.daily.farming.adapters.web.validator;
|
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 app.module.front.usecase.daily.farming.adapters.web.model.CreateDailyFarmingReqVO;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.apache.tika.utils.StringUtils;
|
import org.apache.tika.utils.StringUtils;
|
||||||
@@ -20,12 +21,30 @@ public class CreateDailyFarmingValidator implements Validator {
|
|||||||
public void validate(Object target, Errors errors) {
|
public void validate(Object target, Errors errors) {
|
||||||
CreateDailyFarmingReqVO vo = (CreateDailyFarmingReqVO) target;
|
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(
|
errors.rejectValue(
|
||||||
"categorySelf", "valid.common.required",
|
"categorySelf", "valid.common.required",
|
||||||
"생산물을 입력해 주세요.");
|
"생산물을 입력해 주세요.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
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) {
|
if (vo.getEstimatedValue() == null) {
|
||||||
errors.rejectValue(
|
errors.rejectValue(
|
||||||
"estimatedValue", "valid.common.required",
|
"estimatedValue", "valid.common.required",
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package app.module.front.usecase.daily.forestry.adapters.web.validator;
|
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 app.module.front.usecase.daily.forestry.adapters.web.model.CreateDailyForestryReqVO;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.apache.tika.utils.StringUtils;
|
import org.apache.tika.utils.StringUtils;
|
||||||
@@ -20,6 +21,24 @@ public class CreateDailyForestryValidator implements Validator {
|
|||||||
public void validate(Object target, Errors errors) {
|
public void validate(Object target, Errors errors) {
|
||||||
CreateDailyForestryReqVO vo = (CreateDailyForestryReqVO) target;
|
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) {
|
if (vo.getEstimatedValue() == null) {
|
||||||
errors.rejectValue(
|
errors.rejectValue(
|
||||||
"estimatedValue", "valid.common.required",
|
"estimatedValue", "valid.common.required",
|
||||||
|
|||||||
@@ -21,6 +21,24 @@ public class CreateDailyIncomeValidator implements Validator {
|
|||||||
public void validate(Object target, Errors errors) {
|
public void validate(Object target, Errors errors) {
|
||||||
CreateDailyIncomeReqVO vo = (CreateDailyIncomeReqVO) target;
|
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) {
|
if (vo.getPrice() == null && vo.getEstimatedValue() == null) {
|
||||||
errors.rejectValue(
|
errors.rejectValue(
|
||||||
"price", "valid.common.required",
|
"price", "valid.common.required",
|
||||||
@@ -29,11 +47,5 @@ public class CreateDailyIncomeValidator implements Validator {
|
|||||||
"estimatedValue", "valid.common.required",
|
"estimatedValue", "valid.common.required",
|
||||||
"현금 또는 현물평가액을 입력해 주세요.");
|
"현금 또는 현물평가액을 입력해 주세요.");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (CommonConstants.UNIT_CODE_SELF.equals(vo.getUnitCode()) && StringUtils.isBlank(vo.getUnitSelf())) {
|
|
||||||
errors.rejectValue(
|
|
||||||
"unitSelf", "valid.common.required",
|
|
||||||
"단위를 입력해 주세요.");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package app.module.front.usecase.daily.work.adapters.web.validator;
|
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 app.module.front.usecase.daily.work.adapters.web.model.CreateDailyWorkReqVO;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.apache.tika.utils.StringUtils;
|
import org.apache.tika.utils.StringUtils;
|
||||||
@@ -20,19 +21,37 @@ public class CreateDailyWorkValidator implements Validator {
|
|||||||
public void validate(Object target, Errors errors) {
|
public void validate(Object target, Errors errors) {
|
||||||
CreateDailyWorkReqVO vo = (CreateDailyWorkReqVO) target;
|
CreateDailyWorkReqVO vo = (CreateDailyWorkReqVO) target;
|
||||||
|
|
||||||
if (vo.getHarvestQuantity() == null) {
|
if (vo.getWorkLandArea() == null && !StringUtils.isBlank(vo.getAreaUnitCode())) {
|
||||||
errors.rejectValue(
|
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(
|
errors.rejectValue(
|
||||||
"areaUnitSelf", "valid.common.required",
|
"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(
|
errors.rejectValue(
|
||||||
"harvestUnitSelf", "valid.common.required",
|
"harvestUnitSelf", "valid.common.required",
|
||||||
"단위를 입력해 주세요.");
|
"단위를 입력해 주세요.");
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import lombok.NoArgsConstructor;
|
|||||||
public class UpdateUserReqVO {
|
public class UpdateUserReqVO {
|
||||||
|
|
||||||
@NotBlank(message = "이름을 입력해주세요.")//"이름은 필수 항목입니다.")
|
@NotBlank(message = "이름을 입력해주세요.")//"이름은 필수 항목입니다.")
|
||||||
@Pattern(regexp = "^[가-힣]{2,10}$", message = "이름을 입력해주세요.")//"이름은 2~10자의 한글이어야 합니다.")
|
@Pattern(regexp = "^[가-힣0-9()]{2,10}$", message = "이름을 입력해주세요.")//"이름은 2~10자의 한글이어야 합니다.")
|
||||||
private String ownerName;
|
private String ownerName;
|
||||||
|
|
||||||
@NotNull(message = "나이를 입력해주세요.")
|
@NotNull(message = "나이를 입력해주세요.")
|
||||||
@@ -19,13 +19,13 @@ public class UpdateUserReqVO {
|
|||||||
@Max(value = 120, message = "나이를 입력해주세요.")//"나이는 120세 이하이어야 합니다.")
|
@Max(value = 120, message = "나이를 입력해주세요.")//"나이는 120세 이하이어야 합니다.")
|
||||||
private Integer ownerAge;
|
private Integer ownerAge;
|
||||||
|
|
||||||
@Pattern(regexp = "^\\d{2,3}$", message = "가구 연락처를 입력해주세요.")//"가구 연락처는 2~3자리 숫자여야 합니다.")
|
@Pattern(regexp = "^$|^\\d{2,3}$", message = "가구 연락처를 입력해주세요.")//"가구 연락처는 2~3자리 숫자여야 합니다.")
|
||||||
private String tel1;
|
private String tel1;
|
||||||
|
|
||||||
@Pattern(regexp = "^\\d{3,4}$", message = "가구 연락처를 입력해주세요.")//"가운데 번호는 3~4자리 숫자여야 합니다.")
|
@Pattern(regexp = "^$|^\\d{3,4}$", message = "가구 연락처를 입력해주세요.")//"가운데 번호는 3~4자리 숫자여야 합니다.")
|
||||||
private String tel2;
|
private String tel2;
|
||||||
|
|
||||||
@Pattern(regexp = "^\\d{4}$", message = "가구 연락처를 입력해주세요.")//"끝 번호는 4자리 숫자여야 합니다.")
|
@Pattern(regexp = "^$|^\\d{4}$", message = "가구 연락처를 입력해주세요.")//"끝 번호는 4자리 숫자여야 합니다.")
|
||||||
private String tel3;
|
private String tel3;
|
||||||
|
|
||||||
@Pattern(regexp = "^\\d{2,3}$", message = "휴대폰 번호를 입력해주세요.")//"휴대폰 번호는 2~3자리 숫자여야 합니다.")
|
@Pattern(regexp = "^\\d{2,3}$", message = "휴대폰 번호를 입력해주세요.")//"휴대폰 번호는 2~3자리 숫자여야 합니다.")
|
||||||
|
|||||||
@@ -180,7 +180,7 @@ var ajaxUtil = {
|
|||||||
if (formElement.length > 0) {
|
if (formElement.length > 0) {
|
||||||
$(formElement).find('.component-input').removeClass('input-invalid');
|
$(formElement).find('.component-input').removeClass('input-invalid');
|
||||||
$(formElement).find('.input-flex-group').removeClass('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 () {
|
$(formElement).find('.input-info').each(function () {
|
||||||
$(this).remove();
|
$(this).remove();
|
||||||
});
|
});
|
||||||
@@ -223,7 +223,7 @@ var ajaxUtil = {
|
|||||||
infoBox = $('<ul class="input-info"></ul>').appendTo(component);
|
infoBox = $('<ul class="input-info"></ul>').appendTo(component);
|
||||||
}
|
}
|
||||||
|
|
||||||
infoBox.html('<li>' + oj.message + '1111</li>');
|
infoBox.html('<li>' + oj.message + '</li>');
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -238,7 +238,10 @@ var ajaxUtil = {
|
|||||||
|
|
||||||
// 포커스 이동
|
// 포커스 이동
|
||||||
if ($('.input-invalid').length != 0) {
|
if ($('.input-invalid').length != 0) {
|
||||||
$('.input-invalid').eq(0).find('input,select').focus();
|
$('.input-invalid').eq(0).find('input').focus();
|
||||||
|
}
|
||||||
|
if ($('.select-invalid').length != 0) {
|
||||||
|
$('.select-invalid').eq(0).find('button').focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeof errorCallback !== 'undefined') {
|
if (typeof errorCallback !== 'undefined') {
|
||||||
|
|||||||
@@ -95,8 +95,6 @@ krip.daily.baseBindUI = function() {
|
|||||||
//document.reqForm.todayNone.value = 'N';
|
//document.reqForm.todayNone.value = 'N';
|
||||||
$noneWrap.val('N');
|
$noneWrap.val('N');
|
||||||
}
|
}
|
||||||
// TODO 2번 이벤트 발생하는 원인 찾기
|
|
||||||
console.log(1111)
|
|
||||||
|
|
||||||
krip.daily.todayNone(ENV.month, ENV.groupNo, $noneWrap.data('type'), checked);
|
krip.daily.todayNone(ENV.month, ENV.groupNo, $noneWrap.data('type'), checked);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -26,16 +26,7 @@
|
|||||||
<meta name="_csrf" th:content="${_csrf.token}"/>
|
<meta name="_csrf" th:content="${_csrf.token}"/>
|
||||||
<meta name="_csrf_header" th:content="${_csrf.headerName}"/>
|
<meta name="_csrf_header" th:content="${_csrf.headerName}"/>
|
||||||
|
|
||||||
<meta name="theme-color" content="#4BBC43">
|
<!--/* TODO : theme-color */-->
|
||||||
<!-- 메인 아이콘 (512x512 PNG) -->
|
|
||||||
<!-- <link rel="icon" href="/icon-512.png" sizes="512x512"> -->
|
|
||||||
<link rel="icon" sizes="512x512"><!-- TODO : href="" -->
|
|
||||||
<!-- iOS 홈화면 -->
|
|
||||||
<!-- <link rel="apple-touch-icon" href="/icon-512.png"> -->
|
|
||||||
<link rel="apple-touch-icon"><!-- TODO : href="" -->
|
|
||||||
<!-- PWA -->
|
|
||||||
<link rel="manifest" ><!-- TODO : href="/manifest.json" -->
|
|
||||||
<link rel="icon" type="image/x-icon" /><!-- TODO : href="" -->
|
|
||||||
|
|
||||||
<link th:href="@{/static/assets/styles/style.css}" type="text/css" rel="stylesheet" />
|
<link th:href="@{/static/assets/styles/style.css}" type="text/css" rel="stylesheet" />
|
||||||
<script th:src="@{/static/assets/scripts/common.ui.plugin.js}"></script>
|
<script th:src="@{/static/assets/scripts/common.ui.plugin.js}"></script>
|
||||||
|
|||||||
@@ -369,7 +369,6 @@
|
|||||||
errors.push({field: form.transferCategoryCode.value+"_value", message: '수입대상을 입력해주세요.'});
|
errors.push({field: form.transferCategoryCode.value+"_value", message: '수입대상을 입력해주세요.'});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!form.sourcePurpose.value) errors.push({field: 'sourcePurpose', message: '수입원을 입력해주세요.'});
|
|
||||||
|
|
||||||
if(form.count.value){
|
if(form.count.value){
|
||||||
if(!form.unitCode.value){
|
if(!form.unitCode.value){
|
||||||
@@ -559,7 +558,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<ul class="detail-list">
|
<ul class="detail-list">
|
||||||
<li><p>재배형태</p><span>${getCrop(product.cropCode)}</span></li>
|
<li><p>재배형태</p><span>${getCrop(product.cropCode)}</span></li>
|
||||||
<li><p>수입원</p><span>${product.sourcePurpose}</span></li>
|
${product.sourcePurpose != null && product.sourcePurpose != ''
|
||||||
|
? `<li><p>수입원</p><span>${product.sourcePurpose}</span></li>`
|
||||||
|
: ''}
|
||||||
${tagCount}
|
${tagCount}
|
||||||
<li><p>현금</p><span>${format(product.price)}원</span></li>
|
<li><p>현금</p><span>${format(product.price)}원</span></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
@@ -86,12 +86,16 @@
|
|||||||
<!-- transferCategory+Text-->
|
<!-- transferCategory+Text-->
|
||||||
<th:block th:each="item : ${transferCategoryList}">
|
<th:block th:each="item : ${transferCategoryList}">
|
||||||
<div class="component-input " th:data-option="${item.codeText}">
|
<div class="component-input " th:data-option="${item.codeText}">
|
||||||
<div class="input-field">
|
<div class="input-field" th:if="${item.id != 'code.bank.input.10' and item.id != 'code.bank.input.12' and item.id != 'code.bank.input.13'}">
|
||||||
<input type="text" th:id="${item.id}+'_value'" th:name="${item.id}+'_value'" value="" placeholder="수입 대상을 입력해 주세요." maxlength="30">
|
<input type="text" th:id="${item.id}+'_value'" th:name="${item.id}+'_value'"
|
||||||
|
value="" maxlength="30"
|
||||||
|
th:placeholder="${item.id == 'code.bank.input.self' ? '수입의 종류를 입력해 주세요.' : '수입 대상을 입력해 주세요.'}">
|
||||||
</div>
|
</div>
|
||||||
|
<th:block th:if="${item.id == 'code.bank.input.1' or item.id == 'code.bank.input.4'}">
|
||||||
<ul class="guide-info" th:if="${item.msgCode}">
|
<ul class="guide-info" th:if="${item.msgCode}">
|
||||||
<li class="txt-blue" th:text="${item.msgCode}"></li>
|
<li class="txt-blue" th:text="${item.msgCode}"></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
</th:block>
|
||||||
</div>
|
</div>
|
||||||
</th:block>
|
</th:block>
|
||||||
</div>
|
</div>
|
||||||
@@ -100,7 +104,6 @@
|
|||||||
<div class="input-label">
|
<div class="input-label">
|
||||||
<label for="sourcePurpose" class="label-txt">
|
<label for="sourcePurpose" class="label-txt">
|
||||||
수입원
|
수입원
|
||||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
|
|||||||
@@ -361,7 +361,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!form.sourcePurpose.value) errors.push({field: 'sourcePurpose', message: '용도 입력해주세요.'});
|
|
||||||
if(form.count.value){
|
if(form.count.value){
|
||||||
if(!form.unitCode.value){
|
if(!form.unitCode.value){
|
||||||
errors.push({
|
errors.push({
|
||||||
@@ -552,7 +551,9 @@
|
|||||||
${buttonGroupHtml}
|
${buttonGroupHtml}
|
||||||
</div>
|
</div>
|
||||||
<ul class="detail-list">
|
<ul class="detail-list">
|
||||||
<li><p>용도</p><span>${product.sourcePurpose}</span></li>
|
${product.sourcePurpose != null && product.sourcePurpose != ''
|
||||||
|
? `<li><p>용도</p><span>${product.sourcePurpose}</span></li>`
|
||||||
|
: ''}
|
||||||
${tagCount}
|
${tagCount}
|
||||||
<li><p>현금</p><span>${format(product.price)}원</span></li>
|
<li><p>현금</p><span>${format(product.price)}원</span></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
@@ -63,7 +63,6 @@
|
|||||||
<div class="input-label">
|
<div class="input-label">
|
||||||
<label for="sourcePurpose" class="label-txt">
|
<label for="sourcePurpose" class="label-txt">
|
||||||
용도
|
용도
|
||||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
|
|||||||
@@ -93,7 +93,7 @@
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="unitCode" th:value="${detail.unitCode}">
|
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
<strong>지출 내역 [[${#lists.isEmpty(expenseList) ? 0 : #lists.size(expenseList)}]]건 등록</strong> <br>
|
<strong>지출 내역 [[${#lists.isEmpty(expenseList) ? 0 : #lists.size(expenseList)}]]건 등록</strong> <br>
|
||||||
되었습니다.
|
되었습니다.
|
||||||
</h3>
|
</h3>
|
||||||
<p th:if="${#lists.isEmpty(expenseList)}">지출 내역을 등록해 주세요..</p>
|
<p th:if="${#lists.isEmpty(expenseList)}">지출 내역을 등록해 주세요.</p>
|
||||||
<p th:unless="${#lists.isEmpty(expenseList)}">등록 내용을 확인하거나 다음 단계로 이동하세요.</p>
|
<p th:unless="${#lists.isEmpty(expenseList)}">등록 내용을 확인하거나 다음 단계로 이동하세요.</p>
|
||||||
</hgroup>
|
</hgroup>
|
||||||
|
|
||||||
@@ -140,10 +140,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/daily/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/daily/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -80,7 +80,7 @@
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="unitCode" th:value="${detail.unitCode}">
|
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -143,10 +143,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/farming/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/farming/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -55,7 +55,7 @@
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="unitCode" th:value="${detail.unitCode}">
|
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -143,10 +143,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/forestry/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/forestry/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -123,7 +123,7 @@
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="unitCode" th:value="${detail.unitCode}">
|
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -155,10 +155,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/daily/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/daily/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -128,10 +128,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/power/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/power/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -66,7 +66,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="areaUnitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요"
|
<div id="areaUnitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요"
|
||||||
data-props-type="bottomSheet">
|
data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="areaUnitCode" th:value="${detail.areaUnitCode}">
|
<input type="hidden" name="areaUnitCode" data-type="select" th:value="${detail.areaUnitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
@@ -104,7 +104,6 @@
|
|||||||
<div class="input-label">
|
<div class="input-label">
|
||||||
<label for="harvestQuantity" class="label-txt">
|
<label for="harvestQuantity" class="label-txt">
|
||||||
수확량
|
수확량
|
||||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
@@ -120,7 +119,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="harvestUnitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요"
|
<div id="harvestUnitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요"
|
||||||
data-props-type="bottomSheet">
|
data-props-type="bottomSheet">
|
||||||
<input type="hidden" name="harvestUnitCode" th:value="${detail.harvestUnitCode}">
|
<input type="hidden" name="harvestUnitCode" data-type="select" th:value="${detail.harvestUnitCode}">
|
||||||
<button type="button" class="select-box">
|
<button type="button" class="select-box">
|
||||||
<span class="select-txt"></span>
|
<span class="select-txt"></span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -189,10 +189,6 @@
|
|||||||
<section layout:fragment="script">
|
<section layout:fragment="script">
|
||||||
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
<script th:src="@{/static/ui/page/daily-record.js}"></script>
|
||||||
<script th:inline="javascript">
|
<script th:inline="javascript">
|
||||||
$(function() {
|
|
||||||
formControl.init();
|
|
||||||
});
|
|
||||||
|
|
||||||
let ENV = {
|
let ENV = {
|
||||||
httpUrl: {
|
httpUrl: {
|
||||||
root: /*[[|/record/work/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
root: /*[[|/record/work/${reqVO.searchMonth}/${reqVO.groupNo}|]]*/'rootUrl',
|
||||||
|
|||||||
@@ -35,7 +35,7 @@
|
|||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="password" name="password" id="floatingPassword" placeholder="비밀번호 4자리를 입력해 주세요" maxlength="4">
|
<input type="password" inputmode="numeric" maxlength="4" name="password" id="floatingPassword" placeholder="비밀번호 4자리를 입력해 주세요">
|
||||||
</div>
|
</div>
|
||||||
<ul class="input-info" id="password-error" style="display: none;">
|
<ul class="input-info" id="password-error" style="display: none;">
|
||||||
<li>비밀번호를 입력해주세요</li>
|
<li>비밀번호를 입력해주세요</li>
|
||||||
|
|||||||
Reference in New Issue
Block a user