Merge branch 'dev' into 'deploy-dev-front'

Dev

See merge request korea-research/korea-research!29
This commit is contained in:
김현주 개발
2025-06-23 08:55:46 +00:00
23 changed files with 312 additions and 130 deletions

File diff suppressed because one or more lines are too long

View File

@@ -6677,6 +6677,14 @@ input[type=number] {
-webkit-justify-content: space-between; -webkit-justify-content: space-between;
justify-content: space-between; justify-content: space-between;
} }
.table-group .table-tit-group.large {
margin-bottom: 2.4rem;
}
.table-group .table-tit-group.large h3 {
font-size: 2.4rem;
font-weight: 700;
color: #212529;
}
.table-group .table-tit-group h3 { .table-group .table-tit-group h3 {
display: -webkit-box; display: -webkit-box;
display: -webkit-flex; display: -webkit-flex;
@@ -6708,6 +6716,9 @@ table a {
table th { table th {
background-color: #f1f3f5 !important; background-color: #f1f3f5 !important;
} }
table tr.total {
background-color: #F1F3F5;
}
table .align-right { table .align-right {
text-align: right; text-align: right;
} }
@@ -7193,6 +7204,18 @@ table tbody th {
flex: 1; flex: 1;
background-color: #ffffff; background-color: #ffffff;
} }
.dounut-chart-area .chart-group.type-green .donut-chart {
background: conic-gradient(#95BA45 -webkit-calc(var(--percent) * 1%), #E9ECEF 0%);
background: conic-gradient(#95BA45 calc(var(--percent) * 1%), #E9ECEF 0%);
}
.dounut-chart-area .chart-group.type-blue .donut-chart {
background: conic-gradient(#00B09B -webkit-calc(var(--percent) * 1%), #E9ECEF 0%);
background: conic-gradient(#00B09B calc(var(--percent) * 1%), #E9ECEF 0%);
}
.dounut-chart-area .chart-group.type-orange .donut-chart {
background: conic-gradient(#FD9E01 -webkit-calc(var(--percent) * 1%), #E9ECEF 0%);
background: conic-gradient(#FD9E01 calc(var(--percent) * 1%), #E9ECEF 0%);
}
.dounut-chart-area .chart-group dl { .dounut-chart-area .chart-group dl {
color: #212529; color: #212529;
} }
@@ -7231,16 +7254,22 @@ table tbody th {
.donut-chart { .donut-chart {
--percent: 75; --percent: 75;
width: 160px; min-width: 16rem;
height: 160px; min-height: 16rem;
width: 16rem;
height: 16rem;
border-radius: 50%; border-radius: 50%;
background: conic-gradient(#95BA45 -webkit-calc(75 * 1%), #E9ECEF 0%); background: conic-gradient(#95ba45 0 -webkit-calc(75 * 1%), #e9ecef 0);
background: conic-gradient(#95BA45 calc(75 * 1%), #E9ECEF 0%); background: conic-gradient(#95ba45 0 calc(75 * 1%), #e9ecef 0);
background: conic-gradient(#95BA45 -webkit-calc(var(--percent) * 1%), #E9ECEF 0%);
background: conic-gradient(#95BA45 calc(var(--percent) * 1%), #E9ECEF 0%);
position: relative; position: relative;
} }
@supports (background: conic-gradient(red 0deg, red 0deg 1deg, red 2deg)){
.donut-chart {
background: conic-gradient(#95ba45 0 -webkit-calc(var(--percent) * 1%), #e9ecef 0);
background: conic-gradient(#95ba45 0 calc(var(--percent) * 1%), #e9ecef 0);
}
}
.donut-chart::before { .donut-chart::before {
content: ""; content: "";
position: absolute; position: absolute;
@@ -7253,6 +7282,100 @@ table tbody th {
background: #fff; background: #fff;
border-radius: 50%; border-radius: 50%;
} }
.donut-chart::after {
content: "";
position: absolute;
top: 0;
left: 50%;
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
width: 4px;
height: 50px;
background: #ffffff;
}
.donut-chart .end-line {
content: "";
position: absolute;
top: 0;
left: 50%;
-webkit-transform: translateX(-50%) rotate(-webkit-calc(var(--percent) * 3.6deg));
transform: translateX(-50%) rotate(calc(var(--percent) * 3.6deg));
-webkit-transform-origin: center 80px;
transform-origin: center 80px;
width: 4px;
height: 50px;
background: #ffffff;
}
.progress-group {
display: -webkit-box;
display: -webkit-flex;
display: flex;
-webkit-box-align: center;
-webkit-align-items: center;
align-items: center;
-webkit-box-pack: center;
-webkit-justify-content: center;
justify-content: center;
gap: 2.4rem;
}
.progress-group.type-green .progress::-webkit-progress-value {
background: #95BA45;
border-radius: 0px;
}
.progress-group.type-blue .progress::-webkit-progress-value {
background: #00B09B;
border-radius: 0px;
}
.progress-group.type-orange .progress::-webkit-progress-value {
background: #FD9E01;
border-radius: 0px;
}
.progress-group .progress {
-webkit-box-flex: 1;
-webkit-flex: 1;
flex: 1;
width: 100%;
max-width: 20rem;
height: 0.8rem;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
.progress-group .progress::-webkit-progress-bar {
background: #E9ECEF;
border-radius: 12px;
height: 0.8rem;
overflow: hidden;
}
.progress-group .progress::-webkit-progress-value {
background: #95BA45;
border-radius: 0px;
}
.progress-group .detail {
display: -webkit-box;
display: -webkit-flex;
display: flex;
-webkit-box-align: center;
-webkit-align-items: center;
align-items: center;
}
.progress-group .detail .percent {
position: relative;
padding-right: 1.3rem;
margin-right: 0.4rem;
}
.progress-group .detail .percent::after {
position: absolute;
content: "%";
display: block;
right: 0;
top: 0;
}
.progress-group .detail .d-flex {
gap: 0.2rem;
}
/* https://cdn.datatables.net/1.12.1/css/jquery.dataTables.min.css */ /* https://cdn.datatables.net/1.12.1/css/jquery.dataTables.min.css */
table.dataTable td.dt-control { table.dataTable td.dt-control {

File diff suppressed because one or more lines are too long

View File

@@ -2,13 +2,15 @@ package app.module.front.usecase.daily.calendar.adapters.persistence;
import app.module.core.config.application.enums.MonthStatus; import app.module.core.config.application.enums.MonthStatus;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordCalendarDto; import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordCalendarDto;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto; import app.module.front.usecase.daily.record.adapters.persistence.DailyRecordMapper;
import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.MonthlyStatusDto; import app.module.front.usecase.daily.calendar.adapters.persistence.model.MonthlyStatusDto;
import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortOut; import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortOut;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar;
import app.module.front.usecase.daily.calendar.ports.application.domain.CalendarChildren; import app.module.front.usecase.daily.calendar.ports.application.domain.CalendarChildren;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd;
import app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus; import app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus;
import app.module.front.usecase.daily.record.ports.application.domain.GetDailyRecordCmd;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
@@ -23,6 +25,7 @@ import java.util.Objects;
@RequiredArgsConstructor @RequiredArgsConstructor
public class RecordCalendarDao implements RecordCalendarPortOut { public class RecordCalendarDao implements RecordCalendarPortOut {
private final RecordCalendarMapper recordCalendarMapper; private final RecordCalendarMapper recordCalendarMapper;
private final DailyRecordMapper dailyRecordMapper;
@Override @Override
public List<RecordCalendar> operate(RecordCalendarCmd command) { public List<RecordCalendar> operate(RecordCalendarCmd command) {
@@ -176,7 +179,7 @@ public class RecordCalendarDao implements RecordCalendarPortOut {
* @return * @return
*/ */
private List<DailyRecordStatusDto> getDailyRecordStatus(RecordCalendarCmd command) { private List<DailyRecordStatusDto> getDailyRecordStatus(RecordCalendarCmd command) {
List<DailyRecordStatusDto> statusList = recordCalendarMapper.getDailyRecordStatus(command); List<DailyRecordStatusDto> statusList = dailyRecordMapper.getDailyRecordStatus(new GetDailyRecordCmd(command.getSearchMonth(), null, command.getHouseholdSeq()));
if (statusList == null || statusList.isEmpty()) { if (statusList == null || statusList.isEmpty()) {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@@ -1,7 +1,7 @@
package app.module.front.usecase.daily.calendar.adapters.persistence; package app.module.front.usecase.daily.calendar.adapters.persistence;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordCalendarDto; import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordCalendarDto;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto; import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.MonthlyStatusDto; import app.module.front.usecase.daily.calendar.adapters.persistence.model.MonthlyStatusDto;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
@@ -18,14 +18,6 @@ public interface RecordCalendarMapper {
*/ */
List<DailyRecordCalendarDto> getCalendarByDailyRecord(RecordCalendarCmd command); List<DailyRecordCalendarDto> getCalendarByDailyRecord(RecordCalendarCmd command);
/**
* 특정일의 일계부 등록 상태 조회
*
* @param command 검색 조건
* @return 일계부 등록 현황 목록
*/
List<DailyRecordStatusDto> getDailyRecordStatus(RecordCalendarCmd command);
/** /**
* 특정월의 월별 작성 상태 조회 * 특정월의 월별 작성 상태 조회
* *

View File

@@ -1,7 +1,5 @@
package app.module.front.usecase.daily.calendar.ports; package app.module.front.usecase.daily.calendar.ports;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.calendar.adapters.web.model.RecordCalendarUIReqVO;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd;

View File

@@ -1,7 +1,5 @@
package app.module.front.usecase.daily.calendar.ports; package app.module.front.usecase.daily.calendar.ports;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordCalendarDto;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendar;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd; import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd;

View File

@@ -1,6 +1,5 @@
package app.module.front.usecase.daily.calendar.ports.application; package app.module.front.usecase.daily.calendar.ports.application;
import app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.calendar.adapters.web.model.RecordCalendarUIReqVO; import app.module.front.usecase.daily.calendar.adapters.web.model.RecordCalendarUIReqVO;
import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortIn; import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortIn;
import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortOut; import app.module.front.usecase.daily.calendar.ports.RecordCalendarPortOut;
@@ -9,12 +8,7 @@ import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCa
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.util.Date;
import java.util.List; import java.util.List;
import java.util.Locale;
@Service @Service
@RequiredArgsConstructor @RequiredArgsConstructor

View File

@@ -2,7 +2,9 @@ package app.module.front.usecase.daily.record.adapters.persistence;
import app.module.front.config.application.util.AuditUtil; import app.module.front.config.application.util.AuditUtil;
import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordDto; import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordDto;
import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.record.adapters.web.model.CreateDailyRecordReqVO; import app.module.front.usecase.daily.record.adapters.web.model.CreateDailyRecordReqVO;
import app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus;
import app.module.front.usecase.daily.record.ports.DailyRecordPortOut; import app.module.front.usecase.daily.record.ports.DailyRecordPortOut;
import app.module.front.usecase.daily.record.ports.application.domain.CreateDailyRecordCmd; import app.module.front.usecase.daily.record.ports.application.domain.CreateDailyRecordCmd;
import app.module.front.usecase.daily.record.ports.application.domain.GetDailyRecordCmd; import app.module.front.usecase.daily.record.ports.application.domain.GetDailyRecordCmd;
@@ -13,7 +15,9 @@ import org.springframework.stereotype.Repository;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.time.LocalDate; import java.time.LocalDate;
import java.util.Collections;
import java.util.Date; import java.util.Date;
import java.util.List;
import java.util.Locale; import java.util.Locale;
@Slf4j @Slf4j
@@ -55,11 +59,12 @@ public class DailyRecordDao implements DailyRecordPortOut {
log.debug("[CreateDailyRecord] record={}", command); log.debug("[CreateDailyRecord] record={}", command);
} else { } else {
// TODO : NONE 으로 변경시 연관 테이블 데이터 삭제할 것인가?
dailyRecordMapper.updateDailyRecord(command); dailyRecordMapper.updateDailyRecord(command);
log.warn("[DailyRecordCreate] existCount={}, recordMonth={}, dayGroupNo={}", existCount, findCmd.getSearchMonth(), findCmd.getGroupNo()); log.warn("[DailyRecordCreate] existCount={}, recordMonth={}, dayGroupNo={}", existCount, findCmd.getSearchMonth(), findCmd.getGroupNo());
} }
this.updateByAllStatus(findCmd);
} }
@Override @Override
@@ -76,6 +81,22 @@ public class DailyRecordDao implements DailyRecordPortOut {
dailyRecordMapper.updateDailyRecordStatus(command); dailyRecordMapper.updateDailyRecordStatus(command);
// TODO : target 업데이트 후 데이터 등록이 완료된 건은 allStatus 값 변경해주기 this.updateByAllStatus(new GetDailyRecordCmd(recordMonth, dayGroupNo, command.getHouseholdSeq()));
}
/**
* TODO : target 업데이트 후 데이터 등록이 완료된 건은 allStatus 값 변경해주기
* @param findCmd
*/
private void updateByAllStatus(GetDailyRecordCmd findCmd) {
List<DailyRecordStatusDto> statusList = dailyRecordMapper.getDailyRecordStatus(findCmd);
if (statusList != null && !statusList.isEmpty()) {
DailyRecordStatusDto statusDetail = statusList.get(0);
if (DailyTargetStatus.TARGET.equals(statusDetail.getIncomeStatus()) && statusDetail.getIncomeCount() != 0) {
}
}
} }
} }

View File

@@ -1,11 +1,15 @@
package app.module.front.usecase.daily.record.adapters.persistence; package app.module.front.usecase.daily.record.adapters.persistence;
import app.module.front.usecase.daily.calendar.ports.application.domain.RecordCalendarCmd;
import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordDto; import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordDto;
import app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto;
import app.module.front.usecase.daily.record.ports.application.domain.CreateDailyRecordCmd; import app.module.front.usecase.daily.record.ports.application.domain.CreateDailyRecordCmd;
import app.module.front.usecase.daily.record.ports.application.domain.GetDailyRecordCmd; import app.module.front.usecase.daily.record.ports.application.domain.GetDailyRecordCmd;
import app.module.front.usecase.daily.record.ports.application.domain.UpdateDailyRecordStatusCmd; import app.module.front.usecase.daily.record.ports.application.domain.UpdateDailyRecordStatusCmd;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper @Mapper
public interface DailyRecordMapper { public interface DailyRecordMapper {
/** /**
@@ -16,6 +20,14 @@ public interface DailyRecordMapper {
*/ */
DailyRecordDto getDailyRecord(GetDailyRecordCmd command); DailyRecordDto getDailyRecord(GetDailyRecordCmd command);
/**
* 특정일의 일계부 등록 상태 조회
*
* @param command 검색 조건
* @return 일계부 등록 현황 목록
*/
List<DailyRecordStatusDto> getDailyRecordStatus(GetDailyRecordCmd command);
/** /**
* 일계부 항목 등록 여부 * 일계부 항목 등록 여부
* *

View File

@@ -74,7 +74,9 @@ public class DailyRecordDto {
* @return true=수정 가능, false=수정 불가 * @return true=수정 가능, false=수정 불가
*/ */
public boolean isModifiable() { public boolean isModifiable() {
LocalDate limitStart = LocalDate.now().minusDays(15); // TODO : 15일로 변경, 테스트를 위해 30일로 진행중
LocalDate limitStart = LocalDate.now().minusDays(30);
log.debug("@@limitStart: {}", limitStart);
return (limitStart.isBefore(startDate) || limitStart.isEqual(startDate) || limitStart.isEqual(endDate)); return (limitStart.isBefore(startDate) || limitStart.isEqual(startDate) || limitStart.isEqual(endDate));
} }

View File

@@ -1,4 +1,4 @@
package app.module.front.usecase.daily.calendar.adapters.persistence.model; package app.module.front.usecase.daily.record.adapters.persistence.model;
import app.module.front.usecase.daily.record.adapters.web.model.DailyStatus; import app.module.front.usecase.daily.record.adapters.web.model.DailyStatus;
import app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus; import app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus;

View File

@@ -31,6 +31,6 @@ public class SuggestionController {
suggestionPortIn.create(formVO); suggestionPortIn.create(formVO);
return ResponseEntity.status(HttpStatus.OK).body(null); return ResponseEntity.status(HttpStatus.OK).body(1);
} }
} }

View File

@@ -16,6 +16,29 @@
and ddg.group_no = #{groupNo} and ddg.group_no = #{groupNo}
</select> </select>
<select id="getDailyRecordStatus"
resultType="app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto">
select dr.id as daily_id
, dr.day_group_no, dr.start_date, dr.end_date
, dr.all_status
, dr.income_status
, dr.work_status
, dr.expense_status
, dr.power_status
, dr.forestry_status
, dr.farming_status
, (select count(*) from daily_income di where di.daily_record_seq = dr.id and di.is_deleted = false) as income_count
, (select count(*) from daily_work dw where dw.daily_record_seq = dr.id and dw.is_deleted = false) as work_count
, (select count(*) from daily_expense de where de.daily_record_seq = dr.id and de.is_deleted = false) as expense_count
, (select count(*) from daily_power dp where dp.daily_record_seq = dr.id and dp.is_deleted = false) as power_count
, (select count(*) from daily_forestry df1 where df1.daily_record_seq = dr.id and df1.is_deleted = false) as forestry_count
, (select count(*) from daily_farming df2 where df2.daily_record_seq = dr.id and df2.is_deleted = false) as farming_count
from daily_record dr
where dr.is_deleted = false
and dr.household_seq = #{householdSeq}
and dr.record_month = #{searchMonth}
</select>
<select id="getDailyRecordExistCount" resultType="int"> <select id="getDailyRecordExistCount" resultType="int">
select count(1) as exist select count(1) as exist
from daily_record dr from daily_record dr

View File

@@ -16,29 +16,6 @@
ddg.group_no asc ddg.group_no asc
</select> </select>
<select id="getDailyRecordStatus"
resultType="app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto">
select dr.id as daily_id
, dr.day_group_no, dr.start_date, dr.end_date
, dr.all_status
, dr.income_status
, dr.work_status
, dr.expense_status
, dr.power_status
, dr.forestry_status
, dr.farming_status
, (select count(*) from daily_income di where di.daily_record_seq = dr.id and di.is_deleted = false) as income_count
, (select count(*) from daily_work dw where dw.daily_record_seq = dr.id and dw.is_deleted = false) as work_count
, (select count(*) from daily_expense de where de.daily_record_seq = dr.id and de.is_deleted = false) as expense_count
, (select count(*) from daily_power dp where dp.daily_record_seq = dr.id and dp.is_deleted = false) as power_count
, (select count(*) from daily_forestry df1 where df1.daily_record_seq = dr.id and df1.is_deleted = false) as forestry_count
, (select count(*) from daily_farming df2 where df2.daily_record_seq = dr.id and df2.is_deleted = false) as farming_count
from daily_record dr
where dr.is_deleted = false
and dr.household_seq = #{householdSeq}
and dr.record_month = #{searchMonth}
</select>
<select id="getMonthlyStatus"> <select id="getMonthlyStatus">
select mis.forest_product_status as forest_product, mis.bank_auto_transfer_input_status as bank_input, mis.bank_auto_transfer_output_status as bank_output select mis.forest_product_status as forest_product, mis.bank_auto_transfer_input_status as bank_input, mis.bank_auto_transfer_output_status as bank_output
from monthly_input_status mis from monthly_input_status mis
@@ -115,7 +92,7 @@
</select> </select>
<select id="getLatestDate" <select id="getLatestDate"
resultType="app.module.front.usecase.daily.calendar.adapters.persistence.model.DailyRecordStatusDto"> resultType="app.module.front.usecase.daily.record.adapters.persistence.model.DailyRecordStatusDto">
select dr.id as daily_id select dr.id as daily_id
, dr.day_group_no, dr.start_date, dr.end_date , dr.day_group_no, dr.start_date, dr.end_date
from daily_record dr from daily_record dr

View File

@@ -85,13 +85,13 @@
</div> </div>
<div class="component-input"> <div class="component-input">
<div class="input-field"> <div class="input-field">
<input type="text" placeholder=0000 th:field="*{tel2}" maxlength="4" <input type="text" th:field="*{tel2}" maxlength="4"
oninput="this.value=this.value.replace(/[^0-9]/g,'')"/> oninput="this.value=this.value.replace(/[^0-9]/g,'')"/>
</div> </div>
</div> </div>
<div class="component-input"> <div class="component-input">
<div class="input-field"> <div class="input-field">
<input type="text" placeholder=0000 th:field="*{tel3}" maxlength="4" <input type="text" th:field="*{tel3}" maxlength="4"
oninput="this.value=this.value.replace(/[^0-9]/g,'')"/> oninput="this.value=this.value.replace(/[^0-9]/g,'')"/>
</div> </div>
</div> </div>
@@ -123,8 +123,7 @@
</div> </div>
<div class="select-scroll"> <div class="select-scroll">
<ul class=""> <ul class="">
<li class="option" data-value="010">010</li> <li class="option" data-value="010" th:field="*{phone2}">010</li>
<li class="option" data-value="011">011</li>
</ul> </ul>
</div> </div>
</div> </div>
@@ -132,13 +131,13 @@
</div> </div>
<div class="component-input"> <div class="component-input">
<div class="input-field"> <div class="input-field">
<input type="text" id="temp_input_0006" placeholder=0000 th:field="*{phone2}" <input type="text" id="temp_input_0006" th:field="*{phone2}"
maxlength="4" oninput="this.value=this.value.replace(/[^0-9]/g,'')"> maxlength="4" oninput="this.value=this.value.replace(/[^0-9]/g,'')">
</div> </div>
</div> </div>
<div class="component-input"> <div class="component-input">
<div class="input-field"> <div class="input-field">
<input type="text" id="temp_input_0007" placeholder=0000 th:field="*{phone3}" <input type="text" id="temp_input_0007" th:field="*{phone3}"
maxlength="4" oninput="this.value=this.value.replace(/[^0-9]/g,'')"> maxlength="4" oninput="this.value=this.value.replace(/[^0-9]/g,'')">
</div> </div>
</div> </div>
@@ -155,24 +154,26 @@
</div> </div>
<div id="regionMainCodeId" class="component-select bottom-sheet" data-props-default="시/도 선택" <div id="regionMainCodeId" class="component-select bottom-sheet" data-props-default="지역 선택"
data-props-type="bottomSheet"> data-props-type="bottomSheet">
<input type="hidden" th:field="*{regionMainCode}" data-type="select"> <input type="hidden1" name="regionMainCode" data-type="select" th:value="${userInfo.regionMainCode}">
<button type="button" class="select-box"> <button type="button" class="select-box">
<span class="select-txt">선택</span> <span class="select-txt">선택</span>
</button> </button>
<div class="select-options"> <div class="select-options">
<div class="select-header"> <div class="select-header">
<p>시/도 선택</p> <p>지역 선택</p>
<button type="button" class="select-close"> <button type="button" class="select-close">
<span class="hide-txt">닫기</span> <span class="hide-txt">닫기</span>
</button> </button>
</div> </div>
<div class="select-scroll"> <div class="select-scroll">
<ul class=""> <ul class="">
<th:block th:each="item : ${regionMainList}"> <th:block th:each="item : ${regionMainList}">
<li class="option" th:data-value="${item.id}" <li class="option" th:data-value="${item.id}"
th:text="${item.codeText}">option1 th:text="${item.codeText}"
th:selected="${item.id eq userInfo.regionMainCode ? 'current' : ''}">option1
</li> </li>
</th:block> </th:block>
</ul> </ul>
@@ -185,14 +186,14 @@
<div class="select-group"> <div class="select-group">
<div id="regionSubCodeId" class="component-select bottom-sheet" <div id="regionSubCodeId" class="component-select bottom-sheet"
data-props-default="시/군/구 선택" data-props-type="bottomSheet"> data-props-default="세부지역 선택" data-props-type="bottomSheet">
<input type="hidden" th:field="*{regionSubCode}" data-type="select"> <input type="hidden" th:field="*{regionSubCode}" data-type="select">
<button type="button" class="select-box"> <button type="button" class="select-box">
<span class="select-txt">선택</span> <span class="select-txt">선택</span>
</button> </button>
<div class="select-options"> <div class="select-options">
<div class="select-header"> <div class="select-header">
<p>시/군/구 선택</p> <p>세부지역 선택</p>
<button type="button" class="select-close"> <button type="button" class="select-close">
<span class="hide-txt">닫기</span> <span class="hide-txt">닫기</span>
</button> </button>
@@ -277,6 +278,10 @@
<section layout:fragment="script"> <section layout:fragment="script">
<script th:inline="javascript"> <script th:inline="javascript">
$(function() {
//formControl.init();
});
let ENV = { let ENV = {
httpUrl: { httpUrl: {
root: /*[[#{uri.front.info.user.path}]]*/'rootUrl', root: /*[[#{uri.front.info.user.path}]]*/'rootUrl',
@@ -297,6 +302,18 @@
}, },
_bindUI() { _bindUI() {
ENV.module.confirmPopup = document.querySelector(".confirmPopup").ui; ENV.module.confirmPopup = document.querySelector(".confirmPopup").ui;
const $select1 = document.querySelector('#regionMainCodeId');
const selectboxInstance1 = new etUI.components.SelectBox();
selectboxInstance1.core.init($select1, {
selectItemCallback({selectValue, dataValue}){
console.log('selectItemCallback', selectValue, dataValue)
$('input[name="regionMainCode"]').val(dataValue);
}
});
// selectboxInstance1.update();
selectboxInstance1.setValue($('input[name=regionMainCode]').val());
}, },
confirmPopup() { confirmPopup() {
ENV.module.confirmPopup.open(); ENV.module.confirmPopup.open();

View File

@@ -30,7 +30,6 @@
</div> </div>
</div> </div>
</section> </section>
</form>
<div class="component-btns"> <div class="component-btns">
<div class="btns-row"> <div class="btns-row">
@@ -40,6 +39,7 @@
</button> </button>
</div> </div>
</div> </div>
</form>
</div> </div>
</div> </div>
<button type="button" class="modal-close"></button> <button type="button" class="modal-close"></button>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.expenseStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -23,11 +25,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(expenseList)}"> <th:block th:if="${#lists.isEmpty(expenseList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.expenseStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class=" ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.expenseStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -47,7 +46,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(expenseList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(expenseList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -57,7 +57,8 @@
th:each="item, itemStatus : ${expenseList}"> th:each="item, itemStatus : ${expenseList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.expenseKind}]]</p> <p class="item-name">[[${item.expenseKind}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.farmingStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -23,11 +25,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(farmingList)}"> <th:block th:if="${#lists.isEmpty(farmingList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.farmingStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class="ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.farmingStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -53,7 +52,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(farmingList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(farmingList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -63,7 +63,8 @@
th:each="item, itemStatus : ${farmingList}"> th:each="item, itemStatus : ${farmingList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.productLabel}]]</p> <p class="item-name">[[${item.productLabel}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.forestryStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -23,11 +25,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(forestryList)}"> <th:block th:if="${#lists.isEmpty(forestryList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.forestryStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class="ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.forestryStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -53,7 +52,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(forestryList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(forestryList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -63,7 +63,8 @@
th:each="item, itemStatus : ${forestryList}"> th:each="item, itemStatus : ${forestryList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.productName}]]</p> <p class="item-name">[[${item.productName}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.incomeStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -24,11 +26,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(incomeList)}"> <th:block th:if="${#lists.isEmpty(incomeList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.incomeStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class=" ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.incomeStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -48,7 +47,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(incomeList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(incomeList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -58,7 +58,8 @@
th:each="item, itemStatus : ${incomeList}"> th:each="item, itemStatus : ${incomeList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.incomeKind}]]</p> <p class="item-name">[[${item.incomeKind}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>
@@ -91,7 +92,9 @@
</ul> </ul>
</div> </div>
</div> </div>
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:if="${not btnDisabled}">
<i class="ico-add ico-small" aria-hidden="true"></i> <i class="ico-add ico-small" aria-hidden="true"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.powerStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -23,11 +25,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(powerList)}"> <th:block th:if="${#lists.isEmpty(powerList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.powerStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class="ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.powerStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -47,7 +46,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(powerList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(powerList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -57,7 +57,8 @@
th:each="item, itemStatus : ${powerList}"> th:each="item, itemStatus : ${powerList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.equipmentName}]]</p> <p class="item-name">[[${item.equipmentName}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>

View File

@@ -3,7 +3,9 @@
xmlns:th="http://www.thymeleaf.org" lang="ko"> xmlns:th="http://www.thymeleaf.org" lang="ko">
<div layout:fragment="content" th:classappend="acco-wrap"> <div layout:fragment="content" th:classappend="acco-wrap">
<main id="content" role="main"> <main id="content" role="main"
th:with="btnDisabled=${not dailyRecord.modifiable || #strings.equals(dailyRecord.workStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}
, btnIcoClass=${btnDisabled ? 'ico-add-disabled' : 'ico-add'}">
<div class="inner"> <div class="inner">
<hgroup class="tit-group"> <hgroup class="tit-group">
<h3> <h3>
@@ -23,11 +25,8 @@
<!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */--> <!--/* 신규 등록 : dailyRecord.modifiable=false 수정 기간 아님 */-->
<th:block th:if="${#lists.isEmpty(workList)}"> <th:block th:if="${#lists.isEmpty(workList)}">
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01" <button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
th:disabled="${not dailyRecord.modifiable th:disabled="${btnDisabled}">
|| #strings.equals(dailyRecord.workStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE)}"> <i class="ico-small" aria-hidden="true" th:classappend="${btnIcoClass}"></i>
<i class="ico-small" aria-hidden="true"
th:classappend="${not dailyRecord.modifiable
|| #strings.equals(dailyRecord.workStatus, T(app.module.front.usecase.daily.record.adapters.web.model.DailyTargetStatus).TODAY_NONE) ? 'ico-add-disabled' : 'ico-add'}"></i>
<span class="btn-txt">추가 등록</span> <span class="btn-txt">추가 등록</span>
</button> </button>
<div class="component-input align-center"> <div class="component-input align-center">
@@ -55,7 +54,8 @@
<section class="regist-item-area"> <section class="regist-item-area">
<p class="total"> <p class="total">
<span>총 <strong>[[${#lists.size(workList)}]]</strong>건</span> <span>총 <strong>[[${#lists.size(workList)}]]</strong>건</span>
<button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"> <button type="button" class="btn-reset" onclick="krip.daily.resetConfirm()"
th:if="${not btnDisabled}">
<i class="ico-reset ico-small" aria-hidden="true"></i> <i class="ico-reset ico-small" aria-hidden="true"></i>
<span>초기화</span> <span>초기화</span>
</button> </button>
@@ -65,7 +65,8 @@
th:each="item, itemStatus : ${workList}"> th:each="item, itemStatus : ${workList}">
<div class="item-tit-group"> <div class="item-tit-group">
<p class="item-name">[[${item.itemName}]]</p> <p class="item-name">[[${item.itemName}]]</p>
<div class="btn-group"> <div class="btn-group"
th:if="${not btnDisabled}">
<button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button> <button type="button" class="delete" th:onclick="krip.daily.removeConfirm([[${item.id}]])"><span class="hide-txt">삭제</span></button>
<button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button> <button type="button" class="edit" th:onclick="krip.daily.createModal([[${item.id}]])"><span class="hide-txt">수정</span></button>
</div> </div>