resolve merge conflict: accept remote .gitignore
This commit is contained in:
14
.classpath
14
.classpath
@@ -1,9 +1,10 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<classpath>
|
<classpath>
|
||||||
<classpathentry kind="src" output="bin/main" path="src/main/java">
|
<classpathentry kind="src" output="bin/test" path="src/test/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="gradle_scope" value="main"/>
|
<attribute name="gradle_scope" value="test"/>
|
||||||
<attribute name="gradle_used_by_scope" value="main,test"/>
|
<attribute name="gradle_used_by_scope" value="test"/>
|
||||||
|
<attribute name="test" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry kind="src" output="bin/main" path="src/main/resources">
|
<classpathentry kind="src" output="bin/main" path="src/main/resources">
|
||||||
@@ -12,11 +13,10 @@
|
|||||||
<attribute name="gradle_used_by_scope" value="main,test"/>
|
<attribute name="gradle_used_by_scope" value="main,test"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry kind="src" output="bin/test" path="src/test/java">
|
<classpathentry kind="src" output="bin/main" path="src/main/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="gradle_scope" value="test"/>
|
<attribute name="gradle_scope" value="main"/>
|
||||||
<attribute name="gradle_used_by_scope" value="test"/>
|
<attribute name="gradle_used_by_scope" value="main,test"/>
|
||||||
<attribute name="test" value="true"/>
|
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21/"/>
|
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21/"/>
|
||||||
|
|||||||
14
.gitignore
vendored
14
.gitignore
vendored
@@ -55,5 +55,15 @@ Thumbs.db
|
|||||||
# gradle-wrapper.jar를 제외 목록에서 제거하거나
|
# gradle-wrapper.jar를 제외 목록에서 제거하거나
|
||||||
# 다음 라인을 추가하여 명시적으로 포함
|
# 다음 라인을 추가하여 명시적으로 포함
|
||||||
!gradle/wrapper/gradle-wrapper.jar
|
!gradle/wrapper/gradle-wrapper.jar
|
||||||
build_log.txt
|
.classpath
|
||||||
gradle.properties
|
.settings/org.eclipse.buildship.core.prefs
|
||||||
|
.settings/org.eclipse.jdt.core.prefs
|
||||||
|
.settings/org.eclipse.jdt.core.prefs
|
||||||
|
.settings/org.eclipse.buildship.core.prefs
|
||||||
|
.classpath
|
||||||
|
|
||||||
|
# Wiki repo (별도 git 리포)
|
||||||
|
.wiki/
|
||||||
|
|
||||||
|
# Agent workflows
|
||||||
|
.agent/
|
||||||
|
|||||||
@@ -1,11 +1,15 @@
|
|||||||
eclipse.preferences.version=1
|
eclipse.preferences.version=1
|
||||||
|
org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=ignore
|
||||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||||
org.eclipse.jdt.core.compiler.annotation.nonnull=javax.annotation.Nonnull
|
org.eclipse.jdt.core.compiler.annotation.nonnull=javax.annotation.Nonnull
|
||||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=javax.annotation.ParametersAreNonnullByDefault
|
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=javax.annotation.ParametersAreNonnullByDefault
|
||||||
org.eclipse.jdt.core.compiler.annotation.nullable=javax.annotation.Nullable
|
org.eclipse.jdt.core.compiler.annotation.nullable=javax.annotation.Nullable
|
||||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||||
|
org.eclipse.jdt.core.compiler.codegen.targetPlatform=21
|
||||||
|
org.eclipse.jdt.core.compiler.compliance=21
|
||||||
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
|
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
|
||||||
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
||||||
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning
|
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning
|
||||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning
|
org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning
|
||||||
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
||||||
|
org.eclipse.jdt.core.compiler.source=21
|
||||||
|
|||||||
10
.vscode/launch.json
vendored
10
.vscode/launch.json
vendored
@@ -9,6 +9,16 @@
|
|||||||
"projectName": "madeu",
|
"projectName": "madeu",
|
||||||
"args": "",
|
"args": "",
|
||||||
"envFile": "${workspaceFolder}/.env"
|
"envFile": "${workspaceFolder}/.env"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "java",
|
||||||
|
"name": "Spring Boot-MadeuApplication<madeu_crm>",
|
||||||
|
"request": "launch",
|
||||||
|
"cwd": "${workspaceFolder}",
|
||||||
|
"mainClass": "com.madeu.MadeuApplication",
|
||||||
|
"projectName": "madeu_crm",
|
||||||
|
"args": "",
|
||||||
|
"envFile": "${workspaceFolder}/.env"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
54
sql/MU_CTI_LOG_DDL.sql
Normal file
54
sql/MU_CTI_LOG_DDL.sql
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
-- ============================================
|
||||||
|
-- CTI 통화 로그 테이블 (MariaDB)
|
||||||
|
-- ============================================
|
||||||
|
|
||||||
|
-- CTI 통화 로그 메인 테이블
|
||||||
|
CREATE TABLE IF NOT EXISTS MU_CTI_LOG (
|
||||||
|
MU_CTI_LOG_ID VARCHAR(20) NOT NULL COMMENT 'CTI 로그 ID (PK)',
|
||||||
|
RECORD_NO VARCHAR(50) NULL COMMENT 'CTI 레코드 번호',
|
||||||
|
CID VARCHAR(20) NULL COMMENT '발신자 전화번호',
|
||||||
|
FULLDNIS VARCHAR(20) NULL COMMENT '매장 수신번호 (ARS 대표번호)',
|
||||||
|
BOUND VARCHAR(10) NULL COMMENT '통화방향 (IN/OUT)',
|
||||||
|
MENU_NO VARCHAR(10) NULL COMMENT 'ARS 메뉴 번호',
|
||||||
|
STATE_TYPE VARCHAR(20) NULL COMMENT '상태유형 (start/ringout/link/callback/lms/local)',
|
||||||
|
CTI_STEP VARCHAR(5) NULL COMMENT '통화단계 (1=수신, 2=ring, 3=link, 4=linkend, 5=bend, 98=callback)',
|
||||||
|
LOGINCID VARCHAR(20) NULL COMMENT '상담원 전화번호',
|
||||||
|
C_TYPE1 VARCHAR(20) NULL COMMENT '구분2 (초진/재진)',
|
||||||
|
C_TYPE2 VARCHAR(20) NULL COMMENT '구분3 (상담/상담후예약/회차예약)',
|
||||||
|
CRM_MB_PID VARCHAR(20) NULL COMMENT 'CRM 회원 PID',
|
||||||
|
STORE_PID VARCHAR(20) NULL COMMENT '매장 PID',
|
||||||
|
INCALL_SEL VARCHAR(500) NULL COMMENT 'In Call 선택값 (파이프 구분)',
|
||||||
|
CALL_BACK_CHK CHAR(1) NULL DEFAULT 'N' COMMENT '콜백 확인 여부 (Y/N)',
|
||||||
|
USE_YN CHAR(1) NOT NULL DEFAULT 'Y' COMMENT '사용여부',
|
||||||
|
CUD_FLAG CHAR(1) NULL DEFAULT 'C' COMMENT 'CUD 플래그',
|
||||||
|
REG_ID VARCHAR(20) NULL COMMENT '등록자 ID',
|
||||||
|
REG_DATE DATETIME NULL DEFAULT CURRENT_TIMESTAMP COMMENT '등록일시',
|
||||||
|
MOD_ID VARCHAR(20) NULL COMMENT '수정자 ID',
|
||||||
|
MOD_DATE DATETIME NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '수정일시',
|
||||||
|
PRIMARY KEY (MU_CTI_LOG_ID)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='CTI 통화 로그';
|
||||||
|
|
||||||
|
-- 인덱스
|
||||||
|
CREATE INDEX IDX_MU_CTI_LOG_RECORD_NO ON MU_CTI_LOG (RECORD_NO);
|
||||||
|
CREATE INDEX IDX_MU_CTI_LOG_REG_DATE ON MU_CTI_LOG (REG_DATE);
|
||||||
|
CREATE INDEX IDX_MU_CTI_LOG_CID ON MU_CTI_LOG (CID);
|
||||||
|
CREATE INDEX IDX_MU_CTI_LOG_FULLDNIS ON MU_CTI_LOG (FULLDNIS);
|
||||||
|
CREATE INDEX IDX_MU_CTI_LOG_STORE_PID ON MU_CTI_LOG (STORE_PID);
|
||||||
|
|
||||||
|
|
||||||
|
-- CTI 통화 메모 테이블
|
||||||
|
CREATE TABLE IF NOT EXISTS MU_CTI_TEXT (
|
||||||
|
MU_CTI_TEXT_ID VARCHAR(20) NOT NULL COMMENT 'CTI 메모 ID (PK)',
|
||||||
|
RECORD_NO VARCHAR(50) NULL COMMENT 'CTI 레코드 번호',
|
||||||
|
CALL_MSG TEXT NULL COMMENT '통화 메모 내용',
|
||||||
|
USE_YN CHAR(1) NOT NULL DEFAULT 'Y' COMMENT '사용여부',
|
||||||
|
CUD_FLAG CHAR(1) NULL DEFAULT 'C' COMMENT 'CUD 플래그',
|
||||||
|
REG_ID VARCHAR(20) NULL COMMENT '등록자 ID',
|
||||||
|
REG_DATE DATETIME NULL DEFAULT CURRENT_TIMESTAMP COMMENT '등록일시',
|
||||||
|
MOD_ID VARCHAR(20) NULL COMMENT '수정자 ID',
|
||||||
|
MOD_DATE DATETIME NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '수정일시',
|
||||||
|
PRIMARY KEY (MU_CTI_TEXT_ID)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='CTI 통화 메모';
|
||||||
|
|
||||||
|
-- 인덱스
|
||||||
|
CREATE INDEX IDX_MU_CTI_TEXT_RECORD_NO ON MU_CTI_TEXT (RECORD_NO);
|
||||||
@@ -25,6 +25,7 @@ import javax.xml.xpath.XPathFactory;
|
|||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.scheduling.annotation.Scheduled;
|
import org.springframework.scheduling.annotation.Scheduled;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import org.w3c.dom.Document;
|
import org.w3c.dom.Document;
|
||||||
import org.w3c.dom.Node;
|
import org.w3c.dom.Node;
|
||||||
import org.w3c.dom.NodeList;
|
import org.w3c.dom.NodeList;
|
||||||
@@ -33,6 +34,9 @@ import org.xml.sax.SAXException;
|
|||||||
|
|
||||||
import com.madeu.dao.web.webpublicholiday.WebPublicHolidaySqlMapDAO;
|
import com.madeu.dao.web.webpublicholiday.WebPublicHolidaySqlMapDAO;
|
||||||
|
|
||||||
|
import org.springframework.context.event.ContextRefreshedEvent;
|
||||||
|
import org.springframework.context.event.EventListener;
|
||||||
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@@ -42,9 +46,30 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
@Autowired
|
@Autowired
|
||||||
private WebPublicHolidaySqlMapDAO webPublicHolidaySqlMapDAO;
|
private WebPublicHolidaySqlMapDAO webPublicHolidaySqlMapDAO;
|
||||||
|
|
||||||
// 21~22년 (공공 api 조회 가능 연도가 내년꺼까지만 가능.) https://www.data.go.kr/dataset/15012690/openapi.do
|
/**
|
||||||
|
* [임시 실행용] 서버 시작(또는 리로드) 시 배치를 즉시 1회 실행합니다.
|
||||||
|
* 실행이 완료된 후에는 다시 주석 처리하거나 삭제하세요.
|
||||||
|
*/
|
||||||
|
// @EventListener(ContextRefreshedEvent.class)
|
||||||
|
public void forceRunBatch() {
|
||||||
|
log.info("============================================================================");
|
||||||
|
log.info("============== [FORCE START] Public Holiday Batch Execution ==============");
|
||||||
|
log.info("============================================================================");
|
||||||
|
try {
|
||||||
|
go();
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("Force Batch Error", e);
|
||||||
|
}
|
||||||
|
log.info("============================================================================");
|
||||||
|
log.info("============== [FORCE END] Public Holiday Batch Execution ================");
|
||||||
|
log.info("============================================================================");
|
||||||
|
}
|
||||||
|
|
||||||
|
// 21~22년 (공공 api 조회 가능 연도가 내년꺼까지만 가능.)
|
||||||
|
// https://www.data.go.kr/dataset/15012690/openapi.do
|
||||||
@Scheduled(cron = "0 0 03 1 * ?") // 매월 1일 03:00
|
@Scheduled(cron = "0 0 03 1 * ?") // 매월 1일 03:00
|
||||||
// @Scheduled(cron = "0 0/1 * * * ?")
|
// @Scheduled(cron = "0 0/1 * * * ?")
|
||||||
|
@Transactional
|
||||||
public void go() {
|
public void go() {
|
||||||
log.debug("InsertPublicHolidayBatchExcute - run start");
|
log.debug("InsertPublicHolidayBatchExcute - run start");
|
||||||
|
|
||||||
@@ -53,39 +78,39 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
Calendar c = Calendar.getInstance();
|
Calendar c = Calendar.getInstance();
|
||||||
int year = c.get(Calendar.YEAR);
|
int year = c.get(Calendar.YEAR);
|
||||||
|
|
||||||
for (int i = year; i <= year+1; i++) {
|
for (int i = year; i <= year + 1; i++) {
|
||||||
// 공휴일을 가져온다
|
// 공휴일을 가져온다
|
||||||
for(int j=1; j<=12; j++) {
|
for (int j = 1; j <= 12; j++) {
|
||||||
int month = j;
|
int month = j;
|
||||||
|
|
||||||
if(i==year) {
|
if (i == year) {
|
||||||
month = c.get(Calendar.MONTH)+j;
|
month = c.get(Calendar.MONTH) + j;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(12 < month) {
|
if (12 < month) {
|
||||||
|
|
||||||
}else {
|
} else {
|
||||||
String yearString = String.valueOf(i);
|
String yearString = String.valueOf(i);
|
||||||
String monthString = String.valueOf(month);
|
String monthString = String.valueOf(month);
|
||||||
|
|
||||||
if(10 > month) {
|
if (10 > month) {
|
||||||
//한자리수일시 01, 02같이 0을 필요로함, request param이 2자리수
|
// 한자리수일시 01, 02같이 0을 필요로함, request param이 2자리수
|
||||||
monthString = "0" + monthString;
|
monthString = "0" + monthString;
|
||||||
}
|
}
|
||||||
|
|
||||||
List<HashMap<String, Object>> listTemp = getPublicHolidayMap(yearString, monthString);
|
List<HashMap<String, Object>> listTemp = getPublicHolidayMap(yearString, monthString);
|
||||||
log.debug(yearString+"년 "+monthString+"월 결과 : " + listTemp);
|
log.debug(yearString + "년 " + monthString + "월 결과 : " + listTemp);
|
||||||
|
|
||||||
publicHolidayList.addAll(listTemp);
|
publicHolidayList.addAll(listTemp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
log.debug(i + "년의 totalPublicHolidayCount : " + publicHolidayList.size());
|
log.debug(i + "년의 totalPublicHolidayCount : " + publicHolidayList.size());
|
||||||
//logger.debug("publicHolidayList : " + publicHolidayList);
|
// logger.debug("publicHolidayList : " + publicHolidayList);
|
||||||
}
|
}
|
||||||
|
|
||||||
int insertedCount = 0;
|
int insertedCount = 0;
|
||||||
|
|
||||||
for(int i=0; i<publicHolidayList.size(); i++) {
|
for (int i = 0; i < publicHolidayList.size(); i++) {
|
||||||
HashMap<String, Object> publicHolidayParamMap = publicHolidayList.get(i);
|
HashMap<String, Object> publicHolidayParamMap = publicHolidayList.get(i);
|
||||||
StringBuffer sbTemp = new StringBuffer(String.valueOf(publicHolidayParamMap.get("locdate")));
|
StringBuffer sbTemp = new StringBuffer(String.valueOf(publicHolidayParamMap.get("locdate")));
|
||||||
sbTemp.insert(6, "-");
|
sbTemp.insert(6, "-");
|
||||||
@@ -95,13 +120,13 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
publicHolidayParamMap.put("dateName", dateName);
|
publicHolidayParamMap.put("dateName", dateName);
|
||||||
publicHolidayParamMap.put("locDate", sbTemp.toString());
|
publicHolidayParamMap.put("locDate", sbTemp.toString());
|
||||||
|
|
||||||
List<Map<String, Object>> listMapTemp = webPublicHolidaySqlMapDAO.selectListPublicHolidayDate(publicHolidayParamMap);
|
List<Map<String, Object>> listMapTemp = webPublicHolidaySqlMapDAO
|
||||||
|
.selectListPublicHolidayDate(publicHolidayParamMap);
|
||||||
|
|
||||||
// 존재하는 공휴일일 경우
|
// 존재하는 공휴일일 경우
|
||||||
if(1 <= listMapTemp.size()) {
|
if (1 <= listMapTemp.size()) {
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
String muPublicHolidayId = ("PH").concat(String.valueOf(System.currentTimeMillis()));
|
String muPublicHolidayId = ("PH").concat(String.valueOf(System.currentTimeMillis()));
|
||||||
publicHolidayParamMap.put("muPublicHolidayId", muPublicHolidayId);
|
publicHolidayParamMap.put("muPublicHolidayId", muPublicHolidayId);
|
||||||
publicHolidayParamMap.put("regId", "BATCH_SYSTEM");
|
publicHolidayParamMap.put("regId", "BATCH_SYSTEM");
|
||||||
@@ -128,17 +153,18 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
DocumentBuilder builder;
|
DocumentBuilder builder;
|
||||||
Document doc = null;
|
Document doc = null;
|
||||||
|
|
||||||
String addr = "http://apis.data.go.kr/B090041/openapi/service/SpcdeInfoService";
|
String addr = "https://apis.data.go.kr/B090041/openapi/service/SpcdeInfoService";
|
||||||
String query = "/getRestDeInfo?";
|
String query = "/getRestDeInfo?";
|
||||||
|
|
||||||
StringBuffer stringBuffer = new StringBuffer();
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
stringBuffer.append(addr);
|
stringBuffer.append(addr);
|
||||||
stringBuffer.append(query);
|
stringBuffer.append(query);
|
||||||
stringBuffer.append("ServiceKey=" + "IMP1dVPnFLL2UYlH8yyENSeLeS5UMLYxnaomTs5L2IHp8qnyd%2FzApTGcCUV9%2FD76wZQzD24HegGoNFotIoh9GA%3D%3D");
|
stringBuffer.append("ServiceKey="
|
||||||
|
+ "bd37daa85809e0f1ef330722c6b92dd8ebbe7226a63be7644d9f334662996e7c");
|
||||||
stringBuffer.append("&solYear=" + year);
|
stringBuffer.append("&solYear=" + year);
|
||||||
stringBuffer.append("&solMonth=" + month);
|
stringBuffer.append("&solMonth=" + month);
|
||||||
|
|
||||||
log.debug("stringBuffer.toString() "+ stringBuffer.toString());
|
log.debug("stringBuffer.toString() " + stringBuffer.toString());
|
||||||
|
|
||||||
try {
|
try {
|
||||||
URL url = new URL(stringBuffer.toString());
|
URL url = new URL(stringBuffer.toString());
|
||||||
@@ -147,19 +173,21 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
|
|
||||||
BufferedReader rd = null;
|
BufferedReader rd = null;
|
||||||
|
|
||||||
rd = new BufferedReader(new InputStreamReader(conn.getInputStream(),"UTF-8"));
|
rd = new BufferedReader(new InputStreamReader(conn.getInputStream(), "UTF-8"));
|
||||||
StringBuffer result = new StringBuffer();
|
StringBuffer result = new StringBuffer();
|
||||||
|
|
||||||
String line;
|
String line;
|
||||||
|
|
||||||
while((line=rd.readLine())!=null){
|
while ((line = rd.readLine()) != null) {
|
||||||
result.append(line.trim());
|
result.append(line.trim());
|
||||||
}
|
}
|
||||||
|
|
||||||
// xml 리절트 출력부분
|
// xml 리절트 출력부분
|
||||||
/*if(0<result.toString().length()){
|
/*
|
||||||
logger.debug("result :"+result.toString());
|
* if(0<result.toString().length()){
|
||||||
}*/
|
* logger.debug("result :"+result.toString());
|
||||||
|
* }
|
||||||
|
*/
|
||||||
|
|
||||||
rd.close();
|
rd.close();
|
||||||
|
|
||||||
@@ -183,8 +211,7 @@ public class InsertPublicHolidayBatchExcute {
|
|||||||
holidayList.add(holidayMapTemp);
|
holidayList.add(holidayMapTemp);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -21,10 +21,9 @@ import jakarta.servlet.http.HttpServletResponse;
|
|||||||
import jakarta.servlet.http.HttpSession;
|
import jakarta.servlet.http.HttpSession;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@Controller
|
@Controller
|
||||||
public class WebHospitalController extends ManagerDraftAction{
|
public class WebHospitalController extends ManagerDraftAction {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private WebHospitalService webHospitalService;
|
private WebHospitalService webHospitalService;
|
||||||
@@ -39,18 +38,18 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value="/webhospital/selectHospitalIntro.do")
|
@RequestMapping(value = "/webhospital/selectHospitalIntro.do")
|
||||||
public String selectHospitalIntro(HttpSession session,HttpServletRequest request, HttpServletResponse response, Model model) {
|
public String selectHospitalIntro(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
log.debug("WebHospitalController selectHospitalIntro START");
|
log.debug("WebHospitalController selectHospitalIntro START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = webHospitalService.selectHospitalIntro(paramMap);
|
map = webHospitalService.selectHospitalIntro(paramMap);
|
||||||
|
|
||||||
@@ -60,8 +59,7 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
||||||
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
}
|
||||||
@@ -76,36 +74,32 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value="/webhospital/selectHospital.do")
|
@RequestMapping(value = "/webhospital/selectHospital.do")
|
||||||
public ModelAndView selectHospital(HttpSession session,HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView selectHospital(HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
log.debug("WebHospitalController selectHospital START");
|
log.debug("WebHospitalController selectHospital START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = webHospitalService.selectHospital(paramMap);
|
map = webHospitalService.selectHospital(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return null;
|
return null;
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -120,36 +114,32 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value="/webhospital/selectWorkTime.do")
|
@RequestMapping(value = "/webhospital/selectWorkTime.do")
|
||||||
public ModelAndView selectWorkTime(HttpSession session,HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView selectWorkTime(HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
log.debug("WebHospitalController selectWorkTime START");
|
log.debug("WebHospitalController selectWorkTime START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = webHospitalService.selectWorkTime(paramMap);
|
map = webHospitalService.selectWorkTime(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return null;
|
return null;
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -157,6 +147,47 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
return HttpUtil.makeHashToJsonModelAndView(map);
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 휴일 정보 조회 (달력 표출용)
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/selectHospitalHolidayList.do")
|
||||||
|
public ModelAndView selectHospitalHolidayList(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController selectHospitalHolidayList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.selectHospitalHolidayList(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
|
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("WebHospitalController selectHospitalHolidayList END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 병원 정보 수정
|
* 병원 정보 수정
|
||||||
*
|
*
|
||||||
@@ -164,8 +195,9 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value="/webhospital/updateHospital.do")
|
@RequestMapping(value = "/webhospital/updateHospital.do")
|
||||||
public ModelAndView updateHospital(HttpSession session,HttpServletRequest request, HttpServletResponse response, MultipartHttpServletRequest file) {
|
public ModelAndView updateHospital(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
MultipartHttpServletRequest file) {
|
||||||
|
|
||||||
log.debug("WebHospitalController updateHospital START");
|
log.debug("WebHospitalController updateHospital START");
|
||||||
|
|
||||||
@@ -174,30 +206,26 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
|
|
||||||
StringBuffer errorMsg = new StringBuffer();
|
StringBuffer errorMsg = new StringBuffer();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = webHospitalService.updateHospital(paramMap);
|
map = webHospitalService.updateHospital(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
errorMsg.append(e);
|
errorMsg.append(e);
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -213,22 +241,192 @@ public class WebHospitalController extends ManagerDraftAction{
|
|||||||
insertMap.put("requestValue", String.valueOf(paramMap));
|
insertMap.put("requestValue", String.valueOf(paramMap));
|
||||||
insertMap.put("responseValue", String.valueOf(map));
|
insertMap.put("responseValue", String.valueOf(map));
|
||||||
insertMap.put("tId", map.get("tId"));
|
insertMap.put("tId", map.get("tId"));
|
||||||
if((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null) || String.valueOf(errorMsg).length() == 0){
|
if ((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null)
|
||||||
|
|| String.valueOf(errorMsg).length() == 0) {
|
||||||
insertMap.put("resultCode", "SUCCESS");
|
insertMap.put("resultCode", "SUCCESS");
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
insertMap.put("resultCode", "ERROR");
|
insertMap.put("resultCode", "ERROR");
|
||||||
}
|
}
|
||||||
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
||||||
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
||||||
|
|
||||||
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
log.debug("WebHospitalController updateHospital END");
|
log.debug("WebHospitalController updateHospital END");
|
||||||
return HttpUtil.makeHashToJsonModelAndView(map);
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 상세 조회
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/selectHospitalScheduleDetail.do")
|
||||||
|
public ModelAndView selectHospitalScheduleDetail(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController selectHospitalScheduleDetail START");
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.selectHospitalScheduleDetail(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("WebHospitalController selectHospitalScheduleDetail END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 저장
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/saveHospitalSchedule.do")
|
||||||
|
public ModelAndView saveHospitalSchedule(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController saveHospitalSchedule START");
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.saveHospitalSchedule(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("WebHospitalController saveHospitalSchedule END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 삭제
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/deleteHospitalSchedule.do")
|
||||||
|
public ModelAndView deleteHospitalSchedule(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController deleteHospitalSchedule START");
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.deleteHospitalSchedule(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("WebHospitalController deleteHospitalSchedule END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 지정 휴일 개별 저장 (insert or update)
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/saveHospitalHoliday.do")
|
||||||
|
public ModelAndView saveHospitalHoliday(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController saveHospitalHoliday START");
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.saveHospitalHoliday(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("WebHospitalController saveHospitalHoliday END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 지정 휴일 선택 삭제 (체크된 row 일괄 삭제)
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/webhospital/deleteHospitalHolidays.do")
|
||||||
|
public ModelAndView deleteHospitalHolidays(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("WebHospitalController deleteHospitalHolidays START");
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = webHospitalService.deleteHospitalHolidays(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("WebHospitalController deleteHospitalHolidays END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
215
src/main/java/com/madeu/crm/callLog/ctrl/CallLogController.java
Normal file
215
src/main/java/com/madeu/crm/callLog/ctrl/CallLogController.java
Normal file
@@ -0,0 +1,215 @@
|
|||||||
|
package com.madeu.crm.callLog.ctrl;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.Model;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
|
import com.madeu.constants.Constants;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogSearchDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallMemoDTO;
|
||||||
|
import com.madeu.crm.callLog.service.CallLogService;
|
||||||
|
import com.madeu.crm.callLog.service.GoodArsService;
|
||||||
|
import com.madeu.init.ManagerDraftAction;
|
||||||
|
import com.madeu.util.HttpUtil;
|
||||||
|
|
||||||
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import jakarta.servlet.http.HttpSession;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/callLog")
|
||||||
|
public class CallLogController extends ManagerDraftAction {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private CallLogService callLogService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private GoodArsService goodArsService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 관리 화면으로 이동
|
||||||
|
*/
|
||||||
|
@RequestMapping("/moveCallLogList.do")
|
||||||
|
public String moveCallLogList(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
|
log.debug("CallLogController moveCallLogList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = null;
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return "/web/login/logout";
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = callLogService.moveCallLogList(paramMap);
|
||||||
|
model.addAttribute("selectUseYn", map.get("selectUseYn"));
|
||||||
|
model.addAttribute("insertUseYn", map.get("insertUseYn"));
|
||||||
|
model.addAttribute("updateUseYn", map.get("updateUseYn"));
|
||||||
|
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
||||||
|
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return "/web/login/logout";
|
||||||
|
}
|
||||||
|
log.debug("CallLogController moveCallLogList END");
|
||||||
|
|
||||||
|
return "/web/callLog/callLogSelectList";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 목록 조회 (통계 포함)
|
||||||
|
*/
|
||||||
|
@PostMapping("/getCallLogList.do")
|
||||||
|
public ModelAndView getCallLogList(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, CallLogSearchDTO searchDTO) {
|
||||||
|
log.debug("CallLogController getCallLogList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
searchDTO.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = callLogService.getCallLogList(searchDTO);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "서버 오류가 발생했습니다.");
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("CallLogController getCallLogList END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 메모 저장
|
||||||
|
*/
|
||||||
|
@PostMapping("/saveCallMemo.do")
|
||||||
|
public ModelAndView saveCallMemo(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, CallMemoDTO memoDTO) {
|
||||||
|
log.debug("CallLogController saveCallMemo START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
memoDTO.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = callLogService.saveCallMemo(memoDTO);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "메모 저장 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("CallLogController saveCallMemo END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 전화 걸기 (아웃바운드)
|
||||||
|
*/
|
||||||
|
@PostMapping("/makeOutboundCall.do")
|
||||||
|
public ModelAndView makeOutboundCall(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("CallLogController makeOutboundCall START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
String loginCid = String.valueOf(paramMap.get("loginCid"));
|
||||||
|
String sendCid = String.valueOf(paramMap.get("sendCid"));
|
||||||
|
String userCid = String.valueOf(paramMap.get("userCid"));
|
||||||
|
|
||||||
|
map = goodArsService.makeOutboundCall(loginCid, sendCid, userCid);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("success", false);
|
||||||
|
map.put("msgDesc", "전화 발신 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("CallLogController makeOutboundCall END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 전화 돌려주기 (Push)
|
||||||
|
*/
|
||||||
|
@PostMapping("/pushCall.do")
|
||||||
|
public ModelAndView pushCall(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("CallLogController pushCall START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
String loginCid = String.valueOf(paramMap.get("loginCid"));
|
||||||
|
String pushCid = String.valueOf(paramMap.get("pushCid"));
|
||||||
|
|
||||||
|
map = goodArsService.pushCall(loginCid, pushCid);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("success", false);
|
||||||
|
map.put("msgDesc", "전화 연결 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("CallLogController pushCall END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 녹음 파일 URL 조회
|
||||||
|
*/
|
||||||
|
@PostMapping("/getRecordFileUrl.do")
|
||||||
|
public ModelAndView getRecordFileUrl(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
log.debug("CallLogController getRecordFileUrl START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
String recordNo = String.valueOf(paramMap.get("recordNo"));
|
||||||
|
String url = goodArsService.getRecordFileUrl(recordNo);
|
||||||
|
map.put("success", true);
|
||||||
|
map.put("recordUrl", url);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("success", false);
|
||||||
|
map.put("msgDesc", "녹음 파일 조회 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("CallLogController getRecordFileUrl END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,199 @@
|
|||||||
|
package com.madeu.crm.callLog.ctrl;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogDTO;
|
||||||
|
import com.madeu.crm.callLog.service.CallLogService;
|
||||||
|
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GoodARS Webhook 수신 Controller
|
||||||
|
*
|
||||||
|
* ARS 서버에서 통화 단계별로 이 엔드포인트를 호출하여 통화 로그를 저장합니다.
|
||||||
|
* 인증 없이(public) 접근 가능해야 합니다.
|
||||||
|
*
|
||||||
|
* 통화 흐름:
|
||||||
|
* step01 (수신) → step02 (ARS 메뉴 선택) → step03 (통화 연결)
|
||||||
|
* → step04 (통화 종료) → step05 (기타 종료)
|
||||||
|
* callback (콜백 요청)
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/cti/webhook")
|
||||||
|
public class CtiWebhookController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private CallLogService callLogService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Step 01 - 전화 수신 (통화 시작)
|
||||||
|
*/
|
||||||
|
@PostMapping("/step01")
|
||||||
|
public String step01(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook step01 - RECORD_NO:{}, CID:{}, FULLDNIS:{}", recordNo, cid, fulldnis);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, stateType, "1");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook step01 error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Step 02 - ARS 메뉴 선택 (Ring)
|
||||||
|
*/
|
||||||
|
@PostMapping("/step02")
|
||||||
|
public String step02(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook step02 - RECORD_NO:{}, MENU_NO:{}", recordNo, menuNo);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, stateType, "2");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook step02 error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Step 03 - 통화 연결 (Link)
|
||||||
|
*/
|
||||||
|
@PostMapping("/step03")
|
||||||
|
public String step03(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook step03 - RECORD_NO:{}, LOGINCID:{}", recordNo, logincid);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, stateType, "3");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook step03 error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Step 04 - 통화 종료 (Link End)
|
||||||
|
*/
|
||||||
|
@PostMapping("/step04")
|
||||||
|
public String step04(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook step04 - RECORD_NO:{}", recordNo);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, stateType, "4");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook step04 error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Step 05 - 기타 종료 (Bend)
|
||||||
|
*/
|
||||||
|
@PostMapping("/step05")
|
||||||
|
public String step05(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook step05 - RECORD_NO:{}", recordNo);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, stateType, "5");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook step05 error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Callback - 콜백 요청
|
||||||
|
*/
|
||||||
|
@PostMapping("/callback")
|
||||||
|
public String callback(
|
||||||
|
@RequestParam(value = "FULLDNIS", required = false, defaultValue = "") String fulldnis,
|
||||||
|
@RequestParam(value = "CID", required = false, defaultValue = "") String cid,
|
||||||
|
@RequestParam(value = "MENU_NO", required = false, defaultValue = "") String menuNo,
|
||||||
|
@RequestParam(value = "LOGINCID", required = false, defaultValue = "") String logincid,
|
||||||
|
@RequestParam(value = "RECORD_NO", required = false, defaultValue = "") String recordNo,
|
||||||
|
@RequestParam(value = "BOUND", required = false, defaultValue = "") String bound,
|
||||||
|
@RequestParam(value = "STATE_TYPE", required = false, defaultValue = "") String stateType) {
|
||||||
|
|
||||||
|
log.debug("CtiWebhook callback - RECORD_NO:{}, CID:{}", recordNo, cid);
|
||||||
|
|
||||||
|
try {
|
||||||
|
CallLogDTO logDTO = buildLogDTO(fulldnis, cid, menuNo, logincid, recordNo, bound, "callback", "98");
|
||||||
|
callLogService.putCtiLog(logDTO);
|
||||||
|
return "success";
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("CtiWebhook callback error", e);
|
||||||
|
return "fail";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 공통 DTO 빌드 메서드
|
||||||
|
*/
|
||||||
|
private CallLogDTO buildLogDTO(String fulldnis, String cid, String menuNo, String logincid,
|
||||||
|
String recordNo, String bound, String stateType, String ctiStep) {
|
||||||
|
CallLogDTO dto = new CallLogDTO();
|
||||||
|
dto.setFulldnis(fulldnis);
|
||||||
|
dto.setCid(cid);
|
||||||
|
dto.setMenuNo(menuNo);
|
||||||
|
dto.setLogincid(logincid);
|
||||||
|
dto.setRecordNo(recordNo);
|
||||||
|
dto.setBound(bound);
|
||||||
|
dto.setStateType(stateType);
|
||||||
|
dto.setCtiStep(ctiStep);
|
||||||
|
return dto;
|
||||||
|
}
|
||||||
|
}
|
||||||
44
src/main/java/com/madeu/crm/callLog/dto/CallLogDTO.java
Normal file
44
src/main/java/com/madeu/crm/callLog/dto/CallLogDTO.java
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
package com.madeu.crm.callLog.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 결과 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CallLogDTO {
|
||||||
|
/* ---- PK / 기본 필드 ---- */
|
||||||
|
private String muCtiLogId;
|
||||||
|
private String recordNo;
|
||||||
|
private String cid; // 발신자 전화번호
|
||||||
|
private String fulldnis; // 매장 수신번호
|
||||||
|
private String bound; // IN/OUT
|
||||||
|
private String menuNo; // ARS 메뉴 번호
|
||||||
|
private String stateType; // 상태유형
|
||||||
|
private String ctiStep; // 통화단계
|
||||||
|
private String logincid; // 상담원 전화번호
|
||||||
|
private String cType1; // 초진/재진
|
||||||
|
private String cType2; // 상담/상담후예약/회차예약
|
||||||
|
private String crmMbPid; // CRM 회원 PID
|
||||||
|
private String storePid; // 매장 PID
|
||||||
|
private String incallSel; // In Call 선택값
|
||||||
|
private String callBackChk; // 콜백 확인 여부
|
||||||
|
private String useYn;
|
||||||
|
private String cudFlag;
|
||||||
|
private String regId;
|
||||||
|
private String regDate;
|
||||||
|
private String modId;
|
||||||
|
private String modDate;
|
||||||
|
|
||||||
|
/* ---- 조인/서브쿼리 결과 필드 ---- */
|
||||||
|
private String ring; // ARS 메뉴 선택 (step2)
|
||||||
|
private String linkDate; // 통화 연결 시각 (step3)
|
||||||
|
private String linkCid; // 통화 연결 상담원 (step3)
|
||||||
|
private String linkEndDate; // 통화 종료 시각 (step4)
|
||||||
|
private String bendDate; // 기타 종료 시각 (step5)
|
||||||
|
private String callbackCid; // 콜백 전화번호 (step98)
|
||||||
|
private String smsFlag; // SMS 전송 여부
|
||||||
|
private String callMsg; // 통화 메모
|
||||||
|
private String memberName; // 고객명
|
||||||
|
private String rowNum; // 행 번호
|
||||||
|
}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
package com.madeu.crm.callLog.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 검색 조건 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CallLogSearchDTO {
|
||||||
|
/* ---- 검색 조건 ---- */
|
||||||
|
private String sDate; // 검색 시작일
|
||||||
|
private String eDate; // 검색 종료일
|
||||||
|
private String callType; // 구분1 (ARS 메뉴: 1=상담, 2=예약, 3=위치안내, callback)
|
||||||
|
private String callType1; // 구분2 (초진/재진)
|
||||||
|
private String callType2; // 구분3 (상담/상담후예약/회차예약)
|
||||||
|
private String mCid; // 고객 전화번호 검색
|
||||||
|
private String fulldnis; // 매장 수신번호
|
||||||
|
private String incallSel; // In Call 선택값 필터
|
||||||
|
|
||||||
|
/* ---- 페이징 ---- */
|
||||||
|
private Integer gridLimitStart;
|
||||||
|
private Integer gridLimitEnd;
|
||||||
|
private String gridSort;
|
||||||
|
|
||||||
|
/* ---- 권한/세션 ---- */
|
||||||
|
private String menuClass;
|
||||||
|
private String loginMemberId;
|
||||||
|
}
|
||||||
18
src/main/java/com/madeu/crm/callLog/dto/CallLogStatsDTO.java
Normal file
18
src/main/java/com/madeu/crm/callLog/dto/CallLogStatsDTO.java
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
package com.madeu.crm.callLog.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 통계 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CallLogStatsDTO {
|
||||||
|
private int totalCnt; // 전체 건수
|
||||||
|
private int inCnt; // IN 건수
|
||||||
|
private int outCnt; // OUT 건수
|
||||||
|
private int type1Cnt; // 초진 건수
|
||||||
|
private int type2Cnt; // 재진 건수
|
||||||
|
private int type11Cnt; // 상담 건수
|
||||||
|
private int type12Cnt; // 상담후예약 건수
|
||||||
|
private int type13Cnt; // 회차예약 건수
|
||||||
|
}
|
||||||
14
src/main/java/com/madeu/crm/callLog/dto/CallMemoDTO.java
Normal file
14
src/main/java/com/madeu/crm/callLog/dto/CallMemoDTO.java
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
package com.madeu.crm.callLog.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 메모 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CallMemoDTO {
|
||||||
|
private String muCtiTextId;
|
||||||
|
private String recordNo;
|
||||||
|
private String callMsg;
|
||||||
|
private String loginMemberId;
|
||||||
|
}
|
||||||
38
src/main/java/com/madeu/crm/callLog/map/CallLogMAP.java
Normal file
38
src/main/java/com/madeu/crm/callLog/map/CallLogMAP.java
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
package com.madeu.crm.callLog.map;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogSearchDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogStatsDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallMemoDTO;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface CallLogMAP {
|
||||||
|
// 통화 로그 목록 건수 조회
|
||||||
|
int getCallLogCnt(CallLogSearchDTO searchDTO);
|
||||||
|
|
||||||
|
// 통화 로그 목록 조회
|
||||||
|
List<CallLogDTO> getCallLogList(CallLogSearchDTO searchDTO);
|
||||||
|
|
||||||
|
// 통화 로그 통계 집계
|
||||||
|
CallLogStatsDTO getCallLogStats(CallLogSearchDTO searchDTO);
|
||||||
|
|
||||||
|
// 통화 메모 존재 여부 확인
|
||||||
|
int getCallMemoCnt(CallMemoDTO memoDTO);
|
||||||
|
|
||||||
|
// 통화 메모 신규 저장
|
||||||
|
int saveCallMemo(CallMemoDTO memoDTO);
|
||||||
|
|
||||||
|
// 통화 메모 수정
|
||||||
|
int modCallMemo(CallMemoDTO memoDTO);
|
||||||
|
|
||||||
|
// CTI 로그 저장 (Webhook용)
|
||||||
|
int putCtiLog(CallLogDTO logDTO);
|
||||||
|
|
||||||
|
// CTI 로그 회원 매핑 업데이트
|
||||||
|
int modCtiLogMember(HashMap<String, Object> paramMap);
|
||||||
|
}
|
||||||
134
src/main/java/com/madeu/crm/callLog/service/CallLogService.java
Normal file
134
src/main/java/com/madeu/crm/callLog/service/CallLogService.java
Normal file
@@ -0,0 +1,134 @@
|
|||||||
|
package com.madeu.crm.callLog.service;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.madeu.common.service.MenuAuthService;
|
||||||
|
import com.madeu.constants.Constants;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogSearchDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallLogStatsDTO;
|
||||||
|
import com.madeu.crm.callLog.dto.CallMemoDTO;
|
||||||
|
import com.madeu.crm.callLog.map.CallLogMAP;
|
||||||
|
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
public class CallLogService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private CallLogMAP callLogMAP;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private MenuAuthService menuAuthService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 화면 이동
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> moveCallLogList(HashMap<String, Object> paramMap) throws Exception {
|
||||||
|
log.debug("moveCallLogList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = menuAuthService.getMenuAuthority(paramMap);
|
||||||
|
|
||||||
|
log.debug("loginMemberId : " + paramMap.get("loginMemberId"));
|
||||||
|
log.debug("menuClass : " + paramMap.get("menuClass"));
|
||||||
|
log.debug("moveCallLogList END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 로그 목록 조회 (통계 포함)
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> getCallLogList(CallLogSearchDTO searchDTO) throws Exception {
|
||||||
|
log.debug("getCallLogList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
List<CallLogDTO> listMap = new ArrayList<>();
|
||||||
|
|
||||||
|
int totalCount = callLogMAP.getCallLogCnt(searchDTO);
|
||||||
|
|
||||||
|
if (0 < totalCount) {
|
||||||
|
listMap = callLogMAP.getCallLogList(searchDTO);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 통계 집계
|
||||||
|
CallLogStatsDTO stats = callLogMAP.getCallLogStats(searchDTO);
|
||||||
|
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("totalCount", totalCount);
|
||||||
|
map.put("rows", listMap);
|
||||||
|
map.put("stats", stats);
|
||||||
|
|
||||||
|
log.debug("getCallLogList END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 통화 메모 저장
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> saveCallMemo(CallMemoDTO memoDTO) throws Exception {
|
||||||
|
log.debug("saveCallMemo START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
int existCnt = callLogMAP.getCallMemoCnt(memoDTO);
|
||||||
|
int result = 0;
|
||||||
|
|
||||||
|
if (existCnt > 0) {
|
||||||
|
// 기존 메모 수정
|
||||||
|
result = callLogMAP.modCallMemo(memoDTO);
|
||||||
|
} else {
|
||||||
|
// 신규 메모 등록
|
||||||
|
result = callLogMAP.saveCallMemo(memoDTO);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (0 < result) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("msgDesc", "메모가 저장되었습니다.");
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
map.put("msgDesc", "메모 저장에 실패하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("saveCallMemo END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* CTI 로그 저장 (Webhook에서 호출)
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> putCtiLog(CallLogDTO logDTO) throws Exception {
|
||||||
|
log.debug("putCtiLog START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
int result = callLogMAP.putCtiLog(logDTO);
|
||||||
|
|
||||||
|
if (0 < result) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("putCtiLog END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* CTI 로그 회원 매핑
|
||||||
|
*/
|
||||||
|
public void updateCtiLogMember(HashMap<String, Object> paramMap) throws Exception {
|
||||||
|
callLogMAP.modCtiLogMember(paramMap);
|
||||||
|
}
|
||||||
|
}
|
||||||
129
src/main/java/com/madeu/crm/callLog/service/GoodArsService.java
Normal file
129
src/main/java/com/madeu/crm/callLog/service/GoodArsService.java
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
package com.madeu.crm.callLog.service;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.web.client.RestTemplate;
|
||||||
|
import org.springframework.web.util.UriComponentsBuilder;
|
||||||
|
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GoodARS CTI API 연동 서비스
|
||||||
|
*
|
||||||
|
* 연동 서버: ars.goodars.co.kr
|
||||||
|
* 고객사 ID(CPID): application.properties에 설정
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
public class GoodArsService {
|
||||||
|
|
||||||
|
@Value("${goodars.cpid:5000036030017}")
|
||||||
|
private String arsCpid;
|
||||||
|
|
||||||
|
@Value("${goodars.base-url:http://ars.goodars.co.kr/LINK/MADEU}")
|
||||||
|
private String arsBaseUrl;
|
||||||
|
|
||||||
|
@Value("${goodars.base-url-ssl:https://ars.goodars.co.kr/LINK/MADEU}")
|
||||||
|
private String arsBaseUrlSsl;
|
||||||
|
|
||||||
|
private final RestTemplate restTemplate = new RestTemplate();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 아웃바운드 전화 발신
|
||||||
|
*
|
||||||
|
* @param loginCid 상담원 전화번호 (내선번호)
|
||||||
|
* @param sendCid 매장 대표번호
|
||||||
|
* @param userCid 고객 전화번호
|
||||||
|
* @return 성공 여부 ("SUCCESS" = 성공)
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> makeOutboundCall(String loginCid, String sendCid, String userCid) {
|
||||||
|
log.debug("makeOutboundCall START - loginCid:{}, sendCid:{}, userCid:{}", loginCid, sendCid, userCid);
|
||||||
|
|
||||||
|
HashMap<String, Object> result = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
String url = UriComponentsBuilder.fromHttpUrl(arsBaseUrl + "/wid_outcall.asp")
|
||||||
|
.queryParam("CPID", arsCpid)
|
||||||
|
.queryParam("LOGINCID", loginCid)
|
||||||
|
.queryParam("SENDCID", sendCid)
|
||||||
|
.queryParam("USERCID", userCid.replaceAll("[^0-9]", ""))
|
||||||
|
.toUriString();
|
||||||
|
|
||||||
|
log.debug("makeOutboundCall URL: {}", url);
|
||||||
|
|
||||||
|
String response = restTemplate.getForObject(url, String.class);
|
||||||
|
log.debug("makeOutboundCall response: {}", response);
|
||||||
|
|
||||||
|
if ("SUCCESS".equals(response)) {
|
||||||
|
result.put("success", true);
|
||||||
|
result.put("msgDesc", "전화 발신 중입니다.");
|
||||||
|
} else {
|
||||||
|
result.put("success", false);
|
||||||
|
result.put("msgDesc", "전화 발신에 실패하였습니다. (" + response + ")");
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("makeOutboundCall error", e);
|
||||||
|
result.put("success", false);
|
||||||
|
result.put("msgDesc", "전화 발신 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("makeOutboundCall END");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 녹음 파일 URL 생성
|
||||||
|
*
|
||||||
|
* @param recordNo CTI 레코드 번호
|
||||||
|
* @return 녹음 파일 URL
|
||||||
|
*/
|
||||||
|
public String getRecordFileUrl(String recordNo) {
|
||||||
|
return UriComponentsBuilder.fromHttpUrl(arsBaseUrl + "/wid_file.asp")
|
||||||
|
.queryParam("CPID", arsCpid)
|
||||||
|
.queryParam("SN", recordNo)
|
||||||
|
.toUriString();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 전화 돌려주기 (Push)
|
||||||
|
*
|
||||||
|
* @param loginCid 상담원 전화번호
|
||||||
|
* @param pushCid 전달받을 상담원 전화번호
|
||||||
|
* @return 성공 여부
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> pushCall(String loginCid, String pushCid) {
|
||||||
|
log.debug("pushCall START - loginCid:{}, pushCid:{}", loginCid, pushCid);
|
||||||
|
|
||||||
|
HashMap<String, Object> result = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
String url = UriComponentsBuilder.fromHttpUrl(arsBaseUrlSsl + "/wid_push.asp")
|
||||||
|
.queryParam("CPID", arsCpid)
|
||||||
|
.queryParam("LOGINCID", loginCid)
|
||||||
|
.queryParam("PUSHCID", pushCid)
|
||||||
|
.toUriString();
|
||||||
|
|
||||||
|
log.debug("pushCall URL: {}", url);
|
||||||
|
|
||||||
|
String response = restTemplate.getForObject(url, String.class);
|
||||||
|
log.debug("pushCall response: {}", response);
|
||||||
|
|
||||||
|
if ("1".equals(response)) {
|
||||||
|
result.put("success", true);
|
||||||
|
result.put("msgDesc", "전화가 연결되었습니다.");
|
||||||
|
} else {
|
||||||
|
result.put("success", false);
|
||||||
|
result.put("msgDesc", "연결에 실패하였습니다.");
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("pushCall error", e);
|
||||||
|
result.put("success", false);
|
||||||
|
result.put("msgDesc", "전화 연결 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("pushCall END");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -39,17 +39,17 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping("/contentsBbs/moveContentsBbsList.do")
|
@PostMapping("/contentsBbs/moveContentsBbsList.do")
|
||||||
public String moveContentsBbsList(HttpSession session, HttpServletRequest request, HttpServletResponse response, Model model) {
|
public String moveContentsBbsList(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
log.debug("WebTreatmentPetitController selectListWebTreatmentPetitIntro START");
|
log.debug("WebTreatmentPetitController selectListWebTreatmentPetitIntro START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.selectListWebTreatmentPetitIntro(paramMap);
|
map = contentsBbsService.selectListWebTreatmentPetitIntro(paramMap);
|
||||||
|
|
||||||
@@ -59,14 +59,12 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
||||||
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
}
|
||||||
log.debug("WebTreatmentPetitController selectListWebTreatmentPetitIntro END");
|
log.debug("WebTreatmentPetitController selectListWebTreatmentPetitIntro END");
|
||||||
|
|
||||||
|
|
||||||
model.addAttribute("categoryDivCd", getMenuToCdTitle(paramMap.get("menuClass")).get("cd"));
|
model.addAttribute("categoryDivCd", getMenuToCdTitle(paramMap.get("menuClass")).get("cd"));
|
||||||
model.addAttribute("title", getMenuToCdTitle(paramMap.get("menuClass")).get("title"));
|
model.addAttribute("title", getMenuToCdTitle(paramMap.get("menuClass")).get("title"));
|
||||||
|
|
||||||
@@ -81,33 +79,30 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping("/contentsBbs/getContentsBbsList.do")
|
@PostMapping("/contentsBbs/getContentsBbsList.do")
|
||||||
public ModelAndView getContentsBbsList(HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView getContentsBbsList(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.getContentsBbsList(paramMap);
|
map = contentsBbsService.getContentsBbsList(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return null;
|
return null;
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -115,6 +110,44 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
return HttpUtil.makeHashToJsonModelAndView(map);
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 카테고리 목록 조회
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@PostMapping("/contentsBbs/getCategoryList.do")
|
||||||
|
public ModelAndView getCategoryList(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
map = contentsBbsService.getCategoryList(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
|
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("ContentsBbsController getCategoryList END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 홈페이지 시술예약(쁘띠) 정보 상세 조회
|
* 홈페이지 시술예약(쁘띠) 정보 상세 조회
|
||||||
*
|
*
|
||||||
@@ -123,34 +156,30 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping("/contentsBbs/getContentsBbs.do")
|
@PostMapping("/contentsBbs/getContentsBbs.do")
|
||||||
public ModelAndView getContentsBbs(HttpSession session,HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView getContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
||||||
log.debug("WebTreatmentPetitController selectWebTreatmentPetit START");
|
log.debug("WebTreatmentPetitController selectWebTreatmentPetit START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.getContentsBbs(paramMap);
|
map = contentsBbsService.getContentsBbs(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return null;
|
return null;
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -166,17 +195,17 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping("/contentsBbs/moveRegContentsBbs.do")
|
@PostMapping("/contentsBbs/moveRegContentsBbs.do")
|
||||||
public String moveRegContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response, Model model) {
|
public String moveRegContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
log.debug("ContentsBbsController moveRegContentsBbs START");
|
log.debug("ContentsBbsController moveRegContentsBbs START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.insertWebTreatmentPetitIntro(paramMap);
|
map = contentsBbsService.insertWebTreatmentPetitIntro(paramMap);
|
||||||
|
|
||||||
@@ -187,8 +216,7 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
||||||
model.addAttribute("categorylist", map.get("categorylist"));
|
model.addAttribute("categorylist", map.get("categorylist"));
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
}
|
||||||
@@ -206,8 +234,10 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping(value="/contentsBbs/putContentsBbs.do")
|
@PostMapping(value = "/contentsBbs/putContentsBbs.do")
|
||||||
public ModelAndView putContentsBbs(HttpSession session,HttpServletRequest request, HttpServletResponse response,@RequestParam(value = "file", required = false) MultipartFile file,@RequestParam(value = "content_file", required = false) MultipartFile content_file) {
|
public ModelAndView putContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
@RequestParam(value = "file", required = false) MultipartFile file,
|
||||||
|
@RequestParam(value = "content_file", required = false) MultipartFile content_file) {
|
||||||
log.debug("ContentsBbsController putContentsBbs START");
|
log.debug("ContentsBbsController putContentsBbs START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
@@ -215,30 +245,26 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
|
|
||||||
StringBuffer errorMsg = new StringBuffer();
|
StringBuffer errorMsg = new StringBuffer();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.putContentsBbs(paramMap,file,content_file);
|
map = contentsBbsService.putContentsBbs(paramMap, file, content_file);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
errorMsg.append(e);
|
errorMsg.append(e);
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -254,18 +280,17 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
insertMap.put("requestValue", String.valueOf(paramMap));
|
insertMap.put("requestValue", String.valueOf(paramMap));
|
||||||
insertMap.put("responseValue", String.valueOf(map));
|
insertMap.put("responseValue", String.valueOf(map));
|
||||||
insertMap.put("tId", map.get("tId"));
|
insertMap.put("tId", map.get("tId"));
|
||||||
if((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null) || String.valueOf(errorMsg).length() == 0){
|
if ((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null)
|
||||||
|
|| String.valueOf(errorMsg).length() == 0) {
|
||||||
insertMap.put("resultCode", "SUCCESS");
|
insertMap.put("resultCode", "SUCCESS");
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
insertMap.put("resultCode", "ERROR");
|
insertMap.put("resultCode", "ERROR");
|
||||||
}
|
}
|
||||||
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
||||||
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
||||||
|
|
||||||
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -280,18 +305,18 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping(value="/contentsBbs/moveContentsBbs.do")
|
@PostMapping(value = "/contentsBbs/moveContentsBbs.do")
|
||||||
public String moveContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response, Model model) {
|
public String moveContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
log.debug("ContentsBbsController moveContentsBbs START");
|
log.debug("ContentsBbsController moveContentsBbs START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.moveContentsBbs(paramMap);
|
map = contentsBbsService.moveContentsBbs(paramMap);
|
||||||
|
|
||||||
@@ -303,8 +328,7 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
model.addAttribute("categoryDivCd", paramMap.get("categoryDivCd"));
|
model.addAttribute("categoryDivCd", paramMap.get("categoryDivCd"));
|
||||||
model.addAttribute("category", map.get("category"));
|
model.addAttribute("category", map.get("category"));
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return "/web/login/logout";
|
return "/web/login/logout";
|
||||||
}
|
}
|
||||||
@@ -322,8 +346,10 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping(value="/contentsBbs/modContentsBbs.do")
|
@PostMapping(value = "/contentsBbs/modContentsBbs.do")
|
||||||
public ModelAndView modContentsBbs(HttpSession session,HttpServletRequest request, HttpServletResponse response, @RequestParam(value = "file", required = false) MultipartFile file, @RequestParam(value = "content_file", required = false) MultipartFile content_file) {
|
public ModelAndView modContentsBbs(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
@RequestParam(value = "file", required = false) MultipartFile file,
|
||||||
|
@RequestParam(value = "content_file", required = false) MultipartFile content_file) {
|
||||||
log.debug("WebTreatmentPetitController updateWebTreatmentPetit START");
|
log.debug("WebTreatmentPetitController updateWebTreatmentPetit START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
@@ -331,30 +357,26 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
|
|
||||||
StringBuffer errorMsg = new StringBuffer();
|
StringBuffer errorMsg = new StringBuffer();
|
||||||
|
|
||||||
try{
|
try {
|
||||||
if(!webCheckLogin(session)){
|
if (!webCheckLogin(session)) {
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.modContentsBbs(paramMap, file, content_file );
|
map = contentsBbsService.modContentsBbs(paramMap, file, content_file);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
errorMsg.append(e);
|
errorMsg.append(e);
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -370,18 +392,17 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
insertMap.put("requestValue", String.valueOf(paramMap));
|
insertMap.put("requestValue", String.valueOf(paramMap));
|
||||||
insertMap.put("responseValue", String.valueOf(map));
|
insertMap.put("responseValue", String.valueOf(map));
|
||||||
insertMap.put("tId", map.get("tId"));
|
insertMap.put("tId", map.get("tId"));
|
||||||
if((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null) || String.valueOf(errorMsg).length() == 0){
|
if ((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null)
|
||||||
|
|| String.valueOf(errorMsg).length() == 0) {
|
||||||
insertMap.put("resultCode", "SUCCESS");
|
insertMap.put("resultCode", "SUCCESS");
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
insertMap.put("resultCode", "ERROR");
|
insertMap.put("resultCode", "ERROR");
|
||||||
}
|
}
|
||||||
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
||||||
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
||||||
|
|
||||||
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -389,7 +410,6 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
return HttpUtil.makeHashToJsonModelAndView(map);
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 홈페이지 시술예약(쁘띠) 정보 삭제
|
* 홈페이지 시술예약(쁘띠) 정보 삭제
|
||||||
*
|
*
|
||||||
@@ -397,41 +417,36 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@PostMapping(value="/contentsBbs/delContentsBbs.do")
|
@PostMapping(value = "/contentsBbs/delContentsBbs.do")
|
||||||
public ModelAndView delContentsBbs(@RequestBody HashMap<String, Object> paramMap, HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView delContentsBbs(@RequestBody HashMap<String, Object> paramMap, HttpSession session,
|
||||||
|
HttpServletRequest request, HttpServletResponse response) {
|
||||||
log.debug("WebTreatmentPetitController deleteWebTreatmentPetit START");
|
log.debug("WebTreatmentPetitController deleteWebTreatmentPetit START");
|
||||||
|
|
||||||
//HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
// HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
StringBuffer errorMsg = new StringBuffer();
|
StringBuffer errorMsg = new StringBuffer();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
try{
|
|
||||||
if(!webCheckLogin(session)){
|
|
||||||
return null;
|
return null;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("regId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.delContentsBbs(paramMap);
|
map = contentsBbsService.delContentsBbs(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
errorMsg.append(e);
|
errorMsg.append(e);
|
||||||
}
|
} finally {
|
||||||
finally {
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
if(Constants.OK == map.get("msgCode")) {
|
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
map.put("msgCode", Constants.FAIL);
|
map.put("msgCode", Constants.FAIL);
|
||||||
map.put("success", false);
|
map.put("success", false);
|
||||||
if(null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
map.put("msgDesc","정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -447,18 +462,17 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
insertMap.put("requestValue", String.valueOf(paramMap));
|
insertMap.put("requestValue", String.valueOf(paramMap));
|
||||||
insertMap.put("responseValue", String.valueOf(map));
|
insertMap.put("responseValue", String.valueOf(map));
|
||||||
insertMap.put("tId", map.get("tId"));
|
insertMap.put("tId", map.get("tId"));
|
||||||
if((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null) || String.valueOf(errorMsg).length() == 0){
|
if ((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null)
|
||||||
|
|| String.valueOf(errorMsg).length() == 0) {
|
||||||
insertMap.put("resultCode", "SUCCESS");
|
insertMap.put("resultCode", "SUCCESS");
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
insertMap.put("resultCode", "ERROR");
|
insertMap.put("resultCode", "ERROR");
|
||||||
}
|
}
|
||||||
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
||||||
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
||||||
|
|
||||||
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -467,14 +481,86 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 시술 정보 리스트 조회 (option)
|
* 출력순서 일괄 업데이트
|
||||||
* 시술등록 팝업
|
*
|
||||||
|
* @param paramMap
|
||||||
|
* @param session
|
||||||
* @param request
|
* @param request
|
||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
//@RequestMapping(value = "/webtreatmentpetit/selectListTreatmentOption.do")
|
@PostMapping(value = "/contentsBbs/updateOrdNo.do")
|
||||||
public ModelAndView selectListTreatmentOption(HttpSession session, HttpServletRequest request, HttpServletResponse response) {
|
public ModelAndView updateOrdNo(@RequestBody HashMap<String, Object> paramMap, HttpSession session,
|
||||||
|
HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
log.debug("ContentsBbsController updateOrdNo START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
StringBuffer errorMsg = new StringBuffer();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
paramMap.put("modId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = contentsBbsService.updateContentsBbsOrdNo(paramMap);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
errorMsg.append(e);
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK == map.get("msgCode")) {
|
||||||
|
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
HashMap<String, Object> visitLogParamMap = RequestLogUtil.getVisitLogParameterMap(request);
|
||||||
|
HashMap<String, Object> insertMap = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
insertMap.put("url", "/contentsBbs/updateOrdNo.do");
|
||||||
|
insertMap.put("func", "updateOrdNo");
|
||||||
|
insertMap.put("funcName", "출력순서 변경");
|
||||||
|
insertMap.put("service", "contentsBbsService");
|
||||||
|
insertMap.put("serviceName", "출력순서 변경");
|
||||||
|
insertMap.put("requestValue", String.valueOf(paramMap));
|
||||||
|
insertMap.put("responseValue", String.valueOf(map));
|
||||||
|
insertMap.put("tId", map.get("tId"));
|
||||||
|
if ((String.valueOf(errorMsg)).equals("") || (String.valueOf(errorMsg) == null)
|
||||||
|
|| String.valueOf(errorMsg).length() == 0) {
|
||||||
|
insertMap.put("resultCode", "SUCCESS");
|
||||||
|
} else {
|
||||||
|
insertMap.put("resultCode", "ERROR");
|
||||||
|
}
|
||||||
|
insertMap.put("resultMsg", String.valueOf(errorMsg));
|
||||||
|
insertMap.put("muMemberId", paramMap.get("loginMemberId"));
|
||||||
|
|
||||||
|
webLogHistoryService.insertLogHistory(insertMap, visitLogParamMap);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("ContentsBbsController updateOrdNo END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 시술 정보 리스트 조회 (option)
|
||||||
|
* 시술등록 팝업
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
// @RequestMapping(value = "/webtreatmentpetit/selectListTreatmentOption.do")
|
||||||
|
public ModelAndView selectListTreatmentOption(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response) {
|
||||||
log.debug("WebTreatmentPetitController selectListTreatmentOption START");
|
log.debug("WebTreatmentPetitController selectListTreatmentOption START");
|
||||||
|
|
||||||
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
@@ -487,8 +573,7 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
map = contentsBbsService.selectListTreatmentOption(paramMap);
|
map = contentsBbsService.selectListTreatmentOption(paramMap);
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception e) {
|
||||||
catch (Exception e) {
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
return null;
|
return null;
|
||||||
} finally {
|
} finally {
|
||||||
@@ -507,33 +592,42 @@ public class ContentsBbsController extends ManagerDraftAction {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private HashMap<String, String> getMenuToCdTitle(Object obj) {
|
private HashMap<String, String> getMenuToCdTitle(Object obj) {
|
||||||
HashMap<String, String> map = new HashMap<String, String>();
|
HashMap<String, String> map = new HashMap<String, String>();
|
||||||
String cd = "";
|
String cd = "";
|
||||||
String title = "";
|
String title = "";
|
||||||
if( "100101".equals(obj) ) {
|
if ("100101".equals(obj)) {
|
||||||
cd = "01";
|
cd = "01";
|
||||||
title = "시술예약(다이어트)";
|
title = "시술예약(다이어트)";
|
||||||
} else if( "100102".equals(obj) ) {
|
} else if ("100102".equals(obj)) {
|
||||||
cd = "02";
|
cd = "02";
|
||||||
title = "이벤트(다이어트)";
|
title = "이벤트(다이어트)";
|
||||||
} else if( "100201".equals(obj) ) {
|
} else if ("100201".equals(obj)) {
|
||||||
cd = "03";
|
cd = "03";
|
||||||
title = "시술예약(쁘띠)";
|
title = "시술예약(쁘띠)";
|
||||||
} else if( "100202".equals(obj) ){
|
} else if ("100202".equals(obj)) {
|
||||||
cd = "04";
|
cd = "04";
|
||||||
title = "이벤트(쁘띠)";
|
title = "이벤트(쁘띠)";
|
||||||
} else {
|
} else {
|
||||||
cd = "01";
|
cd = "01";
|
||||||
title = "시술예약(다이어트)";
|
title = "시술예약(다이어트)";
|
||||||
}
|
}
|
||||||
|
|
||||||
map.put("cd", cd);
|
map.put("cd", cd);
|
||||||
map.put("title", title);
|
map.put("title", title);
|
||||||
return map;
|
return map;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 미리보기 화면으로 이동
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/contentsBbs/contentsBbsPreview.do")
|
||||||
|
public String contentsBbsPreview(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
|
return "/web/contentsBbs/ContentsBbsPreview";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -5,15 +5,28 @@ import org.springframework.web.multipart.MultipartFile;
|
|||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
|
||||||
public interface ContentsBbsService {
|
public interface ContentsBbsService {
|
||||||
public HashMap<String, Object> selectListWebTreatmentPetitIntro(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> selectListWebTreatmentPetitIntro(HashMap<String, Object> paramMap)
|
||||||
public HashMap<String, Object> getContentsBbsList(HashMap<String, Object> paramMap) throws Exception;
|
throws Exception;
|
||||||
public HashMap<String, Object> getContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
|
||||||
|
|
||||||
public HashMap<String, Object> insertWebTreatmentPetitIntro(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> getContentsBbsList(HashMap<String, Object> paramMap) throws Exception;
|
||||||
public HashMap<String, Object> putContentsBbs(HashMap<String, Object> paramMap, MultipartFile file, MultipartFile content_file) throws Exception;
|
|
||||||
|
|
||||||
public HashMap<String, Object> moveContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> getContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
||||||
public HashMap<String, Object> modContentsBbs(HashMap<String, Object> paramMap, MultipartFile file, MultipartFile content_file) throws Exception;
|
|
||||||
public HashMap<String, Object> delContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> insertWebTreatmentPetitIntro(HashMap<String, Object> paramMap) throws Exception;
|
||||||
public HashMap<String, Object> selectListTreatmentOption(HashMap<String, Object> paramMap) throws Exception;
|
|
||||||
|
public HashMap<String, Object> putContentsBbs(HashMap<String, Object> paramMap, MultipartFile file,
|
||||||
|
MultipartFile content_file) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> moveContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> modContentsBbs(HashMap<String, Object> paramMap, MultipartFile file,
|
||||||
|
MultipartFile content_file) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> delContentsBbs(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> selectListTreatmentOption(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> updateContentsBbsOrdNo(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> getCategoryList(HashMap<String, Object> paramMap) throws Exception;
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,201 @@
|
|||||||
|
package com.madeu.crm.smsTemplate.ctrl;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.Model;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
|
import com.madeu.constants.Constants;
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateDTO;
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateSearchDTO;
|
||||||
|
import com.madeu.crm.smsTemplate.service.SmsTemplateService;
|
||||||
|
import com.madeu.init.ManagerDraftAction;
|
||||||
|
import com.madeu.util.HttpUtil;
|
||||||
|
|
||||||
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import jakarta.servlet.http.HttpSession;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/smsTemplate")
|
||||||
|
public class SmsTemplateController extends ManagerDraftAction {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private SmsTemplateService smsTemplateService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 관리 화면으로 이동
|
||||||
|
*/
|
||||||
|
@RequestMapping("/moveSmsTemplateList.do")
|
||||||
|
public String moveSmsTemplateList(HttpSession session, HttpServletRequest request, HttpServletResponse response,
|
||||||
|
Model model) {
|
||||||
|
log.debug("SmsTemplateController moveSmsTemplateList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> paramMap = HttpUtil.getParameterMap(request);
|
||||||
|
HashMap<String, Object> map = null;
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return "/web/login/logout";
|
||||||
|
} else {
|
||||||
|
paramMap.put("loginMemberId", String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.moveSmsTemplateList(paramMap);
|
||||||
|
model.addAttribute("selectUseYn", map.get("selectUseYn"));
|
||||||
|
model.addAttribute("insertUseYn", map.get("insertUseYn"));
|
||||||
|
model.addAttribute("updateUseYn", map.get("updateUseYn"));
|
||||||
|
model.addAttribute("deleteUseYn", map.get("deleteUseYn"));
|
||||||
|
model.addAttribute("downloadUseYn", map.get("downloadUseYn"));
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return "/web/login/logout";
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController moveSmsTemplateList END");
|
||||||
|
|
||||||
|
return "/web/smsTemplate/smsTemplateSelectList";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 목록 조회
|
||||||
|
*/
|
||||||
|
@PostMapping("/getSmsTemplateList.do")
|
||||||
|
public ModelAndView getSmsTemplateList(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, SmsTemplateSearchDTO searchDTO) {
|
||||||
|
log.debug("SmsTemplateController getSmsTemplateList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
searchDTO.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.getSmsTemplateList(searchDTO);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "서버 오류가 발생했습니다.");
|
||||||
|
} finally {
|
||||||
|
if (Constants.OK != map.get("msgCode")) {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", false);
|
||||||
|
if (null == map.get("msgDesc") || ("").equals(map.get("msgDesc"))) {
|
||||||
|
map.put("msgDesc", "정상적으로 수행되지 않았습니다. 관리자에게 문의하시기 바랍니다.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController getSmsTemplateList END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 상세 조회
|
||||||
|
*/
|
||||||
|
@PostMapping("/getSmsTemplate.do")
|
||||||
|
public ModelAndView getSmsTemplate(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, SmsTemplateDTO dto) {
|
||||||
|
log.debug("SmsTemplateController getSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
dto.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.getSmsTemplate(dto);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "조회 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController getSmsTemplate END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 등록
|
||||||
|
*/
|
||||||
|
@PostMapping("/putSmsTemplate.do")
|
||||||
|
public ModelAndView putSmsTemplate(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, SmsTemplateDTO dto) {
|
||||||
|
log.debug("SmsTemplateController putSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
dto.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.putSmsTemplate(dto);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "등록 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController putSmsTemplate END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 수정
|
||||||
|
*/
|
||||||
|
@PostMapping("/modSmsTemplate.do")
|
||||||
|
public ModelAndView modSmsTemplate(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, SmsTemplateDTO dto) {
|
||||||
|
log.debug("SmsTemplateController modSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
dto.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.modSmsTemplate(dto);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "수정 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController modSmsTemplate END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 문자 상용구 삭제
|
||||||
|
*/
|
||||||
|
@PostMapping("/delSmsTemplate.do")
|
||||||
|
public ModelAndView delSmsTemplate(HttpSession session, HttpServletRequest request,
|
||||||
|
HttpServletResponse response, SmsTemplateDTO dto) {
|
||||||
|
log.debug("SmsTemplateController delSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
try {
|
||||||
|
if (!webCheckLogin(session)) {
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
dto.setLoginMemberId(String.valueOf(session.getAttribute("loginMemberId")));
|
||||||
|
map = smsTemplateService.delSmsTemplate(dto);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("msgDesc", "삭제 중 오류가 발생하였습니다.");
|
||||||
|
}
|
||||||
|
log.debug("SmsTemplateController delSmsTemplate END");
|
||||||
|
return HttpUtil.makeHashToJsonModelAndView(map);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package com.madeu.crm.smsTemplate.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* SMS 상용구 결과 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class SmsTemplateDTO {
|
||||||
|
/* ---- 테이블 필드 ---- */
|
||||||
|
private String muSmsTemplateId;
|
||||||
|
private String title;
|
||||||
|
private String content;
|
||||||
|
private String useYn;
|
||||||
|
private String cudFlag;
|
||||||
|
private String regId;
|
||||||
|
private String regDate;
|
||||||
|
private String modId;
|
||||||
|
private String modDate;
|
||||||
|
|
||||||
|
/* ---- 조인/서브쿼리 결과 필드 ---- */
|
||||||
|
private String regName; // 등록자명
|
||||||
|
private String rowNum; // 행 번호
|
||||||
|
|
||||||
|
/* ---- 세션/공통 ---- */
|
||||||
|
private String loginMemberId;
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package com.madeu.crm.smsTemplate.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* SMS 상용구 검색 조건 DTO
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class SmsTemplateSearchDTO {
|
||||||
|
/* ---- 검색 조건 ---- */
|
||||||
|
private String searchKeyword;
|
||||||
|
|
||||||
|
/* ---- 페이징 ---- */
|
||||||
|
private Integer gridLimitStart;
|
||||||
|
private Integer gridLimitEnd;
|
||||||
|
private String gridSort;
|
||||||
|
|
||||||
|
/* ---- 권한/세션 ---- */
|
||||||
|
private String menuClass;
|
||||||
|
private String loginMemberId;
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
package com.madeu.crm.smsTemplate.map;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateDTO;
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateSearchDTO;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface SmsTemplateMAP {
|
||||||
|
// 상용구 목록 건수 조회
|
||||||
|
int getSmsTemplateCnt(SmsTemplateSearchDTO searchDTO);
|
||||||
|
|
||||||
|
// 상용구 목록 조회
|
||||||
|
List<SmsTemplateDTO> getSmsTemplateList(SmsTemplateSearchDTO searchDTO);
|
||||||
|
|
||||||
|
// 상용구 상세 조회
|
||||||
|
SmsTemplateDTO getSmsTemplate(SmsTemplateDTO dto);
|
||||||
|
|
||||||
|
// 상용구 등록
|
||||||
|
int putSmsTemplate(SmsTemplateDTO dto);
|
||||||
|
|
||||||
|
// 상용구 수정
|
||||||
|
int modSmsTemplate(SmsTemplateDTO dto);
|
||||||
|
|
||||||
|
// 상용구 삭제 (논리 삭제)
|
||||||
|
int delSmsTemplate(SmsTemplateDTO dto);
|
||||||
|
}
|
||||||
@@ -0,0 +1,162 @@
|
|||||||
|
package com.madeu.crm.smsTemplate.service;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.madeu.common.service.MenuAuthService;
|
||||||
|
import com.madeu.constants.Constants;
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateDTO;
|
||||||
|
import com.madeu.crm.smsTemplate.dto.SmsTemplateSearchDTO;
|
||||||
|
import com.madeu.crm.smsTemplate.map.SmsTemplateMAP;
|
||||||
|
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
public class SmsTemplateService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private SmsTemplateMAP smsTemplateMAP;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private MenuAuthService menuAuthService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 관리 화면 이동
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> moveSmsTemplateList(HashMap<String, Object> paramMap) throws Exception {
|
||||||
|
log.debug("moveSmsTemplateList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = menuAuthService.getMenuAuthority(paramMap);
|
||||||
|
|
||||||
|
log.debug("loginMemberId : " + paramMap.get("loginMemberId"));
|
||||||
|
log.debug("menuClass : " + paramMap.get("menuClass"));
|
||||||
|
log.debug("moveSmsTemplateList END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 목록 조회
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> getSmsTemplateList(SmsTemplateSearchDTO searchDTO) throws Exception {
|
||||||
|
log.debug("getSmsTemplateList START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
List<SmsTemplateDTO> listMap = new ArrayList<>();
|
||||||
|
|
||||||
|
int totalCount = smsTemplateMAP.getSmsTemplateCnt(searchDTO);
|
||||||
|
|
||||||
|
if (0 < totalCount) {
|
||||||
|
listMap = smsTemplateMAP.getSmsTemplateList(searchDTO);
|
||||||
|
}
|
||||||
|
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("totalCount", totalCount);
|
||||||
|
map.put("rows", listMap);
|
||||||
|
|
||||||
|
log.debug("getSmsTemplateList END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 상세 조회
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> getSmsTemplate(SmsTemplateDTO dto) throws Exception {
|
||||||
|
log.debug("getSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
SmsTemplateDTO detail = smsTemplateMAP.getSmsTemplate(dto);
|
||||||
|
|
||||||
|
if (detail != null) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("data", detail);
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
map.put("msgDesc", "상용구 정보를 찾을 수 없습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("getSmsTemplate END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 등록
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> putSmsTemplate(SmsTemplateDTO dto) throws Exception {
|
||||||
|
log.debug("putSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
int result = smsTemplateMAP.putSmsTemplate(dto);
|
||||||
|
|
||||||
|
if (0 < result) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("msgDesc", "상용구가 등록되었습니다.");
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
map.put("msgDesc", "상용구 등록에 실패하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("putSmsTemplate END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 수정
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> modSmsTemplate(SmsTemplateDTO dto) throws Exception {
|
||||||
|
log.debug("modSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
int result = smsTemplateMAP.modSmsTemplate(dto);
|
||||||
|
|
||||||
|
if (0 < result) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("msgDesc", "상용구가 수정되었습니다.");
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
map.put("msgDesc", "상용구 수정에 실패하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("modSmsTemplate END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 상용구 삭제 (논리 삭제)
|
||||||
|
*/
|
||||||
|
public HashMap<String, Object> delSmsTemplate(SmsTemplateDTO dto) throws Exception {
|
||||||
|
log.debug("delSmsTemplate START");
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
int result = smsTemplateMAP.delSmsTemplate(dto);
|
||||||
|
|
||||||
|
if (0 < result) {
|
||||||
|
map.put("msgCode", Constants.OK);
|
||||||
|
map.put("success", "true");
|
||||||
|
map.put("msgDesc", "상용구가 삭제되었습니다.");
|
||||||
|
} else {
|
||||||
|
map.put("msgCode", Constants.FAIL);
|
||||||
|
map.put("success", "false");
|
||||||
|
map.put("msgDesc", "상용구 삭제에 실패하였습니다.");
|
||||||
|
}
|
||||||
|
|
||||||
|
log.debug("delSmsTemplate END");
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -12,7 +12,7 @@ import java.util.List;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
@Repository
|
@Repository
|
||||||
public class WebHospitalSqlMapDAO extends SqlSessionDaoSupport{
|
public class WebHospitalSqlMapDAO extends SqlSessionDaoSupport {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private SqlSessionTemplate sqlSessionTemplate;
|
private SqlSessionTemplate sqlSessionTemplate;
|
||||||
@@ -66,6 +66,7 @@ public class WebHospitalSqlMapDAO extends SqlSessionDaoSupport{
|
|||||||
logger.debug("WebHospitalSqlMapDAO selectHospitalWeek2 END");
|
logger.debug("WebHospitalSqlMapDAO selectHospitalWeek2 END");
|
||||||
return getSqlSession().selectList(sqlId, paramMap);
|
return getSqlSession().selectList(sqlId, paramMap);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 병원 월별 휴일 정보
|
* 병원 월별 휴일 정보
|
||||||
*
|
*
|
||||||
@@ -95,4 +96,49 @@ public class WebHospitalSqlMapDAO extends SqlSessionDaoSupport{
|
|||||||
logger.debug("WebHospitalSqlMapDAO updateHospital END");
|
logger.debug("WebHospitalSqlMapDAO updateHospital END");
|
||||||
return getSqlSession().update(sqlId, paramMap);
|
return getSqlSession().update(sqlId, paramMap);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 상세 조회
|
||||||
|
*/
|
||||||
|
public Map<String, Object> selectHospitalScheduleDetail(HashMap<String, Object> paramMap)
|
||||||
|
throws DataAccessException {
|
||||||
|
return getSqlSession().selectOne("WebHospital.selectHospitalScheduleDetail", paramMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 존재 여부 확인
|
||||||
|
*/
|
||||||
|
public Map<String, Object> selectHospitalScheduleCheck(HashMap<String, Object> paramMap)
|
||||||
|
throws DataAccessException {
|
||||||
|
return getSqlSession().selectOne("WebHospital.selectHospitalScheduleCheck", paramMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 휴일 여부 확인 (스케줄 등록되지 않은 날짜 기준)
|
||||||
|
*/
|
||||||
|
public Map<String, Object> selectHospitalHolidayCheck(HashMap<String, Object> paramMap)
|
||||||
|
throws DataAccessException {
|
||||||
|
return getSqlSession().selectOne("WebHospital.selectHospitalHolidayCheck", paramMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 등록
|
||||||
|
*/
|
||||||
|
public int insertHospitalSchedule(HashMap<String, Object> paramMap) throws DataAccessException {
|
||||||
|
return getSqlSession().insert("WebHospital.insertHospitalSchedule", paramMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 수정
|
||||||
|
*/
|
||||||
|
public int updateHospitalSchedule(HashMap<String, Object> paramMap) throws DataAccessException {
|
||||||
|
return getSqlSession().update("WebHospital.updateHospitalSchedule", paramMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 병원 스케줄 삭제
|
||||||
|
*/
|
||||||
|
public int deleteHospitalSchedule(HashMap<String, Object> paramMap) throws DataAccessException {
|
||||||
|
return getSqlSession().update("WebHospital.deleteHospitalSchedule", paramMap);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,8 +5,22 @@ import java.util.HashMap;
|
|||||||
public interface WebHospitalService {
|
public interface WebHospitalService {
|
||||||
|
|
||||||
public HashMap<String, Object> selectHospitalIntro(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> selectHospitalIntro(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
public HashMap<String, Object> selectHospital(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> selectHospital(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
public HashMap<String, Object> selectWorkTime(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> selectWorkTime(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
public HashMap<String, Object> updateHospital(HashMap<String, Object> paramMap) throws Exception;
|
public HashMap<String, Object> updateHospital(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> selectHospitalHolidayList(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> selectHospitalScheduleDetail(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> saveHospitalSchedule(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> deleteHospitalSchedule(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> saveHospitalHoliday(HashMap<String, Object> paramMap) throws Exception;
|
||||||
|
|
||||||
|
public HashMap<String, Object> deleteHospitalHolidays(HashMap<String, Object> paramMap) throws Exception;
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -81,6 +81,7 @@
|
|||||||
,USE_YN = 'N'
|
,USE_YN = 'N'
|
||||||
WHERE USE_YN = 'Y'
|
WHERE USE_YN = 'Y'
|
||||||
AND MU_HOSPITAL_ID = #{muHospitalId}
|
AND MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND MU_HOSPITAL_HOLIDAY_ID = #{muHospitalHolidayId}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -5,6 +5,7 @@
|
|||||||
<select id="selectHospital" parameterType="hashmap" resultType="hashmap">
|
<select id="selectHospital" parameterType="hashmap" resultType="hashmap">
|
||||||
SELECT MH.MU_HOSPITAL_ID AS "muHospitalId"
|
SELECT MH.MU_HOSPITAL_ID AS "muHospitalId"
|
||||||
,MH.HOSPITAL_NAME AS "hospitalName"
|
,MH.HOSPITAL_NAME AS "hospitalName"
|
||||||
|
,MH.CENTER_DIV_CD AS "centerDivCd"
|
||||||
,MH.MON_OPEN_YN AS "monOpenYn"
|
,MH.MON_OPEN_YN AS "monOpenYn"
|
||||||
,DATE_FORMAT(MH.MON_OPEN_START_TIME , '%H:%i') AS "monOpenStartTime"
|
,DATE_FORMAT(MH.MON_OPEN_START_TIME , '%H:%i') AS "monOpenStartTime"
|
||||||
,DATE_FORMAT(MH.MON_OPEN_END_TIME , '%H:%i') AS "monOpenEndTime"
|
,DATE_FORMAT(MH.MON_OPEN_END_TIME , '%H:%i') AS "monOpenEndTime"
|
||||||
@@ -49,80 +50,109 @@
|
|||||||
),'') AS "memberName"
|
),'') AS "memberName"
|
||||||
FROM MU_HOSPITAL AS MH
|
FROM MU_HOSPITAL AS MH
|
||||||
WHERE MH.USE_YN = 'Y'
|
WHERE MH.USE_YN = 'Y'
|
||||||
|
<if test="centerDivCd != null and centerDivCd != ''">
|
||||||
|
AND MH.CENTER_DIV_CD = #{centerDivCd}
|
||||||
|
</if>
|
||||||
LIMIT 0, 1
|
LIMIT 0, 1
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectHospitalWeek" parameterType="hashmap" resultType="hashmap">
|
<select id="selectHospitalWeek" parameterType="hashmap" resultType="hashmap">
|
||||||
SELECT MH.MU_HOSPITAL_ID AS "muHospitalId"
|
SELECT MH.MU_HOSPITAL_ID AS "muHospitalId"
|
||||||
,MH.HOSPITAL_NAME AS "hospitalName"
|
,MH.HOSPITAL_NAME AS "hospitalName"
|
||||||
,CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
,CASE
|
||||||
WHEN '2' THEN MH.MON_OPEN_YN
|
WHEN MHS.MU_HOSPITAL_SCHEDULE_ID IS NOT NULL THEN MHS.OPEN_YN
|
||||||
WHEN '3' THEN MH.TUE_OPEN_YN
|
ELSE
|
||||||
WHEN '4' THEN MH.WED_OPEN_YN
|
CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
||||||
WHEN '5' THEN MH.THU_OPEN_YN
|
WHEN '2' THEN MH.MON_OPEN_YN
|
||||||
WHEN '6' THEN MH.FRI_OPEN_YN
|
WHEN '3' THEN MH.TUE_OPEN_YN
|
||||||
WHEN '7' THEN MH.SAT_OPEN_YN
|
WHEN '4' THEN MH.WED_OPEN_YN
|
||||||
WHEN '1' THEN MH.SUN_OPEN_YN
|
WHEN '5' THEN MH.THU_OPEN_YN
|
||||||
|
WHEN '6' THEN MH.FRI_OPEN_YN
|
||||||
|
WHEN '7' THEN MH.SAT_OPEN_YN
|
||||||
|
WHEN '1' THEN MH.SUN_OPEN_YN
|
||||||
|
END
|
||||||
END AS "openYn"
|
END AS "openYn"
|
||||||
,CASE
|
,CASE
|
||||||
WHEN EXISTS (
|
WHEN EXISTS (
|
||||||
SELECT 1
|
SELECT 1
|
||||||
FROM MU_HOSPITAL_HOLIDAY MH
|
FROM MU_HOSPITAL_HOLIDAY MHH
|
||||||
WHERE MH.USE_YN = 'Y'
|
WHERE MHH.USE_YN = 'Y'
|
||||||
|
AND MHH.MU_HOSPITAL_ID = MH.MU_HOSPITAL_ID
|
||||||
AND (
|
AND (
|
||||||
(MH.REPEAT_YN = 'Y' AND DATE_FORMAT(MH.LOC_DATE, '%m-%d') = DATE_FORMAT(#{searchDate}, '%m-%d'))
|
(MHH.REPEAT_YN = 'Y' AND DATE_FORMAT(MHH.LOC_DATE, '%m-%d') = DATE_FORMAT(#{searchDate}, '%m-%d'))
|
||||||
OR
|
OR
|
||||||
(MH.REPEAT_YN = 'N' AND MH.LOC_DATE = #{searchDate})
|
(MHH.REPEAT_YN = 'N' AND MHH.LOC_DATE = #{searchDate})
|
||||||
)) OR
|
)) OR
|
||||||
EXISTS (
|
(MH.PUBLIC_HOLIDAY_USE_YN = 'Y' AND EXISTS (
|
||||||
SELECT 1
|
SELECT 1
|
||||||
FROM MU_PUBLIC_HOLIDAY MPH
|
FROM MU_PUBLIC_HOLIDAY MPH
|
||||||
JOIN MU_HOSPITAL
|
|
||||||
ON PUBLIC_HOLIDAY_USE_YN='Y'
|
|
||||||
WHERE MPH.USE_YN = 'Y'
|
WHERE MPH.USE_YN = 'Y'
|
||||||
AND MPH.LOC_DATE = #{searchDate}
|
AND MPH.LOC_DATE = #{searchDate}
|
||||||
)
|
))
|
||||||
THEN 'Y'
|
THEN 'Y'
|
||||||
ELSE 'N'
|
ELSE 'N'
|
||||||
END AS "holidayYn"
|
END AS "holidayYn"
|
||||||
,CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
,CASE
|
||||||
WHEN '2' THEN MH.MON_OPEN_START_TIME
|
WHEN MHS.MU_HOSPITAL_SCHEDULE_ID IS NOT NULL THEN MHS.OPEN_START_TIME
|
||||||
WHEN '3' THEN MH.TUE_OPEN_START_TIME
|
ELSE
|
||||||
WHEN '4' THEN MH.WED_OPEN_START_TIME
|
CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
||||||
WHEN '5' THEN MH.THU_OPEN_START_TIME
|
WHEN '2' THEN MH.MON_OPEN_START_TIME
|
||||||
WHEN '6' THEN MH.FRI_OPEN_START_TIME
|
WHEN '3' THEN MH.TUE_OPEN_START_TIME
|
||||||
WHEN '7' THEN MH.SAT_OPEN_START_TIME
|
WHEN '4' THEN MH.WED_OPEN_START_TIME
|
||||||
WHEN '1' THEN MH.SUN_OPEN_START_TIME
|
WHEN '5' THEN MH.THU_OPEN_START_TIME
|
||||||
|
WHEN '6' THEN MH.FRI_OPEN_START_TIME
|
||||||
|
WHEN '7' THEN MH.SAT_OPEN_START_TIME
|
||||||
|
WHEN '1' THEN MH.SUN_OPEN_START_TIME
|
||||||
|
END
|
||||||
END AS "openStartTime"
|
END AS "openStartTime"
|
||||||
,CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
,CASE
|
||||||
WHEN '2' THEN MH.MON_OPEN_END_TIME
|
WHEN MHS.MU_HOSPITAL_SCHEDULE_ID IS NOT NULL THEN MHS.OPEN_END_TIME
|
||||||
WHEN '3' THEN MH.TUE_OPEN_END_TIME
|
ELSE
|
||||||
WHEN '4' THEN MH.WED_OPEN_END_TIME
|
CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
||||||
WHEN '5' THEN MH.THU_OPEN_END_TIME
|
WHEN '2' THEN MH.MON_OPEN_END_TIME
|
||||||
WHEN '6' THEN MH.FRI_OPEN_END_TIME
|
WHEN '3' THEN MH.TUE_OPEN_END_TIME
|
||||||
WHEN '7' THEN MH.SAT_OPEN_END_TIME
|
WHEN '4' THEN MH.WED_OPEN_END_TIME
|
||||||
WHEN '1' THEN MH.SUN_OPEN_END_TIME
|
WHEN '5' THEN MH.THU_OPEN_END_TIME
|
||||||
|
WHEN '6' THEN MH.FRI_OPEN_END_TIME
|
||||||
|
WHEN '7' THEN MH.SAT_OPEN_END_TIME
|
||||||
|
WHEN '1' THEN MH.SUN_OPEN_END_TIME
|
||||||
|
END
|
||||||
END AS "openEndTime"
|
END AS "openEndTime"
|
||||||
,CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
,CASE
|
||||||
WHEN '2' THEN MH.MON_BREAK_START_TIME
|
WHEN MHS.MU_HOSPITAL_SCHEDULE_ID IS NOT NULL THEN MHS.BREAK_START_TIME
|
||||||
WHEN '3' THEN MH.TUE_BREAK_START_TIME
|
ELSE
|
||||||
WHEN '4' THEN MH.WED_BREAK_START_TIME
|
CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
||||||
WHEN '5' THEN MH.THU_BREAK_START_TIME
|
WHEN '2' THEN MH.MON_BREAK_START_TIME
|
||||||
WHEN '6' THEN MH.FRI_BREAK_START_TIME
|
WHEN '3' THEN MH.TUE_BREAK_START_TIME
|
||||||
WHEN '7' THEN MH.SAT_BREAK_START_TIME
|
WHEN '4' THEN MH.WED_BREAK_START_TIME
|
||||||
WHEN '1' THEN MH.SUN_BREAK_START_TIME
|
WHEN '5' THEN MH.THU_BREAK_START_TIME
|
||||||
|
WHEN '6' THEN MH.FRI_BREAK_START_TIME
|
||||||
|
WHEN '7' THEN MH.SAT_BREAK_START_TIME
|
||||||
|
WHEN '1' THEN MH.SUN_BREAK_START_TIME
|
||||||
|
END
|
||||||
END AS "breakStartTime"
|
END AS "breakStartTime"
|
||||||
,CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
,CASE
|
||||||
WHEN '2' THEN MH.MON_BREAK_END_TIME
|
WHEN MHS.MU_HOSPITAL_SCHEDULE_ID IS NOT NULL THEN MHS.BREAK_END_TIME
|
||||||
WHEN '3' THEN MH.TUE_BREAK_END_TIME
|
ELSE
|
||||||
WHEN '4' THEN MH.WED_BREAK_END_TIME
|
CASE DAYOFWEEK(DATE_FORMAT(#{searchDate}, '%Y-%m-%d'))
|
||||||
WHEN '5' THEN MH.THU_BREAK_END_TIME
|
WHEN '2' THEN MH.MON_BREAK_END_TIME
|
||||||
WHEN '6' THEN MH.FRI_BREAK_END_TIME
|
WHEN '3' THEN MH.TUE_BREAK_END_TIME
|
||||||
WHEN '7' THEN MH.SAT_BREAK_END_TIME
|
WHEN '4' THEN MH.WED_BREAK_END_TIME
|
||||||
WHEN '1' THEN MH.SUN_BREAK_END_TIME
|
WHEN '5' THEN MH.THU_BREAK_END_TIME
|
||||||
|
WHEN '6' THEN MH.FRI_BREAK_END_TIME
|
||||||
|
WHEN '7' THEN MH.SAT_BREAK_END_TIME
|
||||||
|
WHEN '1' THEN MH.SUN_BREAK_END_TIME
|
||||||
|
END
|
||||||
END AS "breakEndTime"
|
END AS "breakEndTime"
|
||||||
FROM MU_HOSPITAL AS MH
|
FROM MU_HOSPITAL AS MH
|
||||||
|
LEFT JOIN MU_HOSPITAL_SCHEDULE MHS
|
||||||
|
ON MH.MU_HOSPITAL_ID = MHS.MU_HOSPITAL_ID
|
||||||
|
AND MHS.SCHEDULE_DATE = #{searchDate}
|
||||||
|
AND MHS.USE_YN = 'Y'
|
||||||
WHERE MH.USE_YN = 'Y'
|
WHERE MH.USE_YN = 'Y'
|
||||||
|
<if test="centerDivCd != null and centerDivCd != ''">
|
||||||
|
AND MH.CENTER_DIV_CD = #{centerDivCd}
|
||||||
|
</if>
|
||||||
LIMIT 0, 1
|
LIMIT 0, 1
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
@@ -136,7 +166,11 @@
|
|||||||
FROM T_TEMP_DATES
|
FROM T_TEMP_DATES
|
||||||
WHERE RESULT_DATE < #{endDate}
|
WHERE RESULT_DATE < #{endDate}
|
||||||
)
|
)
|
||||||
SELECT TTD.OPEN_YN AS "openYn"
|
SELECT
|
||||||
|
CASE
|
||||||
|
WHEN MHS.OPEN_YN IS NOT NULL THEN MHS.OPEN_YN
|
||||||
|
ELSE TTD.OPEN_YN
|
||||||
|
END AS "openYn"
|
||||||
,TTD.HOLIDAY_YN AS "holidayYn"
|
,TTD.HOLIDAY_YN AS "holidayYn"
|
||||||
FROM (
|
FROM (
|
||||||
SELECT TTD.RESULT_DATE AS RESULT_DATE
|
SELECT TTD.RESULT_DATE AS RESULT_DATE
|
||||||
@@ -160,21 +194,20 @@
|
|||||||
END AS OPEN_YN
|
END AS OPEN_YN
|
||||||
,CASE
|
,CASE
|
||||||
WHEN EXISTS(
|
WHEN EXISTS(
|
||||||
SELECT 1
|
SELECT 1
|
||||||
FROM MU_HOSPITAL_HOLIDAY AS MH
|
FROM MU_HOSPITAL_HOLIDAY AS MHH
|
||||||
WHERE MH.USE_YN = 'Y'
|
WHERE MHH.USE_YN = 'Y'
|
||||||
AND ((MH.REPEAT_YN = 'Y' AND DATE_FORMAT(MH.LOC_DATE, '%m-%d') = DATE_FORMAT(TTD.RESULT_DATE, '%m-%d'))
|
AND MHH.MU_HOSPITAL_ID = MH.MU_HOSPITAL_ID
|
||||||
OR
|
AND ((MHH.REPEAT_YN = 'Y' AND DATE_FORMAT(MHH.LOC_DATE, '%m-%d') = DATE_FORMAT(TTD.RESULT_DATE, '%m-%d'))
|
||||||
(MH.REPEAT_YN = 'N' AND MH.LOC_DATE = TTD.RESULT_DATE))
|
OR
|
||||||
)
|
(MHH.REPEAT_YN = 'N' AND MHH.LOC_DATE = TTD.RESULT_DATE))
|
||||||
OR EXISTS(
|
|
||||||
SELECT 1
|
|
||||||
FROM MU_PUBLIC_HOLIDAY AS MPH
|
|
||||||
JOIN MU_HOSPITAL
|
|
||||||
ON PUBLIC_HOLIDAY_USE_YN='Y'
|
|
||||||
WHERE MPH.USE_YN = 'Y'
|
|
||||||
AND MPH.LOC_DATE = TTD.RESULT_DATE
|
|
||||||
)
|
)
|
||||||
|
OR (MH.PUBLIC_HOLIDAY_USE_YN = 'Y' AND EXISTS(
|
||||||
|
SELECT 1
|
||||||
|
FROM MU_PUBLIC_HOLIDAY AS MPH
|
||||||
|
WHERE MPH.USE_YN = 'Y'
|
||||||
|
AND MPH.LOC_DATE = TTD.RESULT_DATE
|
||||||
|
))
|
||||||
THEN 'Y'
|
THEN 'Y'
|
||||||
ELSE 'N'
|
ELSE 'N'
|
||||||
END AS HOLIDAY_YN
|
END AS HOLIDAY_YN
|
||||||
@@ -185,32 +218,139 @@
|
|||||||
ORDER BY TTD.RESULT_DATE ASC
|
ORDER BY TTD.RESULT_DATE ASC
|
||||||
) AS TTD
|
) AS TTD
|
||||||
LEFT JOIN MU_HOSPITAL AS MH
|
LEFT JOIN MU_HOSPITAL AS MH
|
||||||
ON 1 = 1
|
ON MH.USE_YN = 'Y'
|
||||||
|
<if test="centerDivCd != null and centerDivCd != ''">
|
||||||
|
AND MH.CENTER_DIV_CD = #{centerDivCd}
|
||||||
|
</if>
|
||||||
) AS TTD
|
) AS TTD
|
||||||
|
LEFT JOIN MU_HOSPITAL_SCHEDULE MHS
|
||||||
|
ON MHS.SCHEDULE_DATE = TTD.RESULT_DATE
|
||||||
|
AND MHS.USE_YN = 'Y'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectHospitalHoliday" parameterType="hashmap" resultType="hashmap">
|
<select id="selectHospitalHoliday" parameterType="hashmap" resultType="hashmap">
|
||||||
SELECT 'hospitalHoliday' AS dateType
|
SELECT 'hospitalHoliday' AS "dateType"
|
||||||
, DATE_FORMAT(LOC_DATE, '%Y.%m.%d') AS locDate
|
, HOSPITAL_HOLIDAY_NAME AS "hospitalHolidayName"
|
||||||
|
, DATE_FORMAT(LOC_DATE, '%Y-%m-%d') AS "locDate"
|
||||||
FROM MU_HOSPITAL_HOLIDAY MH
|
FROM MU_HOSPITAL_HOLIDAY MH
|
||||||
WHERE MH.USE_YN = 'Y'
|
WHERE MH.USE_YN = 'Y'
|
||||||
|
AND MH.MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
AND (
|
AND (
|
||||||
(MH.REPEAT_YN = 'Y')
|
(MH.REPEAT_YN = 'Y')
|
||||||
OR
|
OR
|
||||||
(MH.REPEAT_YN = 'N' AND DATE_FORMAT( MH.LOC_DATE, '%Y' ) >= DATE_FORMAT( CURDATE( ), '%Y' ))
|
(MH.REPEAT_YN = 'N' AND DATE_FORMAT( MH.LOC_DATE, '%Y' ) >= DATE_FORMAT( CURDATE( ), '%Y' ))
|
||||||
)
|
)
|
||||||
UNION
|
UNION ALL
|
||||||
(
|
(
|
||||||
SELECT 'publicHoliday' AS dateType
|
SELECT 'publicHoliday' AS "dateType"
|
||||||
, DATE_FORMAT(LOC_DATE, '%Y.%m.%d') AS locDate
|
, MPH.PUBLIC_HOLIDAY_NAME AS "publicHolidayName"
|
||||||
|
, DATE_FORMAT(MPH.LOC_DATE, '%Y-%m-%d') AS "locDate"
|
||||||
FROM MU_PUBLIC_HOLIDAY MPH
|
FROM MU_PUBLIC_HOLIDAY MPH
|
||||||
JOIN MU_HOSPITAL
|
JOIN MU_HOSPITAL MH
|
||||||
ON PUBLIC_HOLIDAY_USE_YN='Y'
|
ON MH.MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND MH.PUBLIC_HOLIDAY_USE_YN = 'Y'
|
||||||
WHERE MPH.USE_YN = 'Y'
|
WHERE MPH.USE_YN = 'Y'
|
||||||
AND DATE_FORMAT( MPH.LOC_DATE, '%Y' ) >= DATE_FORMAT( CURDATE( ), '%Y' )
|
AND DATE_FORMAT( MPH.LOC_DATE, '%Y' ) >= DATE_FORMAT( CURDATE( ), '%Y' )
|
||||||
)
|
)
|
||||||
|
UNION ALL
|
||||||
|
(
|
||||||
|
SELECT 'hospitalSchedule' AS "dateType"
|
||||||
|
, CASE WHEN OPEN_YN = 'Y' THEN '운영' ELSE '휴무' END AS "hospitalHolidayName"
|
||||||
|
, DATE_FORMAT(SCHEDULE_DATE, '%Y-%m-%d') AS "locDate"
|
||||||
|
FROM MU_HOSPITAL_SCHEDULE
|
||||||
|
WHERE MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
AND DATE_FORMAT( SCHEDULE_DATE, '%Y' ) >= DATE_FORMAT( CURDATE( ), '%Y' )
|
||||||
|
)
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectHospitalScheduleDetail" parameterType="hashmap" resultType="hashmap">
|
||||||
|
SELECT MU_HOSPITAL_SCHEDULE_ID AS "muHospitalScheduleId"
|
||||||
|
, MU_HOSPITAL_ID AS "muHospitalId"
|
||||||
|
, DATE_FORMAT(SCHEDULE_DATE, '%Y-%m-%d') AS "scheduleDate"
|
||||||
|
, OPEN_YN AS "openYn"
|
||||||
|
, OPEN_START_TIME AS "openStartTime"
|
||||||
|
, OPEN_END_TIME AS "openEndTime"
|
||||||
|
, BREAK_START_TIME AS "breakStartTime"
|
||||||
|
, BREAK_END_TIME AS "breakEndTime"
|
||||||
|
FROM MU_HOSPITAL_SCHEDULE
|
||||||
|
WHERE MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND SCHEDULE_DATE = #{searchDate}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
LIMIT 1
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectHospitalScheduleCheck" parameterType="hashmap" resultType="hashmap">
|
||||||
|
SELECT MU_HOSPITAL_SCHEDULE_ID AS "muHospitalScheduleId"
|
||||||
|
FROM MU_HOSPITAL_SCHEDULE
|
||||||
|
WHERE MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND SCHEDULE_DATE = #{scheduleDate}
|
||||||
|
LIMIT 1
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectHospitalHolidayCheck" parameterType="hashmap" resultType="hashmap">
|
||||||
|
SELECT 1 AS "isHoliday"
|
||||||
|
FROM DUAL
|
||||||
|
WHERE EXISTS (
|
||||||
|
SELECT 1
|
||||||
|
FROM MU_HOSPITAL_HOLIDAY
|
||||||
|
WHERE MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
AND (
|
||||||
|
(REPEAT_YN = 'Y' AND DATE_FORMAT(LOC_DATE, '%m-%d') = DATE_FORMAT(#{searchDate}, '%m-%d'))
|
||||||
|
OR
|
||||||
|
(REPEAT_YN = 'N' AND LOC_DATE = #{searchDate})
|
||||||
|
)
|
||||||
|
) OR EXISTS (
|
||||||
|
SELECT 1
|
||||||
|
FROM MU_PUBLIC_HOLIDAY MPH
|
||||||
|
JOIN MU_HOSPITAL MH
|
||||||
|
ON MH.MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
|
AND MH.PUBLIC_HOLIDAY_USE_YN = 'Y'
|
||||||
|
WHERE MPH.USE_YN = 'Y'
|
||||||
|
AND MPH.LOC_DATE = #{searchDate}
|
||||||
|
)
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertHospitalSchedule" parameterType="hashmap">
|
||||||
|
INSERT INTO MU_HOSPITAL_SCHEDULE (
|
||||||
|
MU_HOSPITAL_SCHEDULE_ID, MU_HOSPITAL_ID, SCHEDULE_DATE, OPEN_YN,
|
||||||
|
OPEN_START_TIME, OPEN_END_TIME, BREAK_START_TIME, BREAK_END_TIME,
|
||||||
|
WRITE_DATE, WRITE_TIME, CUD_FLAG, USE_YN, REG_ID, MOD_ID,
|
||||||
|
REG_DATE, MOD_DATE
|
||||||
|
) VALUES (
|
||||||
|
(SELECT CONCAT('S', DATE_FORMAT(NOw(), '%y%m%d%H%i%s%f'), LPAD(NEXT_NOT_CACHED_VALUE, 9, '0'))
|
||||||
|
FROM MU_HOSPITAL_SCHEDULE_SEQ),
|
||||||
|
#{muHospitalId}, #{scheduleDate}, #{openYn},
|
||||||
|
#{openStartTime}, #{openEndTime}, #{breakStartTime}, #{breakEndTime},
|
||||||
|
CURDATE(), CURTIME(), 'C', 'Y', #{regId}, #{modId},
|
||||||
|
NOW(),NOW()
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateHospitalSchedule" parameterType="hashmap">
|
||||||
|
UPDATE MU_HOSPITAL_SCHEDULE
|
||||||
|
SET OPEN_YN = #{openYn},
|
||||||
|
OPEN_START_TIME = #{openStartTime},
|
||||||
|
OPEN_END_TIME = #{openEndTime},
|
||||||
|
BREAK_START_TIME = #{breakStartTime},
|
||||||
|
BREAK_END_TIME = #{breakEndTime},
|
||||||
|
USE_YN = 'Y',
|
||||||
|
MOD_ID = #{modId},
|
||||||
|
MOD_DATE = NOW(),
|
||||||
|
CUD_FLAG = 'U'
|
||||||
|
WHERE MU_HOSPITAL_SCHEDULE_ID = #{muHospitalScheduleId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteHospitalSchedule" parameterType="hashmap">
|
||||||
|
UPDATE MU_HOSPITAL_SCHEDULE
|
||||||
|
SET USE_YN = 'N',
|
||||||
|
CUD_FLAG = 'D',
|
||||||
|
MOD_ID = #{modId},
|
||||||
|
MOD_DATE = NOW()
|
||||||
|
WHERE MU_HOSPITAL_SCHEDULE_ID = #{muHospitalScheduleId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
<update id="updateHospital" parameterType="hashmap">
|
<update id="updateHospital" parameterType="hashmap">
|
||||||
UPDATE MU_HOSPITAL
|
UPDATE MU_HOSPITAL
|
||||||
SET MOD_ID = #{modId}
|
SET MOD_ID = #{modId}
|
||||||
@@ -255,4 +395,5 @@
|
|||||||
WHERE USE_YN = 'Y'
|
WHERE USE_YN = 'Y'
|
||||||
AND MU_HOSPITAL_ID = #{muHospitalId}
|
AND MU_HOSPITAL_ID = #{muHospitalId}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -9,10 +9,7 @@
|
|||||||
<if test="webMainBannerSearchType != null and webMainBannerSearchType != ''">
|
<if test="webMainBannerSearchType != null and webMainBannerSearchType != ''">
|
||||||
AND MWMB.BANNER_TYPE = #{webMainBannerSearchType}
|
AND MWMB.BANNER_TYPE = #{webMainBannerSearchType}
|
||||||
</if>
|
</if>
|
||||||
<if test="webMainBannerSearchStartDate != null and webMainBannerSearchStartDate != '' and webMainBannerSearchEndDate != null and webMainBannerSearchEndDate != ''">
|
|
||||||
AND DATE_FORMAT(MWMB.WRITE_DATE, '%Y-%m-%d') >= #{webMainBannerSearchStartDate}
|
|
||||||
AND DATE_FORMAT(MWMB.WRITE_DATE, '%Y-%m-%d') <= #{webMainBannerSearchEndDate}
|
|
||||||
</if>
|
|
||||||
<if test="webMainBannerSearchKeywordParam != null and webMainBannerSearchKeywordParam != ''">
|
<if test="webMainBannerSearchKeywordParam != null and webMainBannerSearchKeywordParam != ''">
|
||||||
AND MWMB.TITLE LIKE CONCAT('%',TRIM(#{webMainBannerSearchKeywordParam}),'%')
|
AND MWMB.TITLE LIKE CONCAT('%',TRIM(#{webMainBannerSearchKeywordParam}),'%')
|
||||||
</if>
|
</if>
|
||||||
@@ -57,10 +54,7 @@
|
|||||||
<if test="webMainBannerSearchType != null and webMainBannerSearchType != ''">
|
<if test="webMainBannerSearchType != null and webMainBannerSearchType != ''">
|
||||||
AND MWMB.BANNER_TYPE = #{webMainBannerSearchType}
|
AND MWMB.BANNER_TYPE = #{webMainBannerSearchType}
|
||||||
</if>
|
</if>
|
||||||
<if test="webMainBannerSearchStartDate != null and webMainBannerSearchStartDate != '' and webMainBannerSearchEndDate != null and webMainBannerSearchEndDate != ''">
|
|
||||||
AND DATE_FORMAT(MWMB.WRITE_DATE, '%Y-%m-%d') >= #{webMainBannerSearchStartDate}
|
|
||||||
AND DATE_FORMAT(MWMB.WRITE_DATE, '%Y-%m-%d') <= #{webMainBannerSearchEndDate}
|
|
||||||
</if>
|
|
||||||
<if test="webMainBannerSearchKeywordParam != null and webMainBannerSearchKeywordParam != ''">
|
<if test="webMainBannerSearchKeywordParam != null and webMainBannerSearchKeywordParam != ''">
|
||||||
AND MWMB.TITLE LIKE CONCAT('%',TRIM(#{webMainBannerSearchKeywordParam}),'%')
|
AND MWMB.TITLE LIKE CONCAT('%',TRIM(#{webMainBannerSearchKeywordParam}),'%')
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
@@ -332,7 +332,7 @@
|
|||||||
,MTP.MU_TREATMENT_PROCEDURE_ID AS "treatmentProcedureId"
|
,MTP.MU_TREATMENT_PROCEDURE_ID AS "treatmentProcedureId"
|
||||||
,MTP.MU_TREATMENT_ID AS "treatmentId"
|
,MTP.MU_TREATMENT_ID AS "treatmentId"
|
||||||
,MTP.TREATMENT_PROCEDURE_NAME AS "treatmentNm"
|
,MTP.TREATMENT_PROCEDURE_NAME AS "treatmentNm"
|
||||||
,MTPP.PRICE AS "price"
|
,(MTPP.PRICE + MTPP.VAT) AS "price"
|
||||||
,IFNULL(MTPP.DISCOUNT_PRICE, 0) AS "discountPrice"
|
,IFNULL(MTPP.DISCOUNT_PRICE, 0) AS "discountPrice"
|
||||||
FROM MU_TREATMENT_PROCEDURE AS MTP
|
FROM MU_TREATMENT_PROCEDURE AS MTP
|
||||||
LEFT OUTER JOIN MU_TREATMENT_PROCEDURE_PRICE MTPP ON MTP.MU_TREATMENT_PROCEDURE_ID = MTPP.MU_TREATMENT_PROCEDURE_ID
|
LEFT OUTER JOIN MU_TREATMENT_PROCEDURE_PRICE MTPP ON MTP.MU_TREATMENT_PROCEDURE_ID = MTPP.MU_TREATMENT_PROCEDURE_ID
|
||||||
|
|||||||
319
src/main/resources/mappers/crm/callLog/CallLogSql.xml
Normal file
319
src/main/resources/mappers/crm/callLog/CallLogSql.xml
Normal file
@@ -0,0 +1,319 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.madeu.crm.callLog.map.CallLogMAP">
|
||||||
|
|
||||||
|
<!-- 통화 로그 목록 건수 조회 -->
|
||||||
|
<select id="getCallLogCnt" parameterType="com.madeu.crm.callLog.dto.CallLogSearchDTO" resultType="Integer">
|
||||||
|
/** CallLogMAP.getCallLogCnt **/
|
||||||
|
SELECT COUNT(*) AS TOTAL_COUNT
|
||||||
|
FROM MU_CTI_LOG A
|
||||||
|
WHERE A.USE_YN = 'Y'
|
||||||
|
AND A.FULLDNIS = #{fulldnis}
|
||||||
|
AND A.REG_DATE >= CONCAT(#{sDate}, ' 00:00:00')
|
||||||
|
AND A.REG_DATE <= CONCAT(#{eDate}, ' 23:59:59')
|
||||||
|
<if test="callType != null and callType != '' and callType != 'callback'">
|
||||||
|
AND A.MENU_NO = #{callType}
|
||||||
|
AND A.STATE_TYPE IN ('start', 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType == 'callback'">
|
||||||
|
AND A.STATE_TYPE = 'callback'
|
||||||
|
</if>
|
||||||
|
<if test="callType == null or callType == ''">
|
||||||
|
AND (A.STATE_TYPE = 'start' OR A.STATE_TYPE = 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType1 != null and callType1 != ''">
|
||||||
|
AND A.C_TYPE1 = #{callType1}
|
||||||
|
</if>
|
||||||
|
<if test="callType2 != null and callType2 != ''">
|
||||||
|
AND A.C_TYPE2 = #{callType2}
|
||||||
|
</if>
|
||||||
|
<if test="mCid != null and mCid != ''">
|
||||||
|
AND A.CID LIKE CONCAT('%', #{mCid}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="incallSel != null and incallSel != ''">
|
||||||
|
AND A.INCALL_SEL LIKE CONCAT('%|=|', #{incallSel}, '|=|%')
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 통화 로그 통계 집계 -->
|
||||||
|
<select id="getCallLogStats" parameterType="com.madeu.crm.callLog.dto.CallLogSearchDTO" resultType="com.madeu.crm.callLog.dto.CallLogStatsDTO">
|
||||||
|
/** CallLogMAP.getCallLogStats **/
|
||||||
|
SELECT COUNT(*) AS "totalCnt"
|
||||||
|
,SUM(IF(A.BOUND = 'IN', 1, 0)) AS "inCnt"
|
||||||
|
,SUM(IF(A.BOUND = 'OUT', 1, 0)) AS "outCnt"
|
||||||
|
,SUM(IF(A.C_TYPE1 = '초진', 1, 0)) AS "type1Cnt"
|
||||||
|
,SUM(IF(A.C_TYPE1 = '재진', 1, 0)) AS "type2Cnt"
|
||||||
|
,SUM(IF(A.C_TYPE2 = '상담', 1, 0)) AS "type11Cnt"
|
||||||
|
,SUM(IF(A.C_TYPE2 = '상담후예약', 1, 0)) AS "type12Cnt"
|
||||||
|
,SUM(IF(A.C_TYPE2 = '회차예약', 1, 0)) AS "type13Cnt"
|
||||||
|
FROM MU_CTI_LOG A
|
||||||
|
WHERE A.USE_YN = 'Y'
|
||||||
|
AND A.FULLDNIS = #{fulldnis}
|
||||||
|
AND A.REG_DATE >= CONCAT(#{sDate}, ' 00:00:00')
|
||||||
|
AND A.REG_DATE <= CONCAT(#{eDate}, ' 23:59:59')
|
||||||
|
<if test="callType != null and callType != '' and callType != 'callback'">
|
||||||
|
AND A.MENU_NO = #{callType}
|
||||||
|
AND A.STATE_TYPE IN ('start', 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType == 'callback'">
|
||||||
|
AND A.STATE_TYPE = 'callback'
|
||||||
|
</if>
|
||||||
|
<if test="callType == null or callType == ''">
|
||||||
|
AND (A.STATE_TYPE = 'start' OR A.STATE_TYPE = 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType1 != null and callType1 != ''">
|
||||||
|
AND A.C_TYPE1 = #{callType1}
|
||||||
|
</if>
|
||||||
|
<if test="callType2 != null and callType2 != ''">
|
||||||
|
AND A.C_TYPE2 = #{callType2}
|
||||||
|
</if>
|
||||||
|
<if test="mCid != null and mCid != ''">
|
||||||
|
AND A.CID LIKE CONCAT('%', #{mCid}, '%')
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 통화 연결 건수 (통계용) -->
|
||||||
|
<select id="getCallLogLinkedStats" parameterType="com.madeu.crm.callLog.dto.CallLogSearchDTO" resultType="hashmap">
|
||||||
|
/** CallLogMAP.getCallLogLinkedStats **/
|
||||||
|
SELECT COUNT(*) AS "totalOkCnt"
|
||||||
|
,SUM(IF(A.BOUND = 'IN', 1, 0)) AS "inOkCnt"
|
||||||
|
,SUM(IF(A.BOUND = 'OUT', 1, 0)) AS "outOkCnt"
|
||||||
|
FROM MU_CTI_LOG A
|
||||||
|
WHERE A.USE_YN = 'Y'
|
||||||
|
AND A.FULLDNIS = #{fulldnis}
|
||||||
|
AND A.REG_DATE >= CONCAT(#{sDate}, ' 00:00:00')
|
||||||
|
AND A.REG_DATE <= CONCAT(#{eDate}, ' 23:59:59')
|
||||||
|
AND A.STATE_TYPE = 'link'
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 통화 로그 목록 조회 -->
|
||||||
|
<select id="getCallLogList" parameterType="com.madeu.crm.callLog.dto.CallLogSearchDTO" resultType="com.madeu.crm.callLog.dto.CallLogDTO">
|
||||||
|
/** CallLogMAP.getCallLogList **/
|
||||||
|
SELECT L.*
|
||||||
|
FROM (
|
||||||
|
SELECT L.*
|
||||||
|
,CAST(@RNUM:=@RNUM + 1 AS CHAR) AS "rowNum"
|
||||||
|
FROM (
|
||||||
|
SELECT A.MU_CTI_LOG_ID AS "muCtiLogId"
|
||||||
|
,A.RECORD_NO AS "recordNo"
|
||||||
|
,A.CID AS "cid"
|
||||||
|
,A.BOUND AS "bound"
|
||||||
|
,A.MENU_NO AS "menuNo"
|
||||||
|
,A.STATE_TYPE AS "stateType"
|
||||||
|
,A.C_TYPE1 AS "cType1"
|
||||||
|
,A.C_TYPE2 AS "cType2"
|
||||||
|
,A.CRM_MB_PID AS "crmMbPid"
|
||||||
|
,A.STORE_PID AS "storePid"
|
||||||
|
,A.INCALL_SEL AS "incallSel"
|
||||||
|
,A.CALL_BACK_CHK AS "callBackChk"
|
||||||
|
,DATE_FORMAT(A.REG_DATE, '%Y-%m-%d %H:%i:%s') AS "regDate"
|
||||||
|
/* ring - ARS 메뉴 선택 */
|
||||||
|
,(SELECT B.MENU_NO
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '2'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "ring"
|
||||||
|
/* 통화 연결 시각 */
|
||||||
|
,(SELECT DATE_FORMAT(B.REG_DATE, '%Y-%m-%d %H:%i:%s')
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '3'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "linkDate"
|
||||||
|
/* 통화 연결 상담원 */
|
||||||
|
,(SELECT B.LOGINCID
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '3'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "linkCid"
|
||||||
|
/* 통화 종료 시각 (step 4) */
|
||||||
|
,(SELECT DATE_FORMAT(B.REG_DATE, '%Y-%m-%d %H:%i:%s')
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '4'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "linkEndDate"
|
||||||
|
/* 통화 종료 시각 (step 5) */
|
||||||
|
,(SELECT DATE_FORMAT(B.REG_DATE, '%Y-%m-%d %H:%i:%s')
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '5'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "bendDate"
|
||||||
|
/* callback CID */
|
||||||
|
,(SELECT B.CID
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.CTI_STEP = '98'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "callbackCid"
|
||||||
|
/* SMS 전송 여부 */
|
||||||
|
,(SELECT B.STATE_TYPE
|
||||||
|
FROM MU_CTI_LOG B
|
||||||
|
WHERE B.RECORD_NO = A.RECORD_NO
|
||||||
|
AND B.STATE_TYPE = 'lms'
|
||||||
|
AND B.USE_YN = 'Y'
|
||||||
|
ORDER BY B.REG_DATE DESC LIMIT 1) AS "smsFlag"
|
||||||
|
/* 통화 메모 */
|
||||||
|
,(SELECT T.CALL_MSG
|
||||||
|
FROM MU_CTI_TEXT T
|
||||||
|
WHERE T.RECORD_NO = A.RECORD_NO
|
||||||
|
AND T.USE_YN = 'Y'
|
||||||
|
ORDER BY T.REG_DATE DESC LIMIT 1) AS "callMsg"
|
||||||
|
/* 고객명 */
|
||||||
|
,(SELECT MM.NAME
|
||||||
|
FROM MU_MEMBER MM
|
||||||
|
WHERE MM.MU_MEMBER_ID = A.CRM_MB_PID
|
||||||
|
AND MM.USE_YN = 'Y'
|
||||||
|
LIMIT 1) AS "memberName"
|
||||||
|
FROM MU_CTI_LOG A
|
||||||
|
WHERE A.USE_YN = 'Y'
|
||||||
|
AND A.FULLDNIS = #{fulldnis}
|
||||||
|
AND A.REG_DATE >= CONCAT(#{sDate}, ' 00:00:00')
|
||||||
|
AND A.REG_DATE <= CONCAT(#{eDate}, ' 23:59:59')
|
||||||
|
<if test="callType != null and callType != '' and callType != 'callback'">
|
||||||
|
AND A.MENU_NO = #{callType}
|
||||||
|
AND A.STATE_TYPE IN ('start', 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType == 'callback'">
|
||||||
|
AND A.STATE_TYPE = 'callback'
|
||||||
|
</if>
|
||||||
|
<if test="callType == null or callType == ''">
|
||||||
|
AND (A.STATE_TYPE = 'start' OR A.STATE_TYPE = 'ringout')
|
||||||
|
</if>
|
||||||
|
<if test="callType1 != null and callType1 != ''">
|
||||||
|
AND A.C_TYPE1 = #{callType1}
|
||||||
|
</if>
|
||||||
|
<if test="callType2 != null and callType2 != ''">
|
||||||
|
AND A.C_TYPE2 = #{callType2}
|
||||||
|
</if>
|
||||||
|
<if test="mCid != null and mCid != ''">
|
||||||
|
AND A.CID LIKE CONCAT('%', #{mCid}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="incallSel != null and incallSel != ''">
|
||||||
|
AND A.INCALL_SEL LIKE CONCAT('%|=|', #{incallSel}, '|=|%')
|
||||||
|
</if>
|
||||||
|
ORDER BY A.REG_DATE DESC
|
||||||
|
LIMIT 18446744073709551615
|
||||||
|
) L, (SELECT @RNUM:=0) R
|
||||||
|
WHERE 1 = 1
|
||||||
|
) L
|
||||||
|
WHERE 1 = 1
|
||||||
|
<if test="gridLimitEnd != null and gridLimitEnd != ''">
|
||||||
|
LIMIT ${gridLimitStart}, ${gridLimitEnd}
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 통화 메모 존재 여부 -->
|
||||||
|
<select id="getCallMemoCnt" parameterType="com.madeu.crm.callLog.dto.CallMemoDTO" resultType="Integer">
|
||||||
|
/** CallLogMAP.getCallMemoCnt **/
|
||||||
|
SELECT COUNT(*)
|
||||||
|
FROM MU_CTI_TEXT
|
||||||
|
WHERE RECORD_NO = #{recordNo}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 통화 메모 신규 저장 -->
|
||||||
|
<insert id="saveCallMemo" parameterType="com.madeu.crm.callLog.dto.CallMemoDTO">
|
||||||
|
<selectKey resultType="string" keyProperty="muCtiTextId" order="BEFORE">
|
||||||
|
SELECT CONCAT('CTXT', LPAD(IFNULL(MAX(CAST(SUBSTRING(MU_CTI_TEXT_ID, 5) AS UNSIGNED)), 0) + 1, 11, '0'))
|
||||||
|
FROM MU_CTI_TEXT
|
||||||
|
</selectKey>
|
||||||
|
/** CallLogMAP.saveCallMemo **/
|
||||||
|
INSERT INTO MU_CTI_TEXT (
|
||||||
|
MU_CTI_TEXT_ID
|
||||||
|
,RECORD_NO
|
||||||
|
,CALL_MSG
|
||||||
|
,USE_YN
|
||||||
|
,CUD_FLAG
|
||||||
|
,REG_ID
|
||||||
|
,REG_DATE
|
||||||
|
,MOD_ID
|
||||||
|
,MOD_DATE
|
||||||
|
) VALUES (
|
||||||
|
#{muCtiTextId}
|
||||||
|
,#{recordNo}
|
||||||
|
,#{callMsg}
|
||||||
|
,'Y'
|
||||||
|
,'C'
|
||||||
|
,#{loginMemberId}
|
||||||
|
,NOW()
|
||||||
|
,#{loginMemberId}
|
||||||
|
,NOW()
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<!-- 통화 메모 수정 -->
|
||||||
|
<update id="modCallMemo" parameterType="com.madeu.crm.callLog.dto.CallMemoDTO">
|
||||||
|
/** CallLogMAP.modCallMemo **/
|
||||||
|
UPDATE MU_CTI_TEXT
|
||||||
|
SET CALL_MSG = #{callMsg}
|
||||||
|
,CUD_FLAG = 'U'
|
||||||
|
,MOD_ID = #{loginMemberId}
|
||||||
|
,MOD_DATE = NOW()
|
||||||
|
WHERE RECORD_NO = #{recordNo}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<!-- CTI 로그 저장 (Webhook용) -->
|
||||||
|
<insert id="putCtiLog" parameterType="com.madeu.crm.callLog.dto.CallLogDTO">
|
||||||
|
<selectKey resultType="string" keyProperty="muCtiLogId" order="BEFORE">
|
||||||
|
SELECT CONCAT('CLOG', LPAD(IFNULL(MAX(CAST(SUBSTRING(MU_CTI_LOG_ID, 5) AS UNSIGNED)), 0) + 1, 11, '0'))
|
||||||
|
FROM MU_CTI_LOG
|
||||||
|
</selectKey>
|
||||||
|
/** CallLogMAP.putCtiLog **/
|
||||||
|
INSERT INTO MU_CTI_LOG (
|
||||||
|
MU_CTI_LOG_ID
|
||||||
|
,RECORD_NO
|
||||||
|
,CID
|
||||||
|
,FULLDNIS
|
||||||
|
,BOUND
|
||||||
|
,MENU_NO
|
||||||
|
,STATE_TYPE
|
||||||
|
,CTI_STEP
|
||||||
|
,LOGINCID
|
||||||
|
,C_TYPE1
|
||||||
|
,C_TYPE2
|
||||||
|
,CRM_MB_PID
|
||||||
|
,STORE_PID
|
||||||
|
,INCALL_SEL
|
||||||
|
,USE_YN
|
||||||
|
,CUD_FLAG
|
||||||
|
,REG_DATE
|
||||||
|
,MOD_DATE
|
||||||
|
) VALUES (
|
||||||
|
#{muCtiLogId}
|
||||||
|
,#{recordNo}
|
||||||
|
,#{cid}
|
||||||
|
,#{fulldnis}
|
||||||
|
,#{bound}
|
||||||
|
,#{menuNo}
|
||||||
|
,#{stateType}
|
||||||
|
,#{ctiStep}
|
||||||
|
,#{logincid}
|
||||||
|
,#{cType1}
|
||||||
|
,#{cType2}
|
||||||
|
,#{crmMbPid}
|
||||||
|
,#{storePid}
|
||||||
|
,#{incallSel}
|
||||||
|
,'Y'
|
||||||
|
,'C'
|
||||||
|
,NOW()
|
||||||
|
,NOW()
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<!-- CTI 로그 회원 매핑 업데이트 -->
|
||||||
|
<update id="modCtiLogMember" parameterType="hashmap">
|
||||||
|
/** CallLogMAP.modCtiLogMember **/
|
||||||
|
UPDATE MU_CTI_LOG
|
||||||
|
SET STORE_PID = #{storePid}
|
||||||
|
,CRM_MB_PID = #{crmMbPid}
|
||||||
|
,MOD_DATE = NOW()
|
||||||
|
WHERE RECORD_NO = #{recordNo}
|
||||||
|
AND USE_YN = 'Y'
|
||||||
|
</update>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -12,15 +12,12 @@
|
|||||||
AND HC.CATEGORY_NO = HCB.CATEGORY_NO
|
AND HC.CATEGORY_NO = HCB.CATEGORY_NO
|
||||||
AND HCB.USE_YN = 'Y'
|
AND HCB.USE_YN = 'Y'
|
||||||
AND HCB.CATEGORY_DIV_CD = #{categoryDivCd}
|
AND HCB.CATEGORY_DIV_CD = #{categoryDivCd}
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(categoryNm)">
|
<if test="@org.springframework.util.StringUtils@hasLength(searchCategoryNo)">
|
||||||
AND HCB.CATEGORY_NM LIKE CONCAT('%', #{categoryNm}, '%')
|
AND HC.CATEGORY_NO = #{searchCategoryNo}
|
||||||
</if>
|
</if>
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(title)">
|
<if test="@org.springframework.util.StringUtils@hasLength(title)">
|
||||||
AND HCB.TITLE LIKE CONCAT('%', #{title}, '%')
|
AND HCB.TITLE LIKE CONCAT('%', #{title}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(regNm)">
|
|
||||||
AND MM.NAME = #{regNm}
|
|
||||||
</if>
|
|
||||||
) total
|
) total
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
@@ -38,8 +35,11 @@
|
|||||||
,HC.CATEGORY_NO
|
,HC.CATEGORY_NO
|
||||||
,HCB.THUMBNAIL_BOTTOM_TXT
|
,HCB.THUMBNAIL_BOTTOM_TXT
|
||||||
,HCB.HASHTAG
|
,HCB.HASHTAG
|
||||||
|
,HCB.ORD_NO
|
||||||
,DATE_FORMAT(HCB.REG_DATE, '%Y-%m-%d') as REG_DT
|
,DATE_FORMAT(HCB.REG_DATE, '%Y-%m-%d') as REG_DT
|
||||||
,MM.NAME as REG_NM
|
,MM.NAME as REG_NM
|
||||||
|
,DATE_FORMAT(HCB.EVENT_START_DT, '%Y-%m-%d') as START_DT
|
||||||
|
,DATE_FORMAT(HCB.EVENT_END_DT, '%Y-%m-%d') as END_DT
|
||||||
FROM HP_CATEGORY HC,
|
FROM HP_CATEGORY HC,
|
||||||
HP_CONTENTS_BBS HCB,
|
HP_CONTENTS_BBS HCB,
|
||||||
(SELECT * FROM MU_MEMBER WHERE USE_YN = 'Y') MM
|
(SELECT * FROM MU_MEMBER WHERE USE_YN = 'Y') MM
|
||||||
@@ -49,21 +49,18 @@
|
|||||||
AND HCB.USE_YN = 'Y'
|
AND HCB.USE_YN = 'Y'
|
||||||
AND HC.USE_YN = 'Y'
|
AND HC.USE_YN = 'Y'
|
||||||
AND HCB.CATEGORY_DIV_CD = #{categoryDivCd}
|
AND HCB.CATEGORY_DIV_CD = #{categoryDivCd}
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(categoryNm)">
|
<if test="@org.springframework.util.StringUtils@hasLength(searchCategoryNo)">
|
||||||
AND HCB.CATEGORY_NM LIKE CONCAT('%', #{categoryNm}, '%')
|
AND HC.CATEGORY_NO = #{searchCategoryNo}
|
||||||
</if>
|
</if>
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(title)">
|
<if test="@org.springframework.util.StringUtils@hasLength(title)">
|
||||||
AND HCB.TITLE LIKE CONCAT('%', #{title}, '%')
|
AND HCB.TITLE LIKE CONCAT('%', #{title}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(regNm)">
|
|
||||||
AND MM.NAME = #{regNm}
|
|
||||||
</if>
|
|
||||||
<choose>
|
<choose>
|
||||||
<when test="@org.springframework.util.StringUtils@hasLength(webTreatmentPetitSort)">
|
<when test="@org.springframework.util.StringUtils@hasLength(webTreatmentPetitSort)">
|
||||||
ORDER BY ${webTreatmentPetitSort}
|
ORDER BY ${webTreatmentPetitSort}
|
||||||
</when>
|
</when>
|
||||||
<otherwise>
|
<otherwise>
|
||||||
ORDER BY CATEGORY_NO, POST_NO ASC
|
ORDER BY HCB.ORD_NO DESC
|
||||||
</otherwise>
|
</otherwise>
|
||||||
</choose>
|
</choose>
|
||||||
LIMIT 18446744073709551615
|
LIMIT 18446744073709551615
|
||||||
@@ -86,6 +83,8 @@
|
|||||||
,HAF.FILE_PATH as CONTENT_IMG_PATH
|
,HAF.FILE_PATH as CONTENT_IMG_PATH
|
||||||
,HCB.OLD_CRM_ITEM_ID
|
,HCB.OLD_CRM_ITEM_ID
|
||||||
,HCB.ORD_NO
|
,HCB.ORD_NO
|
||||||
|
,DATE_FORMAT(HCB.EVENT_START_DT, '%Y-%m-%d') as START_DT
|
||||||
|
,DATE_FORMAT(HCB.EVENT_END_DT, '%Y-%m-%d') as END_DT
|
||||||
FROM HP_CONTENTS_BBS AS HCB
|
FROM HP_CONTENTS_BBS AS HCB
|
||||||
LEFT OUTER JOIN HP_ATTACH_FILE HAF ON HAF.ATTACHFILE_ID = HCB.CONTENTS_ATTACHFILE_ID
|
LEFT OUTER JOIN HP_ATTACH_FILE HAF ON HAF.ATTACHFILE_ID = HCB.CONTENTS_ATTACHFILE_ID
|
||||||
LEFT OUTER JOIN HP_ATTACH_FILE HAF2 ON HAF2.ATTACHFILE_ID = HCB.THUMBNAIL_ATTACHFILE_ID
|
LEFT OUTER JOIN HP_ATTACH_FILE HAF2 ON HAF2.ATTACHFILE_ID = HCB.THUMBNAIL_ATTACHFILE_ID
|
||||||
@@ -103,7 +102,7 @@
|
|||||||
,HCBP.MU_TREATMENT_ID
|
,HCBP.MU_TREATMENT_ID
|
||||||
,HCBP.MU_TREATMENT_PROCEDURE_ID
|
,HCBP.MU_TREATMENT_PROCEDURE_ID
|
||||||
,MTP.TREATMENT_PROCEDURE_NAME
|
,MTP.TREATMENT_PROCEDURE_NAME
|
||||||
,MTPP.PRICE
|
,MTPP.PRICE + MTPP.VAT as PRICE
|
||||||
,IFNULL(MTPP.DISCOUNT_PRICE, 0) as DISCOUNT_PRICE
|
,IFNULL(MTPP.DISCOUNT_PRICE, 0) as DISCOUNT_PRICE
|
||||||
FROM HP_CONTENTS_BBS_PROCEDURE AS HCBP
|
FROM HP_CONTENTS_BBS_PROCEDURE AS HCBP
|
||||||
LEFT OUTER JOIN MU_TREATMENT_PROCEDURE MTP ON HCBP.MU_TREATMENT_ID = MTP.MU_TREATMENT_ID AND HCBP.MU_TREATMENT_PROCEDURE_ID = MTP.MU_TREATMENT_PROCEDURE_ID
|
LEFT OUTER JOIN MU_TREATMENT_PROCEDURE MTP ON HCBP.MU_TREATMENT_ID = MTP.MU_TREATMENT_ID AND HCBP.MU_TREATMENT_PROCEDURE_ID = MTP.MU_TREATMENT_PROCEDURE_ID
|
||||||
@@ -141,6 +140,8 @@
|
|||||||
,MOD_DATE
|
,MOD_DATE
|
||||||
,OLD_CRM_ITEM_ID
|
,OLD_CRM_ITEM_ID
|
||||||
,ORD_NO
|
,ORD_NO
|
||||||
|
,EVENT_START_DT
|
||||||
|
,EVENT_END_DT
|
||||||
)VALUES(
|
)VALUES(
|
||||||
#{categoryDivCd}
|
#{categoryDivCd}
|
||||||
,#{categoryNo}
|
,#{categoryNo}
|
||||||
@@ -160,6 +161,8 @@
|
|||||||
,(SELECT MAX(ORD_NO) + 1
|
,(SELECT MAX(ORD_NO) + 1
|
||||||
FROM HP_CONTENTS_BBS as TEMP
|
FROM HP_CONTENTS_BBS as TEMP
|
||||||
WHERE CATEGORY_DIV_CD = #{categoryDivCd} AND CATEGORY_NO = #{categoryNo})
|
WHERE CATEGORY_DIV_CD = #{categoryDivCd} AND CATEGORY_NO = #{categoryNo})
|
||||||
|
,NULLIF(#{eventStartDt}, '')
|
||||||
|
,NULLIF(#{eventEndDt}, '')
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@@ -264,6 +267,8 @@
|
|||||||
,CONTENT = #{content}
|
,CONTENT = #{content}
|
||||||
,THUMBNAIL_BOTTOM_TXT = #{thumbnailBottomTxt}
|
,THUMBNAIL_BOTTOM_TXT = #{thumbnailBottomTxt}
|
||||||
,HASHTAG = #{hashtag}
|
,HASHTAG = #{hashtag}
|
||||||
|
,EVENT_START_DT = NULLIF(#{eventStartDt}, '')
|
||||||
|
,EVENT_END_DT = NULLIF(#{eventEndDt}, '')
|
||||||
<if test="@org.springframework.util.StringUtils@hasLength(thumbnailAttachfileId)">
|
<if test="@org.springframework.util.StringUtils@hasLength(thumbnailAttachfileId)">
|
||||||
,THUMBNAIL_ATTACHFILE_ID = #{thumbnailAttachfileId}
|
,THUMBNAIL_ATTACHFILE_ID = #{thumbnailAttachfileId}
|
||||||
</if>
|
</if>
|
||||||
@@ -305,4 +310,16 @@
|
|||||||
AND HC.CATEGORY_DIV_CD = #{categoryDivCd}
|
AND HC.CATEGORY_DIV_CD = #{categoryDivCd}
|
||||||
ORDER BY HC.CATEGORY_NO ASC
|
ORDER BY HC.CATEGORY_NO ASC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<update id="updateContentsBbsOrdNo" parameterType="hashmap">
|
||||||
|
/** ContentsBbsSql.updateContentsBbsOrdNo **/
|
||||||
|
UPDATE HP_CONTENTS_BBS
|
||||||
|
SET ORD_NO = #{ordNo}
|
||||||
|
,MOD_ID = #{modId}
|
||||||
|
,MOD_DATE = NOW()
|
||||||
|
WHERE USE_YN = 'Y'
|
||||||
|
AND CATEGORY_DIV_CD = #{categoryDivCd}
|
||||||
|
AND CATEGORY_NO = #{categoryNo}
|
||||||
|
AND POST_NO = #{postNo}
|
||||||
|
</update>
|
||||||
</mapper>
|
</mapper>
|
||||||
133
src/main/resources/mappers/crm/smsTemplate/SmsTemplateSql.xml
Normal file
133
src/main/resources/mappers/crm/smsTemplate/SmsTemplateSql.xml
Normal file
@@ -0,0 +1,133 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.madeu.crm.smsTemplate.map.SmsTemplateMAP">
|
||||||
|
|
||||||
|
<!-- 상용구 목록 건수 조회 -->
|
||||||
|
<select id="getSmsTemplateCnt" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateSearchDTO" resultType="Integer">
|
||||||
|
/** SmsTemplateMAP.getSmsTemplateCnt **/
|
||||||
|
SELECT COUNT(*) AS TOTAL_COUNT
|
||||||
|
FROM MU_SMS_TEMPLATE
|
||||||
|
WHERE USE_YN = 'Y'
|
||||||
|
<if test="searchKeyword != null and searchKeyword != ''">
|
||||||
|
AND (TITLE LIKE CONCAT('%', TRIM(#{searchKeyword}), '%')
|
||||||
|
OR CONTENT LIKE CONCAT('%', TRIM(#{searchKeyword}), '%'))
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 상용구 목록 조회 -->
|
||||||
|
<select id="getSmsTemplateList" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateSearchDTO" resultType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO">
|
||||||
|
/** SmsTemplateMAP.getSmsTemplateList **/
|
||||||
|
SELECT ST.*
|
||||||
|
FROM (
|
||||||
|
SELECT ST.*
|
||||||
|
,CAST(@RNUM:=@RNUM + 1 AS CHAR) AS "rowNum"
|
||||||
|
FROM (
|
||||||
|
SELECT ST.MU_SMS_TEMPLATE_ID AS "muSmsTemplateId"
|
||||||
|
,ST.TITLE AS "title"
|
||||||
|
,ST.CONTENT AS "content"
|
||||||
|
,DATE_FORMAT(ST.REG_DATE, '%Y-%m-%d %H:%i') AS "regDate"
|
||||||
|
,DATE_FORMAT(ST.MOD_DATE, '%Y-%m-%d %H:%i') AS "modDate"
|
||||||
|
,(SELECT MM.NAME
|
||||||
|
FROM MU_MEMBER AS MM
|
||||||
|
WHERE MM.USE_YN = 'Y'
|
||||||
|
AND MM.MU_MEMBER_ID = ST.REG_ID
|
||||||
|
LIMIT 0, 1) AS "regName"
|
||||||
|
FROM MU_SMS_TEMPLATE AS ST
|
||||||
|
WHERE ST.USE_YN = 'Y'
|
||||||
|
<if test="searchKeyword != null and searchKeyword != ''">
|
||||||
|
AND (ST.TITLE LIKE CONCAT('%', TRIM(#{searchKeyword}), '%')
|
||||||
|
OR ST.CONTENT LIKE CONCAT('%', TRIM(#{searchKeyword}), '%'))
|
||||||
|
</if>
|
||||||
|
<choose>
|
||||||
|
<when test="gridSort != null and gridSort != ''">
|
||||||
|
ORDER BY ${gridSort}
|
||||||
|
</when>
|
||||||
|
<otherwise>
|
||||||
|
ORDER BY ST.REG_DATE DESC
|
||||||
|
</otherwise>
|
||||||
|
</choose>
|
||||||
|
LIMIT 18446744073709551615
|
||||||
|
) ST, (SELECT @RNUM:=0) R
|
||||||
|
WHERE 1 = 1
|
||||||
|
) ST
|
||||||
|
WHERE 1 = 1
|
||||||
|
<if test="gridLimitEnd != null and gridLimitEnd != ''">
|
||||||
|
LIMIT ${gridLimitStart}, ${gridLimitEnd}
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 상용구 상세 조회 -->
|
||||||
|
<select id="getSmsTemplate" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO" resultType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO">
|
||||||
|
/** SmsTemplateMAP.getSmsTemplate **/
|
||||||
|
SELECT ST.MU_SMS_TEMPLATE_ID AS "muSmsTemplateId"
|
||||||
|
,ST.TITLE AS "title"
|
||||||
|
,ST.CONTENT AS "content"
|
||||||
|
,DATE_FORMAT(ST.REG_DATE, '%Y-%m-%d %H:%i') AS "regDate"
|
||||||
|
,DATE_FORMAT(ST.MOD_DATE, '%Y-%m-%d %H:%i') AS "modDate"
|
||||||
|
,(SELECT MM.NAME
|
||||||
|
FROM MU_MEMBER AS MM
|
||||||
|
WHERE MM.USE_YN = 'Y'
|
||||||
|
AND MM.MU_MEMBER_ID = ST.REG_ID
|
||||||
|
LIMIT 0, 1) AS "regName"
|
||||||
|
FROM MU_SMS_TEMPLATE AS ST
|
||||||
|
WHERE ST.USE_YN = 'Y'
|
||||||
|
AND ST.MU_SMS_TEMPLATE_ID = #{muSmsTemplateId}
|
||||||
|
LIMIT 0, 1
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 상용구 등록 -->
|
||||||
|
<insert id="putSmsTemplate" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO">
|
||||||
|
<selectKey resultType="string" keyProperty="muSmsTemplateId" order="BEFORE">
|
||||||
|
SELECT CONCAT('SMST', LPAD(IFNULL(MAX(CAST(SUBSTRING(MU_SMS_TEMPLATE_ID, 5) AS UNSIGNED)), 0) + 1, 11, '0'))
|
||||||
|
FROM MU_SMS_TEMPLATE
|
||||||
|
</selectKey>
|
||||||
|
/** SmsTemplateMAP.putSmsTemplate **/
|
||||||
|
INSERT INTO MU_SMS_TEMPLATE (
|
||||||
|
MU_SMS_TEMPLATE_ID
|
||||||
|
,TITLE
|
||||||
|
,CONTENT
|
||||||
|
,USE_YN
|
||||||
|
,CUD_FLAG
|
||||||
|
,REG_ID
|
||||||
|
,REG_DATE
|
||||||
|
,MOD_ID
|
||||||
|
,MOD_DATE
|
||||||
|
) VALUES (
|
||||||
|
#{muSmsTemplateId}
|
||||||
|
,#{title}
|
||||||
|
,#{content}
|
||||||
|
,'Y'
|
||||||
|
,'C'
|
||||||
|
,#{loginMemberId}
|
||||||
|
,NOW()
|
||||||
|
,#{loginMemberId}
|
||||||
|
,NOW()
|
||||||
|
)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<!-- 상용구 수정 -->
|
||||||
|
<update id="modSmsTemplate" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO">
|
||||||
|
/** SmsTemplateMAP.modSmsTemplate **/
|
||||||
|
UPDATE MU_SMS_TEMPLATE
|
||||||
|
SET TITLE = #{title}
|
||||||
|
,CONTENT = #{content}
|
||||||
|
,CUD_FLAG = 'U'
|
||||||
|
,MOD_ID = #{loginMemberId}
|
||||||
|
,MOD_DATE = NOW()
|
||||||
|
WHERE USE_YN = 'Y'
|
||||||
|
AND MU_SMS_TEMPLATE_ID = #{muSmsTemplateId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<!-- 상용구 삭제 (논리 삭제) -->
|
||||||
|
<update id="delSmsTemplate" parameterType="com.madeu.crm.smsTemplate.dto.SmsTemplateDTO">
|
||||||
|
/** SmsTemplateMAP.delSmsTemplate **/
|
||||||
|
UPDATE MU_SMS_TEMPLATE
|
||||||
|
SET USE_YN = 'N'
|
||||||
|
,CUD_FLAG = 'D'
|
||||||
|
,MOD_ID = #{loginMemberId}
|
||||||
|
,MOD_DATE = NOW()
|
||||||
|
WHERE USE_YN = 'Y'
|
||||||
|
AND MU_SMS_TEMPLATE_ID = #{muSmsTemplateId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
38
src/main/resources/sql/center_div_migration.sql
Normal file
38
src/main/resources/sql/center_div_migration.sql
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
-- ================================================================
|
||||||
|
-- 센터구분(CENTER_DIV_CD) 컬럼 추가 및 쁘띠센터 행 생성 마이그레이션
|
||||||
|
-- ================================================================
|
||||||
|
|
||||||
|
-- 1. 센터구분 컬럼 추가
|
||||||
|
ALTER TABLE MU_HOSPITAL ADD COLUMN CENTER_DIV_CD VARCHAR(10) DEFAULT 'DIET' COMMENT '센터구분(DIET/PETIT)' AFTER HOSPITAL_NAME;
|
||||||
|
|
||||||
|
-- 2. 기존 행을 다이어트센터로 설정
|
||||||
|
UPDATE MU_HOSPITAL SET CENTER_DIV_CD = 'DIET' WHERE USE_YN = 'Y';
|
||||||
|
|
||||||
|
-- 3. 쁘띠센터 행 생성 (기존 다이어트 운영시간을 복사, 운영시간은 별도 설정 필요)
|
||||||
|
INSERT INTO MU_HOSPITAL (
|
||||||
|
MU_HOSPITAL_ID, HOSPITAL_NAME, CENTER_DIV_CD,
|
||||||
|
MON_OPEN_YN, MON_OPEN_START_TIME, MON_OPEN_END_TIME, MON_BREAK_START_TIME, MON_BREAK_END_TIME,
|
||||||
|
TUE_OPEN_YN, TUE_OPEN_START_TIME, TUE_OPEN_END_TIME, TUE_BREAK_START_TIME, TUE_BREAK_END_TIME,
|
||||||
|
WED_OPEN_YN, WED_OPEN_START_TIME, WED_OPEN_END_TIME, WED_BREAK_START_TIME, WED_BREAK_END_TIME,
|
||||||
|
THU_OPEN_YN, THU_OPEN_START_TIME, THU_OPEN_END_TIME, THU_BREAK_START_TIME, THU_BREAK_END_TIME,
|
||||||
|
FRI_OPEN_YN, FRI_OPEN_START_TIME, FRI_OPEN_END_TIME, FRI_BREAK_START_TIME, FRI_BREAK_END_TIME,
|
||||||
|
SAT_OPEN_YN, SAT_OPEN_START_TIME, SAT_OPEN_END_TIME, SAT_BREAK_START_TIME, SAT_BREAK_END_TIME,
|
||||||
|
SUN_OPEN_YN, SUN_OPEN_START_TIME, SUN_OPEN_END_TIME, SUN_BREAK_START_TIME, SUN_BREAK_END_TIME,
|
||||||
|
PUBLIC_HOLIDAY_USE_YN, MU_MEMBER_ID,
|
||||||
|
WRITE_DATE, WRITE_TIME, CUD_FLAG, USE_YN, REG_ID, REG_DATE, MOD_ID, MOD_DATE
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
CONCAT(LEFT(MU_HOSPITAL_ID, 24), '2'), -- 새 ID 생성
|
||||||
|
HOSPITAL_NAME, 'PETIT',
|
||||||
|
MON_OPEN_YN, MON_OPEN_START_TIME, MON_OPEN_END_TIME, MON_BREAK_START_TIME, MON_BREAK_END_TIME,
|
||||||
|
TUE_OPEN_YN, TUE_OPEN_START_TIME, TUE_OPEN_END_TIME, TUE_BREAK_START_TIME, TUE_BREAK_END_TIME,
|
||||||
|
WED_OPEN_YN, WED_OPEN_START_TIME, WED_OPEN_END_TIME, WED_BREAK_START_TIME, WED_BREAK_END_TIME,
|
||||||
|
THU_OPEN_YN, THU_OPEN_START_TIME, THU_OPEN_END_TIME, THU_BREAK_START_TIME, THU_BREAK_END_TIME,
|
||||||
|
FRI_OPEN_YN, FRI_OPEN_START_TIME, FRI_OPEN_END_TIME, FRI_BREAK_START_TIME, FRI_BREAK_END_TIME,
|
||||||
|
SAT_OPEN_YN, SAT_OPEN_START_TIME, SAT_OPEN_END_TIME, SAT_BREAK_START_TIME, SAT_BREAK_END_TIME,
|
||||||
|
SUN_OPEN_YN, SUN_OPEN_START_TIME, SUN_OPEN_END_TIME, SUN_BREAK_START_TIME, SUN_BREAK_END_TIME,
|
||||||
|
PUBLIC_HOLIDAY_USE_YN, MU_MEMBER_ID,
|
||||||
|
CURDATE(), CURTIME(), 'C', 'Y', 'SYSTEM', NOW(), 'SYSTEM', NOW()
|
||||||
|
FROM MU_HOSPITAL
|
||||||
|
WHERE USE_YN = 'Y' AND CENTER_DIV_CD = 'DIET'
|
||||||
|
LIMIT 1;
|
||||||
36
src/main/resources/sql/hospital_schedule_migration.sql
Normal file
36
src/main/resources/sql/hospital_schedule_migration.sql
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
CREATE TABLE `MU_HOSPITAL_SCHEDULE` (
|
||||||
|
`MU_HOSPITAL_SCHEDULE_ID` varchar(25) NOT NULL COMMENT '병원 스케줄 식별자',
|
||||||
|
`MU_HOSPITAL_ID` varchar(25) NOT NULL COMMENT '병원 식별자',
|
||||||
|
`SCHEDULE_DATE` date NOT NULL COMMENT '스케줄 날짜',
|
||||||
|
`OPEN_YN` char(1) NOT NULL DEFAULT 'Y' COMMENT '운영여부 (Y/N)',
|
||||||
|
`OPEN_START_TIME` varchar(5) DEFAULT NULL COMMENT '운영 시작시간 (HH:mm)',
|
||||||
|
`OPEN_END_TIME` varchar(5) DEFAULT NULL COMMENT '운영 종료시간 (HH:mm)',
|
||||||
|
`BREAK_START_TIME` varchar(5) DEFAULT NULL COMMENT '휴게 시작시간 (HH:mm)',
|
||||||
|
`BREAK_END_TIME` varchar(5) DEFAULT NULL COMMENT '휴게 종료시간 (HH:mm)',
|
||||||
|
`WRITE_DATE` date NOT NULL COMMENT '작성일자',
|
||||||
|
`WRITE_TIME` time NOT NULL COMMENT '작성시간',
|
||||||
|
`REMARK` text DEFAULT NULL COMMENT '비고',
|
||||||
|
`CUD_FLAG` char(1) DEFAULT 'C' COMMENT '작업타입',
|
||||||
|
`USE_YN` char(1) NOT NULL DEFAULT 'Y' COMMENT '사용여부',
|
||||||
|
`REG_ID` varchar(25) NOT NULL COMMENT '등록자',
|
||||||
|
`REG_DATE` timestamp NOT NULL DEFAULT current_timestamp() COMMENT '등록일시',
|
||||||
|
`MOD_ID` varchar(25) NOT NULL COMMENT '수정자',
|
||||||
|
`MOD_DATE` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '수정일시',
|
||||||
|
`T_ID` varchar(13) DEFAULT NULL,
|
||||||
|
`T_DATE` datetime DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`MU_HOSPITAL_SCHEDULE_ID`),
|
||||||
|
UNIQUE KEY `UK_HOSPITAL_DATE` (`MU_HOSPITAL_ID`, `SCHEDULE_DATE`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='병원별 날짜별 운영 스케줄 (예외처리)';
|
||||||
|
|
||||||
|
CREATE TABLE `MU_HOSPITAL_SCHEDULE_SEQ` (
|
||||||
|
`next_not_cached_value` bigint(21) NOT NULL,
|
||||||
|
`minimum_value` bigint(21) NOT NULL,
|
||||||
|
`maximum_value` bigint(21) NOT NULL,
|
||||||
|
`start_value` bigint(21) NOT NULL COMMENT 'start value when sequences is created or value if RESTART is used',
|
||||||
|
`increment` bigint(21) NOT NULL COMMENT 'increment value',
|
||||||
|
`cache_size` bigint(21) unsigned NOT NULL,
|
||||||
|
`cycle_option` tinyint(1) unsigned NOT NULL COMMENT '0 if no cycles are allowed, 1 if the sequence should begin a new cycle when maximum_value is passed',
|
||||||
|
`cycle_count` bigint(21) NOT NULL COMMENT 'How many cycles have been done'
|
||||||
|
) ENGINE=InnoDB SEQUENCE=1;
|
||||||
|
|
||||||
|
INSERT INTO `MU_HOSPITAL_SCHEDULE_SEQ` VALUES (1,1,9999999999,1,1,0,1,0);
|
||||||
@@ -1,37 +1,170 @@
|
|||||||
.project_wrap {width:100%; min-width:1080px; margin:0 auto;}
|
.project_wrap {
|
||||||
|
width: 100%;
|
||||||
|
min-width: 1080px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
/*오른쪽영역*/
|
/*오른쪽영역*/
|
||||||
.project_wrap .content_section {margin-top:50px; width:100%; min-width:1080px; display:table;}
|
.project_wrap .content_section {
|
||||||
.project_wrap .content_section .hospital_wrap {width: calc(100% - 72px); min-width:calc(1080px - 72px); height:calc(100vh - 50px); float:left; position:relative;}
|
margin-top: 50px;
|
||||||
|
width: 100%;
|
||||||
|
min-width: 1080px;
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap {
|
||||||
|
width: calc(100% - 72px);
|
||||||
|
min-width: calc(1080px - 72px);
|
||||||
|
height: calc(100vh - 50px);
|
||||||
|
float: left;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* 왼쪽_메뉴 영역 */
|
/* 왼쪽_메뉴 영역 */
|
||||||
.project_wrap .content_section .hospital_wrap .left_box {position:absolute; width:240px; height:calc(100vh - 50px); overflow:auto; padding:10px 20px;}
|
.project_wrap .content_section .hospital_wrap .left_box {
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list {width:100%;}
|
position: absolute;
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {width:100%; height:auto; margin:20px 0 10px 0; padding:0; font-size:14px; font-weight:700;}
|
width: 240px;
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu.first {margin-top:0;}
|
height: calc(100vh - 50px);
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a {width:100%; height:100%; display:block; margin-bottom:8px; padding:8px; font-size:14px; text-align:left; border-radius:5px;}
|
overflow: auto;
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a.on {background:#3985EA; border:none;}
|
padding: 10px 20px;
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {width:100%; height:36px; margin-bottom:8px;}
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a.on {color:#fff;}
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
margin: 20px 0 10px 0;
|
||||||
|
padding: 0;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu.first {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
padding: 8px;
|
||||||
|
font-size: 14px;
|
||||||
|
text-align: left;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a.on {
|
||||||
|
background: #3985EA;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {
|
||||||
|
width: 100%;
|
||||||
|
height: 36px;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a.on {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
/* 센터쪽 */
|
/* 센터쪽 */
|
||||||
.project_wrap .content_section .hospital_wrap .center_box {width:calc(100% - 240px); height:calc(100vh - 50px); position:absolute; left:240px; padding:10px 10px 10px 0;}
|
.project_wrap .content_section .hospital_wrap .center_box {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_title {min-width:90px; padding-left:10px; font-size:18px; font-weight:700; line-height:50px; float:left;}
|
width: calc(100% - 240px);
|
||||||
.consultation-info input { width:80%; height:36px; padding:0 10px; border:1px solid #E9ECF0; border-radius:5px;}
|
height: calc(100vh - 50px);
|
||||||
.consultation-info input input::placeholder {color:#B5BDC4;}
|
position: absolute;
|
||||||
.consultation-info label {padding-left: 10px;}
|
left: 240px;
|
||||||
.consultation-info input[type="checkbox"] {width: 15px; height:15px; padding:0 10px; border:1px solid #E9ECF0; border-radius:5px;}
|
padding: 10px 10px 10px 0;
|
||||||
.consultation-info input[type="checkbox"] input::placeholder {color:#B5BDC4;}
|
}
|
||||||
.consultation-info select {width:80%; height:36px; padding:0 10px; border:1px solid #E9ECF0; border-radius:5px;}
|
|
||||||
.consultation-info textarea { width:80%; padding:10px; border:1px solid #E9ECF0; border-radius:5px; resize:none; }
|
.project_wrap .content_section .hospital_wrap .center_box .page_title {
|
||||||
.consultation-info textarea::placeholder {color:#B5BDC4;}
|
min-width: 90px;
|
||||||
.wp60 input { width:80%; height:36px; padding:0 10px; border:1px solid #E9ECF0; border-radius:5px;}
|
padding-left: 10px;
|
||||||
.wp60 input input::placeholder {color:#B5BDC4;}
|
font-size: 18px;
|
||||||
.wp60 textarea { width:80%; padding:10px; border:1px solid #E9ECF0; border-radius:5px; resize:none; }
|
font-weight: 700;
|
||||||
.wp60 textarea::placeholder {color:#B5BDC4;}
|
line-height: 50px;
|
||||||
.content{
|
float: left;
|
||||||
width: 100%;
|
}
|
||||||
|
|
||||||
|
.consultation-info input {
|
||||||
|
width: 80%;
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info input input::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info label {
|
||||||
|
padding-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info input[type="checkbox"] {
|
||||||
|
width: 15px;
|
||||||
|
height: 15px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info input[type="checkbox"] input::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info select {
|
||||||
|
width: 80%;
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info textarea {
|
||||||
|
width: 80%;
|
||||||
|
padding: 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
resize: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.consultation-info textarea::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.wp60 input {
|
||||||
|
width: 80%;
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.wp60 input input::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.wp60 textarea {
|
||||||
|
width: 80%;
|
||||||
|
padding: 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
resize: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.wp60 textarea::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.content {
|
||||||
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
border: solid 1px #E9ECF0;
|
border: solid 1px #E9ECF0;
|
||||||
@@ -40,32 +173,52 @@
|
|||||||
background: #fff;
|
background: #fff;
|
||||||
float: left;
|
float: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* content_box */
|
/* content_box */
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box { width:100%; height:calc(100% - 50px); padding-top:20px; display:table; }
|
.project_wrap .content_section .hospital_wrap .center_box .content_box {
|
||||||
.add_btn{
|
width: 100%;
|
||||||
width:24px;
|
height: calc(100% - 50px);
|
||||||
height:24px;
|
padding-top: 20px;
|
||||||
padding-left: 0px;
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.add_btn {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
padding-left: 0px;
|
||||||
padding-right: 0px;
|
padding-right: 0px;
|
||||||
padding-top: 0px;
|
padding-top: 0px;
|
||||||
margin-top: 0px;
|
margin-top: 0px;
|
||||||
line-height:0px !important;
|
line-height: 0px !important;
|
||||||
}
|
}
|
||||||
.ml50{
|
|
||||||
margin-left:50%;
|
.ml50 {
|
||||||
|
margin-left: 50%;
|
||||||
}
|
}
|
||||||
.button_box button { width:70px; font-size:12px; height:32px; border-radius: 16px;}
|
|
||||||
.button_box button.cancel_btn {background: #F8FBFF;}
|
.button_box button {
|
||||||
|
width: 70px;
|
||||||
|
font-size: 12px;
|
||||||
|
height: 32px;
|
||||||
|
border-radius: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.button_box button.cancel_btn {
|
||||||
|
background: #F8FBFF;
|
||||||
|
}
|
||||||
|
|
||||||
.button_box button.registration_btn {
|
.button_box button.registration_btn {
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
background: #3985EA;
|
background: #3985EA;
|
||||||
}
|
}
|
||||||
|
|
||||||
.button_box {
|
.button_box {
|
||||||
width:100%;
|
width: 100%;
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
margin-left:56%;
|
margin-left: 56%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.fix_area {
|
.fix_area {
|
||||||
min-width: 1200px;
|
min-width: 1200px;
|
||||||
width: 1200px;
|
width: 1200px;
|
||||||
@@ -74,10 +227,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.btn-basic {
|
.btn-basic {
|
||||||
width:120px;
|
width: 120px;
|
||||||
height:40px;
|
height: 40px;
|
||||||
border: 1px solid #a73439;
|
border: 1px solid #a73439;
|
||||||
border-radius:5px;
|
border-radius: 5px;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
color: #a73439;
|
color: #a73439;
|
||||||
}
|
}
|
||||||
@@ -92,12 +245,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.clear > .right {
|
.clear>.right {
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
.clear > .left{
|
.clear>.left {
|
||||||
float:left;
|
float: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.main-img-size {
|
.main-img-size {
|
||||||
@@ -108,6 +261,7 @@
|
|||||||
border-radius: 0.25rem;
|
border-radius: 0.25rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.img_center img {
|
.img_center img {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
@@ -122,7 +276,7 @@
|
|||||||
padding-top: 15px;
|
padding-top: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.thumbnail-bottom-txt > span {
|
.thumbnail-bottom-txt>span {
|
||||||
display: block;
|
display: block;
|
||||||
color: #6c696a;
|
color: #6c696a;
|
||||||
font-size: 13.5px;
|
font-size: 13.5px;
|
||||||
@@ -131,15 +285,17 @@
|
|||||||
.content>.wp60 {
|
.content>.wp60 {
|
||||||
width: 60%;
|
width: 60%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content>.wp40 {
|
.content>.wp40 {
|
||||||
width: 40%;
|
width: 40%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.wp10{
|
.wp10 {
|
||||||
width:10%;
|
width: 10%;
|
||||||
}
|
}
|
||||||
.wp90{
|
|
||||||
width:90%;
|
.wp90 {
|
||||||
|
width: 90%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -147,12 +303,13 @@
|
|||||||
float: left;
|
float: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.consultation-info h2{
|
.consultation-info h2 {
|
||||||
font-size: 4rem;
|
font-size: 4rem;
|
||||||
}
|
}
|
||||||
.consultation-info p{
|
|
||||||
margin-top: 2rem;
|
.consultation-info p {
|
||||||
font-size:2rem;
|
margin-top: 2rem;
|
||||||
|
font-size: 2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -162,30 +319,31 @@
|
|||||||
margin-top: 3rem;
|
margin-top: 3rem;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.price-area .border-line {
|
.price-area .border-line {
|
||||||
height: 1px;
|
height: 1px;
|
||||||
background-color: #ddd;
|
background-color: #ddd;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.hashtag_list{
|
.hashtag_list {
|
||||||
padding: 1rem 0 1.5rem;
|
padding: 1rem 0 1.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hashtag_list span{
|
.hashtag_list span {
|
||||||
font-size:1.6rem;
|
font-size: 1.6rem;
|
||||||
color:#a94442;
|
color: #a94442;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.procedure-area>.procedure_select_txt{
|
.procedure-area>.procedure_select_txt {
|
||||||
float: left;
|
float: left;
|
||||||
width: 7rem;
|
width: 7rem;
|
||||||
line-height: 1.5;
|
line-height: 1.5;
|
||||||
padding-top: 0.375rem;
|
padding-top: 0.375rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.procedure-area > .dropdown_area {
|
.procedure-area>.dropdown_area {
|
||||||
float: right;
|
float: right;
|
||||||
width: calc(100% - 7rem);
|
width: calc(100% - 7rem);
|
||||||
}
|
}
|
||||||
@@ -218,7 +376,7 @@
|
|||||||
display: none;
|
display: none;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index:1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select_procedure_div.active .option_scrl_wrap {
|
.select_procedure_div.active .option_scrl_wrap {
|
||||||
@@ -263,10 +421,11 @@
|
|||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cs-checkbox > label.d-block {
|
.cs-checkbox>label.d-block {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
.cs-checkbox > label {
|
|
||||||
|
.cs-checkbox>label {
|
||||||
position: relative;
|
position: relative;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
@@ -297,14 +456,15 @@
|
|||||||
/* } */
|
/* } */
|
||||||
|
|
||||||
input[type="checkbox"] {
|
input[type="checkbox"] {
|
||||||
transform: scale(1.5); /* 크기를 1.5배로 확대 */
|
transform: scale(1.5);
|
||||||
|
/* 크기를 1.5배로 확대 */
|
||||||
}
|
}
|
||||||
|
|
||||||
.idxChk{
|
.idxChk {
|
||||||
position:absolute;
|
position: absolute;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cs-checkbox > label:before {
|
.cs-checkbox>label:before {
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@@ -359,9 +519,9 @@ input[type="checkbox"] {
|
|||||||
content: "";
|
content: "";
|
||||||
}
|
}
|
||||||
|
|
||||||
.selected-procedure{
|
.selected-procedure {
|
||||||
margin-top:20px;
|
margin-top: 20px;
|
||||||
position:relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -380,9 +540,10 @@ input[type="checkbox"] {
|
|||||||
padding-top: 0.2em;
|
padding-top: 0.2em;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
.selt_info_wrap .info button{
|
|
||||||
border:none;
|
.selt_info_wrap .info button {
|
||||||
background-color:#fff;
|
border: none;
|
||||||
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -394,14 +555,14 @@ input[type="checkbox"] {
|
|||||||
|
|
||||||
.selected-procedure .selt_info_wrap {
|
.selected-procedure .selt_info_wrap {
|
||||||
padding: 0.8rem 0;
|
padding: 0.8rem 0;
|
||||||
z-index:0;
|
z-index: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.selt_info_wrap {
|
.selt_info_wrap {
|
||||||
position: relative;
|
position: relative;
|
||||||
min-height: 2.5rem;
|
min-height: 2.5rem;
|
||||||
background-color:#fff;
|
background-color: #fff;
|
||||||
border:1px solid #eee;
|
border: 1px solid #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
.selected-procedure .selt_info_wrap .selt {
|
.selected-procedure .selt_info_wrap .selt {
|
||||||
@@ -428,6 +589,7 @@ input[type="checkbox"] {
|
|||||||
font-size: 2rem;
|
font-size: 2rem;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.total-price-area .total .right strong {
|
.total-price-area .total .right strong {
|
||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
@@ -472,83 +634,320 @@ input[type="checkbox"] {
|
|||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.img-content{
|
.img-content {
|
||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
.img-area{
|
.img-area {
|
||||||
padding-top: 70px;
|
padding-top: 70px;
|
||||||
padding-bottom: 200px;
|
padding-bottom: 200px;
|
||||||
text-align:center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 페이지게이션 */
|
/* 페이지게이션 */
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box {position:absolute; bottom:20px; width:100%; height:24px;}
|
.project_wrap .content_section .hospital_wrap .center_box .page_box {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {height:24px;}
|
position: absolute;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination {margin:0 auto; display:table;}
|
bottom: 20px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li {display:inline-block; padding:0}
|
width: 100%;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a, .project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {position:relative; width:24px; height:24px; background:none;}
|
height: 24px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a:hover, .project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a:hover {background:none;}
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img {position:absolute; top:50%; left:50%; transform:translate3d(-50%, -50%, 0); width:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {position:absolute; top:50%; left:50%; transform:translate3d(-50%, -50%, 0) rotate(180deg); width:10px;}
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {width:24px; height:24px; padding:0; border:none; text-align:center; line-height:22px; font-size:14px; font-weight:500; background:#FFF; font-size:14px;}
|
height: 24px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a:hover, .project_wrap .content_section .hospital_wrap .center_box .right_note .page_box .navigation .pagination li a:focus {background:#3985EA; color:#fff; font-weight:700;}
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li.active a {background:#3985EA; color:#fff;}
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination {
|
||||||
|
margin: 0 auto;
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 0
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {
|
||||||
|
position: relative;
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a:hover,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a:hover {
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
transform: translate3d(-50%, -50%, 0);
|
||||||
|
width: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
transform: translate3d(-50%, -50%, 0) rotate(180deg);
|
||||||
|
width: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
padding: 0;
|
||||||
|
border: none;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 22px;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 500;
|
||||||
|
background: #FFF;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a:hover,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .right_note .page_box .navigation .pagination li a:focus {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li.active a {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
/*반응형 View*/
|
/*반응형 View*/
|
||||||
@media only screen and (max-width:1500px) {
|
@media only screen and (max-width:1500px) {
|
||||||
.project_wrap .content_section .hospital_wrap .left_box { width:160px; padding:10px 15px; }
|
.project_wrap .content_section .hospital_wrap .left_box {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box { width:calc(100% - 160px); left:160px; }
|
width: 160px;
|
||||||
|
padding: 10px 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box {
|
||||||
|
width: calc(100% - 160px);
|
||||||
|
left: 160px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media only screen and (max-width:1280px) {
|
@media only screen and (max-width:1280px) {
|
||||||
.project_wrap .content_section .hospital_wrap { width:calc(100% - 60px); }
|
.project_wrap .content_section .hospital_wrap {
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu { font-size:12px; }
|
width: calc(100% - 60px);
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li { height:32px; margin-bottom:5px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a { font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_title { min-width:80px; height:40px; font-size:16px; line-height:40px; }
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .total { font-size:12px; line-height:40px; }
|
font-size: 12px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box { padding:15px 0; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box { width:120px; height:32px; background-size:18px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label { padding:0 10px; font-size:12px; }
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item { font-size:12px; }
|
height: 32px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box { width:120px; height:32px; }
|
margin-bottom: 5px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box img { width:22px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box input { height:32px; font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box { width:110px; height:32px; }
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box img { width:20px; }
|
font-size: 12px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box .date_picker { height:32px; padding-left:35px; font-size:10px; line-height:32px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .slash { line-height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn { margin-left:5px; padding-left:10px; }
|
.project_wrap .content_section .hospital_wrap .center_box .page_title {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn p { display:none; }
|
min-width: 80px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn img { width:12px; margin-top:-3px; position:static; transform:none; }
|
height: 40px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box { height:23px; }
|
font-size: 16px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation { height:23px; }
|
line-height: 40px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a { width:23px; height:23px; font-size:12px; }
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .total {
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box {
|
||||||
|
padding: 15px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box {
|
||||||
|
width: 120px;
|
||||||
|
height: 32px;
|
||||||
|
background-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label {
|
||||||
|
padding: 0 10px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box {
|
||||||
|
width: 120px;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box img {
|
||||||
|
width: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box .search_box input {
|
||||||
|
height: 32px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box {
|
||||||
|
width: 110px;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box img {
|
||||||
|
width: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .date_box .date_picker {
|
||||||
|
height: 32px;
|
||||||
|
padding-left: 35px;
|
||||||
|
font-size: 10px;
|
||||||
|
line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .calendar_box .slash {
|
||||||
|
line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn {
|
||||||
|
margin-left: 5px;
|
||||||
|
padding-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn p {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn img {
|
||||||
|
width: 12px;
|
||||||
|
margin-top: -3px;
|
||||||
|
position: static;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box {
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {
|
||||||
|
width: 23px;
|
||||||
|
height: 23px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a { width:23px; height:23px; }
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {
|
||||||
|
width: 23px;
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img,
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img,
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img { width:9px; }
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .table_box { height:calc(100% - 155px); }
|
width: 9px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left { width:350px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left .title { font-size:14px; line-height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label { text-indent:20px; }
|
.project_wrap .content_section .hospital_wrap .center_box .table_box {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label { font-size:12px; }
|
height: calc(100% - 155px);
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label::after { width:15px; height:15px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li input[type='checkbox']:checked + label::before { width:5px; height:8px; left:5px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right p { font-size:14px; line-height:32px; }
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li label { font-size:12px; line-height:32px; }
|
width: 350px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box { width:120px; height:32px; background-size:18px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box .label { padding:0 10px; font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box .select_option_list .option_list_item { font-size:12px; }
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left .title {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li input { font-size:12px; height:32px; width:250px; }
|
font-size: 14px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li textarea { font-size:12px; }
|
line-height: 32px;
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.banner_li label { font-size:12px; height:32px; line-height:32px; }
|
}
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.banner_li label.file_btn img { width:22px; height:22px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right { width:calc(100% - 350px); }
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label {
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right .button_box button { width:70px; font-size:12px; height:32px; }
|
text-indent: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.checkbox_li label::after {
|
||||||
|
width: 15px;
|
||||||
|
height: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li input[type='checkbox']:checked+label::before {
|
||||||
|
width: 5px;
|
||||||
|
height: 8px;
|
||||||
|
left: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right p {
|
||||||
|
font-size: 14px;
|
||||||
|
line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li label {
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box {
|
||||||
|
width: 120px;
|
||||||
|
height: 32px;
|
||||||
|
background-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box .label {
|
||||||
|
padding: 0 10px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li .select_box .select_option_list .option_list_item {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li input {
|
||||||
|
font-size: 12px;
|
||||||
|
height: 32px;
|
||||||
|
width: 250px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.first li textarea {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.banner_li label {
|
||||||
|
font-size: 12px;
|
||||||
|
height: 32px;
|
||||||
|
line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_left ul.last li.banner_li label.file_btn img {
|
||||||
|
width: 22px;
|
||||||
|
height: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right {
|
||||||
|
width: calc(100% - 350px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .content_box .content_right .button_box button {
|
||||||
|
width: 70px;
|
||||||
|
font-size: 12px;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media only screen and (max-width:1080px) {
|
@media only screen and (max-width:1080px) {
|
||||||
.project_wrap .content_section .hospital_wrap { width:calc(100% - 50px); }
|
.project_wrap .content_section .hospital_wrap {
|
||||||
|
width: calc(100% - 50px);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
449
src/main/resources/static/css/web/ContentsBbsSelectList.css
Normal file
449
src/main/resources/static/css/web/ContentsBbsSelectList.css
Normal file
@@ -0,0 +1,449 @@
|
|||||||
|
.project_wrap {
|
||||||
|
width: 100%;
|
||||||
|
min-width: 1080px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*오른쪽영역*/
|
||||||
|
.project_wrap .content_section {
|
||||||
|
margin-top: 50px;
|
||||||
|
width: 100%;
|
||||||
|
min-width: 1080px;
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap {
|
||||||
|
width: calc(100% - 72px);
|
||||||
|
min-width: calc(1080px - 72px);
|
||||||
|
height: calc(100vh - 50px);
|
||||||
|
float: left;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* 왼쪽_메뉴 영역 */
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box {
|
||||||
|
position: absolute;
|
||||||
|
width: 240px;
|
||||||
|
height: calc(100vh - 50px);
|
||||||
|
overflow: auto;
|
||||||
|
padding: 10px 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
margin: 20px 0 10px 0;
|
||||||
|
padding: 0;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu.first {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
padding: 8px;
|
||||||
|
font-size: 14px;
|
||||||
|
text-align: left;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a.on {
|
||||||
|
background: #3985EA;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {
|
||||||
|
width: 100%;
|
||||||
|
height: 36px;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a.on {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 센터쪽 */
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box {
|
||||||
|
width: calc(100% - 240px);
|
||||||
|
height: calc(100vh - 50px);
|
||||||
|
position: absolute;
|
||||||
|
left: 240px;
|
||||||
|
padding: 10px 10px 10px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_title {
|
||||||
|
min-width: 90px;
|
||||||
|
padding-left: 10px;
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: 700;
|
||||||
|
line-height: 50px;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box {
|
||||||
|
display: table;
|
||||||
|
width: 100%;
|
||||||
|
padding: 20px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box {
|
||||||
|
width: 140px;
|
||||||
|
height: 36px;
|
||||||
|
margin-left: 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: url(/image/web/select_arrow.svg) no-repeat 95% 55%/20px auto #fff;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box.first {
|
||||||
|
width: 150px;
|
||||||
|
margin-left: 0;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box.active {
|
||||||
|
z-index: 10;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
padding: 0 10px;
|
||||||
|
outline: none;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 400;
|
||||||
|
text-align: left;
|
||||||
|
color: #494E53;
|
||||||
|
cursor: pointer;
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list {
|
||||||
|
min-width: 100%;
|
||||||
|
border-radius: 5px;
|
||||||
|
transition: .4s ease-in;
|
||||||
|
border: Solid 1px #E9ECF0;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item {
|
||||||
|
width: 100%;
|
||||||
|
line-height: 30px;
|
||||||
|
transition: .1s;
|
||||||
|
position: relative;
|
||||||
|
display: table;
|
||||||
|
font-size: 14px;
|
||||||
|
color: #494E53;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item label {
|
||||||
|
width: 100%;
|
||||||
|
line-height: 30px;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
clear: both;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list {
|
||||||
|
float: left;
|
||||||
|
position: relative;
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box {
|
||||||
|
width: 150px;
|
||||||
|
float: left;
|
||||||
|
height: 36px;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
transform: translateY(-50%);
|
||||||
|
left: 5px;
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input {
|
||||||
|
width: 100%;
|
||||||
|
height: 36px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: none;
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
padding: 0 10px 0 30px;
|
||||||
|
font-size: 14px;
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box .search_list {
|
||||||
|
position: absolute;
|
||||||
|
top: 40px;
|
||||||
|
left: 0;
|
||||||
|
width: 150px;
|
||||||
|
background: #fff;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
transition: .4s ease-in;
|
||||||
|
z-index: 1;
|
||||||
|
border: solid 1px #E9ECF0;
|
||||||
|
display: none;
|
||||||
|
margin: 0;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_btn {
|
||||||
|
background: #3985EA;
|
||||||
|
border-radius: 5px;
|
||||||
|
color: #fff;
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box {
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .treatmentpetit_btn {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .treatmentpetit_btn img {
|
||||||
|
position: relative;
|
||||||
|
top: -2px;
|
||||||
|
width: 20px;
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .delete_btn {
|
||||||
|
background: #FF2222;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .delete_btn img {
|
||||||
|
position: relative;
|
||||||
|
top: -2px;
|
||||||
|
width: 20px;
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* table_box */
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .table_box {
|
||||||
|
width: 100%;
|
||||||
|
height: calc(100% - 180px);
|
||||||
|
overflow: auto;
|
||||||
|
background: #fff;
|
||||||
|
border: solid 1px #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 페이지게이션 */
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 20px;
|
||||||
|
width: 100%;
|
||||||
|
height: 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {
|
||||||
|
height: 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination {
|
||||||
|
margin: 0 auto;
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 0
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {
|
||||||
|
position: relative;
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a:hover,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a:hover {
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
transform: translate3d(-50%, -50%, 0);
|
||||||
|
width: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
transform: translate3d(-50%, -50%, 0) rotate(180deg);
|
||||||
|
width: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
padding: 0;
|
||||||
|
border: none;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 22px;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 500;
|
||||||
|
background: #FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a:hover,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .right_note .page_box .navigation .pagination li a:focus {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li.active a {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*반응형 View*/
|
||||||
|
@media only screen and (max-width:1500px) {
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box {
|
||||||
|
width: 160px;
|
||||||
|
padding: 10px 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box {
|
||||||
|
width: calc(100% - 160px);
|
||||||
|
left: 160px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media only screen and (max-width:1280px) {
|
||||||
|
.project_wrap .content_section .hospital_wrap {
|
||||||
|
width: calc(100% - 60px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {
|
||||||
|
height: 32px;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_title {
|
||||||
|
min-width: 80px;
|
||||||
|
height: 40px;
|
||||||
|
font-size: 16px;
|
||||||
|
line-height: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .total {
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box {
|
||||||
|
padding: 15px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box {
|
||||||
|
width: 120px;
|
||||||
|
height: 32px;
|
||||||
|
background-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label {
|
||||||
|
padding: 0 10px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box {
|
||||||
|
width: 120px;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box img {
|
||||||
|
width: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input {
|
||||||
|
height: 32px;
|
||||||
|
padding-left: 35px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box {
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {
|
||||||
|
width: 23px;
|
||||||
|
height: 23px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {
|
||||||
|
width: 23px;
|
||||||
|
height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img,
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {
|
||||||
|
width: 9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.project_wrap .content_section .hospital_wrap .center_box .table_box {
|
||||||
|
height: calc(100% - 155px);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media only screen and (max-width:1080px) {
|
||||||
|
.project_wrap .content_section .hospital_wrap {
|
||||||
|
width: calc(100% - 50px);
|
||||||
|
}
|
||||||
|
}
|
||||||
1259
src/main/resources/static/css/web/ContentsBbsUpd.css
Normal file
1259
src/main/resources/static/css/web/ContentsBbsUpd.css
Normal file
File diff suppressed because it is too large
Load Diff
350
src/main/resources/static/css/web/call_log.css
Normal file
350
src/main/resources/static/css/web/call_log.css
Normal file
@@ -0,0 +1,350 @@
|
|||||||
|
/* ============================================
|
||||||
|
통화 로그 관리 (call_log.css)
|
||||||
|
============================================ */
|
||||||
|
|
||||||
|
/* ---- 검색 필터 영역 ---- */
|
||||||
|
.cl_filter_wrap {
|
||||||
|
background: #fff;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 12px 16px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_row {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_row+.cl_filter_row {
|
||||||
|
margin-top: 8px;
|
||||||
|
padding-top: 8px;
|
||||||
|
border-top: 1px solid #F0F1F3;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item label {
|
||||||
|
font-size: 13px;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #555;
|
||||||
|
white-space: nowrap;
|
||||||
|
min-width: 55px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item select,
|
||||||
|
.cl_filter_item .cl_select {
|
||||||
|
height: 32px;
|
||||||
|
padding: 0 8px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #333;
|
||||||
|
background: #fff url(/image/web/select_arrow.svg) no-repeat 95% 55%/18px auto;
|
||||||
|
-webkit-appearance: none;
|
||||||
|
-moz-appearance: none;
|
||||||
|
appearance: none;
|
||||||
|
padding-right: 28px;
|
||||||
|
min-width: 90px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item input[type="text"] {
|
||||||
|
height: 32px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 13px;
|
||||||
|
width: 140px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item input[type="text"]::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 날짜 필터 */
|
||||||
|
.cl_date_item input[type="date"] {
|
||||||
|
height: 32px;
|
||||||
|
padding: 0 8px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_date_sep {
|
||||||
|
color: #888;
|
||||||
|
font-size: 13px;
|
||||||
|
margin: 0 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 날짜 단축 버튼 */
|
||||||
|
.cl_quick_btns {
|
||||||
|
display: flex;
|
||||||
|
gap: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_quick_btns button {
|
||||||
|
height: 30px;
|
||||||
|
padding: 0 10px;
|
||||||
|
border: 1px solid #D5D8DC;
|
||||||
|
border-radius: 4px;
|
||||||
|
background: #FAFBFC;
|
||||||
|
color: #555;
|
||||||
|
font-size: 12px;
|
||||||
|
cursor: pointer;
|
||||||
|
white-space: nowrap;
|
||||||
|
transition: all 0.15s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_quick_btns button:hover {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
border-color: #3985EA;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 조회 버튼 */
|
||||||
|
.cl_search_btn {
|
||||||
|
height: 32px;
|
||||||
|
padding: 0 20px;
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
border: none;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 13px;
|
||||||
|
font-weight: 600;
|
||||||
|
cursor: pointer;
|
||||||
|
white-space: nowrap;
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_search_btn:hover {
|
||||||
|
background: #2D6CC0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 통계 요약 바 ---- */
|
||||||
|
.cl_stats_bar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 10px;
|
||||||
|
background: #F7F9FC;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 10px 16px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #555;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_stats_bar strong {
|
||||||
|
color: #3985EA;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_stats_sep {
|
||||||
|
color: #D5D8DC;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_stats_detail {
|
||||||
|
font-size: 12px;
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_stats_detail strong {
|
||||||
|
color: #333;
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- ag-Grid 영역 ---- */
|
||||||
|
.cl_grid_box {
|
||||||
|
width: 100%;
|
||||||
|
height: calc(100% - 230px);
|
||||||
|
min-height: 300px;
|
||||||
|
background: #fff;
|
||||||
|
border: solid 1px #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 메모 팝업 ---- */
|
||||||
|
.cl_memo_overlay {
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background: rgba(0, 0, 0, 0.35);
|
||||||
|
z-index: 9999;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_popup {
|
||||||
|
background: #fff;
|
||||||
|
border-radius: 8px;
|
||||||
|
width: 480px;
|
||||||
|
max-width: 90%;
|
||||||
|
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_header {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 10px;
|
||||||
|
padding: 16px 20px;
|
||||||
|
border-bottom: 1px solid #E9ECF0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_header h3 {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: 700;
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_record {
|
||||||
|
font-size: 12px;
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_close {
|
||||||
|
margin-left: auto;
|
||||||
|
background: none;
|
||||||
|
border: none;
|
||||||
|
font-size: 22px;
|
||||||
|
color: #999;
|
||||||
|
cursor: pointer;
|
||||||
|
line-height: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_close:hover {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_body {
|
||||||
|
padding: 16px 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_body textarea {
|
||||||
|
width: 100%;
|
||||||
|
padding: 10px 12px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-size: 14px;
|
||||||
|
resize: vertical;
|
||||||
|
min-height: 120px;
|
||||||
|
line-height: 1.6;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_body textarea:focus {
|
||||||
|
border-color: #3985EA;
|
||||||
|
outline: none;
|
||||||
|
box-shadow: 0 0 0 2px rgba(57, 133, 234, 0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_footer {
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
padding: 12px 20px 16px;
|
||||||
|
justify-content: flex-end;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_save_btn {
|
||||||
|
height: 34px;
|
||||||
|
padding: 0 20px;
|
||||||
|
border: none;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_save_btn:hover {
|
||||||
|
background: #2D6CC0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_cancel_btn {
|
||||||
|
height: 34px;
|
||||||
|
padding: 0 16px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #fff;
|
||||||
|
color: #666;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_memo_cancel_btn:hover {
|
||||||
|
background: #F7F8FA;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 그리드 내 버튼/뱃지 ---- */
|
||||||
|
.cl_play_btn {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
width: 28px;
|
||||||
|
height: 28px;
|
||||||
|
border: 1px solid #3985EA;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: #fff;
|
||||||
|
color: #3985EA;
|
||||||
|
font-size: 11px;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.15s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_play_btn:hover {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_incall_badge {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 1px 6px;
|
||||||
|
margin: 1px 2px;
|
||||||
|
background: #EEF3FB;
|
||||||
|
color: #3366AA;
|
||||||
|
border-radius: 3px;
|
||||||
|
font-size: 11px;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 반응형 ---- */
|
||||||
|
@media screen and (max-width: 1500px) {
|
||||||
|
.cl_filter_row {
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item label {
|
||||||
|
min-width: 45px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item select,
|
||||||
|
.cl_filter_item .cl_select {
|
||||||
|
min-width: 80px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_filter_item input[type="text"] {
|
||||||
|
width: 120px;
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cl_quick_btns button {
|
||||||
|
padding: 0 7px;
|
||||||
|
font-size: 11px;
|
||||||
|
}
|
||||||
|
}
|
||||||
4
src/main/resources/static/css/web/datepicker-fix.css
Normal file
4
src/main/resources/static/css/web/datepicker-fix.css
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
/* Fix datepicker z-index issue */
|
||||||
|
.ui-datepicker {
|
||||||
|
z-index: 9999 !important;
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
285
src/main/resources/static/css/web/sms_template.css
Normal file
285
src/main/resources/static/css/web/sms_template.css
Normal file
@@ -0,0 +1,285 @@
|
|||||||
|
/* ============================================
|
||||||
|
문자 상용구 관리 - 좌측 목록 / 우측 상세
|
||||||
|
============================================ */
|
||||||
|
|
||||||
|
/* ---- 2패널 컨테이너 ---- */
|
||||||
|
.sms_two_panel {
|
||||||
|
display: flex;
|
||||||
|
gap: 10px;
|
||||||
|
height: calc(100% - 60px);
|
||||||
|
min-height: 400px;
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 좌측 목록 패널 ---- */
|
||||||
|
.sms_left_panel {
|
||||||
|
width: 45%;
|
||||||
|
min-width: 360px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #fff;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 검색 영역 */
|
||||||
|
.sms_search_area {
|
||||||
|
display: flex;
|
||||||
|
gap: 5px;
|
||||||
|
padding: 10px;
|
||||||
|
border-bottom: 1px solid #E9ECF0;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_box {
|
||||||
|
flex: 1;
|
||||||
|
position: relative;
|
||||||
|
height: 36px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_box img {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
transform: translateY(-50%);
|
||||||
|
left: 8px;
|
||||||
|
z-index: 1;
|
||||||
|
width: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_box input {
|
||||||
|
width: 100%;
|
||||||
|
height: 36px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 0 10px 0 32px;
|
||||||
|
font-size: 13px;
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_box input::placeholder {
|
||||||
|
color: #B5BDC4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_btn {
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 14px;
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
border: none;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_search_btn:hover {
|
||||||
|
background: #2D6CC0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_new_btn {
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 14px;
|
||||||
|
background: #fff;
|
||||||
|
color: #3985EA;
|
||||||
|
border: 1px solid #3985EA;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_new_btn:hover {
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ag-Grid 영역 */
|
||||||
|
.sms_grid_box {
|
||||||
|
flex: 1;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---- 우측 상세 패널 ---- */
|
||||||
|
.sms_right_panel {
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #fff;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 빈 상태 */
|
||||||
|
.sms_empty_state {
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_empty_state p {
|
||||||
|
text-align: center;
|
||||||
|
color: #B5BDC4;
|
||||||
|
font-size: 14px;
|
||||||
|
line-height: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 상세 폼 */
|
||||||
|
.sms_detail_form {
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_detail_title_bar {
|
||||||
|
padding: 14px 20px;
|
||||||
|
border-bottom: 1px solid #E9ECF0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_detail_title_bar h3 {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: 700;
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_form_row {
|
||||||
|
padding: 0 20px;
|
||||||
|
margin-top: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_form_row label {
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
font-size: 13px;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #555;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_form_row input[type="text"] {
|
||||||
|
width: 100%;
|
||||||
|
height: 38px;
|
||||||
|
padding: 0 12px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-size: 14px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_form_row textarea {
|
||||||
|
width: 100%;
|
||||||
|
padding: 10px 12px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-size: 14px;
|
||||||
|
resize: vertical;
|
||||||
|
min-height: 160px;
|
||||||
|
line-height: 1.6;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_form_row input:focus,
|
||||||
|
.sms_form_row textarea:focus {
|
||||||
|
border-color: #3985EA;
|
||||||
|
outline: none;
|
||||||
|
box-shadow: 0 0 0 2px rgba(57, 133, 234, 0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
.byte_info {
|
||||||
|
text-align: right;
|
||||||
|
margin-top: 5px;
|
||||||
|
font-size: 12px;
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.type_badge {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 2px 8px;
|
||||||
|
border-radius: 10px;
|
||||||
|
font-size: 11px;
|
||||||
|
font-weight: 600;
|
||||||
|
margin-left: 4px;
|
||||||
|
vertical-align: middle;
|
||||||
|
}
|
||||||
|
|
||||||
|
.type_badge.sms {
|
||||||
|
background: #E8F5E9;
|
||||||
|
color: #2E7D32;
|
||||||
|
}
|
||||||
|
|
||||||
|
.type_badge.lms {
|
||||||
|
background: #FFF3E0;
|
||||||
|
color: #E65100;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_info_row {
|
||||||
|
display: flex;
|
||||||
|
gap: 16px;
|
||||||
|
padding: 10px 20px !important;
|
||||||
|
margin-top: 10px !important;
|
||||||
|
border-top: 1px solid #F0F1F3;
|
||||||
|
font-size: 12px;
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_info_row strong {
|
||||||
|
font-weight: 500;
|
||||||
|
color: #555;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_btn_group {
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
padding: 14px 20px;
|
||||||
|
border-top: 1px solid #E9ECF0;
|
||||||
|
margin-top: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_save_btn {
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 24px;
|
||||||
|
border: none;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #3985EA;
|
||||||
|
color: #fff;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_save_btn:hover {
|
||||||
|
background: #2D6CC0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_delete_btn {
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 18px;
|
||||||
|
border: 1px solid #FF2222;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: transparent;
|
||||||
|
color: #FF2222;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_delete_btn:hover {
|
||||||
|
background: #FF2222;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_cancel_btn {
|
||||||
|
height: 36px;
|
||||||
|
padding: 0 18px;
|
||||||
|
border: 1px solid #E9ECF0;
|
||||||
|
border-radius: 5px;
|
||||||
|
background: #fff;
|
||||||
|
color: #666;
|
||||||
|
font-size: 13px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sms_cancel_btn:hover {
|
||||||
|
background: #F7F8FA;
|
||||||
|
}
|
||||||
@@ -1,11 +1,6 @@
|
|||||||
.project_wrap {width:100%; min-width:1080px; margin:0 auto;}
|
.project_wrap {width:100%; min-width:1080px; margin:0 auto;}
|
||||||
#homepageDivCd{
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box.first { width:150px; }
|
||||||
float:left;
|
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item { cursor:pointer; }
|
||||||
font-size:18px;
|
|
||||||
padding: 5px;
|
|
||||||
border-radius: 5px;
|
|
||||||
border-color: #ddd;
|
|
||||||
}
|
|
||||||
/*오른쪽영역*/
|
/*오른쪽영역*/
|
||||||
.project_wrap .content_section {margin-top:50px; width:100%; min-width:1080px; display:table;}
|
.project_wrap .content_section {margin-top:50px; width:100%; min-width:1080px; display:table;}
|
||||||
.project_wrap .content_section .hospital_wrap {width: calc(100% - 72px); min-width:calc(1080px - 72px); height:calc(100vh - 50px); float:left; position:relative;}
|
.project_wrap .content_section .hospital_wrap {width: calc(100% - 72px); min-width:calc(1080px - 72px); height:calc(100vh - 50px); float:left; position:relative;}
|
||||||
|
|||||||
@@ -1,107 +0,0 @@
|
|||||||
.project_wrap {width:100%; min-width:1080px; margin:0 auto;}
|
|
||||||
|
|
||||||
/*오른쪽영역*/
|
|
||||||
.project_wrap .content_section {margin-top:50px; width:100%; min-width:1080px; display:table;}
|
|
||||||
.project_wrap .content_section .hospital_wrap {width: calc(100% - 72px); min-width:calc(1080px - 72px); height:calc(100vh - 50px); float:left; position:relative;}
|
|
||||||
|
|
||||||
|
|
||||||
/* 왼쪽_메뉴 영역 */
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box {position:absolute; width:240px; height:calc(100vh - 50px); overflow:auto; padding:10px 20px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list {width:100%;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu {width:100%; height:auto; margin:20px 0 10px 0; padding:0; font-size:14px; font-weight:700;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu.first {margin-top:0;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a {width:100%; height:100%; display:block; margin-bottom:8px; padding:8px; font-size:14px; text-align:left; border-radius:5px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list a.on {background:#3985EA; border:none;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li {width:100%; height:36px; margin-bottom:8px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a.on {color:#fff;}
|
|
||||||
|
|
||||||
/* 센터쪽 */
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box {width:calc(100% - 240px); height:calc(100vh - 50px); position:absolute; left:240px; padding:10px 10px 10px 0;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_title {min-width:90px; padding-left:10px; font-size:18px; font-weight:700; line-height:50px; float:left;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box {display:table; width:100%; padding:20px 0;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box {width:140px; height:36px; margin-left:10px; border:1px solid #E9ECF0; border-radius:5px; background:url(/image/web/select_arrow.svg) no-repeat 95% 55%/20px auto #fff;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box.first { width:100px; margin-left:0; float:left; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .slash {width:6px; font-size:14px; font-weight:400; color:#000; line-height:36px; margin:0 12px; display:block; float:left;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list_box { margin-left:10px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box.active {z-index:10;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label {width:100%; height:100%; padding:0 10px; outline:none; font-size:14px; font-weight:400; text-align:left; color: #494E53; cursor:pointer; background:none;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list {min-width:100%; border-radius:5px; transition:.4s ease-in; border:Solid 1px #E9ECF0; padding:10px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item {width:100%; line-height:30px; transition:.1s; position:relative; display:table; font-size:14px; color:#494E53;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item label {width:100%; line-height:30px; margin-bottom:0px; clear:both; font-weight:400;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box {border-radius:8px; float:left; position:relative;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box {position:relative; width:140px; height:36px; float:left; margin-left:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box.last {margin-left:0;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box img {position:absolute; top:50%; transform:translateY(-50%); left:10px; z-index:1; width:22px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box .date_picker {line-height:34px; display:block; margin-right:20px; width:100%; font-size:14px; padding:0 12px; padding-left:40px; outline:none; border:1px solid #E9ECF0; border-radius:5px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box input[type="date"]::-webkit-calendar-picker-indicator {display:none;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box .date_picker {-webkit-appearance:none; -moz-appearance:none; appearance:none; position:absolute; cursor:pointer;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .slash {color:#000; font-size:14px; font-weight:400; line-height:36px; margin:0 5px; width:6px; display:block; float:left;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list {float:left; position:relative; margin-left:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box {width:150px; float:left; height:36px; position:relative;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box img {position:absolute; top:50%; transform:translateY(-50%); left:5px; z-index:1;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input {width:100%; height:36px; border:1px solid #E9ECF0; border-radius:5px; background:none; position:absolute; left:0; padding:0 10px 0 30px; font-size:14px; background:#fff;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input::placeholder {color:#B5BDC4;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box .search_list {position:absolute; top:40px; left:0; width:150px; background:#fff; color:#fff; border-radius:5px; transition:.4s ease-in; z-index:1; border:solid 1px #E9ECF0; display:none; margin:0; padding:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_btn {background:#3985EA; border-radius:5px; color:#fff; margin-left:5px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box {float:right;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .treatmentpetit_btn {background:#3985EA; color:#fff; border-radius:5px; float:left;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .treatmentpetit_btn img {position:relative; top:-2px; width:20px; margin-right:5px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .delete_btn {background:#FF2222; color:#fff; border-radius:5px; margin-left:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .right_btn_box .delete_btn img {position:relative; top:-2px; width:20px; margin-right:5px;}
|
|
||||||
|
|
||||||
/* table_box */
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .table_box {width:100%; height:calc(100% - 180px); overflow:auto; background:#fff; border:solid 1px #E9ECF0; border-radius:5px;}
|
|
||||||
|
|
||||||
/* 페이지게이션 */
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box {position:absolute; bottom:20px; width:100%; height:24px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation {height:24px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination {margin:0 auto; display:table;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li {display:inline-block; padding:0}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a, .project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a {position:relative; width:24px; height:24px; background:none;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a:hover, .project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a:hover {background:none;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img {position:absolute; top:50%; left:50%; transform:translate3d(-50%, -50%, 0); width:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img {position:absolute; top:50%; left:50%; transform:translate3d(-50%, -50%, 0) rotate(180deg); width:10px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a {width:24px; height:24px; padding:0; border:none; text-align:center; line-height:22px; font-size:14px; font-weight:500; background:#FFF; font-size:14px;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a:hover, .project_wrap .content_section .hospital_wrap .center_box .right_note .page_box .navigation .pagination li a:focus {background:#3985EA; color:#fff; font-weight:700;}
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li.active a {background:#3985EA; color:#fff;}
|
|
||||||
|
|
||||||
/*반응형 View*/
|
|
||||||
@media only screen and (max-width:1500px) {
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box { width:160px; padding:10px 15px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box { width:calc(100% - 160px); left:160px; }
|
|
||||||
}
|
|
||||||
|
|
||||||
@media only screen and (max-width:1280px) {
|
|
||||||
.project_wrap .content_section .hospital_wrap { width:calc(100% - 60px); }
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list .title_menu { font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li { height:32px; margin-bottom:5px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .left_box .sub_menu_list li a { font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_title { min-width:80px; height:40px; font-size:16px; line-height:40px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .total { font-size:12px; line-height:40px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box { padding:15px 0; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box { width:120px; height:32px; background-size:18px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .label { padding:0 10px; font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .select_box .select_option_list .option_list_item { font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box { width:120px; height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box img { width:20px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .date_box .date_picker { height:32px; padding-left:35px; font-size:12px; line-height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .calendar_box .slash { line-height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box { width:120px; height:32px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box img { width:22px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .form_box .search_list .search_box input { height:32px; padding-left:35px; font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn { margin-left:5px; padding-left:10px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn p { display:none; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .filter_box .right_btn_box .download_btn img { width:12px; margin-top:-3px; position:static; transform:none; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box { height:23px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation { height:23px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li a { width:23px; height:23px; font-size:12px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a,
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a { width:23px; height:23px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:first-child a img,
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .page_box .navigation .pagination li:last-child a img { width:9px; }
|
|
||||||
.project_wrap .content_section .hospital_wrap .center_box .table_box { height:calc(100% - 155px); }
|
|
||||||
}
|
|
||||||
|
|
||||||
@media only screen and (max-width:1080px) {
|
|
||||||
.project_wrap .content_section .hospital_wrap { width:calc(100% - 50px); }
|
|
||||||
}
|
|
||||||
427
src/main/resources/static/js/web/callLog/callLogSelectList.js
Normal file
427
src/main/resources/static/js/web/callLog/callLogSelectList.js
Normal file
@@ -0,0 +1,427 @@
|
|||||||
|
/**
|
||||||
|
* 통화 로그 관리 - ag-Grid
|
||||||
|
*/
|
||||||
|
$(document).ready(function () {
|
||||||
|
fn_initGrid();
|
||||||
|
fn_init();
|
||||||
|
fn_setToday();
|
||||||
|
fn_loadCallLogList();
|
||||||
|
});
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
전역 변수
|
||||||
|
============================================ */
|
||||||
|
var gridApi = null;
|
||||||
|
|
||||||
|
/* ARS 메뉴 번호 → 텍스트 매핑 */
|
||||||
|
var arsMenuMap = {
|
||||||
|
'1': '상담',
|
||||||
|
'2': '예약',
|
||||||
|
'3': '위치안내'
|
||||||
|
};
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
ag-Grid 초기화
|
||||||
|
============================================ */
|
||||||
|
function fn_initGrid() {
|
||||||
|
var columnDefs = [
|
||||||
|
{
|
||||||
|
headerName: 'No',
|
||||||
|
valueGetter: function (params) {
|
||||||
|
return params.node.rowIndex + 1;
|
||||||
|
},
|
||||||
|
width: 60,
|
||||||
|
maxWidth: 60,
|
||||||
|
cellStyle: { textAlign: 'center' },
|
||||||
|
suppressSizeToFit: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: 'RECORD NO',
|
||||||
|
field: 'recordNo',
|
||||||
|
width: 100,
|
||||||
|
maxWidth: 110,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '구분1',
|
||||||
|
field: 'menuText',
|
||||||
|
width: 100,
|
||||||
|
maxWidth: 120,
|
||||||
|
cellStyle: { textAlign: 'center' },
|
||||||
|
valueGetter: function (params) {
|
||||||
|
var d = params.data;
|
||||||
|
if (!d) return '';
|
||||||
|
if (d.bound === 'OUT') return 'OUT';
|
||||||
|
if (d.callbackCid) return 'Call Back';
|
||||||
|
return arsMenuMap[d.ring] || '';
|
||||||
|
},
|
||||||
|
cellRenderer: function (params) {
|
||||||
|
if (!params.data) return '';
|
||||||
|
if (params.data.bound === 'OUT') {
|
||||||
|
return '<span style="color:#0000ff;font-weight:600">OUT</span>';
|
||||||
|
}
|
||||||
|
if (params.data.callbackCid) {
|
||||||
|
return 'Call Back<br><small>' + params.data.callbackCid + '</small>';
|
||||||
|
}
|
||||||
|
return params.value || '';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '구분2',
|
||||||
|
field: 'cType1',
|
||||||
|
width: 65,
|
||||||
|
maxWidth: 80,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '구분3',
|
||||||
|
field: 'cType2',
|
||||||
|
width: 80,
|
||||||
|
maxWidth: 100,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '고객명',
|
||||||
|
field: 'memberName',
|
||||||
|
width: 90,
|
||||||
|
maxWidth: 120,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '전화번호',
|
||||||
|
field: 'cid',
|
||||||
|
width: 120,
|
||||||
|
maxWidth: 140,
|
||||||
|
cellStyle: { textAlign: 'center' },
|
||||||
|
valueFormatter: function (params) {
|
||||||
|
return fn_formatPhone(params.value);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '전화 온 시간',
|
||||||
|
field: 'regDate',
|
||||||
|
width: 145,
|
||||||
|
maxWidth: 160,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '통화 시작',
|
||||||
|
field: 'linkDate',
|
||||||
|
width: 145,
|
||||||
|
maxWidth: 160,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '통화 종료',
|
||||||
|
valueGetter: function (params) {
|
||||||
|
if (!params.data) return '';
|
||||||
|
return params.data.linkEndDate || params.data.bendDate || '';
|
||||||
|
},
|
||||||
|
width: 145,
|
||||||
|
maxWidth: 160,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '상담 전화번호',
|
||||||
|
field: 'linkCid',
|
||||||
|
width: 110,
|
||||||
|
maxWidth: 130,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '통화파일',
|
||||||
|
field: 'recordNo',
|
||||||
|
width: 80,
|
||||||
|
maxWidth: 90,
|
||||||
|
cellStyle: { textAlign: 'center' },
|
||||||
|
cellRenderer: function (params) {
|
||||||
|
if (!params.data || !params.data.recordNo || !params.data.linkDate) return '';
|
||||||
|
var btn = '<button type="button" class="cl_play_btn" onclick="fn_playRecord(\'' + params.data.recordNo + '\')">▶</button>';
|
||||||
|
return btn;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: 'In Call',
|
||||||
|
field: 'incallSel',
|
||||||
|
width: 150,
|
||||||
|
minWidth: 100,
|
||||||
|
cellStyle: { textAlign: 'left' },
|
||||||
|
cellRenderer: function (params) {
|
||||||
|
var val = params.value;
|
||||||
|
if (!val) return '';
|
||||||
|
// incallSel은 '|=|값1|=||=|값2|=|' 형식
|
||||||
|
var items = val.split('|=|').filter(function (v) { return v.trim() !== ''; });
|
||||||
|
if (items.length === 0) return '';
|
||||||
|
return items.map(function (item) {
|
||||||
|
return '<span class="cl_incall_badge">' + item + '</span>';
|
||||||
|
}).join(' ');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '메모',
|
||||||
|
field: 'callMsg',
|
||||||
|
flex: 1,
|
||||||
|
minWidth: 120,
|
||||||
|
cellStyle: { textAlign: 'left', cursor: 'pointer' },
|
||||||
|
cellRenderer: function (params) {
|
||||||
|
var msg = params.value || '';
|
||||||
|
// HTML 태그 제거하여 표시
|
||||||
|
var plainText = msg.replace(/<[^>]+>/g, '').trim();
|
||||||
|
if (plainText.length > 30) {
|
||||||
|
plainText = plainText.substring(0, 30) + '...';
|
||||||
|
}
|
||||||
|
return plainText || '<span style="color:#B5BDC4">클릭하여 메모 입력</span>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
var gridOptions = {
|
||||||
|
columnDefs: columnDefs,
|
||||||
|
rowData: [],
|
||||||
|
rowSelection: 'single',
|
||||||
|
animateRows: true,
|
||||||
|
headerHeight: 36,
|
||||||
|
rowHeight: 40,
|
||||||
|
suppressCellFocus: true,
|
||||||
|
overlayNoRowsTemplate: '<span style="color:#B5BDC4; font-size:13px;">검색된 통화 내역이 없습니다.</span>',
|
||||||
|
onCellClicked: function (event) {
|
||||||
|
if (event.colDef.field === 'callMsg') {
|
||||||
|
fn_openMemo(event.data);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
defaultColDef: {
|
||||||
|
resizable: true,
|
||||||
|
sortable: true
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
var gridDiv = document.querySelector('#callLogGrid');
|
||||||
|
gridApi = new agGrid.Grid(gridDiv, gridOptions);
|
||||||
|
gridApi = gridOptions.api;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
초기화 (이벤트 바인딩)
|
||||||
|
============================================ */
|
||||||
|
function fn_init() {
|
||||||
|
$('#searchBtn').on('click', function () {
|
||||||
|
fn_loadCallLogList();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#mCid').on('keypress', function (e) {
|
||||||
|
if (e.which === 13) fn_loadCallLogList();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#sDate, #eDate').on('change', function () {
|
||||||
|
// 날짜 변경 시 자동 검색하지 않음 (사용자가 조회 버튼 클릭)
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
오늘 날짜 설정
|
||||||
|
============================================ */
|
||||||
|
function fn_setToday() {
|
||||||
|
var today = fn_getDateStr(new Date());
|
||||||
|
$('#sDate').val(today);
|
||||||
|
$('#eDate').val(today);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
날짜 단축 버튼
|
||||||
|
============================================ */
|
||||||
|
function fn_dayChk(type) {
|
||||||
|
var now = new Date();
|
||||||
|
var sDate, eDate;
|
||||||
|
|
||||||
|
switch (type) {
|
||||||
|
case 't': // 오늘
|
||||||
|
sDate = new Date();
|
||||||
|
eDate = new Date();
|
||||||
|
break;
|
||||||
|
case 'p': // 어제
|
||||||
|
sDate = new Date(now.getFullYear(), now.getMonth(), now.getDate() - 1);
|
||||||
|
eDate = new Date(now.getFullYear(), now.getMonth(), now.getDate() - 1);
|
||||||
|
break;
|
||||||
|
case 'w': // 이번주 (월요일~오늘)
|
||||||
|
var dayOfWeek = now.getDay();
|
||||||
|
var diff = dayOfWeek === 0 ? 6 : dayOfWeek - 1;
|
||||||
|
sDate = new Date(now.getFullYear(), now.getMonth(), now.getDate() - diff);
|
||||||
|
eDate = new Date();
|
||||||
|
break;
|
||||||
|
case 'pw': // 지난주 (월요일~일요일)
|
||||||
|
var dayOfWeek = now.getDay();
|
||||||
|
var diff = dayOfWeek === 0 ? 6 : dayOfWeek - 1;
|
||||||
|
var thisMonday = new Date(now.getFullYear(), now.getMonth(), now.getDate() - diff);
|
||||||
|
sDate = new Date(thisMonday.getFullYear(), thisMonday.getMonth(), thisMonday.getDate() - 7);
|
||||||
|
eDate = new Date(thisMonday.getFullYear(), thisMonday.getMonth(), thisMonday.getDate() - 1);
|
||||||
|
break;
|
||||||
|
case 'm': // 이번달
|
||||||
|
sDate = new Date(now.getFullYear(), now.getMonth(), 1);
|
||||||
|
eDate = new Date();
|
||||||
|
break;
|
||||||
|
case 'pm': // 지난달
|
||||||
|
sDate = new Date(now.getFullYear(), now.getMonth() - 1, 1);
|
||||||
|
eDate = new Date(now.getFullYear(), now.getMonth(), 0);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$('#sDate').val(fn_getDateStr(sDate));
|
||||||
|
$('#eDate').val(fn_getDateStr(eDate));
|
||||||
|
fn_loadCallLogList();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
목록 조회
|
||||||
|
============================================ */
|
||||||
|
function fn_loadCallLogList() {
|
||||||
|
var param = {
|
||||||
|
sDate: $('#sDate').val(),
|
||||||
|
eDate: $('#eDate').val(),
|
||||||
|
callType: $('#callType').val(),
|
||||||
|
callType1: $('#callType1').val(),
|
||||||
|
callType2: $('#callType2').val(),
|
||||||
|
mCid: $('#mCid').val().replace(/[^0-9]/g, ''),
|
||||||
|
fulldnis: '', // TODO: 매장별 수신번호 설정 필요
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/callLog/getCallLogList.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
var rows = data.rows || [];
|
||||||
|
gridApi.setRowData(rows);
|
||||||
|
|
||||||
|
if (rows.length === 0) {
|
||||||
|
gridApi.showNoRowsOverlay();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 통계 업데이트
|
||||||
|
fn_updateStats(data.stats);
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('목록 조회 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
통계 업데이트
|
||||||
|
============================================ */
|
||||||
|
function fn_updateStats(stats) {
|
||||||
|
if (!stats) {
|
||||||
|
$('#statTotal, #statIn, #statOut, #statType1, #statType2, #statType11, #statType12, #statType13').text('0');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$('#statTotal').text(fn_numberFormat(stats.totalCnt || 0));
|
||||||
|
$('#statIn').text(fn_numberFormat(stats.inCnt || 0));
|
||||||
|
$('#statOut').text(fn_numberFormat(stats.outCnt || 0));
|
||||||
|
$('#statType1').text(fn_numberFormat(stats.type1Cnt || 0));
|
||||||
|
$('#statType2').text(fn_numberFormat(stats.type2Cnt || 0));
|
||||||
|
$('#statType11').text(fn_numberFormat(stats.type11Cnt || 0));
|
||||||
|
$('#statType12').text(fn_numberFormat(stats.type12Cnt || 0));
|
||||||
|
$('#statType13').text(fn_numberFormat(stats.type13Cnt || 0));
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
메모 팝업
|
||||||
|
============================================ */
|
||||||
|
function fn_openMemo(data) {
|
||||||
|
if (!data || !data.recordNo) return;
|
||||||
|
|
||||||
|
$('#memoRecordNoVal').val(data.recordNo);
|
||||||
|
$('#memoRecordNo').text('RECORD NO: ' + data.recordNo);
|
||||||
|
$('#memoContent').val(data.callMsg || '');
|
||||||
|
$('#memoOverlay').fadeIn(200);
|
||||||
|
$('#memoContent').focus();
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_closeMemo() {
|
||||||
|
$('#memoOverlay').fadeOut(200);
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_saveMemo() {
|
||||||
|
var recordNo = $('#memoRecordNoVal').val();
|
||||||
|
var callMsg = $.trim($('#memoContent').val());
|
||||||
|
|
||||||
|
if (!recordNo) return;
|
||||||
|
|
||||||
|
var param = {
|
||||||
|
recordNo: recordNo,
|
||||||
|
callMsg: callMsg,
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/callLog/saveCallMemo.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
alert(data.msgDesc || '저장되었습니다.');
|
||||||
|
fn_closeMemo();
|
||||||
|
fn_loadCallLogList();
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('메모 저장 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
유틸리티 함수
|
||||||
|
============================================ */
|
||||||
|
function fn_getDateStr(date) {
|
||||||
|
var y = date.getFullYear();
|
||||||
|
var m = ('0' + (date.getMonth() + 1)).slice(-2);
|
||||||
|
var d = ('0' + date.getDate()).slice(-2);
|
||||||
|
return y + '-' + m + '-' + d;
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_numberFormat(num) {
|
||||||
|
if (!num && num !== 0) return '0';
|
||||||
|
return Number(num).toLocaleString();
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_formatPhone(phone) {
|
||||||
|
if (!phone) return '';
|
||||||
|
phone = phone.replace(/[^0-9]/g, '');
|
||||||
|
if (phone.length === 11) {
|
||||||
|
return phone.replace(/(\d{3})(\d{4})(\d{4})/, '$1-$2-$3');
|
||||||
|
} else if (phone.length === 10) {
|
||||||
|
return phone.replace(/(\d{3})(\d{3})(\d{4})/, '$1-$2-$3');
|
||||||
|
} else if (phone.length === 9) {
|
||||||
|
return phone.replace(/(\d{2})(\d{3})(\d{4})/, '$1-$2-$3');
|
||||||
|
}
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
녹음 파일 재생
|
||||||
|
============================================ */
|
||||||
|
function fn_playRecord(recordNo) {
|
||||||
|
if (!recordNo) return;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/callLog/getRecordFileUrl.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: { recordNo: recordNo },
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
if (data.success && data.recordUrl) {
|
||||||
|
window.open(data.recordUrl, '_blank', 'width=400,height=200');
|
||||||
|
} else {
|
||||||
|
alert('녹음 파일을 불러올 수 없습니다.');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('녹음 파일 조회 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
@@ -1,19 +1,19 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 로그아웃
|
* 로그아웃
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_logout(){
|
function fn_logout() {
|
||||||
window.location ='/weblogin/logout.do';
|
window.location = '/weblogin/logout.do';
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 로그아웃(session 종료)
|
* 로그아웃(session 종료)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_sessionLogout(){
|
function fn_sessionLogout() {
|
||||||
if(checkMobile()){
|
if (checkMobile()) {
|
||||||
getLoginInfo();
|
getLoginInfo();
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
window.location ='/weblogin/logout.do';
|
window.location = '/weblogin/logout.do';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -28,23 +28,23 @@ function fn_numberFormat(str) {
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 이동
|
* 페이지 이동
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_leftFormAction(action){
|
function fn_leftFormAction(action) {
|
||||||
let newForm = $("<form><form/>");
|
let newForm = $("<form><form/>");
|
||||||
newForm.attr("name","submitForm");
|
newForm.attr("name", "submitForm");
|
||||||
newForm.attr("method","POST");
|
newForm.attr("method", "POST");
|
||||||
|
|
||||||
if(-1 != action.indexOf("?")) {
|
if (-1 != action.indexOf("?")) {
|
||||||
let actionArr = action.split('?');
|
let actionArr = action.split('?');
|
||||||
newForm.attr("action",actionArr[0]);
|
newForm.attr("action", actionArr[0]);
|
||||||
|
|
||||||
let paramUrlArr = actionArr[1].split('&');
|
let paramUrlArr = actionArr[1].split('&');
|
||||||
for(let i = 0; i < paramUrlArr.length; i++){
|
for (let i = 0; i < paramUrlArr.length; i++) {
|
||||||
let paramArr = paramUrlArr[i].split('=');
|
let paramArr = paramUrlArr[i].split('=');
|
||||||
newForm.append($('<input/>',{type:'hidden',name:paramArr[0],value:paramArr[1]}));
|
newForm.append($('<input/>', { type: 'hidden', name: paramArr[0], value: paramArr[1] }));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
newForm.attr("action",action);
|
newForm.attr("action", action);
|
||||||
}
|
}
|
||||||
|
|
||||||
// newForm.append($('<input/>',{type:'hidden',name:"menuCode",value:menuCode}));
|
// newForm.append($('<input/>',{type:'hidden',name:"menuCode",value:menuCode}));
|
||||||
@@ -55,26 +55,26 @@ function fn_leftFormAction(action){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 이동2
|
* 페이지 이동2
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_leftFormAction2(menuClass, action){
|
function fn_leftFormAction2(menuClass, action) {
|
||||||
let newForm = $("<form><form/>");
|
let newForm = $("<form><form/>");
|
||||||
newForm.attr("name","submitForm");
|
newForm.attr("name", "submitForm");
|
||||||
newForm.attr("method","POST");
|
newForm.attr("method", "POST");
|
||||||
|
|
||||||
if(-1 != action.indexOf("?")) {
|
if (-1 != action.indexOf("?")) {
|
||||||
let actionArr = action.split('?');
|
let actionArr = action.split('?');
|
||||||
newForm.attr("action",actionArr[0]);
|
newForm.attr("action", actionArr[0]);
|
||||||
|
|
||||||
let paramUrlArr = actionArr[1].split('&');
|
let paramUrlArr = actionArr[1].split('&');
|
||||||
for(let i = 0; i < paramUrlArr.length; i++){
|
for (let i = 0; i < paramUrlArr.length; i++) {
|
||||||
let paramArr = paramUrlArr[i].split('=');
|
let paramArr = paramUrlArr[i].split('=');
|
||||||
newForm.append($('<input/>',{type:'hidden',name:paramArr[0],value:paramArr[1]}));
|
newForm.append($('<input/>', { type: 'hidden', name: paramArr[0], value: paramArr[1] }));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
newForm.attr("action",action);
|
newForm.attr("action", action);
|
||||||
}
|
}
|
||||||
|
|
||||||
newForm.append($('<input/>',{type:'hidden',name:"menuClass",value:menuClass}));
|
newForm.append($('<input/>', { type: 'hidden', name: "menuClass", value: menuClass }));
|
||||||
newForm.appendTo('body');
|
newForm.appendTo('body');
|
||||||
newForm.submit();
|
newForm.submit();
|
||||||
}
|
}
|
||||||
@@ -82,24 +82,24 @@ function fn_leftFormAction2(menuClass, action){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 새창 이동 (미리보기)
|
* 새창 이동 (미리보기)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_openPopup(action){
|
function fn_openPopup(action) {
|
||||||
let newForm = $("<form><form/>");
|
let newForm = $("<form><form/>");
|
||||||
newForm.attr("name","submitForm");
|
newForm.attr("name", "submitForm");
|
||||||
newForm.attr("method","POST");
|
newForm.attr("method", "POST");
|
||||||
newForm.attr("target","_blank");
|
newForm.attr("target", "_blank");
|
||||||
|
|
||||||
if(-1 != action.indexOf("?")) {
|
if (-1 != action.indexOf("?")) {
|
||||||
let actionArr = action.split('?');
|
let actionArr = action.split('?');
|
||||||
newForm.attr("action",actionArr[0]);
|
newForm.attr("action", actionArr[0]);
|
||||||
|
|
||||||
let paramUrlArr = actionArr[1].split('&');
|
let paramUrlArr = actionArr[1].split('&');
|
||||||
for(let i = 0; i < paramUrlArr.length; i++){
|
for (let i = 0; i < paramUrlArr.length; i++) {
|
||||||
let paramArr = paramUrlArr[i].split('=');
|
let paramArr = paramUrlArr[i].split('=');
|
||||||
newForm.append($('<input/>',{type:'hidden',name:paramArr[0],value:paramArr[1]}));
|
newForm.append($('<input/>', { type: 'hidden', name: paramArr[0], value: paramArr[1] }));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
newForm.attr("action",action);
|
newForm.attr("action", action);
|
||||||
}
|
}
|
||||||
|
|
||||||
newForm.appendTo('body');
|
newForm.appendTo('body');
|
||||||
@@ -109,29 +109,29 @@ function fn_openPopup(action){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 새창 이동2 (미리보기)
|
* 새창 이동2 (미리보기)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_openPopup2(menuClass, action){
|
function fn_openPopup2(menuClass, action) {
|
||||||
const newWindow = window.open("about:blank", "popup", "width=1600, height=800");
|
const newWindow = window.open("about:blank", "popup", "width=1600, height=800");
|
||||||
|
|
||||||
let newForm = $("<form><form/>");
|
let newForm = $("<form><form/>");
|
||||||
newForm.attr("name","submitForm");
|
newForm.attr("name", "submitForm");
|
||||||
newForm.attr("method","POST");
|
newForm.attr("method", "POST");
|
||||||
newForm.attr("target","popup");
|
newForm.attr("target", "popup");
|
||||||
|
|
||||||
if(-1 != action.indexOf("?")) {
|
if (-1 != action.indexOf("?")) {
|
||||||
let actionArr = action.split('?');
|
let actionArr = action.split('?');
|
||||||
newForm.attr("action",actionArr[0]);
|
newForm.attr("action", actionArr[0]);
|
||||||
|
|
||||||
let paramUrlArr = actionArr[1].split('&');
|
let paramUrlArr = actionArr[1].split('&');
|
||||||
for(let i = 0; i < paramUrlArr.length; i++){
|
for (let i = 0; i < paramUrlArr.length; i++) {
|
||||||
let paramArr = paramUrlArr[i].split('=');
|
let paramArr = paramUrlArr[i].split('=');
|
||||||
newForm.append($('<input/>',{type:'hidden',name:paramArr[0],value:paramArr[1]}));
|
newForm.append($('<input/>', { type: 'hidden', name: paramArr[0], value: paramArr[1] }));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
newForm.attr("action",action);
|
newForm.attr("action", action);
|
||||||
}
|
}
|
||||||
|
|
||||||
newForm.append($('<input/>',{type:'hidden',name:"menuClass",value:menuClass}));
|
newForm.append($('<input/>', { type: 'hidden', name: "menuClass", value: menuClass }));
|
||||||
newForm.appendTo('body');
|
newForm.appendTo('body');
|
||||||
newForm.submit();
|
newForm.submit();
|
||||||
}
|
}
|
||||||
@@ -139,14 +139,14 @@ function fn_openPopup2(menuClass, action){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 뒤로가기
|
* 뒤로가기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_back(){
|
function fn_back() {
|
||||||
history.back();
|
history.back();
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 새로고침
|
* 새로고침
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_reload(){
|
function fn_reload() {
|
||||||
location.reload();
|
location.reload();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -154,36 +154,36 @@ function fn_reload(){
|
|||||||
* 전화번호 형식 변경
|
* 전화번호 형식 변경
|
||||||
* type:0이면 중간번호 가리기
|
* type:0이면 중간번호 가리기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setFormatPhone(num,type){
|
function fn_setFormatPhone(num, type) {
|
||||||
if (!num) return '';
|
if (!num) return '';
|
||||||
num = String(num);
|
num = String(num);
|
||||||
let formatNum = '';
|
let formatNum = '';
|
||||||
|
|
||||||
if(11 == num.length){
|
if (11 == num.length) {
|
||||||
if(0 == type){
|
if (0 == type) {
|
||||||
formatNum = num.replace(/(\d{3})(\d{4})(\d{4})/, '$1-****-$3');
|
formatNum = num.replace(/(\d{3})(\d{4})(\d{4})/, '$1-****-$3');
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
formatNum = num.replace(/(\d{3})(\d{4})(\d{4})/, '$1-$2-$3');
|
formatNum = num.replace(/(\d{3})(\d{4})(\d{4})/, '$1-$2-$3');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(8 == num.length){
|
else if (8 == num.length) {
|
||||||
formatNum = num.replace(/(\d{4})(\d{4})/, '$1-$2');
|
formatNum = num.replace(/(\d{4})(\d{4})/, '$1-$2');
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
if(0 == num.indexOf('02')){
|
if (0 == num.indexOf('02')) {
|
||||||
if(0 == type){
|
if (0 == type) {
|
||||||
formatNum = num.replace(/(\d{2})(\d{4})(\d{4})/, '$1-****-$3');
|
formatNum = num.replace(/(\d{2})(\d{4})(\d{4})/, '$1-****-$3');
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
formatNum = num.replace(/(\d{2})(\d{4})(\d{4})/, '$1-$2-$3');
|
formatNum = num.replace(/(\d{2})(\d{4})(\d{4})/, '$1-$2-$3');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
if(0 == type){
|
if (0 == type) {
|
||||||
formatNum = num.replace(/(\d{3})(\d{3})(\d{4})/, '$1-***-$3');
|
formatNum = num.replace(/(\d{3})(\d{3})(\d{4})/, '$1-***-$3');
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
formatNum = num.replace(/(\d{3})(\d{3})(\d{4})/, '$1-$2-$3');
|
formatNum = num.replace(/(\d{3})(\d{3})(\d{4})/, '$1-$2-$3');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -195,14 +195,14 @@ function fn_setFormatPhone(num,type){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 날짜 보이는 영역에 셋팅
|
* 날짜 보이는 영역에 셋팅
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectDateTime(paramId, paramValue){
|
function fn_selectDateTime(paramId, paramValue) {
|
||||||
$("#"+paramId).val(paramValue);
|
$("#" + paramId).val(paramValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* datePicker 생성
|
* datePicker 생성
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_datePicker(id){
|
function fn_datePicker(id) {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'YYYY-MM-DD'
|
format: 'YYYY-MM-DD'
|
||||||
@@ -213,7 +213,7 @@ function fn_datePicker(id){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* datePicker
|
* datePicker
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_searchDatePicker(startId, endId){
|
function fn_searchDatePicker(startId, endId) {
|
||||||
$(startId).datetimepicker({
|
$(startId).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'YYYY-MM-DD',
|
format: 'YYYY-MM-DD',
|
||||||
@@ -235,7 +235,7 @@ function fn_searchDatePicker(startId, endId){
|
|||||||
$(startId).on("dp.change", function (e) {
|
$(startId).on("dp.change", function (e) {
|
||||||
$(endId).data("DateTimePicker").minDate(e.date);
|
$(endId).data("DateTimePicker").minDate(e.date);
|
||||||
|
|
||||||
if($(endId).data("DateTimePicker").date() < e.date){
|
if ($(endId).data("DateTimePicker").date() < e.date) {
|
||||||
$(endId).data("DateTimePicker").date(e.date);
|
$(endId).data("DateTimePicker").date(e.date);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -244,15 +244,15 @@ function fn_searchDatePicker(startId, endId){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* dateTimePicker 생성
|
* dateTimePicker 생성
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateTimePicker1(id, value){
|
function fn_dateTimePicker1(id, value) {
|
||||||
if(value){
|
if (value) {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'HH:mm',
|
format: 'HH:mm',
|
||||||
defaultDate: moment().format('YYYY-MM-DD')+'T'+ value
|
defaultDate: moment().format('YYYY-MM-DD') + 'T' + value
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'HH:mm'
|
format: 'HH:mm'
|
||||||
@@ -263,7 +263,7 @@ function fn_dateTimePicker1(id, value){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* dateTimePicker 생성 (AM, PM 선택)
|
* dateTimePicker 생성 (AM, PM 선택)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateTimePicker2(id){
|
function fn_dateTimePicker2(id) {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'LT'
|
format: 'LT'
|
||||||
@@ -273,7 +273,7 @@ function fn_dateTimePicker2(id){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* dateTimePicker 생성
|
* dateTimePicker 생성
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateTimePicker3(id){
|
function fn_dateTimePicker3(id) {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'YYYY-MM-DD HH:mm'
|
format: 'YYYY-MM-DD HH:mm'
|
||||||
@@ -283,7 +283,7 @@ function fn_dateTimePicker3(id){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* dateTimePicker 생성 (AM, PM 선택)
|
* dateTimePicker 생성 (AM, PM 선택)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateMonthPicker(id){
|
function fn_dateMonthPicker(id) {
|
||||||
$(id).datetimepicker({
|
$(id).datetimepicker({
|
||||||
allowInputToggle: true,
|
allowInputToggle: true,
|
||||||
format: 'YYYY-MM',
|
format: 'YYYY-MM',
|
||||||
@@ -294,11 +294,11 @@ function fn_dateMonthPicker(id){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* null 확인
|
* null 확인
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_emptyYn(value){
|
function fn_emptyYn(value) {
|
||||||
if( value == "" || value == null || value == undefined || ( value != null && typeof value == "object" && !Object.keys(value).length ) ){
|
if (value == "" || value == null || value == undefined || (value != null && typeof value == "object" && !Object.keys(value).length)) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -319,7 +319,7 @@ function fn_getToDate() {
|
|||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_getToYesterday() {
|
function fn_getToYesterday() {
|
||||||
let toDate = new Date();
|
let toDate = new Date();
|
||||||
let newToDate = fn_formatToDate(toDate.getFullYear(), 4) + '-' + fn_formatToDate(toDate.getMonth() + 1, 2) + '-' + fn_formatToDate(toDate.getDate()-1, 2);
|
let newToDate = fn_formatToDate(toDate.getFullYear(), 4) + '-' + fn_formatToDate(toDate.getMonth() + 1, 2) + '-' + fn_formatToDate(toDate.getDate() - 1, 2);
|
||||||
|
|
||||||
return newToDate;
|
return newToDate;
|
||||||
}
|
}
|
||||||
@@ -332,7 +332,7 @@ function fn_formatToDate(day, number) {
|
|||||||
day = day.toString();
|
day = day.toString();
|
||||||
|
|
||||||
if (day.length < number) {
|
if (day.length < number) {
|
||||||
for (i = 0; i < number - day.length; i++){
|
for (i = 0; i < number - day.length; i++) {
|
||||||
temp += '0';
|
temp += '0';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -344,10 +344,10 @@ function fn_formatToDate(day, number) {
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 날짜 요일 조회
|
* 날짜 요일 조회
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_getDayName(param){
|
function fn_getDayName(param) {
|
||||||
let paramArray = param.split('-');
|
let paramArray = param.split('-');
|
||||||
let week = new Array('일', '월', '화', '수', '목', '금', '토');
|
let week = new Array('일', '월', '화', '수', '목', '금', '토');
|
||||||
let dt = new Date(parseInt(paramArray[0]), parseInt(paramArray[1])-1, parseInt(paramArray[2]));
|
let dt = new Date(parseInt(paramArray[0]), parseInt(paramArray[1]) - 1, parseInt(paramArray[2]));
|
||||||
let dayName = week[dt.getDay()];
|
let dayName = week[dt.getDay()];
|
||||||
|
|
||||||
return dayName;
|
return dayName;
|
||||||
@@ -367,47 +367,47 @@ function fn_getDayName(param){
|
|||||||
function setFormatDate(type, param) {
|
function setFormatDate(type, param) {
|
||||||
let retureValue = param;
|
let retureValue = param;
|
||||||
|
|
||||||
if("A" == type){
|
if ("A" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
retureValue = dateArray[0]+"년 "+dateArray[1]+"월 "+dateArray[2]+"일";
|
retureValue = dateArray[0] + "년 " + dateArray[1] + "월 " + dateArray[2] + "일";
|
||||||
}
|
}
|
||||||
else if("B" == type){
|
else if ("B" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
retureValue = dateArray[1]+"월 "+dateArray[2]+"일";
|
retureValue = dateArray[1] + "월 " + dateArray[2] + "일";
|
||||||
}
|
}
|
||||||
else if("C" == type){
|
else if ("C" == type) {
|
||||||
let tempArray = param.split(" ");
|
let tempArray = param.split(" ");
|
||||||
let dateArray1 = tempArray[0].split("-");
|
let dateArray1 = tempArray[0].split("-");
|
||||||
let dateArray2 = tempArray[1];
|
let dateArray2 = tempArray[1];
|
||||||
|
|
||||||
retureValue = dateArray1[0]+"년 "+dateArray1[1]+"월 "+dateArray1[2]+"일 "+dateArray2;
|
retureValue = dateArray1[0] + "년 " + dateArray1[1] + "월 " + dateArray1[2] + "일 " + dateArray2;
|
||||||
}
|
}
|
||||||
else if("D" == type){
|
else if ("D" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
retureValue = dateArray[0].substring(2, 4)+"."+dateArray[1]+"."+dateArray[2];
|
retureValue = dateArray[0].substring(2, 4) + "." + dateArray[1] + "." + dateArray[2];
|
||||||
}
|
}
|
||||||
else if("E" == type){
|
else if ("E" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
retureValue = dateArray[0].substring(0, 4)+"."+dateArray[1]+"."+dateArray[2];
|
retureValue = dateArray[0].substring(0, 4) + "." + dateArray[1] + "." + dateArray[2];
|
||||||
}
|
}
|
||||||
else if("F" == type){
|
else if ("F" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
const week = ['일', '월', '화', '수', '목', '금', '토'];
|
const week = ['일', '월', '화', '수', '목', '금', '토'];
|
||||||
const dayOfWeek = week[new Date(dateArray[0], dateArray[1], dateArray[2]).getDay()];
|
const dayOfWeek = week[new Date(dateArray[0], dateArray[1], dateArray[2]).getDay()];
|
||||||
|
|
||||||
retureValue = dateArray[1]+"/"+dateArray[2]+"("+dayOfWeek+")";
|
retureValue = dateArray[1] + "/" + dateArray[2] + "(" + dayOfWeek + ")";
|
||||||
}
|
}
|
||||||
else if("G" == type){
|
else if ("G" == type) {
|
||||||
// 년.월.일(요일)
|
// 년.월.일(요일)
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
const week = ['일', '월', '화', '수', '목', '금', '토'];
|
const week = ['일', '월', '화', '수', '목', '금', '토'];
|
||||||
const dayOfWeek = week[new Date(dateArray[0], dateArray[1], dateArray[2]).getDay()];
|
const dayOfWeek = week[new Date(dateArray[0], dateArray[1], dateArray[2]).getDay()];
|
||||||
|
|
||||||
retureValue = dateArray[0].substring(0, 4)+"."+dateArray[1]+"."+dateArray[2]+"("+dayOfWeek+")";
|
retureValue = dateArray[0].substring(0, 4) + "." + dateArray[1] + "." + dateArray[2] + "(" + dayOfWeek + ")";
|
||||||
}
|
}
|
||||||
else if("H" == type){
|
else if ("H" == type) {
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
retureValue = dateArray[0].substr(2, 4)+dateArray[1]+dateArray[2];
|
retureValue = dateArray[0].substr(2, 4) + dateArray[1] + dateArray[2];
|
||||||
}
|
}
|
||||||
|
|
||||||
return retureValue;
|
return retureValue;
|
||||||
@@ -416,11 +416,11 @@ function setFormatDate(type, param) {
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 빈값 체크
|
* 빈값 체크
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_emptyCheck(param){
|
function fn_emptyCheck(param) {
|
||||||
if(param === null || param === "" || param === "null" || param === "NULL" || param === undefined || param === "undefined"){
|
if (param === null || param === "" || param === "null" || param === "NULL" || param === undefined || param === "undefined") {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -428,13 +428,13 @@ function fn_emptyCheck(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 길이 체크
|
* 길이 체크
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_lengthCheck(str, maxLength){
|
function fn_lengthCheck(str, maxLength) {
|
||||||
let strLength = str.length;
|
let strLength = str.length;
|
||||||
|
|
||||||
if(strLength > maxLength){
|
if (strLength > maxLength) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -442,26 +442,26 @@ function fn_lengthCheck(str, maxLength){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 날짜 체크
|
* 날짜 체크
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateCheck(value){
|
function fn_dateCheck(value) {
|
||||||
let strLength = value.length;
|
let strLength = value.length;
|
||||||
let cnt = 0;
|
let cnt = 0;
|
||||||
let searchChar = "-"; // 찾으려는 문자
|
let searchChar = "-"; // 찾으려는 문자
|
||||||
let pos = value.indexOf(searchChar); // pos는 0의 값을 가짐
|
let pos = value.indexOf(searchChar); // pos는 0의 값을 가짐
|
||||||
|
|
||||||
if(10 == strLength){
|
if (10 == strLength) {
|
||||||
while(-1 !== pos){
|
while (-1 !== pos) {
|
||||||
cnt++;
|
cnt++;
|
||||||
pos = value.indexOf(searchChar, pos + 1) // 첫 번째 - 이후의 인덱스부터 -를 찾음
|
pos = value.indexOf(searchChar, pos + 1) // 첫 번째 - 이후의 인덱스부터 -를 찾음
|
||||||
}
|
}
|
||||||
|
|
||||||
if(2 == cnt){
|
if (2 == cnt) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// let date = value.split("-");
|
// let date = value.split("-");
|
||||||
@@ -480,26 +480,26 @@ function fn_dateCheck(value){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 날짜 시간 체크
|
* 날짜 시간 체크
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_dateTimeCheck(value){
|
function fn_dateTimeCheck(value) {
|
||||||
let strLength = value.length;
|
let strLength = value.length;
|
||||||
let cnt = 0;
|
let cnt = 0;
|
||||||
let searchChar = "-"; // 찾으려는 문자
|
let searchChar = "-"; // 찾으려는 문자
|
||||||
let pos = value.indexOf(searchChar); // pos는 0의 값을 가짐
|
let pos = value.indexOf(searchChar); // pos는 0의 값을 가짐
|
||||||
|
|
||||||
if(10 == strLength){
|
if (10 == strLength) {
|
||||||
while(-1 !== pos){
|
while (-1 !== pos) {
|
||||||
cnt++;
|
cnt++;
|
||||||
pos = value.indexOf(searchChar, pos + 1) // 첫 번째 - 이후의 인덱스부터 -를 찾음
|
pos = value.indexOf(searchChar, pos + 1) // 첫 번째 - 이후의 인덱스부터 -를 찾음
|
||||||
}
|
}
|
||||||
|
|
||||||
if(2 == cnt){
|
if (2 == cnt) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -519,71 +519,71 @@ function fn_dateTimeCheck(value){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 첨부파일 최대 용량
|
* 첨부파일 최대 용량
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_maxFileSize(){
|
function fn_maxFileSize() {
|
||||||
return 52428800;
|
return 52428800;
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 첨부파일 최대 갯수 : 10
|
* 첨부파일 최대 갯수 : 10
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_maxFileCount(){
|
function fn_maxFileCount() {
|
||||||
return 10;
|
return 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 첨부파일 최대 갯수 : 5
|
* 첨부파일 최대 갯수 : 5
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_maxFileCount2(){
|
function fn_maxFileCount2() {
|
||||||
return 5;
|
return 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 약관 페이지 이동
|
* 약관 페이지 이동
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectPolicyIntro(param){
|
function fn_selectPolicyIntro(param) {
|
||||||
let pagingParam = '?policyType='+param;
|
let pagingParam = '?policyType=' + param;
|
||||||
|
|
||||||
fn_openPopup("/webpolicy/policyDetailIntro.do"+pagingParam);
|
fn_openPopup("/webpolicy/policyDetailIntro.do" + pagingParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 기본 프로필 사진 처리
|
* 기본 프로필 사진 처리
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setProfileUrlEmpty(param, widthParam, heightParam, index, className){
|
function fn_setProfileUrlEmpty(param, widthParam, heightParam, index, className) {
|
||||||
if(fn_emptyCheck(param)){
|
if (fn_emptyCheck(param)) {
|
||||||
if(widthParam<heightParam){
|
if (widthParam < heightParam) {
|
||||||
$("."+className+index).attr("src",param);
|
$("." + className + index).attr("src", param);
|
||||||
$("."+className+index).css("width","100%");
|
$("." + className + index).css("width", "100%");
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
$("."+className+index).attr("src",param);
|
$("." + className + index).attr("src", param);
|
||||||
$("."+className+index).css("height","100%");
|
$("." + className + index).css("height", "100%");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
$("."+className+index).attr("src","/image/web/profile-empty.svg");
|
$("." + className + index).attr("src", "/image/web/profile-empty.svg");
|
||||||
$("."+className+index).css("width","100%");
|
$("." + className + index).css("width", "100%");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 기본 프로필 사진 처리2
|
* 기본 프로필 사진 처리2
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setProfileUrlEmpty2(fileUrlParam,widthParam, heightParam){
|
function fn_setProfileUrlEmpty2(fileUrlParam, widthParam, heightParam) {
|
||||||
let object = new Object;
|
let object = new Object;
|
||||||
if(fn_emptyCheck(fileUrlParam)){
|
if (fn_emptyCheck(fileUrlParam)) {
|
||||||
//파일 경로가 있지만 가로가 더 작은 경우
|
//파일 경로가 있지만 가로가 더 작은 경우
|
||||||
if(parseInt(widthParam)<parseInt(heightParam)){
|
if (parseInt(widthParam) < parseInt(heightParam)) {
|
||||||
object.styleValue = 'width:100%;';
|
object.styleValue = 'width:100%;';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
//경로가 있지만 세로가 더 작은 경우
|
//경로가 있지만 세로가 더 작은 경우
|
||||||
object.styleValue = 'height:100%;';
|
object.styleValue = 'height:100%;';
|
||||||
}
|
}
|
||||||
|
|
||||||
object.urlValue = fileUrlParam;
|
object.urlValue = fileUrlParam;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
//파일 경로가 없는경우
|
//파일 경로가 없는경우
|
||||||
object.urlValue = '/image/web/profile-empty.svg';
|
object.urlValue = '/image/web/profile-empty.svg';
|
||||||
object.styleValue = 'width:100%;';
|
object.styleValue = 'width:100%;';
|
||||||
@@ -595,7 +595,7 @@ function fn_setProfileUrlEmpty2(fileUrlParam,widthParam, heightParam){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 기본 프로필 사진 경로만 있을경우
|
* 기본 프로필 사진 경로만 있을경우
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setProfileUrlSizeNone(fileUrlParam,profileIdParam,_callback){
|
function fn_setProfileUrlSizeNone(fileUrlParam, profileIdParam, _callback) {
|
||||||
let image = new Image();
|
let image = new Image();
|
||||||
image.src = fileUrlParam;
|
image.src = fileUrlParam;
|
||||||
|
|
||||||
@@ -604,31 +604,31 @@ function fn_setProfileUrlSizeNone(fileUrlParam,profileIdParam,_callback){
|
|||||||
|
|
||||||
let object = new Object;
|
let object = new Object;
|
||||||
|
|
||||||
if(!fn_emptyCheck(fileUrlParam)){
|
if (!fn_emptyCheck(fileUrlParam)) {
|
||||||
//파일 경로가 없는경우
|
//파일 경로가 없는경우
|
||||||
object.urlValue = '/image/web/profile-empty.svg';
|
object.urlValue = '/image/web/profile-empty.svg';
|
||||||
object.styleValue = 'width:100%;';
|
object.styleValue = 'width:100%;';
|
||||||
|
|
||||||
$("#"+profileIdParam).attr('src',object.urlValue).attr('style',object.styleValue);
|
$("#" + profileIdParam).attr('src', object.urlValue).attr('style', object.styleValue);
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
image.onload = function () {
|
image.onload = function () {
|
||||||
widthParam = image.width;
|
widthParam = image.width;
|
||||||
heightParam = image.height;
|
heightParam = image.height;
|
||||||
//_callback();
|
//_callback();
|
||||||
|
|
||||||
//파일 경로가 있지만 가로가 더 작은 경우
|
//파일 경로가 있지만 가로가 더 작은 경우
|
||||||
if(widthParam<heightParam){
|
if (widthParam < heightParam) {
|
||||||
object.styleValue = 'width:100%;';
|
object.styleValue = 'width:100%;';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
//경로가 있지만 세로가 더 작은 경우
|
//경로가 있지만 세로가 더 작은 경우
|
||||||
object.styleValue = 'height:100%;';
|
object.styleValue = 'height:100%;';
|
||||||
}
|
}
|
||||||
|
|
||||||
object.urlValue = fileUrlParam;
|
object.urlValue = fileUrlParam;
|
||||||
|
|
||||||
$("#"+profileIdParam).attr('src',object.urlValue).attr('style',object.styleValue);
|
$("#" + profileIdParam).attr('src', object.urlValue).attr('style', object.styleValue);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -638,29 +638,29 @@ function fn_setProfileUrlSizeNone(fileUrlParam,profileIdParam,_callback){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 디데이 구하기
|
* 디데이 구하기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setDday(param){
|
function fn_setDday(param) {
|
||||||
if(fn_emptyCheck(param)){
|
if (fn_emptyCheck(param)) {
|
||||||
const today = new Date();
|
const today = new Date();
|
||||||
|
|
||||||
let dateArray = param.split("-");
|
let dateArray = param.split("-");
|
||||||
const paramDay = new Date(dateArray[0], dateArray[1]-1, dateArray[2]);
|
const paramDay = new Date(dateArray[0], dateArray[1] - 1, dateArray[2]);
|
||||||
|
|
||||||
if(paramDay>today){
|
if (paramDay > today) {
|
||||||
const gapDay = paramDay.getTime() - today.getTime();
|
const gapDay = paramDay.getTime() - today.getTime();
|
||||||
|
|
||||||
const resultDate = Math.ceil(gapDay / (1000 * 60 * 60 * 24));
|
const resultDate = Math.ceil(gapDay / (1000 * 60 * 60 * 24));
|
||||||
|
|
||||||
return 'D-'+resultDate;
|
return 'D-' + resultDate;
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
const gapDay = today.getTime() - paramDay.getTime();
|
const gapDay = today.getTime() - paramDay.getTime();
|
||||||
|
|
||||||
const resultDate = Math.ceil(gapDay / (1000 * 60 * 60 * 24))-1;
|
const resultDate = Math.ceil(gapDay / (1000 * 60 * 60 * 24)) - 1;
|
||||||
|
|
||||||
if(0==resultDate){
|
if (0 == resultDate) {
|
||||||
return 'D-day';
|
return 'D-day';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -670,21 +670,21 @@ function fn_setDday(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* selectBox 선택 시 색상
|
* selectBox 선택 시 색상
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectColor(param){
|
function fn_selectColor(param) {
|
||||||
let selectValue = $(param).val();
|
let selectValue = $(param).val();
|
||||||
|
|
||||||
if(""!=selectValue){
|
if ("" != selectValue) {
|
||||||
$(param).css("color","#121212");
|
$(param).css("color", "#121212");
|
||||||
}else{
|
} else {
|
||||||
$(param).css("color","#969696");
|
$(param).css("color", "#969696");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 프로필 화면 이동
|
* 프로필 화면 이동
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_userProfileIntro(param){
|
function fn_userProfileIntro(param) {
|
||||||
location.href = "/webuserprofile/selectListUserProfileIntro.do?userName="+param;
|
location.href = "/webuserprofile/selectListUserProfileIntro.do?userName=" + param;
|
||||||
|
|
||||||
//fn_leftFormAction2("", "/webuserprofile/selectListUserProfileIntro.do?userName="+param+"&loginId="+param2);
|
//fn_leftFormAction2("", "/webuserprofile/selectListUserProfileIntro.do?userName="+param+"&loginId="+param2);
|
||||||
}
|
}
|
||||||
@@ -692,92 +692,92 @@ function fn_userProfileIntro(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색 화면 이동
|
* 검색 화면 이동
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_searchFeedIntro(param,param2){
|
function fn_searchFeedIntro(param, param2) {
|
||||||
fn_leftFormAction2(menuClass, "/websearch/selectListSearchIntro.do?searchText=#"+param+"&searchType="+param2);
|
fn_leftFormAction2(menuClass, "/websearch/selectListSearchIntro.do?searchText=#" + param + "&searchType=" + param2);
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 전화번호 형식 (가운데 마스킹 처리)
|
* 전화번호 형식 (가운데 마스킹 처리)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_setFormatPhoneNumber(param){
|
function fn_setFormatPhoneNumber(param) {
|
||||||
if(fn_emptyCheck(param)){
|
if (fn_emptyCheck(param)) {
|
||||||
return param
|
return param
|
||||||
.replace(/(\d{3})(\d{4})(\d{4})/, '$1-$2-$3')
|
.replace(/(\d{3})(\d{4})(\d{4})/, '$1-$2-$3')
|
||||||
.split('-')
|
.split('-')
|
||||||
.reduce((pre, cur, idx) => (idx === 1 ? pre + '****' : pre + cur), '');
|
.reduce((pre, cur, idx) => (idx === 1 ? pre + '****' : pre + cur), '');
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function modalCloseEvent(){
|
function modalCloseEvent() {
|
||||||
$(".loading-image-layer").hide();
|
$(".loading-image-layer").hide();
|
||||||
|
|
||||||
let modalCheck = false;
|
let modalCheck = false;
|
||||||
let modalArrLength = modalArr.length;
|
let modalArrLength = modalArr.length;
|
||||||
|
|
||||||
for(let i=0;i<modalArrLength;i++){
|
for (let i = 0; i < modalArrLength; i++) {
|
||||||
let modalName = modalArr[i];
|
let modalName = modalArr[i];
|
||||||
if(location.hash=='#'+modalName){
|
if (location.hash == '#' + modalName) {
|
||||||
modalCheck = true;
|
modalCheck = true;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(location.hash=='#'+modalArr[modalArr.length-1]){
|
if (location.hash == '#' + modalArr[modalArr.length - 1]) {
|
||||||
modalBackYn = 'N';
|
modalBackYn = 'N';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
let modalName = modalArr[modalArr.length-1];
|
let modalName = modalArr[modalArr.length - 1];
|
||||||
|
|
||||||
modalBackYn = 'Y';
|
modalBackYn = 'Y';
|
||||||
|
|
||||||
|
|
||||||
if("commonModal"==modalName && true==modalCheck){
|
if ("commonModal" == modalName && true == modalCheck) {
|
||||||
modalEvent.close();
|
modalEvent.close();
|
||||||
}
|
}
|
||||||
else if("jobPostingApplyPopup"==modalName && true==modalCheck){
|
else if ("jobPostingApplyPopup" == modalName && true == modalCheck) {
|
||||||
$("#jobPostingApplyPopup .modal-header img").click();
|
$("#jobPostingApplyPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("contentPopup"==modalName && true==modalCheck){
|
else if ("contentPopup" == modalName && true == modalCheck) {
|
||||||
$("#contentPopup .modal-header img").click();
|
$("#contentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("areaPopup"==modalName && true==modalCheck){
|
else if ("areaPopup" == modalName && true == modalCheck) {
|
||||||
$("#areaPopup .modal-header img").click();
|
$("#areaPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("jobPopup"==modalName && true==modalCheck){
|
else if ("jobPopup" == modalName && true == modalCheck) {
|
||||||
$("#jobPopup .modal-header img").click();
|
$("#jobPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("userFeedTagPopup"==modalName && true==modalCheck){
|
else if ("userFeedTagPopup" == modalName && true == modalCheck) {
|
||||||
$("#userFeedTagPopup .modal-header img").click();
|
$("#userFeedTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("feedCommentPopup"==modalName && true==modalCheck){
|
else if ("feedCommentPopup" == modalName && true == modalCheck) {
|
||||||
$("#feedCommentPopup .modal-header img").click();
|
$("#feedCommentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("branchPopup"==modalName && true==modalCheck){
|
else if ("branchPopup" == modalName && true == modalCheck) {
|
||||||
$("#branchPopup .modal-header img").click();
|
$("#branchPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("userTagPopup"==modalName && true==modalCheck){
|
else if ("userTagPopup" == modalName && true == modalCheck) {
|
||||||
$("#userTagPopup .modal-header img").click();
|
$("#userTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("feedAndCommentPopup"==modalName && true==modalCheck){
|
else if ("feedAndCommentPopup" == modalName && true == modalCheck) {
|
||||||
$("#feedAndCommentPopup .modal-header img").click();
|
$("#feedAndCommentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("branchSelectPopup"==modalName && true==modalCheck){
|
else if ("branchSelectPopup" == modalName && true == modalCheck) {
|
||||||
$("#branchSelectPopup .modal-header img").click();
|
$("#branchSelectPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("interestKeywordTagPopup"==modalName && true==modalCheck){
|
else if ("interestKeywordTagPopup" == modalName && true == modalCheck) {
|
||||||
$("#interestKeywordTagPopup .modal-header img").click();
|
$("#interestKeywordTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
//hash명이 정의되지않은 이름일시 팝업 전부 닫기
|
//hash명이 정의되지않은 이름일시 팝업 전부 닫기
|
||||||
|
|
||||||
let modalArrLength = modalArr.length;
|
let modalArrLength = modalArr.length;
|
||||||
|
|
||||||
for(let i=0;i<modalArrLength;i++){
|
for (let i = 0; i < modalArrLength; i++) {
|
||||||
fn_modalBackCloseEvent(modalArr[modalArr.length-1]);
|
fn_modalBackCloseEvent(modalArr[modalArr.length - 1]);
|
||||||
}
|
}
|
||||||
modalArr = new Array();
|
modalArr = new Array();
|
||||||
}
|
}
|
||||||
@@ -785,87 +785,87 @@ function modalCloseEvent(){
|
|||||||
|
|
||||||
const scrollPosition = pageYOffset;
|
const scrollPosition = pageYOffset;
|
||||||
|
|
||||||
if(0==modalArr.length){
|
if (0 == modalArr.length) {
|
||||||
//팝업이 다 닫혀있다면 새로고침 켜기
|
//팝업이 다 닫혀있다면 새로고침 켜기
|
||||||
window.scrollTo(0,scrollPosition+1);
|
window.scrollTo(0, scrollPosition + 1);
|
||||||
|
|
||||||
//setRefreshOn();
|
//setRefreshOn();
|
||||||
}else{
|
} else {
|
||||||
//팝업이 한개라도 열려있다면 새로고침 끄기
|
//팝업이 한개라도 열려있다면 새로고침 끄기
|
||||||
//setRefreshOff();
|
//setRefreshOff();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//모달 Array에 있는 이름으로 닫기
|
//모달 Array에 있는 이름으로 닫기
|
||||||
function fn_modalBackCloseEvent(modalNameParam){
|
function fn_modalBackCloseEvent(modalNameParam) {
|
||||||
if("commonModal"==modalNameParam){
|
if ("commonModal" == modalNameParam) {
|
||||||
modalEvent.close();
|
modalEvent.close();
|
||||||
}
|
}
|
||||||
else if("jobPostingApplyPopup"==modalNameParam){
|
else if ("jobPostingApplyPopup" == modalNameParam) {
|
||||||
$("#jobPostingApplyPopup .modal-header img").click();
|
$("#jobPostingApplyPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("contentPopup"==modalNameParam){
|
else if ("contentPopup" == modalNameParam) {
|
||||||
$("#contentPopup .modal-header img").click();
|
$("#contentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("areaPopup"==modalNameParam){
|
else if ("areaPopup" == modalNameParam) {
|
||||||
$("#areaPopup .modal-header img").click();
|
$("#areaPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("jobPopup"==modalNameParam){
|
else if ("jobPopup" == modalNameParam) {
|
||||||
$("#jobPopup .modal-header img").click();
|
$("#jobPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("userFeedTagPopup"==modalNameParam){
|
else if ("userFeedTagPopup" == modalNameParam) {
|
||||||
$("#userFeedTagPopup .modal-header img").click();
|
$("#userFeedTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("feedCommentPopup"==modalNameParam){
|
else if ("feedCommentPopup" == modalNameParam) {
|
||||||
$("#feedCommentPopup .modal-header img").click();
|
$("#feedCommentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("branchPopup"==modalNameParam){
|
else if ("branchPopup" == modalNameParam) {
|
||||||
$("#branchPopup .modal-header img").click();
|
$("#branchPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("userTagPopup"==modalNameParam){
|
else if ("userTagPopup" == modalNameParam) {
|
||||||
$("#userTagPopup .modal-header img").click();
|
$("#userTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("feedAndCommentPopup"==modalNameParam){
|
else if ("feedAndCommentPopup" == modalNameParam) {
|
||||||
$("#feedAndCommentPopup .modal-header img").click();
|
$("#feedAndCommentPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("branchSelectPopup"==modalNameParam){
|
else if ("branchSelectPopup" == modalNameParam) {
|
||||||
$("#branchSelectPopup .modal-header img").click();
|
$("#branchSelectPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
else if("interestKeywordTagPopup"==modalNameParam){
|
else if ("interestKeywordTagPopup" == modalNameParam) {
|
||||||
$("#interestKeywordTagPopup .modal-header img").click();
|
$("#interestKeywordTagPopup .modal-header img").click();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function checkMobile(){
|
function checkMobile() {
|
||||||
return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
|
return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 30분단위 시간값 셋팅
|
// 30분단위 시간값 셋팅
|
||||||
function fn_setTimeValue(target, defaultTime){
|
function fn_setTimeValue(target, defaultTime) {
|
||||||
let timeHTML = '';
|
let timeHTML = '';
|
||||||
|
|
||||||
for(let i = 0; i <= 23; i++){
|
for (let i = 0; i <= 23; i++) {
|
||||||
let hour = i;
|
let hour = i;
|
||||||
|
|
||||||
if(hour <10) hour = '0' + hour;
|
if (hour < 10) hour = '0' + hour;
|
||||||
|
|
||||||
if(i==0){
|
if (i == 0) {
|
||||||
timeHTML += '<li class="option_list_item first">'+hour+':00</li>';
|
timeHTML += '<li class="option_list_item first">' + hour + ':00</li>';
|
||||||
timeHTML += '<li class="option_list_item">'+hour+':30</li>';
|
timeHTML += '<li class="option_list_item">' + hour + ':30</li>';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
timeHTML += '<li class="option_list_item">'+hour+':00</li>';
|
timeHTML += '<li class="option_list_item">' + hour + ':00</li>';
|
||||||
timeHTML += '<li class="option_list_item">'+hour+':30</li>';
|
timeHTML += '<li class="option_list_item">' + hour + ':30</li>';
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
$('#'+target).empty().html(timeHTML);
|
$('#' + target).empty().html(timeHTML);
|
||||||
|
|
||||||
$('#'+target).siblings("button").text(defaultTime);
|
$('#' + target).siblings("button").text(defaultTime);
|
||||||
$('#'+target).siblings("input").val(defaultTime);
|
$('#' + target).siblings("input").val(defaultTime);
|
||||||
|
|
||||||
// 옵션 선택 이벤트
|
// 옵션 선택 이벤트
|
||||||
$('#'+target + '>.option_list_item').on('click', function() {
|
$('#' + target + '>.option_list_item').on('click', function () {
|
||||||
let selectedOption = $(this).text();
|
let selectedOption = $(this).text();
|
||||||
$(this).parent().siblings("button").text(selectedOption);
|
$(this).parent().siblings("button").text(selectedOption);
|
||||||
$(this).parent().siblings("input").val(selectedOption);
|
$(this).parent().siblings("input").val(selectedOption);
|
||||||
@@ -875,10 +875,10 @@ function fn_setTimeValue(target, defaultTime){
|
|||||||
|
|
||||||
|
|
||||||
// 공백처리
|
// 공백처리
|
||||||
function fn_formatNull(param){
|
function fn_formatNull(param) {
|
||||||
if(null==param){
|
if (null == param) {
|
||||||
return '';
|
return '';
|
||||||
}else{
|
} else {
|
||||||
return param;
|
return param;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
/* ##############################################################
|
/* ##############################################################
|
||||||
설 명 : [Modal]고객 검색 팝업
|
설 명 : [Modal]고객 검색 팝업
|
||||||
작성일 : 2025. 06. 24.
|
작성일 : 2025. 06. 24.
|
||||||
작성자 : NTsoft
|
작성자 : NTsoft
|
||||||
수정일 수정자 수정내용
|
수정일 수정자 수정내용
|
||||||
------- -------- ---------------------------
|
------- -------- ---------------------------
|
||||||
2024. 03. 14. NTsoft 최초 생성
|
2024. 03. 14. NTsoft 최초 생성
|
||||||
*/
|
*/
|
||||||
let treatmentSelectModal = {
|
let treatmentSelectModal = {
|
||||||
callback: null,
|
callback: null,
|
||||||
@@ -16,52 +16,62 @@ let treatmentSelectModal = {
|
|||||||
$('body').append(this.HtmlTemplate);
|
$('body').append(this.HtmlTemplate);
|
||||||
//그리드 이벤트
|
//그리드 이벤트
|
||||||
this.setEvent();
|
this.setEvent();
|
||||||
treatmentSelectModal.searchIntroUserList('Y');
|
treatmentSelectModal.searchIntroUserList('Y');
|
||||||
},
|
},
|
||||||
/* 그리드 이벤트 설정 */
|
/* 그리드 이벤트 설정 */
|
||||||
setEvent: function () {
|
setEvent: function () {
|
||||||
$('#treatmentSelectModal .btnCancle').on("click", function () {
|
$('#treatmentSelectModal .btnCancle').off('click').on("click", function () {
|
||||||
treatmentSelectModal.close();
|
treatmentSelectModal.close();
|
||||||
});
|
});
|
||||||
$('#treatmentSelectModal .btnSave').on("click", function () {
|
|
||||||
treatmentSelectModal.save();
|
// Remove existing listener to prevent duplicates if any
|
||||||
});
|
let searchBtn = document.getElementById("searchIntroUserBtn");
|
||||||
document.getElementById("searchIntroUserBtn").addEventListener('click',()=>{
|
if (searchBtn) {
|
||||||
treatmentSelectModal.searchIntroUserList('N');
|
let newSearchBtn = searchBtn.cloneNode(true);
|
||||||
});
|
searchBtn.parentNode.replaceChild(newSearchBtn, searchBtn);
|
||||||
document.getElementById("introUserSearchKeyword").addEventListener('keypress',(e)=>{
|
newSearchBtn.addEventListener('click', () => {
|
||||||
fn_IntroUserEnter(e)
|
treatmentSelectModal.searchIntroUserList('N');
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
let searchInput = document.getElementById("introUserSearchKeyword");
|
||||||
|
if (searchInput) {
|
||||||
|
let newSearchInput = searchInput.cloneNode(true);
|
||||||
|
searchInput.parentNode.replaceChild(newSearchInput, searchInput);
|
||||||
|
newSearchInput.addEventListener('keypress', (e) => {
|
||||||
|
fn_IntroUserEnter(e)
|
||||||
|
});
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
/* 데이터 선택 */
|
/* 데이터 선택 */
|
||||||
setSelect: function (selectNumber) {
|
setSelect: function (selectNumber) {
|
||||||
let checkedData = dataList[selectNumber];
|
let checkedData = dataList[selectNumber];
|
||||||
if(dataList==null||checkedData==undefined){
|
if (dataList == null || checkedData == undefined) {
|
||||||
return ;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( treatmentSelectModal.callback ) {
|
if (treatmentSelectModal.callback) {
|
||||||
treatmentSelectModal.callback(checkedData);
|
treatmentSelectModal.callback(checkedData);
|
||||||
}
|
}
|
||||||
treatmentSelectModal.close();
|
treatmentSelectModal.close();
|
||||||
},
|
},
|
||||||
//저장
|
//저장
|
||||||
save: function () {
|
save: function () {
|
||||||
|
|
||||||
},
|
},
|
||||||
searchIntroUserList:function (initflag){
|
searchIntroUserList: function (initflag) {
|
||||||
let searchKeyword = document.querySelector("#introUserSearchKeyword").value;
|
let searchKeyword = document.querySelector("#introUserSearchKeyword").value;
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
|
|
||||||
if(2 > searchKeyword.length && initflag == 'N'){
|
if (2 > searchKeyword.length && initflag == 'N') {
|
||||||
modalEvent.warning("", "검색어는 2자 이상으로 입력해 주시기 바랍니다.");
|
modalEvent.warning("", "검색어는 2자 이상으로 입력해 주시기 바랍니다.");
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("userSearchKeywordParam", searchKeyword??'');
|
formData.append("userSearchKeywordParam", searchKeyword ?? '');
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/webtreatmentdiet/selectListTreatmentOption.do'),
|
url: encodeURI('/webtreatmentdiet/selectListTreatmentOption.do'),
|
||||||
@@ -78,12 +88,14 @@ let treatmentSelectModal = {
|
|||||||
tbody.removeChild(tbody.firstChild);
|
tbody.removeChild(tbody.firstChild);
|
||||||
}
|
}
|
||||||
dataList = data.rows;
|
dataList = data.rows;
|
||||||
data.rows.forEach(function(treatment, index) {
|
data.rows.forEach(function (treatment, index) {
|
||||||
let tr = document.createElement('tr');
|
let tr = document.createElement('tr');
|
||||||
|
// Use style pointer to indicate clickable
|
||||||
|
tr.style.cursor = 'pointer';
|
||||||
tr.innerHTML = '<td id="' + treatment.treatmentId + '">' + treatment.treatmentNm + '</td>';
|
tr.innerHTML = '<td id="' + treatment.treatmentId + '">' + treatment.treatmentNm + '</td>';
|
||||||
tr.innerHTML += '<td id="' + treatment.price + '">' + treatment.price.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + '</td>';
|
tr.innerHTML += '<td id="' + treatment.price + '">' + treatment.price.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + '</td>';
|
||||||
tr.innerHTML += '<td id="' + treatment.discountPrice + '">' + treatment.discountPrice.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + '</td>';
|
tr.innerHTML += '<td id="' + treatment.discountPrice + '">' + treatment.discountPrice.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + '</td>';
|
||||||
tr.onclick = function() {
|
tr.onclick = function () {
|
||||||
treatmentSelectModal.setSelect(index);
|
treatmentSelectModal.setSelect(index);
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -127,11 +139,15 @@ let treatmentSelectModal = {
|
|||||||
close: function () {
|
close: function () {
|
||||||
$('#treatmentSelectModal').modal('hide');
|
$('#treatmentSelectModal').modal('hide');
|
||||||
|
|
||||||
setTimeout(function(){
|
setTimeout(function () {
|
||||||
$('#treatmentSelectModal').remove();
|
// Properly dispose of modal if using bootstrap 5 or just remove for simple usage
|
||||||
},500);
|
$('#treatmentSelectModal').remove();
|
||||||
|
$('.modal-backdrop').remove(); // Ensure backdrop is removed
|
||||||
|
$('body').removeClass('modal-open');
|
||||||
|
$('body').css('padding-right', '');
|
||||||
|
}, 500);
|
||||||
},
|
},
|
||||||
HtmlTemplate : `
|
HtmlTemplate: `
|
||||||
<div id="treatmentSelectModal" class="modal list1_diagnosis fade" tabIndex="-1"
|
<div id="treatmentSelectModal" class="modal list1_diagnosis fade" tabIndex="-1"
|
||||||
aria-labelledby="exampleModalLabel"
|
aria-labelledby="exampleModalLabel"
|
||||||
aria-hidden="">
|
aria-hidden="">
|
||||||
@@ -177,35 +193,35 @@ let treatmentSelectModal = {
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색 엔터 이벤트
|
* 검색 엔터 이벤트
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_IntroUserEnter(e){
|
function fn_IntroUserEnter(e) {
|
||||||
if(e.which){
|
if (e.which) {
|
||||||
// 파이어폭스
|
// 파이어폭스
|
||||||
if(13 == e.which) {
|
if (13 == e.which) {
|
||||||
//로그인 액션 스크립트
|
//로그인 액션 스크립트
|
||||||
treatmentSelectModal.searchIntroUserList();
|
treatmentSelectModal.searchIntroUserList();
|
||||||
}
|
}
|
||||||
}else{
|
} else {
|
||||||
// 윈도우, 사파리, 크롬
|
// 윈도우, 사파리, 크롬
|
||||||
if(13 == event.keyCode) {
|
if (13 == event.keyCode) {
|
||||||
//로그인 액션 스크립트
|
//로그인 액션 스크립트
|
||||||
treatmentSelectModal.searchIntroUserList();
|
treatmentSelectModal.searchIntroUserList();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
function convertDateFormat(input) {
|
function convertDateFormat(input) {
|
||||||
if(input){
|
if (input) {
|
||||||
const datePart = input.match(/\d{4}-\d{2}-\d{2}/)[0];
|
const datePart = input.match(/\d{4}-\d{2}-\d{2}/)[0];
|
||||||
|
|
||||||
const date = new Date(datePart);
|
const date = new Date(datePart);
|
||||||
|
|
||||||
const year = date.getFullYear();
|
const year = date.getFullYear();
|
||||||
const month = ('0' + (date.getMonth() + 1)).slice(-2);
|
const month = ('0' + (date.getMonth() + 1)).slice(-2);
|
||||||
const day = ('0' + date.getDate()).slice(-2);
|
const day = ('0' + date.getDate()).slice(-2);
|
||||||
|
|
||||||
return `${year}.${month}.${day}`;
|
return `${year}.${month}.${day}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,40 +1,72 @@
|
|||||||
|
// Custom Table Logic
|
||||||
|
let treatmentList = [];
|
||||||
|
|
||||||
|
function renderTreatmentTable() {
|
||||||
|
let tbody = document.getElementById("treatmentListBody");
|
||||||
|
if (!tbody) {
|
||||||
|
// If the tbody doesn't exist (e.g., on a page without the table), do nothing.
|
||||||
|
// This can happen if this JS is included on multiple pages.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
tbody.innerHTML = "";
|
||||||
|
|
||||||
|
treatmentList.forEach((item, index) => {
|
||||||
|
let row = document.createElement("tr");
|
||||||
|
row.innerHTML = `
|
||||||
|
<td><input type="checkbox" name="treatmentCheck" value="${index}"></td>
|
||||||
|
<td style="text-align:left; padding-left:10px;">${item.treatmentProcedureName}</td>
|
||||||
|
<td style="text-align:right;">${num2won(item.price)}</td>
|
||||||
|
<td style="text-align:right;">${num2won(item.discountPrice)}</td>
|
||||||
|
`;
|
||||||
|
tbody.appendChild(row);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_checkAll(source) {
|
||||||
|
let checkboxes = document.getElementsByName('treatmentCheck');
|
||||||
|
for (var i = 0, n = checkboxes.length; i < n; i++) {
|
||||||
|
checkboxes[i].checked = source.checked;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function num2won(x) {
|
||||||
|
if (typeof x === 'undefined' || x === null) return '';
|
||||||
|
return x.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
|
||||||
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 이벤트 등록
|
* 이벤트 등록
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_insertWebEvent(){
|
function fn_insertWebEvent() {
|
||||||
if("Y"!=insertUseYn){
|
if ("Y" != insertUseYn) {
|
||||||
modalEvent.warning("", "등록 권한이 없습니다.");
|
modalEvent.warning("", "등록 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
let title = $("#title").val();
|
let title = $("#title").val();
|
||||||
let content = $("#content").val();
|
let content = $("#content").val();
|
||||||
let hashtag = $("#hashtag").val();
|
let hashtag = $("#hashtag").val();
|
||||||
let thumbnail_bottom_txt = $("#thumbnail-bottom-txt").val();
|
let thumbnail_bottom_txt = $("#thumbnailBottomTxt").val();
|
||||||
let categoryNo = $("select[name=categorylist]").val();
|
let categoryNo = $("select[name=category]").val();
|
||||||
|
|
||||||
var treatmentlen = $("input[name=treatmentlist]").length;
|
var treatmentIdList = []; // muTreatmentId
|
||||||
var treatmentlist = new Array(treatmentlen);
|
var treatmentProcedureIdList = []; // muTreatmentProcedureId
|
||||||
for(var i=0; i<treatmentlen; i++){
|
|
||||||
treatmentlist[i] = $("input[name=treatmentlist]").eq(i).val();
|
|
||||||
}
|
|
||||||
|
|
||||||
var treatmentprocedurelen = $("input[name=treatmentprocedurelist]").length;
|
treatmentList.forEach(item => {
|
||||||
var treatmentprocedurelist = new Array(treatmentprocedurelen);
|
treatmentIdList.push(item.muTreatmentId);
|
||||||
for(var i=0; i<treatmentprocedurelen; i++){
|
treatmentProcedureIdList.push(item.muTreatmentProcedureId);
|
||||||
treatmentprocedurelist[i] = $("input[name=treatmentprocedurelist]").eq(i).val();
|
});
|
||||||
}
|
|
||||||
|
|
||||||
//let eventStartDate = $("#eventStartDate").val();
|
let eventStartDt = $("#eventStartDt").val();
|
||||||
//let eventEndDate = $("#eventEndDate").val();
|
let eventEndDt = $("#eventEndDt").val();
|
||||||
let file = $("#file")[0].files[0];
|
let file = $("#file")[0].files[0];
|
||||||
let content_file = $("#content_file")[0].files[0];
|
let content_file = $("#content_file")[0].files[0];
|
||||||
|
|
||||||
if(true != fn_emptyCheck(categoryNo)) {
|
if (true != fn_emptyCheck(categoryNo)) {
|
||||||
modalEvent.warning("등록", "카테고리를 입력하세요.");
|
modalEvent.warning("등록", "카테고리를 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(true != fn_emptyCheck(title)) {
|
if (true != fn_emptyCheck(title)) {
|
||||||
modalEvent.warning("등록", "제목을 입력하세요.");
|
modalEvent.warning("등록", "제목을 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -43,11 +75,11 @@ function fn_insertWebEvent(){
|
|||||||
modalEvent.warning("등록", "내용을 입력하세요.");
|
modalEvent.warning("등록", "내용을 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(true != fn_emptyCheck(hashtag)) {
|
if(true != fn_emptyCheck(hashtag)) {
|
||||||
modalEvent.warning("등록", "해시태그를 입력하세요.");
|
modalEvent.warning("등록", "해시태그를 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(true != fn_emptyCheck(thumbnail_bottom_txt)) {
|
if(true != fn_emptyCheck(thumbnail_bottom_txt)) {
|
||||||
modalEvent.warning("등록", "썸네일 하단 내용을 입력하세요.");
|
modalEvent.warning("등록", "썸네일 하단 내용을 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -65,35 +97,37 @@ function fn_insertWebEvent(){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(true != fn_emptyCheck(content_file)) {
|
if(true != fn_emptyCheck(content_file)) {
|
||||||
modalEvent.warning("등록", "컨텐츠 이미지가 첨부되지 않았습니다.");
|
modalEvent.warning("등록", "컨텐츠 이미지가 첨부되지 않았습니다.");
|
||||||
return;
|
return;
|
||||||
}else{
|
}else{
|
||||||
for(let i=0; i<content_file.length; i++){
|
for(let i=0; i<content_file.length; i++){
|
||||||
let fileSize = content_file[i].size;
|
let fileSize = content_file[i].size;
|
||||||
if(fileSize > fn_maxFileSize()){
|
if(fileSize > fn_maxFileSize()){
|
||||||
modalEvent.warning("", "파일정보 용량이 50MB를 넘습니다. 업로드가 불가능합니다.");
|
modalEvent.warning("", "파일정보 용량이 50MB를 넘습니다. 업로드가 불가능합니다.");
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
modalEvent.info("등록", categorytitle + " 정보를 등록하시겠습니까?", function(){
|
modalEvent.info("등록", categorytitle + " 정보를 등록하시겠습니까?", function () {
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("categoryDivCd", categoryDivCd);
|
formData.append("categoryDivCd", categoryDivCd);
|
||||||
formData.append("categoryNo", categoryNo);
|
formData.append("categoryNo", categoryNo);
|
||||||
formData.append("title", title);
|
formData.append("title", title);
|
||||||
formData.append("content", content);
|
formData.append("content", content);
|
||||||
formData.append("hashtag", hashtag);
|
formData.append("hashtag", hashtag);
|
||||||
formData.append("thumbnail_bottom_txt", thumbnail_bottom_txt);
|
formData.append("thumbnail_bottom_txt", thumbnail_bottom_txt);
|
||||||
formData.append("file", file);
|
formData.append("file", file);
|
||||||
formData.append("content_file", content_file);
|
formData.append("content_file", content_file);
|
||||||
formData.append("treatmentlist", treatmentlist);
|
formData.append("treatmentlist", treatmentIdList);
|
||||||
formData.append("treatmentprocedurelist", treatmentprocedurelist);
|
formData.append("treatmentprocedurelist", treatmentProcedureIdList);
|
||||||
formData.append("oldCrmItemId", $("#oldCrmItemId").val());
|
formData.append("oldCrmItemId", $("#oldCrmItemId").val());
|
||||||
formData.append("ordNo", $("#ordNo").val());
|
formData.append("ordNo", $("#ordNo").val());
|
||||||
|
formData.append("eventStartDt", eventStartDt);
|
||||||
|
formData.append("eventEndDt", eventEndDt);
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/contentsBbs/putContentsBbs.do'),
|
url: encodeURI('/contentsBbs/putContentsBbs.do'),
|
||||||
@@ -103,128 +137,87 @@ function fn_insertWebEvent(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
modalEvent.success("등록 성공", data.msgDesc, function(){
|
modalEvent.success("등록 성공", data.msgDesc, function () {
|
||||||
fn_selectListWebTreatmentPetitIntro();
|
fn_selectListWebTreatmentPetitIntro();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("등록 오류", data.msgDesc);
|
modalEvent.danger("등록 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("등록 오류", "등록 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("등록 오류", "등록 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
|
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* html 에디터 이미지 업로드시
|
* 배너 이미지 미리보기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function uploadSummernoteImageFileNoticeInsert(files, editor){
|
function fn_filePreview(width, height, obj) {
|
||||||
Object.values(files).forEach(file => {
|
let file = "";
|
||||||
let formData = new FormData();
|
if (obj == '.img_box') {
|
||||||
formData.append('menuClass', menuClass);
|
file = $("#file")[0].files[0];
|
||||||
formData.append('file', file);
|
} else {
|
||||||
$.ajax({
|
file = $("#content_file")[0].files[0];
|
||||||
url: encodeURI('/webtreatmentpetit/uploadFile.do'),
|
}
|
||||||
data: formData,
|
|
||||||
dataType: "json",
|
if (file) {
|
||||||
processData: false,
|
// 기존 이미지 제거 대신 src 교체를 위해 구조 변경됨
|
||||||
contentType: false,
|
// 하지만 ContentsBbsUpd와 구조를 맞췄으므로 img 태그 id를 이용하는 것이 좋음
|
||||||
type: 'POST',
|
const reader = new FileReader();
|
||||||
async: true,
|
reader.onload = function (e) {
|
||||||
success: function (data) {
|
if (obj == '.img_box') {
|
||||||
if ('0' == data.msgCode) {
|
$("#thumbnailImg").attr("src", e.target.result).show();
|
||||||
$(editor).summernote('insertImage', data.rows.filePath, function ($image) {
|
} else {
|
||||||
});
|
$("#contentsImg").attr("src", e.target.result).show();
|
||||||
}
|
|
||||||
},
|
|
||||||
error: function (xhr, status, error) {
|
|
||||||
modalEvent.danger('오류', '이미지 업로드 중 오류가 발생했습니다.');
|
|
||||||
},
|
|
||||||
beforeSend: function () {
|
|
||||||
// 로딩열기
|
|
||||||
$(".loading-image-layer").show();
|
|
||||||
},
|
|
||||||
complete: function () {
|
|
||||||
// 로딩닫기
|
|
||||||
$(".loading-image-layer").hide();
|
|
||||||
}
|
}
|
||||||
});
|
};
|
||||||
})
|
reader.readAsDataURL(file);
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* 배너 이미지 미리보기
|
|
||||||
****************************************************************************/
|
|
||||||
function fn_filePreview(width, height, obj){
|
|
||||||
let file = "";
|
|
||||||
if(obj == '.img_box'){
|
|
||||||
file = $("#file")[0].files[0];
|
|
||||||
} else {
|
|
||||||
file = $("#content_file")[0].files[0];
|
|
||||||
}
|
|
||||||
|
|
||||||
if(file){
|
|
||||||
$(obj).html('');
|
|
||||||
const reader = new FileReader();
|
|
||||||
|
|
||||||
reader.onload = function (e) {
|
|
||||||
// 이미지 요소를 생성하고 미리보기 추가
|
|
||||||
const img = document.createElement('img');
|
|
||||||
img.src = e.target.result;
|
|
||||||
img.style.width = width; // 원하는 크기로 조정
|
|
||||||
img.style.height = height;
|
|
||||||
$(obj).append(img);
|
|
||||||
};
|
|
||||||
|
|
||||||
// 파일을 읽기 시작
|
|
||||||
reader.readAsDataURL(file);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 삭제
|
* 배너 이미지 삭제
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_removePreview(){
|
function fn_removePreview() {
|
||||||
$("#file").val('');
|
$("#file").val('');
|
||||||
$('.img_box').html('');
|
$("#thumbnailImg").attr("src", "").hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 미리보기
|
* 배너 이미지 미리보기 (컨텐츠) - Unified in fn_filePreview logic mostly but kept callback
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_fileContentPreview(){
|
// fn_filePreview handles logic based on obj param
|
||||||
const file = $("#content_file")[0].files[0];
|
|
||||||
if(file){
|
|
||||||
$('.file_box').html(file.name);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 삭제
|
* 배너 이미지 삭제 (컨텐츠)
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_removeContentPreview(){
|
function fn_removeContentPreview() {
|
||||||
$("#content_file").val('');
|
$("#content_file").val('');
|
||||||
$('.file_box').html('');
|
$("#contentsImg").attr("src", "").hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 리스트 화면으로 이동.
|
* 리스트 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectListWebTreatmentPetitIntro(){
|
function fn_selectListWebTreatmentPetitIntro() {
|
||||||
if("Y"==selectUseYn){
|
if ("Y" == selectUseYn) {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
fn_leftFormAction("/contentsBbs/moveContentsBbsList.do"+pagingParam);
|
pagingParam += "&categoryDivCd=" + categoryDivCd;
|
||||||
}else{
|
fn_leftFormAction("/contentsBbs/moveContentsBbsList.do" + pagingParam);
|
||||||
|
} else {
|
||||||
modalEvent.warning("", "조회 권한이 없습니다.");
|
modalEvent.warning("", "조회 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -233,42 +226,54 @@ function fn_selectListWebTreatmentPetitIntro(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 init
|
* 페이지 init
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageInit(){
|
function fn_pageInit() {
|
||||||
// 날짜 datepicker
|
// 날짜 datepicker (jQuery UI)
|
||||||
fn_searchDatePicker("#eventStartDate", "#eventEndDate");
|
$("#eventStartDt, #eventEndDt").datepicker({
|
||||||
|
dateFormat: 'yy-mm-dd',
|
||||||
$('#summernote').summernote({
|
prevText: '이전 달',
|
||||||
height: 540,
|
nextText: '다음 달',
|
||||||
callbacks: { //여기 부분이 이미지를 첨부하는 부분
|
monthNames: ['1월', '2월', '3월', '4월', '5월', '6월', '7월', '8월', '9월', '10월', '11월', '12월'],
|
||||||
onImageUpload : function(files) {
|
monthNamesShort: ['1월', '2월', '3월', '4월', '5월', '6월', '7월', '8월', '9월', '10월', '11월', '12월'],
|
||||||
uploadSummernoteImageFileNoticeInsert(files, this);
|
dayNames: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
}
|
dayNamesShort: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
},
|
dayNamesMin: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
|
showMonthAfterYear: true,
|
||||||
|
yearSuffix: '년',
|
||||||
|
changeMonth: true,
|
||||||
|
changeYear: true
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// 시작일 오늘 날짜 세팅
|
||||||
|
$("#eventStartDt").datepicker("setDate", new Date());
|
||||||
|
|
||||||
|
if (categoryDivCd === '02' || categoryDivCd === '04') {
|
||||||
|
$("#dateSelectionRow").show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 event
|
* 페이지 event
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageEvent(){
|
function fn_pageEvent() {
|
||||||
// 검색 input
|
// 검색 input
|
||||||
$('.btnCancle').on("click", function(){
|
$('.btnCancle').on("click", function () {
|
||||||
fn_selectListWebTreatmentPetitIntro();
|
fn_selectListWebTreatmentPetitIntro();
|
||||||
});
|
});
|
||||||
|
|
||||||
$('.btnSave').on("click", function(){
|
$('.btnSave').on("click", function () {
|
||||||
fn_insertWebEvent();
|
fn_insertWebEvent();
|
||||||
});
|
});
|
||||||
$('#delete_btn').on("click", function(){
|
$('#delete_btn').on("click", function () {
|
||||||
fn_removePreview();
|
fn_removePreview();
|
||||||
});
|
});
|
||||||
$('#file').on('change', function(e) {
|
$('#file').on('change', function (e) {
|
||||||
|
// Updated selector logic for new structure
|
||||||
fn_filePreview('800px', '450px', '.img_box');
|
fn_filePreview('800px', '450px', '.img_box');
|
||||||
})
|
})
|
||||||
$('#content_delete_btn').on("click", function(){
|
$('#content_delete_btn').on("click", function () {
|
||||||
fn_removeContentPreview();
|
fn_removeContentPreview();
|
||||||
});
|
});
|
||||||
$('#content_file').on('change', function(e) {
|
$('#content_file').on('change', function (e) {
|
||||||
fn_filePreview('100%', '100%', '.file_box');
|
fn_filePreview('100%', '100%', '.file_box');
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -276,37 +281,85 @@ function fn_pageEvent(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 시술 목록 팝업
|
* 시술 목록 팝업
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function listOpen(){
|
function listOpen() {
|
||||||
let reqParam = {};
|
let reqParam = {};
|
||||||
treatmentSelectModal.popup(function (obj, reqParam) {
|
treatmentSelectModal.popup(function (obj, reqParam) {
|
||||||
const childDivCount = $("#treatmentlist > div").length;
|
|
||||||
if($("#" + obj.treatmentProcedureId).length > 0){
|
let isDuplicate = false;
|
||||||
modalEvent.warning("", "이미 시술정보가 있습니다.");
|
treatmentList.forEach((item) => {
|
||||||
return;
|
if (item.muTreatmentProcedureId == obj.treatmentProcedureId) {
|
||||||
}
|
isDuplicate = true;
|
||||||
var htmlstring = `<div id="treatment`+childDivCount+`">
|
}
|
||||||
<input type="checkbox" id="`+obj.treatmentProcedureId+`" name="treatment">
|
});
|
||||||
<input type="hidden" name="treatmentprocedurelist" value="`+obj.treatmentProcedureId+`">
|
|
||||||
<input type="hidden" name="treatmentlist" value="`+obj.treatmentId+`">
|
if (isDuplicate) {
|
||||||
<label for="`+obj.treatmentProcedureId+`">`+obj.treatmentNm + `-` + obj.price.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + `-` + obj.discountPrice.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") +`</label>
|
modalEvent.warning("", "이미 시술정보가 있습니다.");
|
||||||
</div>`;
|
return;
|
||||||
$('#treatmentlist').append(htmlstring);
|
}
|
||||||
|
|
||||||
|
let newItem = {
|
||||||
|
treatmentProcedureName: obj.treatmentNm,
|
||||||
|
price: obj.price,
|
||||||
|
discountPrice: obj.discountPrice,
|
||||||
|
muTreatmentId: obj.treatmentId,
|
||||||
|
muTreatmentProcedureId: obj.treatmentProcedureId
|
||||||
|
};
|
||||||
|
treatmentList.push(newItem);
|
||||||
|
renderTreatmentTable();
|
||||||
|
|
||||||
}, reqParam);
|
}, reqParam);
|
||||||
}
|
}
|
||||||
function fn_removeRow(){
|
|
||||||
$('input:checkbox[name="treatment"]').each(function() {
|
|
||||||
if(this.checked){//checked 처리된 항목의 값
|
|
||||||
$(this).parent().remove();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
|
function fn_removeRow() {
|
||||||
|
let checkboxes = document.getElementsByName('treatmentCheck');
|
||||||
|
let indicesToRemove = [];
|
||||||
|
|
||||||
|
// Collect indices checking from end to start to maintain index validity
|
||||||
|
for (let i = checkboxes.length - 1; i >= 0; i--) {
|
||||||
|
if (checkboxes[i].checked) {
|
||||||
|
indicesToRemove.push(parseInt(checkboxes[i].value));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (indicesToRemove.length === 0) {
|
||||||
|
modalEvent.warning("", "삭제할 항목을 선택해주세요.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Remove items
|
||||||
|
indicesToRemove.forEach(index => {
|
||||||
|
treatmentList.splice(index, 1);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Uncheck "all" checkbox if checked
|
||||||
|
let checkAllCheckbox = document.getElementById("checkAll");
|
||||||
|
if (checkAllCheckbox) {
|
||||||
|
checkAllCheckbox.checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
renderTreatmentTable();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$(function(){
|
$(function () {
|
||||||
// 페이지 init
|
// 페이지 init
|
||||||
fn_pageInit();
|
fn_pageInit();
|
||||||
|
|
||||||
// 페이지 event
|
// 페이지 event
|
||||||
fn_pageEvent();
|
fn_pageEvent();
|
||||||
|
|
||||||
|
// Initial render for empty table
|
||||||
|
renderTreatmentTable();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
/* =========================================
|
||||||
|
PREVIEW LOGIC
|
||||||
|
========================================= */
|
||||||
|
function fn_openPreview() {
|
||||||
|
let url = "/contentsBbs/contentsBbsPreview.do";
|
||||||
|
window.open(url, "preview", "width=1280,height=900,scrollbars=yes");
|
||||||
|
}
|
||||||
|
|
||||||
|
function getTreatmentListForPreview() {
|
||||||
|
return treatmentList;
|
||||||
|
}
|
||||||
@@ -1,213 +1,25 @@
|
|||||||
/* 페이징 관련 변수 */
|
/* 페이징 관련 변수 */
|
||||||
let webTreatmentPetitTotalCount = 0;
|
let webTreatmentPetitTotalCount = 0;
|
||||||
let webTreatmentPetitTotalPages = 0;
|
let webTreatmentPetitTotalPages = 0;
|
||||||
|
|
||||||
/*aggird*/
|
/*aggird*/
|
||||||
let webTreatmentPetitAgGridData = [];
|
let webTreatmentPetitAgGridData = [];
|
||||||
|
|
||||||
let delList = [];
|
let delList = [];
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* 검색 날짜 설정
|
|
||||||
//(A:오늘, B:3일, C:7일, D:최근30일, E:최근90일, F:이번달, G:올해, H:지난주, I:지난달)
|
|
||||||
****************************************************************************/
|
|
||||||
function fn_webTreatmentPetitSetDate(param){
|
|
||||||
if("A"==param){
|
|
||||||
// 오늘
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-'+month+'-'+day;
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
}
|
|
||||||
else if("B"==param){
|
|
||||||
// 3일
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
toDate.setDate(toDate.getDate() - 3);
|
|
||||||
year = toDate.getFullYear();
|
|
||||||
month = toDate.getMonth() + 1;
|
|
||||||
day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-'+month+'-'+day;
|
|
||||||
}
|
|
||||||
else if("C"==param){
|
|
||||||
// 이번주
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
toDate.setDate(toDate.getDate() - 7);
|
|
||||||
year = toDate.getFullYear();
|
|
||||||
month = toDate.getMonth() + 1;
|
|
||||||
day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-'+month+'-'+day;
|
|
||||||
}
|
|
||||||
else if("D"==param){
|
|
||||||
// 최근30일
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
//최근30일
|
|
||||||
toDate.setDate(toDate.getDate() - 30);
|
|
||||||
startYear = toDate.getFullYear();
|
|
||||||
startMonth = toDate.getMonth() + 1;
|
|
||||||
startDay = toDate.getDate();
|
|
||||||
|
|
||||||
if(startMonth < 10) startMonth = "0" + startMonth;
|
|
||||||
if(startDay < 10) startDay = "0" + startDay;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchStartDate = startYear+'-'+startMonth+'-'+startDay;
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
}
|
|
||||||
else if("E"==param){
|
|
||||||
// 최근90일
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
toDate.setDate(toDate.getDate() - 90);
|
|
||||||
year = toDate.getFullYear();
|
|
||||||
month = toDate.getMonth() + 1;
|
|
||||||
day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-'+month+'-'+day;
|
|
||||||
}
|
|
||||||
else if("F"==param){
|
|
||||||
//F:이번달
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-'+month+'-01';
|
|
||||||
}
|
|
||||||
else if("G"==param){
|
|
||||||
// G:올해
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-01-01';
|
|
||||||
}
|
|
||||||
else if("H"==param){
|
|
||||||
// H:지난주, I:지난달
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-01-01';
|
|
||||||
}
|
|
||||||
else if("I"==param){
|
|
||||||
// I:지난달
|
|
||||||
// 검색 종료일자
|
|
||||||
let toDate = new Date();
|
|
||||||
let year = toDate.getFullYear();
|
|
||||||
let month = toDate.getMonth() + 1;
|
|
||||||
let day = toDate.getDate();
|
|
||||||
|
|
||||||
if(month < 10) month = "0" + month;
|
|
||||||
if(day < 10) day = "0" + day;
|
|
||||||
|
|
||||||
webTreatmentPetitSearchEndDate = year+'-'+month+'-'+day;
|
|
||||||
|
|
||||||
// 검색 시작일자
|
|
||||||
webTreatmentPetitSearchStartDate = year+'-01-01';
|
|
||||||
}
|
|
||||||
|
|
||||||
$("#webTreatmentPetitSearchStartDate").val(webTreatmentPetitSearchStartDate).trigger("change");
|
|
||||||
$("#webTreatmentPetitSearchEndDate").val(webTreatmentPetitSearchEndDate).trigger("change");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 이벤트 정보 리스트 조회
|
* 이벤트 정보 리스트 조회
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectListWebTreatmentPetitJson(){
|
function fn_selectListWebTreatmentPetitJson() {
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("categoryDivCd", categoryDivCd);
|
formData.append("categoryDivCd", categoryDivCd);
|
||||||
formData.append("webTreatmentPetitSearchKeywordParam0", webTreatmentPetitSearchKeywordParam0);
|
formData.append("searchCategoryNo", webTreatmentPetitSearchKeywordParam0);
|
||||||
formData.append("webTreatmentPetitSearchKeywordParam1", webTreatmentPetitSearchKeywordParam1);
|
formData.append("title", webTreatmentPetitSearchKeywordParam1);
|
||||||
formData.append("webTreatmentPetitSearchKeywordParam2", webTreatmentPetitSearchKeywordParam2);
|
|
||||||
formData.append("webTreatmentPetitSearchKeywordParam3", webTreatmentPetitSearchKeywordParam3);
|
|
||||||
formData.append("webTreatmentPetitSort", webTreatmentPetitSort);
|
formData.append("webTreatmentPetitSort", webTreatmentPetitSort);
|
||||||
formData.append("webTreatmentPetitDir", webTreatmentPetitDir);
|
formData.append("webTreatmentPetitDir", webTreatmentPetitDir);
|
||||||
formData.append("webTreatmentPetitStart", webTreatmentPetitStart);
|
formData.append("webTreatmentPetitStart", webTreatmentPetitStart);
|
||||||
formData.append("webTreatmentPetitLimit", webTreatmentPetitLimit);
|
formData.append("webTreatmentPetitLimit", webTreatmentPetitLimit);
|
||||||
formData.append("webTreatmentPetitSearchStartDate", webTreatmentPetitSearchStartDate);
|
|
||||||
formData.append("webTreatmentPetitSearchEndDate", webTreatmentPetitSearchEndDate);
|
|
||||||
formData.append("webTreatmentPetitSearchDateType", webTreatmentPetitSearchDateType);
|
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/contentsBbs/getContentsBbsList.do'),
|
url: encodeURI('/contentsBbs/getContentsBbsList.do'),
|
||||||
@@ -217,52 +29,47 @@ function fn_selectListWebTreatmentPetitJson(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
// 페이징 처리
|
// 페이징 처리
|
||||||
webTreatmentPetitTotalCount = data.totalCount;
|
webTreatmentPetitTotalCount = data.totalCount;
|
||||||
//$("#txt_noticeTotalCount").text(noticeTotalCount);
|
|
||||||
|
|
||||||
webTreatmentPetitTotalPages = Math.ceil(webTreatmentPetitTotalCount/webTreatmentPetitLimit);
|
webTreatmentPetitTotalPages = Math.ceil(webTreatmentPetitTotalCount / webTreatmentPetitLimit);
|
||||||
|
|
||||||
// 리스트 조회
|
// 리스트 조회
|
||||||
webTreatmentPetitAgGridData = data.rows;
|
webTreatmentPetitAgGridData = data.rows;
|
||||||
webTreatmentPetitGridOptions.api.setRowData(webTreatmentPetitAgGridData);
|
webTreatmentPetitGridOptions.api.setRowData(webTreatmentPetitAgGridData);
|
||||||
|
|
||||||
if(0<data.rows.length){
|
if (0 < data.rows.length) {
|
||||||
//페이징 처리
|
//페이징 처리
|
||||||
window.pagObj = $('#webTreatmentPetitPagination').twbsPagination({
|
window.pagObj = $('#webTreatmentPetitPagination').twbsPagination({
|
||||||
startPage : ((webTreatmentPetitStart/webTreatmentPetitLimit)+1),
|
startPage: ((webTreatmentPetitStart / webTreatmentPetitLimit) + 1),
|
||||||
totalPages : (webTreatmentPetitTotalPages==0)?1:webTreatmentPetitTotalPages,
|
totalPages: (webTreatmentPetitTotalPages == 0) ? 1 : webTreatmentPetitTotalPages,
|
||||||
visiblePages : 10,
|
visiblePages: 10,
|
||||||
initiateStartPageClick: false,
|
initiateStartPageClick: false,
|
||||||
prev : '<img src="/image/web/page_navigation_arrow.svg" alt="prev"/>',
|
prev: '<img src="/image/web/page_navigation_arrow.svg" alt="prev"/>',
|
||||||
next : '<img src="/image/web/page_navigation_arrow.svg" alt="next"/>',
|
next: '<img src="/image/web/page_navigation_arrow.svg" alt="next"/>',
|
||||||
first : '',
|
first: '',
|
||||||
last : '',
|
last: '',
|
||||||
onPageClick: function (treatmentpetit, page) {
|
onPageClick: function (treatmentpetit, page) {
|
||||||
fn_webTreatmentPetitPagination(page);
|
fn_webTreatmentPetitPagination(page);
|
||||||
}
|
}
|
||||||
}).on('page', function (treatmentpetit, page) {
|
}).on('page', function (treatmentpetit, page) {
|
||||||
//console.info(page + ' (from treatmentpetit listening)');
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("조회 오류", data.msgDesc);
|
modalEvent.danger("조회 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("조회 오류", "조회 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("조회 오류", "조회 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
// 로딩열기
|
// 로딩열기
|
||||||
webTreatmentPetitGridOptions.api.showLoadingOverlay();
|
webTreatmentPetitGridOptions.api.showLoadingOverlay();
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -271,8 +78,8 @@ function fn_selectListWebTreatmentPetitJson(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색하기
|
* 검색하기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webTreatmentPetitSearch(param){
|
function fn_webTreatmentPetitSearch(param) {
|
||||||
if("A"!=param && "Y"!=selectUseYn){
|
if ("A" != param && "Y" != selectUseYn) {
|
||||||
modalEvent.warning("", "조회 권한이 없습니다.");
|
modalEvent.warning("", "조회 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -280,38 +87,16 @@ function fn_webTreatmentPetitSearch(param){
|
|||||||
fn_webTreatmentPetitPaginReset();
|
fn_webTreatmentPetitPaginReset();
|
||||||
|
|
||||||
webTreatmentPetitSearchKeywordParam0 = $("#webTreatmentPetitSearchKeyword0").val();
|
webTreatmentPetitSearchKeywordParam0 = $("#webTreatmentPetitSearchKeyword0").val();
|
||||||
webTreatmentPetitSearchKeywordParam1 = $("#webTreatmentPetitSearchKeyword1").val();
|
webTreatmentPetitSearchKeywordParam1 = $("#webTreatmentPetitSearchKeyword1").val();
|
||||||
webTreatmentPetitSearchKeywordParam2 = $("#webTreatmentPetitSearchKeyword2").val();
|
|
||||||
webTreatmentPetitSearchKeywordParam3 = $("#webTreatmentPetitSearchKeyword3").val();
|
|
||||||
|
|
||||||
webTreatmentPetitSearchDateType = $("#webTreatmentPetitSearchDateType").val();
|
|
||||||
webTreatmentPetitSearchStartDate = $("#webTreatmentPetitSearchStartDate").val();
|
|
||||||
webTreatmentPetitSearchEndDate = $("#webTreatmentPetitSearchEndDate").val();
|
|
||||||
|
|
||||||
fn_selectListWebTreatmentPetitJson();
|
fn_selectListWebTreatmentPetitJson();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* 초기화하기
|
|
||||||
****************************************************************************/
|
|
||||||
function fn_webTreatmentPetitReset(){
|
|
||||||
fn_webTreatmentPetitSetDate('D');
|
|
||||||
$("#webTreatmentPetitSearchDateType option:eq(0)").prop("selected", true);
|
|
||||||
|
|
||||||
$("#webTreatmentPetitSearchKeyword0").val("");
|
|
||||||
$("#webTreatmentPetitSearchKeyword1").val("");
|
|
||||||
$("#webTreatmentPetitSearchKeyword2").val("");
|
|
||||||
$("#webTreatmentPetitSearchKeyword3").val("");
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSearch();
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이징 처리
|
* 페이징 처리
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webTreatmentPetitPagination(param){
|
function fn_webTreatmentPetitPagination(param) {
|
||||||
webTreatmentPetitStart = (parseInt(param)-1)*webTreatmentPetitLimit;
|
webTreatmentPetitStart = (parseInt(param) - 1) * webTreatmentPetitLimit;
|
||||||
|
|
||||||
fn_selectListWebTreatmentPetitJson();
|
fn_selectListWebTreatmentPetitJson();
|
||||||
}
|
}
|
||||||
@@ -319,19 +104,17 @@ function fn_webTreatmentPetitPagination(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이징 리셋
|
* 페이징 리셋
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webTreatmentPetitPaginReset(){
|
function fn_webTreatmentPetitPaginReset() {
|
||||||
webTreatmentPetitSearchKeywordParam0 = '';
|
webTreatmentPetitSearchKeywordParam0 = '';
|
||||||
webTreatmentPetitSearchKeywordParam1 = '';
|
webTreatmentPetitSearchKeywordParam1 = '';
|
||||||
webTreatmentPetitSearchKeywordParam2 = '';
|
|
||||||
webTreatmentPetitSearchKeywordParam3 = '';
|
|
||||||
|
|
||||||
webTreatmentPetitStart = 0;
|
webTreatmentPetitStart = 0;
|
||||||
webTreatmentPetitLimit = 100;
|
webTreatmentPetitLimit = 100;
|
||||||
webTreatmentPetitTotalCount = 0;
|
webTreatmentPetitTotalCount = 0;
|
||||||
webTreatmentPetitTotalPages = 0;
|
webTreatmentPetitTotalPages = 0;
|
||||||
|
|
||||||
//페이징 초기화
|
//페이징 초기화
|
||||||
if($("#webTreatmentPetitPagination").data("twbs-pagination")){
|
if ($("#webTreatmentPetitPagination").data("twbs-pagination")) {
|
||||||
$("#webTreatmentPetitPagination").twbsPagination("destroy");
|
$("#webTreatmentPetitPagination").twbsPagination("destroy");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -339,27 +122,23 @@ function fn_webTreatmentPetitPaginReset(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 이벤트 삭제
|
* 이벤트 삭제
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_deleteWebTreatmentPetit(){
|
function fn_deleteWebTreatmentPetit() {
|
||||||
if("Y"!=deleteUseYn){
|
if ("Y" != deleteUseYn) {
|
||||||
modalEvent.warning("", "삭제 권한이 없습니다.");
|
modalEvent.warning("", "삭제 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!delList){
|
if (!delList) {
|
||||||
modalEvent.warning("", "삭제할 대상을 선택하세요.");
|
modalEvent.warning("", "삭제할 대상을 선택하세요.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
modalEvent.info("삭제", "선택한 이벤트 정보를 삭제하시겠습니까?", function(){
|
modalEvent.info("삭제", "선택한 이벤트 정보를 삭제하시겠습니까?", function () {
|
||||||
/*let formData = new FormData();
|
let data = {
|
||||||
formData.append("menuClass", menuClass);
|
menuClass: menuClass,
|
||||||
formData.append("delList", delList);*/
|
categoryDivCd: categoryDivCd,
|
||||||
|
delList: delList
|
||||||
let data = {
|
};
|
||||||
menuClass: menuClass,
|
|
||||||
categoryDivCd: categoryDivCd,
|
|
||||||
delList: delList
|
|
||||||
};
|
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/contentsBbs/delContentsBbs.do'),
|
url: encodeURI('/contentsBbs/delContentsBbs.do'),
|
||||||
@@ -368,24 +147,70 @@ function fn_deleteWebTreatmentPetit(){
|
|||||||
contentType: 'application/json; charset=utf-8',
|
contentType: 'application/json; charset=utf-8',
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
modalEvent.success("삭제 성공", data.msgDesc, function(){
|
modalEvent.success("삭제 성공", data.msgDesc, function () {
|
||||||
fn_webTreatmentPetitOk();
|
fn_webTreatmentPetitSearch("A");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("삭제 오류", data.msgDesc);
|
modalEvent.danger("삭제 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("삭제 오류", "삭제 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("삭제 오류", "삭제 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
}
|
||||||
beforeSend:function(){
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
},
|
/****************************************************************************
|
||||||
complete:function(){
|
* 출력순서 저장
|
||||||
|
****************************************************************************/
|
||||||
|
function fn_saveOrdNo() {
|
||||||
|
if ("Y" != updateUseYn) {
|
||||||
|
modalEvent.warning("", "수정 권한이 없습니다.");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
let orderList = [];
|
||||||
|
let totalRows = webTreatmentPetitGridOptions.api.getDisplayedRowCount();
|
||||||
|
|
||||||
|
for (let i = 0; i < totalRows; i++) {
|
||||||
|
let rowNode = webTreatmentPetitGridOptions.api.getDisplayedRowAtIndex(i);
|
||||||
|
orderList.push({
|
||||||
|
categoryNo: rowNode.data.categoryNo,
|
||||||
|
postNo: rowNode.data.postNo,
|
||||||
|
ordNo: totalRows - i // 상단이 큰 값 (DESC 정렬)
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
modalEvent.info("순서저장", "변경된 출력순서를 저장하시겠습니까?", function () {
|
||||||
|
let data = {
|
||||||
|
menuClass: menuClass,
|
||||||
|
categoryDivCd: categoryDivCd,
|
||||||
|
orderList: orderList
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: encodeURI('/contentsBbs/updateOrdNo.do'),
|
||||||
|
data: JSON.stringify(data),
|
||||||
|
dataType: "json",
|
||||||
|
contentType: 'application/json; charset=utf-8',
|
||||||
|
type: 'POST',
|
||||||
|
async: true,
|
||||||
|
success: function (data) {
|
||||||
|
if ('0' == data.msgCode) {
|
||||||
|
modalEvent.success("순서저장 성공", data.msgDesc, function () {
|
||||||
|
$("#btnSaveOrdNo").prop("disabled", true).css("opacity", "0.5");
|
||||||
|
fn_selectListWebTreatmentPetitJson();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
modalEvent.danger("순서저장 오류", data.msgDesc);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (xhr, status, error) {
|
||||||
|
modalEvent.danger("순서저장 오류", "순서 저장 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -394,92 +219,28 @@ function fn_deleteWebTreatmentPetit(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색 엔터 이벤트
|
* 검색 엔터 이벤트
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webTreatmentPetitEnter(e){
|
function fn_webTreatmentPetitEnter(e) {
|
||||||
if(e.which){
|
if (e.which) {
|
||||||
// 파이어폭스
|
if (13 == e.which) {
|
||||||
if(13 == e.which) {
|
|
||||||
//로그인 액션 스크립트
|
|
||||||
fn_webTreatmentPetitSearch();
|
fn_webTreatmentPetitSearch();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
// 윈도우, 사파리, 크롬
|
if (13 == e.keyCode) {
|
||||||
if(13 == treatmentpetit.keyCode) {
|
|
||||||
//로그인 액션 스크립트
|
|
||||||
fn_webTreatmentPetitSearch();
|
fn_webTreatmentPetitSearch();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* 정렬 이벤트
|
|
||||||
****************************************************************************/
|
|
||||||
function fn_alignTreatmentPetit(param, param2){
|
|
||||||
let align = "";
|
|
||||||
|
|
||||||
if("A"==param){
|
|
||||||
align = "오늘";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('A');
|
|
||||||
}
|
|
||||||
else if("B"==param){
|
|
||||||
align = "최근30일";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('D');
|
|
||||||
}
|
|
||||||
else if("C"==param){
|
|
||||||
align = "최근90일";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('E');
|
|
||||||
}
|
|
||||||
else if("D"==param){
|
|
||||||
align = "이번주";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('C');
|
|
||||||
}
|
|
||||||
else if("E"==param){
|
|
||||||
align = "이번달";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('F');
|
|
||||||
}
|
|
||||||
else if("F"==param){
|
|
||||||
align = "올해";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('G');
|
|
||||||
}
|
|
||||||
else if("G"==param){
|
|
||||||
align = "지난주";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('H');
|
|
||||||
}
|
|
||||||
else if("H"==param){
|
|
||||||
align = "지난달";
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSetDate('I');
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
align = "";
|
|
||||||
}
|
|
||||||
$("#webTreatmentPetitSearchDateType").val(param);
|
|
||||||
$("#webTreatmentPetitSearchDateType").siblings("button").text(align);
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* 완료
|
|
||||||
****************************************************************************/
|
|
||||||
function fn_webTreatmentPetitOk(){
|
|
||||||
fn_webTreatmentPetitReset();
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 등록 화면으로 이동.
|
* 등록 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_insertWebTreatmentPetitIntro(){
|
function fn_insertWebTreatmentPetitIntro() {
|
||||||
if("Y"==insertUseYn){
|
if ("Y" == insertUseYn) {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
pagingParam += "&categoryDivCd="+categoryDivCd;
|
pagingParam += "&categoryDivCd=" + categoryDivCd;
|
||||||
fn_leftFormAction("/contentsBbs/moveRegContentsBbs.do"+pagingParam);
|
fn_leftFormAction("/contentsBbs/moveRegContentsBbs.do" + pagingParam);
|
||||||
}else{
|
} else {
|
||||||
modalEvent.warning("", "등록 권한이 없습니다.");
|
modalEvent.warning("", "등록 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -489,14 +250,14 @@ function fn_insertWebTreatmentPetitIntro(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 수정 화면으로 이동.
|
* 수정 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_updateWebTreatmentPetitIntro(postNo, categoryNo){
|
function fn_updateWebTreatmentPetitIntro(postNo, categoryNo) {
|
||||||
if("Y"==updateUseYn){
|
if ("Y" == updateUseYn) {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
pagingParam += "&categoryDivCd="+categoryDivCd;
|
pagingParam += "&categoryDivCd=" + categoryDivCd;
|
||||||
pagingParam += "&postNo="+postNo;
|
pagingParam += "&postNo=" + postNo;
|
||||||
pagingParam += "&categoryNo="+categoryNo;
|
pagingParam += "&categoryNo=" + categoryNo;
|
||||||
fn_leftFormAction("/contentsBbs/moveContentsBbs.do"+pagingParam);
|
fn_leftFormAction("/contentsBbs/moveContentsBbs.do" + pagingParam);
|
||||||
}else{
|
} else {
|
||||||
modalEvent.warning("", "수정 권한이 없습니다.");
|
modalEvent.warning("", "수정 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -504,82 +265,90 @@ function fn_updateWebTreatmentPetitIntro(postNo, categoryNo){
|
|||||||
|
|
||||||
|
|
||||||
let webTreatmentPetitColumnDefs = [
|
let webTreatmentPetitColumnDefs = [
|
||||||
{field: "checkbox", headerName:"", minWidth:55, maxWidth:55, headerCheckboxSelection: true, checkboxSelection: true},
|
{ field: "checkbox", headerName: "", minWidth: 55, maxWidth: 55, rowDrag: true, headerCheckboxSelection: true, checkboxSelection: true },
|
||||||
{field: "rowNum", headerName:"번호", minWidth:60, maxWidth:60,sortable: false, cellStyle:{textAlign: 'center'}},
|
{ field: "rowNum", headerName: "번호", minWidth: 60, maxWidth: 60, sortable: false, cellStyle: { textAlign: 'center' } },
|
||||||
{field: "categoryNm", headerName:"카테고리", minWidth:60},
|
{ field: "categoryNm", headerName: "카테고리", minWidth: 120, maxWidth: 130, cellStyle: { textAlign: 'center' } },
|
||||||
{field: "title", headerName:"제목", minWidth:150, cellStyle:{cursor: 'pointer', color:'#3985EA'}},
|
{ field: "title", headerName: "제목", minWidth: 150, cellStyle: { cursor: 'pointer', color: '#3985EA' } },
|
||||||
{field: "content", headerName:"내용요약", minWidth:150},
|
{ field: "content", headerName: "내용요약", minWidth: 150 },
|
||||||
{field: "hashtag", headerName:"해시태그", minWidth:150},
|
{ field: "hashtag", headerName: "해시태그", minWidth: 150 },
|
||||||
{field: "regDt", headerName:"등록일",minWidth:100, maxWidth:150},
|
{ field: "regDt", headerName: "등록일", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
{field: "regNm", headerName:"작성자",minWidth:100, maxWidth:150},
|
{ field: "regNm", headerName: "작성자", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
];
|
];
|
||||||
|
|
||||||
|
if (categoryDivCd === '02' || categoryDivCd === '04') {
|
||||||
|
webTreatmentPetitColumnDefs = [
|
||||||
|
{ field: "checkbox", headerName: "", minWidth: 55, maxWidth: 55, rowDrag: true, headerCheckboxSelection: true, checkboxSelection: true },
|
||||||
|
{ field: "rowNum", headerName: "번호", minWidth: 60, maxWidth: 60, sortable: false, cellStyle: { textAlign: 'center' } },
|
||||||
|
{ field: "categoryNm", headerName: "카테고리", minWidth: 120, maxWidth: 130, cellStyle: { textAlign: 'center' } },
|
||||||
|
{ field: "title", headerName: "제목", minWidth: 150, cellStyle: { cursor: 'pointer', color: '#3985EA' } },
|
||||||
|
{ field: "content", headerName: "내용요약", minWidth: 150 },
|
||||||
|
{ field: "startDt", headerName: "시작일", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
|
{ field: "endDt", headerName: "종료일", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
|
{ field: "hashtag", headerName: "해시태그", minWidth: 150 },
|
||||||
|
{ field: "regDt", headerName: "등록일", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
|
{ field: "regNm", headerName: "작성자", minWidth: 100, maxWidth: 120, cellStyle: { textAlign: 'center' } },
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
// let the grid know which columns and what data to use
|
// let the grid know which columns and what data to use
|
||||||
let webTreatmentPetitGridOptions = {
|
let webTreatmentPetitGridOptions = {
|
||||||
suppressRowTransform: true,
|
suppressRowTransform: true,
|
||||||
|
rowDragManaged: true,
|
||||||
|
animateRows: true,
|
||||||
columnDefs: webTreatmentPetitColumnDefs,
|
columnDefs: webTreatmentPetitColumnDefs,
|
||||||
defaultColDef: { // 리스트 기본 설정
|
defaultColDef: { // 리스트 기본 설정
|
||||||
flex: 1,
|
flex: 1,
|
||||||
sortable: true, //정렬 여부
|
sortable: true, //정렬 여부
|
||||||
resizable: true, //리사이즈
|
resizable: true, //리사이즈
|
||||||
editable: true, // 그리드에서 데이터 수정
|
editable: true, // 그리드에서 데이터 수정
|
||||||
cellStyle:{textAlign:'left',fontSize:'14px',padding:'0'},
|
cellStyle: { textAlign: 'left', fontSize: '14px', padding: '0' },
|
||||||
//suppressSizeToFit:true, //자동 맞춤
|
|
||||||
//enableRowGroup: true, // 그룹 묶음
|
|
||||||
enablePivot: true,
|
enablePivot: true,
|
||||||
enableValue : true
|
enableValue: true
|
||||||
},
|
},
|
||||||
//suppressMultiSort:true, //단일솔트 true가 단일, false가 다중 shift + sort 시
|
headerHeight: 41, // header 높이
|
||||||
headerHeight : 41, // header 높이
|
rowHeight: 41, // row 높이
|
||||||
rowHeight : 41, // row 높이
|
rowData: webTreatmentPetitAgGridData,
|
||||||
rowData : webTreatmentPetitAgGridData,
|
suppressRowClickSelection: true, // 로우 클릭시 체크박스 선택 true no, false yes
|
||||||
suppressRowClickSelection : true, // 로우 클릭시 체크박스 선택 true no, false yes
|
localeText: {
|
||||||
localeText : {
|
noRowsToShow: '조회 결과가 없습니다.'
|
||||||
noRowsToShow : '조회 결과가 없습니다.'
|
|
||||||
}, //데이터 없을 시 나오는 문구
|
}, //데이터 없을 시 나오는 문구
|
||||||
rowSelection : 'multiple', // row 다중 선택
|
rowSelection: 'multiple', // row 다중 선택
|
||||||
debug : false,
|
debug: false,
|
||||||
onCellClicked: function(cell){ //셀 클릭 이벤트\
|
onCellClicked: function (cell) { //셀 클릭 이벤트
|
||||||
|
|
||||||
/* alert(treatmentpetit.column.colId); */
|
if ('title' == cell.column.colId) {
|
||||||
if( 'title' == cell.column.colId ){
|
|
||||||
fn_updateWebTreatmentPetitIntro(cell.data.postNo, cell.data.categoryNo);
|
fn_updateWebTreatmentPetitIntro(cell.data.postNo, cell.data.categoryNo);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onSelectionChanged: function(treatmentpetit){ //체크박스 선택
|
onRowDragEnd: function (event) {
|
||||||
delList = treatmentpetit.api.getSelectedRows();
|
// 드래그 완료 시 순서저장 버튼 활성화
|
||||||
console.log(delList);
|
$("#btnSaveOrdNo").prop("disabled", false).css("opacity", "1");
|
||||||
/*let selectRows = [];
|
|
||||||
selectRows = treatmentpetit.api.getSelectedRows();
|
|
||||||
console.log(selectRows);
|
|
||||||
webTreatmentPetitSelectId = '';
|
|
||||||
for(let i=0; i<selectRows.length; i++){
|
|
||||||
webTreatmentPetitSelectId += selectRows[i].muWebTreatmentPetitId + ",";
|
|
||||||
}
|
|
||||||
webTreatmentPetitSelectId = webTreatmentPetitSelectId.substring(0, webTreatmentPetitSelectId.lastIndexOf(','));*/
|
|
||||||
},
|
},
|
||||||
onSortChanged: function(treatmentpetit){
|
onSelectionChanged: function (treatmentpetit) { //체크박스 선택
|
||||||
|
delList = treatmentpetit.api.getSelectedRows();
|
||||||
|
},
|
||||||
|
onSortChanged: function (treatmentpetit) {
|
||||||
//정렬
|
//정렬
|
||||||
webTreatmentPetitSort = ''; //기존 정렬 초기화
|
webTreatmentPetitSort = ''; //기존 정렬 초기화
|
||||||
let columnArr = treatmentpetit.columnApi.getColumnState();
|
let columnArr = treatmentpetit.columnApi.getColumnState();
|
||||||
if(0<columnArr.length){
|
if (0 < columnArr.length) {
|
||||||
//sort index 순으로 재정렬
|
//sort index 순으로 재정렬
|
||||||
columnArr.sort(function(a,b){
|
columnArr.sort(function (a, b) {
|
||||||
return a.sortIndex - b.sortIndex;
|
return a.sortIndex - b.sortIndex;
|
||||||
});
|
});
|
||||||
|
|
||||||
let nullCnt = 0;
|
let nullCnt = 0;
|
||||||
for(let i=0; i<columnArr.length; i++){
|
for (let i = 0; i < columnArr.length; i++) {
|
||||||
let gridSortModel = columnArr[i].colId;
|
let gridSortModel = columnArr[i].colId;
|
||||||
let gridSort = columnArr[i].sort;
|
let gridSort = columnArr[i].sort;
|
||||||
|
|
||||||
if(gridSort != null){
|
if (gridSort != null) {
|
||||||
webTreatmentPetitStart = 0;
|
webTreatmentPetitStart = 0;
|
||||||
webTreatmentPetitSort += gridSortModel+' '+ gridSort + ',';
|
webTreatmentPetitSort += gridSortModel + ' ' + gridSort + ',';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
nullCnt++;
|
nullCnt++;
|
||||||
if(nullCnt == columnArr.length){
|
if (nullCnt == columnArr.length) {
|
||||||
webTreatmentPetitSort = '';
|
webTreatmentPetitSort = '';
|
||||||
webTreatmentPetitDir = '';
|
webTreatmentPetitDir = '';
|
||||||
webTreatmentPetitStart = 0;
|
webTreatmentPetitStart = 0;
|
||||||
@@ -587,7 +356,7 @@ let webTreatmentPetitGridOptions = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
webTreatmentPetitSort = webTreatmentPetitSort.substring(0,webTreatmentPetitSort.lastIndexOf( ",")); //맨끝 콤마 지우기
|
webTreatmentPetitSort = webTreatmentPetitSort.substring(0, webTreatmentPetitSort.lastIndexOf(",")); //맨끝 콤마 지우기
|
||||||
|
|
||||||
fn_webTreatmentPetitSearch();
|
fn_webTreatmentPetitSearch();
|
||||||
}
|
}
|
||||||
@@ -599,52 +368,57 @@ let webTreatmentPetitGridDiv = document.querySelector('#webTreatmentPetitGrid');
|
|||||||
// create the grid passing in the div to use together with the columns & data we want to use
|
// create the grid passing in the div to use together with the columns & data we want to use
|
||||||
new agGrid.Grid(webTreatmentPetitGridDiv, webTreatmentPetitGridOptions);
|
new agGrid.Grid(webTreatmentPetitGridDiv, webTreatmentPetitGridOptions);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 init
|
* 페이지 init
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageInit(){
|
function fn_pageInit() {
|
||||||
// 날짜 datepicker
|
// 카테고리 목록 동적 로드
|
||||||
fn_searchDatePicker("#divWebTreatmentPetitSearchStartDate", "#divWebTreatmentPetitSearchEndDate");
|
fn_loadCategoryList();
|
||||||
|
|
||||||
if(!webTreatmentPetitSearchStartDate&&!webTreatmentPetitSearchEndDate){
|
|
||||||
// 검색 오늘날짜 셋팅
|
|
||||||
fn_webTreatmentPetitSetDate('D');
|
|
||||||
}else{
|
|
||||||
$("#webTreatmentPetitSearchStartDate").val(webTreatmentPetitSearchStartDate).trigger("change");
|
|
||||||
$("#webTreatmentPetitSearchEndDate").val(webTreatmentPetitSearchEndDate).trigger("change");
|
|
||||||
}
|
|
||||||
|
|
||||||
// 초기 페이징 처리
|
// 초기 페이징 처리
|
||||||
$("#webTreatmentPetitSearchKeyword0").val(webTreatmentPetitSearchKeywordParam0);
|
$("#webTreatmentPetitSearchKeyword1").val(webTreatmentPetitSearchKeywordParam1);
|
||||||
$("#webTreatmentPetitSearchKeyword1").val(webTreatmentPetitSearchKeywordParam1);
|
|
||||||
$("#webTreatmentPetitSearchKeyword2").val(webTreatmentPetitSearchKeywordParam2);
|
|
||||||
$("#webTreatmentPetitSearchKeyword3").val(webTreatmentPetitSearchKeywordParam3);
|
|
||||||
|
|
||||||
fn_webTreatmentPetitSearch("A");
|
fn_webTreatmentPetitSearch("A");
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 treatmentpetit
|
* 카테고리 목록 동적 로드
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageTreatmentPetit(){
|
function fn_loadCategoryList() {
|
||||||
// 검색 input
|
let formData = new FormData();
|
||||||
$(document).on('keypress', '#webTreatmentPetitSearchKeyword0', function(e) {
|
formData.append("categoryDivCd", categoryDivCd);
|
||||||
fn_webTreatmentPetitEnter(e);
|
|
||||||
|
$.ajax({
|
||||||
|
url: encodeURI('/contentsBbs/getCategoryList.do'),
|
||||||
|
data: formData,
|
||||||
|
dataType: "json",
|
||||||
|
processData: false,
|
||||||
|
contentType: false,
|
||||||
|
type: 'POST',
|
||||||
|
async: false,
|
||||||
|
success: function (data) {
|
||||||
|
if ('0' == data.msgCode) {
|
||||||
|
let optionList = $("#categoryOptionList");
|
||||||
|
// 기존 항목 유지 (전체)
|
||||||
|
let rows = data.rows;
|
||||||
|
for (let i = 0; i < rows.length; i++) {
|
||||||
|
let li = $('<li class="option_list_item" id="li_' + rows[i].categoryNo + '">' + rows[i].categoryNm + '</li>');
|
||||||
|
optionList.append(li);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (xhr, status, error) {
|
||||||
|
console.error("카테고리 목록 조회 오류", error);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
// 검색 input
|
}
|
||||||
$(document).on('keypress', '#webTreatmentPetitSearchKeyword1', function(e) {
|
|
||||||
fn_webTreatmentPetitEnter(e);
|
/****************************************************************************
|
||||||
});
|
* 페이지 이벤트 바인딩
|
||||||
// 검색 input
|
****************************************************************************/
|
||||||
$(document).on('keypress', '#webTreatmentPetitSearchKeyword2', function(e) {
|
function fn_pageTreatmentPetit() {
|
||||||
fn_webTreatmentPetitEnter(e);
|
// 검색 input 엔터
|
||||||
});
|
$(document).on('keypress', '#webTreatmentPetitSearchKeyword1', function (e) {
|
||||||
// 검색 input
|
|
||||||
$(document).on('keypress', '#webTreatmentPetitSearchKeyword3', function(e) {
|
|
||||||
fn_webTreatmentPetitEnter(e);
|
fn_webTreatmentPetitEnter(e);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -663,24 +437,29 @@ function fn_pageTreatmentPetit(){
|
|||||||
fn_deleteWebTreatmentPetit();
|
fn_deleteWebTreatmentPetit();
|
||||||
});
|
});
|
||||||
|
|
||||||
// 기간 선택 콤보 이벤트
|
// 순서저장 버튼
|
||||||
const target = $("#webTreatmentPetitSearchDateType").siblings("ul.select_option_list");
|
$("#btnSaveOrdNo").click(function () {
|
||||||
target.find("li.option_list_item").click(function () {
|
fn_saveOrdNo();
|
||||||
let selectIdArr = $(this).prop("id").split('_');
|
});
|
||||||
let selectId = selectIdArr[1];
|
|
||||||
let selectName = $(this).text();
|
|
||||||
|
|
||||||
|
// 카테고리 선택 콤보 이벤트
|
||||||
|
$(document).on('click', '#categoryOptionList .option_list_item', function () {
|
||||||
|
let selectIdArr = $(this).prop("id").split('_');
|
||||||
|
let selectId = selectIdArr[1];
|
||||||
|
let selectName = $(this).text();
|
||||||
|
|
||||||
|
if (selectName === '전체') {
|
||||||
|
selectId = '';
|
||||||
|
}
|
||||||
$(this).parent().siblings("button").text(selectName);
|
$(this).parent().siblings("button").text(selectName);
|
||||||
$(this).parent().siblings("input").val(selectId);
|
$(this).parent().siblings("input").val(selectId);
|
||||||
|
|
||||||
fn_alignTreatmentPetit(selectId);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
$(function(){
|
$(function () {
|
||||||
// 페이지 init
|
// 페이지 init
|
||||||
fn_pageInit();
|
fn_pageInit();
|
||||||
|
|
||||||
// 페이지 treatmentpetit
|
// 페이지 이벤트 바인딩
|
||||||
fn_pageTreatmentPetit();
|
fn_pageTreatmentPetit();
|
||||||
});
|
});
|
||||||
@@ -1,16 +1,42 @@
|
|||||||
|
// Custom Table Logic
|
||||||
|
let treatmentList = [];
|
||||||
|
|
||||||
|
function renderTreatmentTable() {
|
||||||
|
let tbody = document.getElementById("treatmentListBody");
|
||||||
|
tbody.innerHTML = "";
|
||||||
|
|
||||||
|
treatmentList.forEach((item, index) => {
|
||||||
|
let row = document.createElement("tr");
|
||||||
|
row.innerHTML = `
|
||||||
|
<td><input type="checkbox" name="treatmentCheck" value="${index}"></td>
|
||||||
|
<td style="text-align:left; padding-left:10px;">${item.treatmentProcedureName}</td>
|
||||||
|
<td style="text-align:right;">${num2won(item.price)}</td>
|
||||||
|
<td style="text-align:right;">${num2won(item.discountPrice)}</td>
|
||||||
|
`;
|
||||||
|
tbody.appendChild(row);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_checkAll(source) {
|
||||||
|
let checkboxes = document.getElementsByName('treatmentCheck');
|
||||||
|
for (var i = 0, n = checkboxes.length; i < n; i++) {
|
||||||
|
checkboxes[i].checked = source.checked;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 이벤트 조회
|
* 이벤트 조회
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectWebTreatmentPetit(){
|
function fn_selectWebTreatmentPetit() {
|
||||||
if(true != fn_emptyCheck(postNo)) {
|
if (true != fn_emptyCheck(postNo)) {
|
||||||
modalEvent.warning("수정", "이벤트 정보가 없습니다.");
|
modalEvent.warning("수정", "이벤트 정보가 없습니다.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("categoryDivCd", categoryDivCd);
|
formData.append("categoryDivCd", categoryDivCd);
|
||||||
formData.append("categoryNo", categoryNo);
|
formData.append("categoryNo", categoryNo);
|
||||||
formData.append("postNo", postNo);
|
formData.append("postNo", postNo);
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/contentsBbs/getContentsBbs.do'),
|
url: encodeURI('/contentsBbs/getContentsBbs.do'),
|
||||||
@@ -20,163 +46,112 @@ function fn_selectWebTreatmentPetit(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(rst){
|
success: function (rst) {
|
||||||
if('0'==rst.msgCode){
|
if ('0' == rst.msgCode) {
|
||||||
let data = rst.detail;
|
let data = rst.detail;
|
||||||
$("select[name=category]").val(data.categoryNo).prop("selected", true);
|
$("select[name=category]").val(data.categoryNo).prop("selected", true);
|
||||||
$("#categoryNo").val(data.categoryNo);
|
$("#categoryNo").val(data.categoryNo);
|
||||||
$("#title").val(data.title);
|
$("#title").val(data.title);
|
||||||
$("#content").val(data.content);
|
$("#content").val(data.content);
|
||||||
$("#hashtag").val(data.hashtag);
|
$("#hashtag").val(data.hashtag);
|
||||||
$("#thumbnailBottomTxt").val(data.thumbnailBottomTxt);
|
$("#thumbnailBottomTxt").val(data.thumbnailBottomTxt);
|
||||||
$("#thumbnailImg").attr("src", CDN_URL + data.thumbnailImgPath);
|
$("#thumbnailImg").attr("src", CDN_URL + data.thumbnailImgPath);
|
||||||
$("#contentsImg").attr("src", CDN_URL + data.contentImgPath);
|
$("#contentsImg").attr("src", CDN_URL + data.contentImgPath);
|
||||||
$("#oldCrmItemId").val(data.oldCrmItemId);
|
$("#oldCrmItemId").val(data.oldCrmItemId);
|
||||||
$("#ordNo").val(data.ordNo);
|
$("#ordNo").val(data.ordNo);
|
||||||
|
|
||||||
var htmlstring = '';
|
if (data.startDt) $("#eventStartDt").val(data.startDt);
|
||||||
rst.treatmentList.forEach((item, i) => {
|
if (data.endDt) $("#eventEndDt").val(data.endDt);
|
||||||
htmlstring += `<div id="treatment${i}">
|
|
||||||
<input type="checkbox" id="${item.muTreatmentProcedureId}" name="treatment">
|
|
||||||
<input type="hidden" name="treatmentprocedurelist" value="${item.muTreatmentProcedureId}">
|
|
||||||
<input type="hidden" name="treatmentlist" value="${item.muTreatmentId}">
|
|
||||||
<label for="${item.muTreatmentProcedureId}">${item.treatmentProcedureName} - ${num2won(item.price)} - ${num2won(item.discountPrice)}</label>
|
|
||||||
</div>`;
|
|
||||||
});
|
|
||||||
|
|
||||||
$('#treatmentlist').append(htmlstring);
|
treatmentList = [];
|
||||||
|
rst.treatmentList.forEach((item, i) => {
|
||||||
|
treatmentList.push({
|
||||||
|
treatmentProcedureName: item.treatmentProcedureName,
|
||||||
|
price: item.price,
|
||||||
|
discountPrice: item.discountPrice,
|
||||||
|
muTreatmentId: item.muTreatmentId,
|
||||||
|
muTreatmentProcedureId: item.muTreatmentProcedureId
|
||||||
|
});
|
||||||
|
});
|
||||||
|
renderTreatmentTable();
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("수정 오류", eventData.msgDesc);
|
modalEvent.danger("수정 오류", eventData.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("수정 오류", "수정 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("수정 오류", "수정 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
|
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function num2won(x){
|
function num2won(x) {
|
||||||
if (typeof x === 'undefined' || x === null) return '';
|
if (typeof x === 'undefined' || x === null) return '';
|
||||||
return x.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
|
return x.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 이벤트 수정
|
* 이벤트 수정
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_updateWebTreatmentPetit(){
|
function fn_updateWebTreatmentPetit() {
|
||||||
if("Y"!=insertUseYn){
|
if ("Y" != insertUseYn) {
|
||||||
modalEvent.warning("", "등록 권한이 없습니다.");
|
modalEvent.warning("", "등록 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
let title = $("#title").val();
|
let title = $("#title").val();
|
||||||
let content = $("#content").val();
|
let content = $("#content").val();
|
||||||
let hashtag = $("#hashtag").val();
|
let hashtag = $("#hashtag").val();
|
||||||
let thumbnailBottomTxt = $("#thumbnailBottomTxt").val();
|
let thumbnailBottomTxt = $("#thumbnailBottomTxt").val();
|
||||||
let categoryNo = $("#categoryNo").val();
|
let categoryNo = $("#categoryNo").val();
|
||||||
|
|
||||||
var treatmentlen = $("input[name=treatmentlist]").length;
|
var treatmentIdList = []; // muTreatmentId
|
||||||
var treatmentlist = new Array(treatmentlen);
|
var treatmentProcedureIdList = []; // muTreatmentProcedureId
|
||||||
for(var i=0; i<treatmentlen; i++){
|
|
||||||
treatmentlist[i] = $("input[name=treatmentlist]").eq(i).val();
|
|
||||||
}
|
|
||||||
|
|
||||||
var treatmentprocedurelen = $("input[name=treatmentprocedurelist]").length;
|
treatmentList.forEach(item => {
|
||||||
var treatmentprocedurelist = new Array(treatmentlen);
|
treatmentIdList.push(item.muTreatmentId);
|
||||||
for(var i=0; i<treatmentprocedurelen; i++){
|
treatmentProcedureIdList.push(item.muTreatmentProcedureId);
|
||||||
treatmentprocedurelist[i] = $("input[name=treatmentprocedurelist]").eq(i).val();
|
});
|
||||||
}
|
|
||||||
|
|
||||||
//let eventStartDate = $("#eventStartDate").val();
|
let eventStartDt = $("#eventStartDt").val();
|
||||||
//let eventEndDate = $("#eventEndDate").val();
|
let eventEndDt = $("#eventEndDt").val();
|
||||||
let file = $("#file")[0].files[0];
|
let file = $("#file")[0].files[0];
|
||||||
let content_file = $("#content_file")[0].files[0];
|
let content_file = $("#content_file")[0].files[0];
|
||||||
|
|
||||||
if(true != fn_emptyCheck(categoryNo)) {
|
if (true != fn_emptyCheck(categoryNo)) {
|
||||||
modalEvent.warning("등록", "카테고리를 입력하세요.");
|
modalEvent.warning("등록", "카테고리를 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(true != fn_emptyCheck(title)) {
|
if (true != fn_emptyCheck(title)) {
|
||||||
modalEvent.warning("등록", "제목을 입력하세요.");
|
modalEvent.warning("등록", "제목을 입력하세요.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
/** 20251024 이상우팀장 요청으로 인해 필수입력 validation 삭제
|
|
||||||
if(true != fn_emptyCheck(content)) {
|
|
||||||
modalEvent.warning("등록", "내용을 입력하세요.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(true != fn_emptyCheck(hashtag)) {
|
|
||||||
modalEvent.warning("등록", "해시태그를 입력하세요.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(true != fn_emptyCheck(thumbnailBottomTxt)) {
|
|
||||||
modalEvent.warning("등록", "썸네일 하단 내용을 입력하세요.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(true != fn_emptyCheck(file)) {
|
modalEvent.info("수정", categorytitle + " 정보를 수정하시겠습니까?", function () {
|
||||||
if($(".img_box > img").length > 0){
|
|
||||||
|
|
||||||
}else{
|
|
||||||
modalEvent.warning("등록", "썸네일 정보가 없습니다.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
}else{
|
|
||||||
for(let i=0; i<file.length; i++){
|
|
||||||
let fileSize = file[i].size;
|
|
||||||
if(fileSize > fn_maxFileSize()){
|
|
||||||
modalEvent.warning("", "파일정보 용량이 50MB를 넘습니다. 업로드가 불가능합니다.");
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(true != fn_emptyCheck(content_file)) {
|
|
||||||
if($(".file_box").text() != ''){
|
|
||||||
|
|
||||||
}else{
|
|
||||||
modalEvent.warning("등록", "컨텐츠 정보가 없습니다.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
}else{
|
|
||||||
for(let i=0; i<content_file.length; i++){
|
|
||||||
let fileSize = content_file[i].size;
|
|
||||||
if(fileSize > fn_maxFileSize()){
|
|
||||||
modalEvent.warning("", "파일정보 용량이 50MB를 넘습니다. 업로드가 불가능합니다.");
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
modalEvent.info("수정", categorytitle + " 정보를 수정하시겠습니까?", function(){
|
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("categoryDivCd", categoryDivCd);
|
formData.append("categoryDivCd", categoryDivCd);
|
||||||
formData.append("categoryNo", categoryNo);
|
formData.append("categoryNo", categoryNo);
|
||||||
formData.append("postNo", postNo);
|
formData.append("postNo", postNo);
|
||||||
formData.append("title", title);
|
formData.append("title", title);
|
||||||
formData.append("content", content);
|
formData.append("content", content);
|
||||||
formData.append("hashtag", hashtag);
|
formData.append("hashtag", hashtag);
|
||||||
formData.append("thumbnailBottomTxt", thumbnailBottomTxt);
|
formData.append("thumbnailBottomTxt", thumbnailBottomTxt);
|
||||||
formData.append("treatmentlist", treatmentlist);
|
formData.append("treatmentlist", treatmentIdList);
|
||||||
formData.append("treatmentprocedurelist", treatmentprocedurelist);
|
formData.append("treatmentprocedurelist", treatmentProcedureIdList);
|
||||||
//formData.append("eventStartDate", eventStartDate);
|
formData.append("eventStartDt", eventStartDt);
|
||||||
//formData.append("eventEndDate", eventEndDate);
|
formData.append("eventEndDt", eventEndDt);
|
||||||
formData.append("file", file);
|
formData.append("file", file);
|
||||||
formData.append("content_file", content_file);
|
formData.append("content_file", content_file);
|
||||||
formData.append("oldCrmItemId", $("#oldCrmItemId").val());
|
formData.append("oldCrmItemId", $("#oldCrmItemId").val());
|
||||||
formData.append("ordNo", $("#ordNo").val());
|
formData.append("ordNo", $("#ordNo").val());
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: encodeURI('/contentsBbs/modContentsBbs.do'),
|
url: encodeURI('/contentsBbs/modContentsBbs.do'),
|
||||||
@@ -186,98 +161,63 @@ function fn_updateWebTreatmentPetit(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
modalEvent.success("등록 성공", data.msgDesc, function(){
|
modalEvent.success("등록 성공", data.msgDesc, function () {
|
||||||
fn_selectListWebTreatmentPetitIntro();
|
fn_selectListWebTreatmentPetitIntro();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("등록 오류", data.msgDesc);
|
modalEvent.danger("등록 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("등록 오류", "등록 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("등록 오류", "등록 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
|
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* html 에디터 이미지 업로드시
|
|
||||||
****************************************************************************/
|
|
||||||
function uploadSummernoteImageFileNoticeInsert(files, editor){
|
|
||||||
Object.values(files).forEach(file => {
|
|
||||||
let formData = new FormData();
|
|
||||||
formData.append('menuClass', menuClass);
|
|
||||||
formData.append('file', file);
|
|
||||||
$.ajax({
|
|
||||||
url: encodeURI('/webtreatmentpetit/uploadFile.do'),
|
|
||||||
data: formData,
|
|
||||||
dataType: "json",
|
|
||||||
processData: false,
|
|
||||||
contentType: false,
|
|
||||||
type: 'POST',
|
|
||||||
async: true,
|
|
||||||
success: function (data) {
|
|
||||||
if ('0' == data.msgCode) {
|
|
||||||
$(editor).summernote('insertImage', data.rows.filePath, function ($image) {
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
error: function (xhr, status, error) {
|
|
||||||
modalEvent.danger('오류', '이미지 업로드 중 오류가 발생했습니다.');
|
|
||||||
},
|
|
||||||
beforeSend: function () {
|
|
||||||
// 로딩열기
|
|
||||||
$(".loading-image-layer").show();
|
|
||||||
},
|
|
||||||
complete: function () {
|
|
||||||
// 로딩닫기
|
|
||||||
$(".loading-image-layer").hide();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 썸네일 이미지 미리보기
|
* 썸네일 이미지 미리보기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_filePreview(width, height, obj){
|
function fn_filePreview(width, height, obj) {
|
||||||
let file = "";
|
let file = "";
|
||||||
if(obj == '.img_box'){
|
if (obj == '.img_box') {
|
||||||
file = $("#file")[0].files[0];
|
file = $("#file")[0].files[0];
|
||||||
} else {
|
} else {
|
||||||
file = $("#content_file")[0].files[0];
|
file = $("#content_file")[0].files[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
if(file){
|
if (file) {
|
||||||
$(obj).html('');
|
$(obj).html('');
|
||||||
const reader = new FileReader();
|
const reader = new FileReader();
|
||||||
|
|
||||||
reader.onload = function (e) {
|
reader.onload = function (e) {
|
||||||
// 이미지 요소를 생성하고 미리보기 추가
|
// 이미지 요소를 생성하고 미리보기 추가
|
||||||
const img = document.createElement('img');
|
const img = document.createElement('img');
|
||||||
img.src = e.target.result;
|
img.src = e.target.result;
|
||||||
img.style.width = width; // 원하는 크기로 조정
|
img.style.width = width; // 원하는 크기로 조정
|
||||||
img.style.height = height;
|
img.style.height = height;
|
||||||
$(obj).append(img);
|
$(obj).append(img);
|
||||||
};
|
};
|
||||||
|
|
||||||
// 파일을 읽기 시작
|
// 파일을 읽기 시작
|
||||||
reader.readAsDataURL(file);
|
reader.readAsDataURL(file);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 삭제
|
* 배너 이미지 삭제
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_removePreview(){
|
function fn_removePreview() {
|
||||||
$("#file").val('');
|
$("#file").val('');
|
||||||
$('.img_box').html('');
|
$('.img_box').html('');
|
||||||
}
|
}
|
||||||
@@ -286,16 +226,16 @@ function fn_removePreview(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 미리보기
|
* 배너 이미지 미리보기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_fileContentPreview(){
|
function fn_fileContentPreview() {
|
||||||
const file = $("#content_file")[0].files[0];
|
const file = $("#content_file")[0].files[0];
|
||||||
if(file){
|
if (file) {
|
||||||
$('.file_box').html(file.name);
|
$('.file_box').html(file.name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 배너 이미지 삭제
|
* 배너 이미지 삭제
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_removeContentPreview(){
|
function fn_removeContentPreview() {
|
||||||
$("#content_file").val('');
|
$("#content_file").val('');
|
||||||
$('.file_box').html('');
|
$('.file_box').html('');
|
||||||
}
|
}
|
||||||
@@ -303,12 +243,12 @@ function fn_removeContentPreview(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 리스트 화면으로 이동.
|
* 리스트 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectListWebTreatmentPetitIntro(){
|
function fn_selectListWebTreatmentPetitIntro() {
|
||||||
if("Y"==selectUseYn){
|
if ("Y" == selectUseYn) {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
pagingParam += "&categoryDivCd="+categoryDivCd;
|
pagingParam += "&categoryDivCd=" + categoryDivCd;
|
||||||
fn_leftFormAction("/contentsBbs/moveContentsBbsList.do"+pagingParam);
|
fn_leftFormAction("/contentsBbs/moveContentsBbsList.do" + pagingParam);
|
||||||
}else{
|
} else {
|
||||||
modalEvent.warning("", "조회 권한이 없습니다.");
|
modalEvent.warning("", "조회 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -317,44 +257,53 @@ function fn_selectListWebTreatmentPetitIntro(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 init
|
* 페이지 init
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageInit(){
|
function fn_pageInit() {
|
||||||
// 날짜 datepicker
|
// 날짜 datepicker (jQuery UI)
|
||||||
fn_searchDatePicker("#eventStartDate", "#eventEndDate");
|
$("#eventStartDt, #eventEndDt").datepicker({
|
||||||
|
dateFormat: 'yy-mm-dd',
|
||||||
$('#summernote').summernote({
|
prevText: '이전 달',
|
||||||
height: 540,
|
nextText: '다음 달',
|
||||||
callbacks: { //여기 부분이 이미지를 첨부하는 부분
|
monthNames: ['1월', '2월', '3월', '4월', '5월', '6월', '7월', '8월', '9월', '10월', '11월', '12월'],
|
||||||
onImageUpload : function(files) {
|
monthNamesShort: ['1월', '2월', '3월', '4월', '5월', '6월', '7월', '8월', '9월', '10월', '11월', '12월'],
|
||||||
uploadSummernoteImageFileNoticeInsert(files, this);
|
dayNames: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
}
|
dayNamesShort: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
},
|
dayNamesMin: ['일', '월', '화', '수', '목', '금', '토'],
|
||||||
|
showMonthAfterYear: true,
|
||||||
|
yearSuffix: '년',
|
||||||
|
changeMonth: true,
|
||||||
|
changeYear: true
|
||||||
});
|
});
|
||||||
fn_selectWebTreatmentPetit();
|
|
||||||
|
if (categoryDivCd === '02' || categoryDivCd === '04') {
|
||||||
|
$("#dateSelectionRow").show();
|
||||||
|
}
|
||||||
|
|
||||||
|
fn_selectWebTreatmentPetit();
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 event
|
* 페이지 event
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageEvent(){
|
function fn_pageEvent() {
|
||||||
// 검색 input
|
// 검색 input
|
||||||
$('.btnCancle').on("click", function(){
|
$('.btnCancle').on("click", function () {
|
||||||
fn_selectListWebTreatmentPetitIntro();
|
fn_selectListWebTreatmentPetitIntro();
|
||||||
});
|
});
|
||||||
|
|
||||||
$('.btnSave').on("click", function(){
|
$('.btnSave').on("click", function () {
|
||||||
fn_updateWebTreatmentPetit();
|
fn_updateWebTreatmentPetit();
|
||||||
});
|
});
|
||||||
$('#delete_btn').on("click", function(){
|
$('#delete_btn').on("click", function () {
|
||||||
fn_removePreview();
|
fn_removePreview();
|
||||||
});
|
});
|
||||||
|
|
||||||
$('#file').on('change', function(e) {
|
$('#file').on('change', function (e) {
|
||||||
fn_filePreview('800px', '450px', '.img_box');
|
fn_filePreview('800px', '450px', '.img_box');
|
||||||
})
|
})
|
||||||
$('#content_delete_btn').on("click", function(){
|
$('#content_delete_btn').on("click", function () {
|
||||||
fn_removeContentPreview();
|
fn_removeContentPreview();
|
||||||
});
|
});
|
||||||
$('#content_file').on('change', function(e) {
|
$('#content_file').on('change', function (e) {
|
||||||
fn_filePreview('100%', '100%', '.file_box');
|
fn_filePreview('100%', '100%', '.file_box');
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -363,37 +312,78 @@ function fn_pageEvent(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 시술 목록 팝업
|
* 시술 목록 팝업
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function listOpen(){
|
function listOpen() {
|
||||||
let reqParam = {};
|
let reqParam = {};
|
||||||
treatmentSelectModal.popup(function (obj, reqParam) {
|
treatmentSelectModal.popup(function (obj, reqParam) {
|
||||||
const childDivCount = $("#treatmentlist > div").length;
|
|
||||||
if($("#" + obj.treatmentProcedureId).length > 0){
|
let isDuplicate = false;
|
||||||
modalEvent.warning("", "이미 시술정보가 있습니다.");
|
treatmentList.forEach((item) => {
|
||||||
return;
|
if (item.muTreatmentProcedureId == obj.treatmentProcedureId) {
|
||||||
}
|
isDuplicate = true;
|
||||||
var htmlstring = `<div id="treatment`+childDivCount+`">
|
}
|
||||||
<input type="checkbox" id="`+obj.treatmentProcedureId+`" name="treatment">
|
});
|
||||||
<input type="hidden" name="treatmentprocedurelist" value="`+obj.treatmentProcedureId+`">
|
|
||||||
<input type="hidden" name="treatmentlist" value="`+obj.treatmentId+`">
|
if (isDuplicate) {
|
||||||
<label for="`+obj.treatmentProcedureId+`">`+obj.treatmentNm + `-` + obj.price.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") + `-` + obj.discountPrice.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",") +`</label>
|
modalEvent.warning("", "이미 시술정보가 있습니다.");
|
||||||
</div>`;
|
return;
|
||||||
$('#treatmentlist').append(htmlstring);
|
}
|
||||||
|
|
||||||
|
let newItem = {
|
||||||
|
treatmentProcedureName: obj.treatmentNm,
|
||||||
|
price: obj.price,
|
||||||
|
discountPrice: obj.discountPrice,
|
||||||
|
muTreatmentId: obj.treatmentId,
|
||||||
|
muTreatmentProcedureId: obj.treatmentProcedureId
|
||||||
|
};
|
||||||
|
treatmentList.push(newItem);
|
||||||
|
renderTreatmentTable();
|
||||||
|
|
||||||
}, reqParam);
|
}, reqParam);
|
||||||
}
|
}
|
||||||
function fn_removeRow(){
|
function fn_removeRow() {
|
||||||
$('input:checkbox[name="treatment"]').each(function() {
|
let checkboxes = document.getElementsByName('treatmentCheck');
|
||||||
if(this.checked){//checked 처리된 항목의 값
|
let indicesToRemove = [];
|
||||||
$(this).parent().remove();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
|
// Collect indices checking from end to start to maintain index validity
|
||||||
|
for (let i = checkboxes.length - 1; i >= 0; i--) {
|
||||||
|
if (checkboxes[i].checked) {
|
||||||
|
indicesToRemove.push(parseInt(checkboxes[i].value));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (indicesToRemove.length === 0) {
|
||||||
|
modalEvent.warning("", "삭제할 항목을 선택해주세요.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Remove items
|
||||||
|
indicesToRemove.forEach(index => {
|
||||||
|
treatmentList.splice(index, 1);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Uncheck "all" checkbox if checked
|
||||||
|
document.getElementById("checkAll").checked = false;
|
||||||
|
|
||||||
|
renderTreatmentTable();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$(function(){
|
$(function () {
|
||||||
// 페이지 init
|
// 페이지 init
|
||||||
fn_pageInit();
|
fn_pageInit();
|
||||||
|
|
||||||
// 페이지 event
|
// 페이지 event
|
||||||
fn_pageEvent();
|
fn_pageEvent();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
/* =========================================
|
||||||
|
PREVIEW LOGIC
|
||||||
|
========================================= */
|
||||||
|
function fn_openPreview() {
|
||||||
|
let url = "/contentsBbs/contentsBbsPreview.do";
|
||||||
|
window.open(url, "preview", "width=1280,height=900,scrollbars=yes");
|
||||||
|
}
|
||||||
|
|
||||||
|
function getTreatmentListForPreview() {
|
||||||
|
return treatmentList;
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,329 @@
|
|||||||
|
/**
|
||||||
|
* 문자 상용구 관리 - ag-Grid
|
||||||
|
*/
|
||||||
|
$(document).ready(function () {
|
||||||
|
fn_initGrid();
|
||||||
|
fn_init();
|
||||||
|
fn_loadTemplateList();
|
||||||
|
});
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
전역 변수
|
||||||
|
============================================ */
|
||||||
|
var gridApi = null;
|
||||||
|
var currentMode = ''; // 'new' | 'edit'
|
||||||
|
var currentTemplateId = '';
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
ag-Grid 초기화
|
||||||
|
============================================ */
|
||||||
|
function fn_initGrid() {
|
||||||
|
var columnDefs = [
|
||||||
|
{
|
||||||
|
headerName: 'No',
|
||||||
|
valueGetter: function (params) {
|
||||||
|
return params.node.rowIndex + 1;
|
||||||
|
},
|
||||||
|
width: 55,
|
||||||
|
maxWidth: 55,
|
||||||
|
cellStyle: { textAlign: 'center' },
|
||||||
|
suppressSizeToFit: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '제목',
|
||||||
|
field: 'title',
|
||||||
|
flex: 2,
|
||||||
|
minWidth: 120,
|
||||||
|
cellStyle: { textAlign: 'left' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '등록자',
|
||||||
|
field: 'regName',
|
||||||
|
width: 80,
|
||||||
|
maxWidth: 100,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
headerName: '등록일',
|
||||||
|
field: 'regDate',
|
||||||
|
width: 100,
|
||||||
|
maxWidth: 120,
|
||||||
|
cellStyle: { textAlign: 'center' }
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
var gridOptions = {
|
||||||
|
columnDefs: columnDefs,
|
||||||
|
rowData: [],
|
||||||
|
rowSelection: 'single',
|
||||||
|
animateRows: true,
|
||||||
|
headerHeight: 36,
|
||||||
|
rowHeight: 38,
|
||||||
|
suppressCellFocus: true,
|
||||||
|
overlayNoRowsTemplate: '<span style="color:#B5BDC4; font-size:13px;">등록된 상용구가 없습니다.</span>',
|
||||||
|
onRowClicked: function (event) {
|
||||||
|
var id = event.data.muSmsTemplateId;
|
||||||
|
if (id) fn_selectTemplate(id);
|
||||||
|
},
|
||||||
|
defaultColDef: {
|
||||||
|
resizable: true,
|
||||||
|
sortable: true
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
var gridDiv = document.querySelector('#smsTemplateGrid');
|
||||||
|
gridApi = new agGrid.Grid(gridDiv, gridOptions);
|
||||||
|
gridApi = gridOptions.api;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
초기화
|
||||||
|
============================================ */
|
||||||
|
function fn_init() {
|
||||||
|
$('#searchBtn').on('click', function () {
|
||||||
|
fn_loadTemplateList();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#searchKeyword').on('keypress', function (e) {
|
||||||
|
if (e.which === 13) fn_loadTemplateList();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#newTemplateBtn').on('click', function () {
|
||||||
|
fn_newTemplate();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#saveBtn').on('click', function () {
|
||||||
|
fn_saveTemplate();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#deleteBtn').on('click', function () {
|
||||||
|
fn_deleteTemplate();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#cancelBtn').on('click', function () {
|
||||||
|
fn_cancelEdit();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#templateContent').on('input', function () {
|
||||||
|
fn_updateByteCount();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
목록 조회
|
||||||
|
============================================ */
|
||||||
|
function fn_loadTemplateList() {
|
||||||
|
var param = {
|
||||||
|
searchKeyword: $('#searchKeyword').val(),
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/smsTemplate/getSmsTemplateList.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
var rows = data.rows || [];
|
||||||
|
gridApi.setRowData(rows);
|
||||||
|
|
||||||
|
if (rows.length === 0) {
|
||||||
|
gridApi.showNoRowsOverlay();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('목록 조회 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
상세 조회
|
||||||
|
============================================ */
|
||||||
|
function fn_selectTemplate(templateId) {
|
||||||
|
var param = {
|
||||||
|
muSmsTemplateId: templateId,
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/smsTemplate/getSmsTemplate.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
if (data.data) {
|
||||||
|
fn_showDetail(data.data);
|
||||||
|
} else {
|
||||||
|
alert(data.msgDesc || '상세 조회에 실패하였습니다.');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('상세 조회 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_showDetail(detail) {
|
||||||
|
currentMode = 'edit';
|
||||||
|
currentTemplateId = detail.muSmsTemplateId;
|
||||||
|
|
||||||
|
$('#detailTitle').text('상용구 수정');
|
||||||
|
$('#muSmsTemplateId').val(detail.muSmsTemplateId);
|
||||||
|
$('#templateTitle').val(detail.title || '');
|
||||||
|
$('#templateContent').val(detail.content || '');
|
||||||
|
$('#regName').text(detail.regName || '-');
|
||||||
|
$('#regDate').text(detail.regDate || '-');
|
||||||
|
$('#modDate').text(detail.modDate || '-');
|
||||||
|
|
||||||
|
$('#infoRow').show();
|
||||||
|
$('#deleteBtn').show();
|
||||||
|
$('#emptyState').hide();
|
||||||
|
$('#detailForm').show();
|
||||||
|
|
||||||
|
fn_updateByteCount();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
새 상용구
|
||||||
|
============================================ */
|
||||||
|
function fn_newTemplate() {
|
||||||
|
currentMode = 'new';
|
||||||
|
currentTemplateId = '';
|
||||||
|
|
||||||
|
$('#detailTitle').text('상용구 등록');
|
||||||
|
$('#muSmsTemplateId').val('');
|
||||||
|
$('#templateTitle').val('');
|
||||||
|
$('#templateContent').val('');
|
||||||
|
|
||||||
|
$('#infoRow').hide();
|
||||||
|
$('#deleteBtn').hide();
|
||||||
|
$('#emptyState').hide();
|
||||||
|
$('#detailForm').show();
|
||||||
|
|
||||||
|
fn_updateByteCount();
|
||||||
|
|
||||||
|
gridApi.deselectAll();
|
||||||
|
$('#templateTitle').focus();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
취소
|
||||||
|
============================================ */
|
||||||
|
function fn_cancelEdit() {
|
||||||
|
currentMode = '';
|
||||||
|
currentTemplateId = '';
|
||||||
|
|
||||||
|
$('#detailForm').hide();
|
||||||
|
$('#emptyState').show();
|
||||||
|
|
||||||
|
gridApi.deselectAll();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
저장 (등록/수정)
|
||||||
|
============================================ */
|
||||||
|
function fn_saveTemplate() {
|
||||||
|
var title = $.trim($('#templateTitle').val());
|
||||||
|
var content = $.trim($('#templateContent').val());
|
||||||
|
|
||||||
|
if (!title) {
|
||||||
|
alert('제목을 입력하세요.');
|
||||||
|
$('#templateTitle').focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!content) {
|
||||||
|
alert('내용을 입력하세요.');
|
||||||
|
$('#templateContent').focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
var url = '';
|
||||||
|
var param = {
|
||||||
|
title: title,
|
||||||
|
content: content,
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
if (currentMode === 'new') {
|
||||||
|
url = '/smsTemplate/putSmsTemplate.do';
|
||||||
|
} else if (currentMode === 'edit') {
|
||||||
|
url = '/smsTemplate/modSmsTemplate.do';
|
||||||
|
param.muSmsTemplateId = currentTemplateId;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!url) return;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: url,
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
alert(data.msgDesc || '처리되었습니다.');
|
||||||
|
fn_cancelEdit();
|
||||||
|
fn_loadTemplateList();
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('저장 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
삭제
|
||||||
|
============================================ */
|
||||||
|
function fn_deleteTemplate() {
|
||||||
|
if (!currentTemplateId) return;
|
||||||
|
if (!confirm('이 상용구를 삭제하시겠습니까?')) return;
|
||||||
|
|
||||||
|
var param = {
|
||||||
|
muSmsTemplateId: currentTemplateId,
|
||||||
|
menuClass: menuClass
|
||||||
|
};
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: '/smsTemplate/delSmsTemplate.do',
|
||||||
|
type: 'POST',
|
||||||
|
data: param,
|
||||||
|
dataType: 'json',
|
||||||
|
success: function (data) {
|
||||||
|
alert(data.msgDesc || '삭제되었습니다.');
|
||||||
|
fn_cancelEdit();
|
||||||
|
fn_loadTemplateList();
|
||||||
|
},
|
||||||
|
error: function () {
|
||||||
|
alert('삭제 중 오류가 발생하였습니다.');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================
|
||||||
|
바이트 카운트
|
||||||
|
============================================ */
|
||||||
|
function fn_updateByteCount() {
|
||||||
|
var content = $('#templateContent').val() || '';
|
||||||
|
var byteLen = fn_getByteLength(content);
|
||||||
|
|
||||||
|
$('#byteCount').text(byteLen);
|
||||||
|
|
||||||
|
var $badge = $('#typeBadge');
|
||||||
|
if (byteLen > 90) {
|
||||||
|
$badge.text('LMS').removeClass('sms').addClass('lms');
|
||||||
|
} else {
|
||||||
|
$badge.text('SMS').removeClass('lms').addClass('sms');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function fn_getByteLength(str) {
|
||||||
|
var byte = 0;
|
||||||
|
for (var i = 0; i < str.length; i++) {
|
||||||
|
if (str.charCodeAt(i) <= 0x7F) {
|
||||||
|
byte += 1;
|
||||||
|
} else {
|
||||||
|
byte += 2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return byte;
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
/* 페이징 관련 변수 */
|
/* 페이징 관련 변수 */
|
||||||
let webPopupTotalCount = 0;
|
let webPopupTotalCount = 0;
|
||||||
let webPopupTotalPages = 0;
|
let webPopupTotalPages = 0;
|
||||||
|
|
||||||
/*aggird*/
|
/*aggird*/
|
||||||
let webPopupAgGridData = [];
|
let webPopupAgGridData = [];
|
||||||
@@ -10,7 +10,7 @@ let webPopupSelectId = "";
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 콘텐츠 정보 리스트 조회
|
* 콘텐츠 정보 리스트 조회
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_selectListWebPopupJson(){
|
function fn_selectListWebPopupJson() {
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("webPopupSearchKeywordParam", webPopupSearchKeywordParam);
|
formData.append("webPopupSearchKeywordParam", webPopupSearchKeywordParam);
|
||||||
@@ -19,7 +19,7 @@ function fn_selectListWebPopupJson(){
|
|||||||
formData.append("webPopupDir", webPopupDir);
|
formData.append("webPopupDir", webPopupDir);
|
||||||
formData.append("webPopupStart", webPopupStart);
|
formData.append("webPopupStart", webPopupStart);
|
||||||
formData.append("webPopupLimit", webPopupLimit);
|
formData.append("webPopupLimit", webPopupLimit);
|
||||||
formData.append("homepageDivCd", $("#homepageDivCd").val());
|
formData.append("homepageDivCd", $("#homepageDivCd").val());
|
||||||
//formData.append("webPopupSearchStartDate", webPopupSearchStartDate);
|
//formData.append("webPopupSearchStartDate", webPopupSearchStartDate);
|
||||||
//formData.append("webPopupSearchEndDate", webPopupSearchEndDate);
|
//formData.append("webPopupSearchEndDate", webPopupSearchEndDate);
|
||||||
//formData.append("webPopupSearchDateType", webPopupSearchDateType);
|
//formData.append("webPopupSearchDateType", webPopupSearchDateType);
|
||||||
@@ -32,34 +32,34 @@ function fn_selectListWebPopupJson(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
// 페이징 처리
|
// 페이징 처리
|
||||||
webPopupTotalCount = data.totalCount;
|
webPopupTotalCount = data.totalCount;
|
||||||
//$("#txt_noticeTotalCount").text(noticeTotalCount);
|
//$("#txt_noticeTotalCount").text(noticeTotalCount);
|
||||||
|
|
||||||
webPopupTotalPages = Math.ceil(webPopupTotalCount/webPopupLimit);
|
webPopupTotalPages = Math.ceil(webPopupTotalCount / webPopupLimit);
|
||||||
|
|
||||||
// 리스트 조회
|
// 리스트 조회
|
||||||
webPopupAgGridData = data.rows.map(row => {
|
webPopupAgGridData = data.rows.map(row => {
|
||||||
if(row.filePath) {
|
if (row.filePath) {
|
||||||
return { ...row, filePath: CDN_URL + row.filePath.replace(/^C:/, "") };
|
return { ...row, filePath: CDN_URL + row.filePath.replace(/^C:/, "") };
|
||||||
}
|
}
|
||||||
return row;
|
return row;
|
||||||
});
|
});
|
||||||
webPopupGridOptions.api.setRowData(webPopupAgGridData);
|
webPopupGridOptions.api.setRowData(webPopupAgGridData);
|
||||||
|
|
||||||
if(0<data.rows.length){
|
if (0 < data.rows.length) {
|
||||||
//페이징 처리
|
//페이징 처리
|
||||||
window.pagObj = $('#webPopupPagination').twbsPagination({
|
window.pagObj = $('#webPopupPagination').twbsPagination({
|
||||||
startPage : ((webPopupStart/webPopupLimit)+1),
|
startPage: ((webPopupStart / webPopupLimit) + 1),
|
||||||
totalPages : (webPopupTotalPages==0)?1:webPopupTotalPages,
|
totalPages: (webPopupTotalPages == 0) ? 1 : webPopupTotalPages,
|
||||||
visiblePages : 10,
|
visiblePages: 10,
|
||||||
initiateStartPageClick: false,
|
initiateStartPageClick: false,
|
||||||
prev : '<img src="/image/web/page_navigation_arrow.svg" alt="prev"/>',
|
prev: '<img src="/image/web/page_navigation_arrow.svg" alt="prev"/>',
|
||||||
next : '<img src="/image/web/page_navigation_arrow.svg" alt="next"/>',
|
next: '<img src="/image/web/page_navigation_arrow.svg" alt="next"/>',
|
||||||
first : '',
|
first: '',
|
||||||
last : '',
|
last: '',
|
||||||
onPageClick: function (event, page) {
|
onPageClick: function (event, page) {
|
||||||
fn_webPopupPagination(page);
|
fn_webPopupPagination(page);
|
||||||
}
|
}
|
||||||
@@ -67,22 +67,22 @@ function fn_selectListWebPopupJson(){
|
|||||||
//console.info(page + ' (from event listening)');
|
//console.info(page + ' (from event listening)');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("조회 오류", data.msgDesc);
|
modalEvent.danger("조회 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("조회 오류", "조회 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("조회 오류", "조회 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
// 로딩열기
|
// 로딩열기
|
||||||
webPopupGridOptions.api.showLoadingOverlay();
|
webPopupGridOptions.api.showLoadingOverlay();
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -91,8 +91,8 @@ function fn_selectListWebPopupJson(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색하기
|
* 검색하기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupSearch(param){
|
function fn_webPopupSearch(param) {
|
||||||
if("A"!=param && "Y"!=selectUseYn){
|
if ("A" != param && "Y" != selectUseYn) {
|
||||||
modalEvent.warning("", "조회 권한이 없습니다.");
|
modalEvent.warning("", "조회 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -114,7 +114,7 @@ function fn_webPopupSearch(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 초기화하기
|
* 초기화하기
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupReset(){
|
function fn_webPopupReset() {
|
||||||
$("#webPopupSearchKeyword").val("");
|
$("#webPopupSearchKeyword").val("");
|
||||||
|
|
||||||
fn_webPopupSearch();
|
fn_webPopupSearch();
|
||||||
@@ -123,8 +123,8 @@ function fn_webPopupReset(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이징 처리
|
* 페이징 처리
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupPagination(param){
|
function fn_webPopupPagination(param) {
|
||||||
webPopupStart = (parseInt(param)-1)*webPopupLimit;
|
webPopupStart = (parseInt(param) - 1) * webPopupLimit;
|
||||||
|
|
||||||
fn_selectListWebPopupJson();
|
fn_selectListWebPopupJson();
|
||||||
}
|
}
|
||||||
@@ -132,16 +132,16 @@ function fn_webPopupPagination(param){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이징 리셋
|
* 페이징 리셋
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupPaginReset(){
|
function fn_webPopupPaginReset() {
|
||||||
webPopupSearchKeywordParam = '';
|
webPopupSearchKeywordParam = '';
|
||||||
|
|
||||||
webPopupStart = 0;
|
webPopupStart = 0;
|
||||||
webPopupLimit = 100;
|
webPopupLimit = 100;
|
||||||
webPopupTotalCount = 0;
|
webPopupTotalCount = 0;
|
||||||
webPopupTotalPages = 0;
|
webPopupTotalPages = 0;
|
||||||
|
|
||||||
//페이징 초기화
|
//페이징 초기화
|
||||||
if($("#webPopupPagination").data("twbs-pagination")){
|
if ($("#webPopupPagination").data("twbs-pagination")) {
|
||||||
$("#webPopupPagination").twbsPagination("destroy");
|
$("#webPopupPagination").twbsPagination("destroy");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -149,18 +149,18 @@ function fn_webPopupPaginReset(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 콘텐츠 삭제
|
* 콘텐츠 삭제
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_deleteWebPopup(){
|
function fn_deleteWebPopup() {
|
||||||
if("Y"!=deleteUseYn){
|
if ("Y" != deleteUseYn) {
|
||||||
modalEvent.warning("", "삭제 권한이 없습니다.");
|
modalEvent.warning("", "삭제 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!webPopupSelectId){
|
if (!webPopupSelectId) {
|
||||||
modalEvent.warning("", "삭제할 대상을 선택하세요.");
|
modalEvent.warning("", "삭제할 대상을 선택하세요.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
modalEvent.info("삭제", "선택한 콘텐츠 정보를 삭제하시겠습니까?", function(){
|
modalEvent.info("삭제", "선택한 콘텐츠 정보를 삭제하시겠습니까?", function () {
|
||||||
let formData = new FormData();
|
let formData = new FormData();
|
||||||
formData.append("menuClass", menuClass);
|
formData.append("menuClass", menuClass);
|
||||||
formData.append("selectId", webPopupSelectId);
|
formData.append("selectId", webPopupSelectId);
|
||||||
@@ -173,23 +173,23 @@ function fn_deleteWebPopup(){
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
async: true,
|
async: true,
|
||||||
success: function(data){
|
success: function (data) {
|
||||||
if('0'==data.msgCode){
|
if ('0' == data.msgCode) {
|
||||||
modalEvent.success("삭제 성공", data.msgDesc, function(){
|
modalEvent.success("삭제 성공", data.msgDesc, function () {
|
||||||
fn_webPopupOk();
|
fn_webPopupOk();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
modalEvent.danger("삭제 오류", data.msgDesc);
|
modalEvent.danger("삭제 오류", data.msgDesc);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error : function(xhr, status, error) {
|
error: function (xhr, status, error) {
|
||||||
modalEvent.danger("삭제 오류", "삭제 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
modalEvent.danger("삭제 오류", "삭제 중 오류가 발생하였습니다. 잠시후 다시시도하십시오.");
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
beforeSend: function () {
|
||||||
|
|
||||||
},
|
},
|
||||||
complete:function(){
|
complete: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -199,17 +199,17 @@ function fn_deleteWebPopup(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 검색 엔터 이벤트
|
* 검색 엔터 이벤트
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupEnter(e){
|
function fn_webPopupEnter(e) {
|
||||||
if(e.which){
|
if (e.which) {
|
||||||
// 파이어폭스
|
// 파이어폭스
|
||||||
if(13 == e.which) {
|
if (13 == e.which) {
|
||||||
//로그인 액션 스크립트
|
//로그인 액션 스크립트
|
||||||
fn_webPopupSearch();
|
fn_webPopupSearch();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
// 윈도우, 사파리, 크롬
|
// 윈도우, 사파리, 크롬
|
||||||
if(13 == event.keyCode) {
|
if (13 == event.keyCode) {
|
||||||
//로그인 액션 스크립트
|
//로그인 액션 스크립트
|
||||||
fn_webPopupSearch();
|
fn_webPopupSearch();
|
||||||
}
|
}
|
||||||
@@ -219,23 +219,23 @@ function fn_webPopupEnter(e){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 완료
|
* 완료
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_webPopupOk(){
|
function fn_webPopupOk() {
|
||||||
fn_webPopupReset();
|
fn_webPopupReset();
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 등록 화면으로 이동.
|
* 등록 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_insertWebPopupIntro(){
|
function fn_insertWebPopupIntro() {
|
||||||
if("Y"==insertUseYn){
|
if ("Y" == insertUseYn) {
|
||||||
if(10<=webPopupAgGridData.length){
|
if (10 <= webPopupAgGridData.length) {
|
||||||
modalEvent.warning("", "등록 갯수를 초과하였습니다.");
|
modalEvent.warning("", "등록 갯수를 초과하였습니다.");
|
||||||
return false;
|
return false;
|
||||||
}else{
|
} else {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
fn_leftFormAction("/webpopup/insertWebPopupIntro.do"+pagingParam);
|
fn_leftFormAction("/webpopup/insertWebPopupIntro.do" + pagingParam);
|
||||||
}
|
}
|
||||||
}else{
|
} else {
|
||||||
modalEvent.warning("", "등록 권한이 없습니다.");
|
modalEvent.warning("", "등록 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -245,38 +245,40 @@ function fn_insertWebPopupIntro(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 수정 화면으로 이동.
|
* 수정 화면으로 이동.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_updateWebPopupIntro(muWebPopupId){
|
function fn_updateWebPopupIntro(muWebPopupId) {
|
||||||
if("Y"==updateUseYn){
|
if ("Y" == updateUseYn) {
|
||||||
let pagingParam = "?menuClass="+menuClass;
|
let pagingParam = "?menuClass=" + menuClass;
|
||||||
pagingParam += "&muWebPopupId="+muWebPopupId;
|
pagingParam += "&muWebPopupId=" + muWebPopupId;
|
||||||
fn_leftFormAction("/webpopup/updateWebPopupIntro.do"+pagingParam);
|
fn_leftFormAction("/webpopup/updateWebPopupIntro.do" + pagingParam);
|
||||||
}else{
|
} else {
|
||||||
modalEvent.warning("", "수정 권한이 없습니다.");
|
modalEvent.warning("", "수정 권한이 없습니다.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
function thumbnailCellRenderer(params) {
|
function thumbnailCellRenderer(params) {
|
||||||
if(!params.value)
|
if (!params.value)
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
return `<img src="${params.value.replace("C:", "")}" width="40" height="40" alt="Thumbnail">`;
|
return `<img src="${params.value.replace("C:", "")}" width="40" height="40" alt="Thumbnail">`;
|
||||||
}
|
}
|
||||||
|
|
||||||
let webPopupColumnDefs = [
|
let webPopupColumnDefs = [
|
||||||
{field: "checkbox", headerName:"", minWidth:55, maxWidth:55, headerCheckboxSelection: true, checkboxSelection: true},
|
{ field: "checkbox", headerName: "", minWidth: 55, maxWidth: 55, headerCheckboxSelection: true, checkboxSelection: true },
|
||||||
/* {field: "rowNum", headerName:"번호", minWidth:80,maxWidth:80, sortable: false}, */
|
/* {field: "rowNum", headerName:"번호", minWidth:80,maxWidth:80, sortable: false}, */
|
||||||
{field: "rowNum", headerName:"번호", minWidth:60, maxWidth:60,sortable: false, cellStyle:{textAlign: 'center'}},
|
{ field: "rowNum", headerName: "번호", minWidth: 60, maxWidth: 60, sortable: false, cellStyle: { textAlign: 'center' } },
|
||||||
{field: "homepageDivCd", headerName:"홈페이지 구분", minWidth:150, maxWidth:150, cellStyle:{textAlign: 'center'},
|
{
|
||||||
valueFormatter: function(params) {
|
field: "homepageDivCd", headerName: "홈페이지 구분", minWidth: 150, maxWidth: 150, cellStyle: { textAlign: 'center' },
|
||||||
if (params.value === "01") return "다이어트";
|
valueFormatter: function (params) {
|
||||||
if (params.value === "02") return "쁘띠";
|
if (params.value === "01") return "다이어트";
|
||||||
return params.value;
|
if (params.value === "02") return "쁘띠";
|
||||||
}},
|
return params.value;
|
||||||
{field: "filePath", headerName:"이미지", minWidth:100, cellRenderer: thumbnailCellRenderer},
|
}
|
||||||
{field: "title", headerName:"제목", minWidth:250, cellStyle:{cursor: 'pointer', color:'#3985EA'}},
|
},
|
||||||
|
{ field: "filePath", headerName: "이미지", minWidth: 100, cellRenderer: thumbnailCellRenderer },
|
||||||
|
{ field: "title", headerName: "제목", minWidth: 250, cellStyle: { cursor: 'pointer', color: '#3985EA' } },
|
||||||
// {field: "content", headerName:"내용",minWidth:500},
|
// {field: "content", headerName:"내용",minWidth:500},
|
||||||
{field: "writeDate", headerName:"등록일",minWidth:150, maxWidth:150},
|
{ field: "writeDate", headerName: "등록일", minWidth: 150, maxWidth: 150 },
|
||||||
{field: "writeName", headerName:"작성자",minWidth:150, maxWidth:150},
|
{ field: "writeName", headerName: "작성자", minWidth: 150, maxWidth: 150 },
|
||||||
];
|
];
|
||||||
|
|
||||||
// let the grid know which columns and what data to use
|
// let the grid know which columns and what data to use
|
||||||
@@ -288,60 +290,60 @@ let webPopupGridOptions = {
|
|||||||
sortable: true, //정렬 여부
|
sortable: true, //정렬 여부
|
||||||
resizable: true, //리사이즈
|
resizable: true, //리사이즈
|
||||||
editable: false, // 그리드에서 데이터 수정
|
editable: false, // 그리드에서 데이터 수정
|
||||||
cellStyle:{textAlign:'left',fontSize:'14px',padding:'0'},
|
cellStyle: { textAlign: 'left', fontSize: '14px', padding: '0' },
|
||||||
//suppressSizeToFit:true, //자동 맞춤
|
//suppressSizeToFit:true, //자동 맞춤
|
||||||
//enableRowGroup: true, // 그룹 묶음
|
//enableRowGroup: true, // 그룹 묶음
|
||||||
enablePivot: true,
|
enablePivot: true,
|
||||||
enableValue : true
|
enableValue: true
|
||||||
},
|
},
|
||||||
//suppressMultiSort:true, //단일솔트 true가 단일, false가 다중 shift + sort 시
|
//suppressMultiSort:true, //단일솔트 true가 단일, false가 다중 shift + sort 시
|
||||||
headerHeight : 41, // header 높이
|
headerHeight: 41, // header 높이
|
||||||
rowHeight : 41, // row 높이
|
rowHeight: 41, // row 높이
|
||||||
rowData : webPopupAgGridData,
|
rowData: webPopupAgGridData,
|
||||||
suppressRowClickSelection : true, // 로우 클릭시 체크박스 선택 true no, false yes
|
suppressRowClickSelection: true, // 로우 클릭시 체크박스 선택 true no, false yes
|
||||||
localeText : {
|
localeText: {
|
||||||
noRowsToShow : '조회 결과가 없습니다.'
|
noRowsToShow: '조회 결과가 없습니다.'
|
||||||
}, //데이터 없을 시 나오는 문구
|
}, //데이터 없을 시 나오는 문구
|
||||||
rowSelection : 'multiple', // row 다중 선택
|
rowSelection: 'multiple', // row 다중 선택
|
||||||
debug : false,
|
debug: false,
|
||||||
onCellClicked: function(event){ //셀 클릭 이벤트
|
onCellClicked: function (event) { //셀 클릭 이벤트
|
||||||
/* alert(event.column.colId); */
|
/* alert(event.column.colId); */
|
||||||
if('title'==event.column.colId){
|
if ('title' == event.column.colId) {
|
||||||
fn_updateWebPopupIntro(event.data.muWebPopupId);
|
fn_updateWebPopupIntro(event.data.muWebPopupId);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onSelectionChanged: function(event){ //체크박스 선택
|
onSelectionChanged: function (event) { //체크박스 선택
|
||||||
let selectRows = [];
|
let selectRows = [];
|
||||||
selectRows = event.api.getSelectedRows();
|
selectRows = event.api.getSelectedRows();
|
||||||
|
|
||||||
webPopupSelectId = '';
|
webPopupSelectId = '';
|
||||||
for(let i=0; i<selectRows.length; i++){
|
for (let i = 0; i < selectRows.length; i++) {
|
||||||
webPopupSelectId += selectRows[i].muWebPopupId + ",";
|
webPopupSelectId += selectRows[i].muWebPopupId + ",";
|
||||||
}
|
}
|
||||||
webPopupSelectId = webPopupSelectId.substring(0, webPopupSelectId.lastIndexOf(','));
|
webPopupSelectId = webPopupSelectId.substring(0, webPopupSelectId.lastIndexOf(','));
|
||||||
},
|
},
|
||||||
onSortChanged: function(event){
|
onSortChanged: function (event) {
|
||||||
//정렬
|
//정렬
|
||||||
webPopupSort = ''; //기존 정렬 초기화
|
webPopupSort = ''; //기존 정렬 초기화
|
||||||
let columnArr = event.columnApi.getColumnState();
|
let columnArr = event.columnApi.getColumnState();
|
||||||
if(0<columnArr.length){
|
if (0 < columnArr.length) {
|
||||||
//sort index 순으로 재정렬
|
//sort index 순으로 재정렬
|
||||||
columnArr.sort(function(a,b){
|
columnArr.sort(function (a, b) {
|
||||||
return a.sortIndex - b.sortIndex;
|
return a.sortIndex - b.sortIndex;
|
||||||
});
|
});
|
||||||
|
|
||||||
let nullCnt = 0;
|
let nullCnt = 0;
|
||||||
for(let i=0; i<columnArr.length; i++){
|
for (let i = 0; i < columnArr.length; i++) {
|
||||||
let gridSortModel = columnArr[i].colId;
|
let gridSortModel = columnArr[i].colId;
|
||||||
let gridSort = columnArr[i].sort;
|
let gridSort = columnArr[i].sort;
|
||||||
|
|
||||||
if(gridSort != null){
|
if (gridSort != null) {
|
||||||
webPopupStart = 0;
|
webPopupStart = 0;
|
||||||
webPopupSort += gridSortModel+' '+ gridSort + ',';
|
webPopupSort += gridSortModel + ' ' + gridSort + ',';
|
||||||
}
|
}
|
||||||
else{
|
else {
|
||||||
nullCnt++;
|
nullCnt++;
|
||||||
if(nullCnt == columnArr.length){
|
if (nullCnt == columnArr.length) {
|
||||||
webPopupSort = '';
|
webPopupSort = '';
|
||||||
webPopupDir = '';
|
webPopupDir = '';
|
||||||
webPopupStart = 0;
|
webPopupStart = 0;
|
||||||
@@ -349,7 +351,7 @@ let webPopupGridOptions = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
webPopupSort = webPopupSort.substring(0,webPopupSort.lastIndexOf( ",")); //맨끝 콤마 지우기
|
webPopupSort = webPopupSort.substring(0, webPopupSort.lastIndexOf(",")); //맨끝 콤마 지우기
|
||||||
|
|
||||||
fn_webPopupSearch();
|
fn_webPopupSearch();
|
||||||
}
|
}
|
||||||
@@ -368,7 +370,7 @@ new agGrid.Grid(webPopupGridDiv, webPopupGridOptions);
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 init
|
* 페이지 init
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageInit(){
|
function fn_pageInit() {
|
||||||
|
|
||||||
// 초기 페이징 처리
|
// 초기 페이징 처리
|
||||||
$("#webPopupSearchKeyword").val(webPopupSearchKeywordParam);
|
$("#webPopupSearchKeyword").val(webPopupSearchKeywordParam);
|
||||||
@@ -379,9 +381,9 @@ function fn_pageInit(){
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* 페이지 event
|
* 페이지 event
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
function fn_pageEvent(){
|
function fn_pageEvent() {
|
||||||
// 검색 input
|
// 검색 input
|
||||||
$(document).on('keypress', '#webPopupSearchKeyword', function(e) {
|
$(document).on('keypress', '#webPopupSearchKeyword', function (e) {
|
||||||
fn_webPopupEnter(e);
|
fn_webPopupEnter(e);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -399,9 +401,23 @@ function fn_pageEvent(){
|
|||||||
$("#btnDeleteWebPopup").click(function () {
|
$("#btnDeleteWebPopup").click(function () {
|
||||||
fn_deleteWebPopup();
|
fn_deleteWebPopup();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// 홈페이지 구분 선택 콤보 이벤트
|
||||||
|
const homepageTarget = $("#homepageDivCd").siblings("ul.select_option_list");
|
||||||
|
homepageTarget.find("li.option_list_item").click(function () {
|
||||||
|
let selectIdArr = $(this).prop("id").split('_');
|
||||||
|
let selectId = selectIdArr[1];
|
||||||
|
let selectName = $(this).text();
|
||||||
|
|
||||||
|
if (selectId.match("ALL")) {
|
||||||
|
selectId = '';
|
||||||
|
}
|
||||||
|
$(this).parent().siblings("button").text(selectName);
|
||||||
|
$(this).parent().siblings("input").val(selectId);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
$(function(){
|
$(function () {
|
||||||
// 페이지 init
|
// 페이지 init
|
||||||
fn_pageInit();
|
fn_pageInit();
|
||||||
|
|
||||||
|
|||||||
126
src/main/resources/templates/web/callLog/callLogSelectList.html
Normal file
126
src/main/resources/templates/web/callLog/callLogSelectList.html
Normal file
@@ -0,0 +1,126 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
|
<th:block layout:fragment="layout_css">
|
||||||
|
<link rel="stylesheet" href="/css/web/webFeedbackSelectList.css">
|
||||||
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
|
<link rel="stylesheet" href="/css/web/call_log.css">
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_top_script">
|
||||||
|
<script>
|
||||||
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
</script>
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_content">
|
||||||
|
<!-- 센터쪽 -->
|
||||||
|
<div class="center_box">
|
||||||
|
<p class="page_title">통화 로그 관리</p>
|
||||||
|
|
||||||
|
<!-- 검색 필터 영역 -->
|
||||||
|
<div class="cl_filter_wrap">
|
||||||
|
<!-- 1행: 구분 필터 -->
|
||||||
|
<div class="cl_filter_row">
|
||||||
|
<div class="cl_filter_item">
|
||||||
|
<label>구분1</label>
|
||||||
|
<select id="callType" class="cl_select">
|
||||||
|
<option value="">전체</option>
|
||||||
|
<option value="1">상담</option>
|
||||||
|
<option value="2">예약</option>
|
||||||
|
<option value="3">위치안내</option>
|
||||||
|
<option value="callback">Call Back</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<div class="cl_filter_item">
|
||||||
|
<label>구분2</label>
|
||||||
|
<select id="callType1" class="cl_select">
|
||||||
|
<option value="">전체</option>
|
||||||
|
<option value="초진">초진</option>
|
||||||
|
<option value="재진">재진</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<div class="cl_filter_item">
|
||||||
|
<label>구분3</label>
|
||||||
|
<select id="callType2" class="cl_select">
|
||||||
|
<option value="">전체</option>
|
||||||
|
<option value="상담">상담</option>
|
||||||
|
<option value="상담후예약">상담후예약</option>
|
||||||
|
<option value="회차예약">회차예약</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
<div class="cl_filter_item">
|
||||||
|
<label>고객전화번호</label>
|
||||||
|
<input type="text" id="mCid" placeholder="전화번호 입력" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 2행: 날짜 필터 -->
|
||||||
|
<div class="cl_filter_row">
|
||||||
|
<div class="cl_filter_item cl_date_item">
|
||||||
|
<label>검색일자</label>
|
||||||
|
<input type="date" id="sDate" />
|
||||||
|
<span class="cl_date_sep">~</span>
|
||||||
|
<input type="date" id="eDate" />
|
||||||
|
</div>
|
||||||
|
<div class="cl_quick_btns">
|
||||||
|
<button type="button" onclick="fn_dayChk('t')">오늘</button>
|
||||||
|
<button type="button" onclick="fn_dayChk('p')">어제</button>
|
||||||
|
<button type="button" onclick="fn_dayChk('w')">이번주</button>
|
||||||
|
<button type="button" onclick="fn_dayChk('pw')">지난주</button>
|
||||||
|
<button type="button" onclick="fn_dayChk('m')">이번달</button>
|
||||||
|
<button type="button" onclick="fn_dayChk('pm')">지난달</button>
|
||||||
|
</div>
|
||||||
|
<button type="button" id="searchBtn" class="cl_search_btn">조회</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 통계 요약 바 -->
|
||||||
|
<div class="cl_stats_bar">
|
||||||
|
<span>전체: <strong id="statTotal">0</strong></span>
|
||||||
|
<span class="cl_stats_sep">|</span>
|
||||||
|
<span>IN: <strong id="statIn">0</strong></span>
|
||||||
|
<span class="cl_stats_detail">[초진: <strong id="statType1">0</strong> / 재진: <strong
|
||||||
|
id="statType2">0</strong>]</span>
|
||||||
|
<span class="cl_stats_detail">[상담: <strong id="statType11">0</strong> / 상담후예약: <strong
|
||||||
|
id="statType12">0</strong> / 회차예약: <strong id="statType13">0</strong>]</span>
|
||||||
|
<span class="cl_stats_sep">|</span>
|
||||||
|
<span>OUT: <strong id="statOut">0</strong></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- ag-Grid 테이블 -->
|
||||||
|
<div id="callLogGrid" class="cl_grid_box ag-theme-balham"></div>
|
||||||
|
|
||||||
|
<!-- 메모 팝업 -->
|
||||||
|
<div class="cl_memo_overlay" id="memoOverlay" style="display:none;">
|
||||||
|
<div class="cl_memo_popup">
|
||||||
|
<div class="cl_memo_header">
|
||||||
|
<h3>통화 메모</h3>
|
||||||
|
<span class="cl_memo_record" id="memoRecordNo"></span>
|
||||||
|
<button type="button" class="cl_memo_close" onclick="fn_closeMemo()">×</button>
|
||||||
|
</div>
|
||||||
|
<div class="cl_memo_body">
|
||||||
|
<input type="hidden" id="memoRecordNoVal" />
|
||||||
|
<textarea id="memoContent" placeholder="메모를 입력하세요" rows="6"></textarea>
|
||||||
|
</div>
|
||||||
|
<div class="cl_memo_footer">
|
||||||
|
<button type="button" class="cl_memo_save_btn" onclick="fn_saveMemo()">저장</button>
|
||||||
|
<button type="button" class="cl_memo_cancel_btn" onclick="fn_closeMemo()">취소</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<form id="callLogForm" onsubmit="return false;"></form>
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_popup">
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_script">
|
||||||
|
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
||||||
|
<script src="/js/web/callLog/callLogSelectList.js"></script>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,729 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/layout}">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
|
|
||||||
|
<th:block layout:fragment="layout_css">
|
||||||
|
<!-- Choices.js CSS -->
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/choices.js/10.2.0/choices.min.css" />
|
||||||
|
|
||||||
|
<style>
|
||||||
|
* {
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: 'Noto Sans KR', sans-serif;
|
||||||
|
margin: 0;
|
||||||
|
background: #f7f7f9;
|
||||||
|
color: #222;
|
||||||
|
}
|
||||||
|
|
||||||
|
#service-header {
|
||||||
|
background: #fff;
|
||||||
|
border-bottom: 1px solid #ececec;
|
||||||
|
padding: 14px 0 14px 24px;
|
||||||
|
font-size: 0.98em;
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.main-wrap {
|
||||||
|
max-width: 1280px;
|
||||||
|
margin: 0 auto;
|
||||||
|
background: #fff;
|
||||||
|
border-radius: 18px;
|
||||||
|
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
|
||||||
|
margin-top: 32px;
|
||||||
|
padding: 0 0 32px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-section {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
gap: 32px;
|
||||||
|
padding: 32px 32px 0 32px;
|
||||||
|
align-items: flex-start;
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-box {
|
||||||
|
border-radius: 18px;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-box img {
|
||||||
|
width: 100%;
|
||||||
|
object-fit: cover;
|
||||||
|
border-radius: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box {
|
||||||
|
flex: 1 1 300px;
|
||||||
|
min-width: 240px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-title {
|
||||||
|
font-size: 1.7em;
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 6px;
|
||||||
|
color: #222;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-desc {
|
||||||
|
color: #444;
|
||||||
|
font-size: 1.1em;
|
||||||
|
margin-bottom: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-price {
|
||||||
|
font-size: 1.2em;
|
||||||
|
font-weight: 700;
|
||||||
|
color: #b23c3c;
|
||||||
|
margin-bottom: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.select-row {
|
||||||
|
margin-bottom: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.select-row label {
|
||||||
|
font-weight: 500;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.total-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 1.1em;
|
||||||
|
margin-bottom: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.total-row .total-label {
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
|
||||||
|
.total-row .total-price {
|
||||||
|
font-weight: bold;
|
||||||
|
color: #b23c3c;
|
||||||
|
}
|
||||||
|
|
||||||
|
.reserve-btn {
|
||||||
|
width: 100%;
|
||||||
|
padding: 14px 0;
|
||||||
|
background: #b23c3c;
|
||||||
|
color: #fff;
|
||||||
|
border: none;
|
||||||
|
border-radius: 8px;
|
||||||
|
font-size: 1.1em;
|
||||||
|
font-weight: bold;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: background 0.15s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.reserve-btn:disabled {
|
||||||
|
background: #ddd;
|
||||||
|
color: #888;
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
|
||||||
|
.desc-section {
|
||||||
|
margin-top: 36px;
|
||||||
|
padding: 0 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.desc-title {
|
||||||
|
font-size: 1.25em;
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 12px;
|
||||||
|
color: #222;
|
||||||
|
}
|
||||||
|
|
||||||
|
.desc-content {
|
||||||
|
color: #444;
|
||||||
|
font-size: 1.05em;
|
||||||
|
line-height: 1.7;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hashtag-section {
|
||||||
|
margin-top: 30px;
|
||||||
|
padding: 20px 0;
|
||||||
|
border-top: 1px solid #eee;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hashtag-container {
|
||||||
|
max-width: 1200px;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 0 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hashtag-list {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
gap: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hashtag {
|
||||||
|
display: inline-block;
|
||||||
|
background-color: #f8f9fa;
|
||||||
|
color: #495057;
|
||||||
|
padding: 8px 15px;
|
||||||
|
border-radius: 20px;
|
||||||
|
font-size: 14px;
|
||||||
|
text-decoration: none;
|
||||||
|
border: 1px solid #dee2e6;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hashtag:hover {
|
||||||
|
background-color: #007bff;
|
||||||
|
color: white;
|
||||||
|
border-color: #007bff;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
#thumbnail-bottom-txt {
|
||||||
|
padding: 8px;
|
||||||
|
margin-top: 10px;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Choices.js 커스터마이징 - 개선된 버전 */
|
||||||
|
.choices {
|
||||||
|
border: 1px solid #ddd !important;
|
||||||
|
border-radius: 6px !important;
|
||||||
|
font-size: 1em !important;
|
||||||
|
background: #fff !important;
|
||||||
|
min-width: 300px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__inner {
|
||||||
|
background: #fff !important;
|
||||||
|
padding: 8px 12px !important;
|
||||||
|
min-height: 40px !important;
|
||||||
|
color: #222 !important;
|
||||||
|
min-width: 280px !important;
|
||||||
|
width: 100% !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 플레이스홀더 텍스트 잘림 방지 - 핵심 수정 */
|
||||||
|
.choices__placeholder {
|
||||||
|
color: #888 !important;
|
||||||
|
opacity: 1 !important;
|
||||||
|
width: 100% !important;
|
||||||
|
min-width: 200px !important;
|
||||||
|
white-space: nowrap !important;
|
||||||
|
overflow: visible !important;
|
||||||
|
text-overflow: clip !important;
|
||||||
|
display: block !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__input {
|
||||||
|
color: #222 !important;
|
||||||
|
background: transparent !important;
|
||||||
|
min-width: 200px !important;
|
||||||
|
width: 100% !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__input::placeholder {
|
||||||
|
color: #888 !important;
|
||||||
|
opacity: 1 !important;
|
||||||
|
width: 100% !important;
|
||||||
|
min-width: 200px !important;
|
||||||
|
white-space: nowrap !important;
|
||||||
|
overflow: visible !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 다중 선택시 입력 필드 너비 확보 */
|
||||||
|
.choices[data-type*="select-multiple"] .choices__input {
|
||||||
|
min-width: 200px !important;
|
||||||
|
width: auto !important;
|
||||||
|
flex: 1 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 선택된 항목들과 입력 필드 공간 분배 */
|
||||||
|
.choices__list--multiple {
|
||||||
|
/* display: flex !important; */
|
||||||
|
flex-wrap: wrap !important;
|
||||||
|
align-items: center !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--multiple:empty+.choices__input {
|
||||||
|
min-width: 200px !important;
|
||||||
|
width: 100% !important;
|
||||||
|
flex: 1 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 선택된 항목의 가격 표시 스타일 - 새로 추가 */
|
||||||
|
.selected-item-content {
|
||||||
|
display: flex !important;
|
||||||
|
flex-direction: column !important;
|
||||||
|
align-items: flex-start !important;
|
||||||
|
flex: 1 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-item-name {
|
||||||
|
font-weight: 500 !important;
|
||||||
|
margin-bottom: 2px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-item-price {
|
||||||
|
font-size: 0.85em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-price {
|
||||||
|
color: #b23c3c !important;
|
||||||
|
font-weight: bold !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-price-discount {
|
||||||
|
color: #b23c3c !important;
|
||||||
|
font-weight: bold !important;
|
||||||
|
font-size: 0.9em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-price-original {
|
||||||
|
color: #aaa !important;
|
||||||
|
font-size: 0.85em !important;
|
||||||
|
text-decoration: line-through !important;
|
||||||
|
margin-left: 4px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 선택된 항목들 스타일 수정 */
|
||||||
|
.choices__list--multiple .choices__item {
|
||||||
|
background-color: #f8f9fa !important;
|
||||||
|
border: 1px solid #dee2e6 !important;
|
||||||
|
border-radius: 16px !important;
|
||||||
|
padding: 8px 12px !important;
|
||||||
|
margin: 2px !important;
|
||||||
|
font-size: 0.9em !important;
|
||||||
|
color: #495057 !important;
|
||||||
|
flex-shrink: 0 !important;
|
||||||
|
display: flex !important;
|
||||||
|
align-items: center !important;
|
||||||
|
/* max-width: 300px !important; */
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 빨간색으로 변경 */
|
||||||
|
.choices__button {
|
||||||
|
background-image: url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjYjIzYzNjIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPjwvc3ZnPg==') !important;
|
||||||
|
background-size: 14px 14px !important;
|
||||||
|
background-position: center !important;
|
||||||
|
background-repeat: no-repeat !important;
|
||||||
|
border-left: 0 !important;
|
||||||
|
margin: 0 !important;
|
||||||
|
padding: 0 !important;
|
||||||
|
width: 14px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 드롭다운 컨테이너 */
|
||||||
|
.choices__list--dropdown {
|
||||||
|
background: #fff !important;
|
||||||
|
border: 1px solid #ddd !important;
|
||||||
|
border-radius: 6px !important;
|
||||||
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 드롭다운 옵션들 스타일 */
|
||||||
|
.choices__list--dropdown .choices__item {
|
||||||
|
padding: 8px 12px !important;
|
||||||
|
display: flex !important;
|
||||||
|
justify-content: space-between !important;
|
||||||
|
align-items: center !important;
|
||||||
|
color: #222 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--dropdown .choices__item--selectable:hover {
|
||||||
|
background-color: #f5f5f5 !important;
|
||||||
|
color: #222 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--dropdown .choices__item--highlighted {
|
||||||
|
background-color: #b23c3c !important;
|
||||||
|
color: #fff !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 포커스 상태 */
|
||||||
|
.choices.is-focused .choices__inner {
|
||||||
|
border-color: #b23c3c !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 가격 표시 스타일 */
|
||||||
|
.procedure-price {
|
||||||
|
color: #b23c3c !important;
|
||||||
|
font-weight: bold !important;
|
||||||
|
font-size: 0.9em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.procedure-price-discount {
|
||||||
|
color: #b23c3c !important;
|
||||||
|
font-weight: bold !important;
|
||||||
|
font-size: 0.9em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.procedure-price-original {
|
||||||
|
color: #aaa !important;
|
||||||
|
font-size: 0.85em !important;
|
||||||
|
text-decoration: line-through !important;
|
||||||
|
margin-left: 4px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 드롭다운이 열렸을 때 하이라이트된 항목의 가격 색상 */
|
||||||
|
.choices__list--dropdown .choices__item--highlighted .procedure-price,
|
||||||
|
.choices__list--dropdown .choices__item--highlighted .procedure-price-discount {
|
||||||
|
color: #fff !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--dropdown .choices__item--highlighted .procedure-price-original {
|
||||||
|
color: #ddd !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 검색 입력창 스타일 */
|
||||||
|
.choices[data-type*="select-multiple"] .choices__input {
|
||||||
|
background-color: transparent !important;
|
||||||
|
color: #222 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 비활성화 상태 */
|
||||||
|
.choices.is-disabled .choices__inner {
|
||||||
|
background-color: #f8f9fa !important;
|
||||||
|
color: #6c757d !important;
|
||||||
|
cursor: not-allowed !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 반응형 대응 */
|
||||||
|
@media (max-width: 600px) {
|
||||||
|
.choices {
|
||||||
|
min-width: 250px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__inner {
|
||||||
|
min-width: 230px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__placeholder,
|
||||||
|
.choices__input,
|
||||||
|
.choices__input::placeholder {
|
||||||
|
min-width: 150px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--multiple .choices__item {
|
||||||
|
max-width: 250px !important;
|
||||||
|
padding: 6px 10px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-item-name {
|
||||||
|
font-size: 0.9em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selected-item-price {
|
||||||
|
font-size: 0.8em !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.choices__list--multiple .choices__item[data-deletable] .choices__button {
|
||||||
|
width: 20px !important;
|
||||||
|
height: 20px !important;
|
||||||
|
font-size: 16px !important;
|
||||||
|
text-indent: 0 !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 900px) {
|
||||||
|
.main-wrap {
|
||||||
|
margin-top: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-section {
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 18px;
|
||||||
|
padding: 20px 10px 0 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-box {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box {
|
||||||
|
min-width: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.desc-section {
|
||||||
|
padding: 0 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 600px) {
|
||||||
|
.main-wrap {
|
||||||
|
margin-top: 0;
|
||||||
|
border-radius: 0;
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-section {
|
||||||
|
padding: 12px 2vw 0 2vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
.desc-section {
|
||||||
|
padding: 0 2vw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
<th:block layout:fragment="layout_top_script">
|
||||||
|
<script th:inline="javascript">
|
||||||
|
const CDN_URL = [[${@environment.getProperty('url.cdn') }]];
|
||||||
|
</script>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
<th:block layout:fragment="layout_content">
|
||||||
|
<div id="service-header">
|
||||||
|
시술안내/가격 > <span id="header-category-nm"></span> > <span id="header-title"></span>
|
||||||
|
</div>
|
||||||
|
<div class="main-wrap">
|
||||||
|
<div class="top-section">
|
||||||
|
<div class="img-box">
|
||||||
|
<img id="serviceThumb" th:src="${@environment.getProperty('madeu.logo.size800x450')}" alt="썸네일 이미지">
|
||||||
|
<pre id="thumbnail-bottom-txt"></pre>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="info-box">
|
||||||
|
<div class="info-title" id="title"></div>
|
||||||
|
<div class="info-desc" id="contents"></div>
|
||||||
|
|
||||||
|
<div class="hashtag-section">
|
||||||
|
<div class="hashtag-container">
|
||||||
|
<div class="hashtag-list">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="info-price"><span id="price">0</span>원 부터</div>
|
||||||
|
|
||||||
|
<div class="select-row">
|
||||||
|
<label for="procedure-select">시술 선택</label>
|
||||||
|
<select id="procedure-select" multiple></select>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="total-row">
|
||||||
|
<span class="total-label">총 금액</span>
|
||||||
|
<span class="total-price" id="total">0원</span>
|
||||||
|
</div>
|
||||||
|
<button class="reserve-btn" id="reserve-btn" disabled>시술 예약하기</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="desc-section">
|
||||||
|
<div class="desc-content">
|
||||||
|
<img id="contents_path" th:src="${@environment.getProperty('madeu.logo.size800x450')}" alt="컨텐츠 이미지"
|
||||||
|
width="100%" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
<th:block layout:fragment="layout_script">
|
||||||
|
<!-- Choices.js JavaScript -->
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/choices.js/10.2.0/choices.min.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
// 전역 변수
|
||||||
|
let procedureChoices;
|
||||||
|
let priceList = [];
|
||||||
|
const totalEl = document.getElementById('total');
|
||||||
|
const reserveBtn = document.getElementById('reserve-btn');
|
||||||
|
|
||||||
|
// 초기화 - Opener 데이터 로드 (DOM 로드 후 실행)
|
||||||
|
document.addEventListener('DOMContentLoaded', function () {
|
||||||
|
fn_initPreview();
|
||||||
|
});
|
||||||
|
|
||||||
|
function fn_initPreview() {
|
||||||
|
if (!window.opener) {
|
||||||
|
alert('비정상적인 접근입니다.');
|
||||||
|
window.close();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
const opener = window.opener;
|
||||||
|
const $ = opener.jQuery; // Use jQuery from opener if possible, or use current document
|
||||||
|
|
||||||
|
// 1. 기본 정보 설정
|
||||||
|
document.getElementById('header-category-nm').innerText = opener.$("select[name=category] option:selected").text();
|
||||||
|
document.getElementById('header-title').innerText = opener.$("#title").val();
|
||||||
|
document.getElementById('title').innerText = opener.$("#title").val();
|
||||||
|
document.getElementById('contents').innerText = opener.$("#content").val();
|
||||||
|
document.getElementById('thumbnail-bottom-txt').innerText = opener.$("#thumbnailBottomTxt").val();
|
||||||
|
|
||||||
|
// 2. 이미지 설정
|
||||||
|
let thumbSrc = opener.$(".img_box img").attr("src");
|
||||||
|
if (!thumbSrc) thumbSrc = opener.$("#thumbnailImg").attr("src");
|
||||||
|
if (thumbSrc) document.getElementById('serviceThumb').src = thumbSrc;
|
||||||
|
|
||||||
|
let contentSrc = opener.$(".file_box img").attr("src");
|
||||||
|
if (!contentSrc) contentSrc = opener.$("#contentsImg").attr("src");
|
||||||
|
if (contentSrc) document.getElementById('contents_path').src = contentSrc;
|
||||||
|
else document.getElementById('contents_path').style.display = 'none';
|
||||||
|
|
||||||
|
// 3. 해시태그 설정
|
||||||
|
let hashtagStr = opener.$("#hashtag").val();
|
||||||
|
let hashtagHtml = '';
|
||||||
|
if (hashtagStr) {
|
||||||
|
let tags = hashtagStr.split('#');
|
||||||
|
tags.forEach(function (tag) {
|
||||||
|
let trimmed = tag.trim();
|
||||||
|
if (trimmed) {
|
||||||
|
hashtagHtml += '<span class="hashtag">#' + trimmed + '</span>';
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
document.querySelector('.hashtag-list').innerHTML = hashtagHtml;
|
||||||
|
|
||||||
|
// 4. 시술 목록 및 가격 설정
|
||||||
|
let treatmentList = opener.getTreatmentListForPreview ? opener.getTreatmentListForPreview() : opener.treatmentList; // Access global variable from opener or fall back
|
||||||
|
if (treatmentList && treatmentList.length > 0) {
|
||||||
|
updateProcedureOptions(treatmentList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/****************************************************************************
|
||||||
|
* Choices.js 초기화 및 옵션 업데이트
|
||||||
|
****************************************************************************/
|
||||||
|
function updateProcedureOptions(data) {
|
||||||
|
priceList = data;
|
||||||
|
|
||||||
|
let minPrice = -1;
|
||||||
|
|
||||||
|
// 선택 옵션 데이터 생성
|
||||||
|
const choices = data.map(item => {
|
||||||
|
const price = parseInt(item.price) || 0;
|
||||||
|
const discountPrice = parseInt(item.discountPrice) || 0;
|
||||||
|
const finalPrice = (discountPrice > 0 && discountPrice < price) ? discountPrice : price;
|
||||||
|
|
||||||
|
if (minPrice === -1 || finalPrice < minPrice) {
|
||||||
|
minPrice = finalPrice;
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
value: item.muTreatmentProcedureId || item.muTreatmentId, // Adjust based on your object structure
|
||||||
|
label: item.treatmentProcedureName,
|
||||||
|
customProperties: {
|
||||||
|
name: item.treatmentProcedureName,
|
||||||
|
price: price,
|
||||||
|
discountPrice: discountPrice
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}).filter(Boolean);
|
||||||
|
|
||||||
|
if (minPrice === -1) minPrice = 0;
|
||||||
|
document.getElementById('price').textContent = minPrice.toLocaleString();
|
||||||
|
|
||||||
|
// Choices.js 초기화
|
||||||
|
procedureChoices = new Choices('#procedure-select', {
|
||||||
|
removeItemButton: true,
|
||||||
|
searchEnabled: true,
|
||||||
|
searchPlaceholderValue: '시술명으로 검색...',
|
||||||
|
placeholder: true,
|
||||||
|
placeholderValue: '시술을 선택하세요',
|
||||||
|
maxItemCount: -1,
|
||||||
|
choices: choices,
|
||||||
|
shouldSort: false,
|
||||||
|
searchResultLimit: 10,
|
||||||
|
searchFields: ['label', 'value'],
|
||||||
|
itemSelectText: '',
|
||||||
|
noChoicesText: '선택 가능한 시술이 없습니다',
|
||||||
|
noResultsText: '검색 결과가 없습니다',
|
||||||
|
loadingText: '시술 정보를 불러오는 중...',
|
||||||
|
|
||||||
|
callbackOnCreateTemplates: function (template) {
|
||||||
|
return {
|
||||||
|
item: ({ classNames }, data) => {
|
||||||
|
const customProps = data.customProperties || {};
|
||||||
|
const name = customProps.name || data.label;
|
||||||
|
const price = customProps.price || 0;
|
||||||
|
const discountPrice = customProps.discountPrice;
|
||||||
|
|
||||||
|
let priceHtml = '';
|
||||||
|
if (discountPrice && discountPrice < price) {
|
||||||
|
priceHtml = `
|
||||||
|
<span class="selected-price-discount">${discountPrice.toLocaleString()}원</span>
|
||||||
|
<span class="selected-price-original">${price.toLocaleString()}원</span>
|
||||||
|
`;
|
||||||
|
} else {
|
||||||
|
priceHtml = `<span class="selected-price">${price.toLocaleString()}원</span>`;
|
||||||
|
}
|
||||||
|
|
||||||
|
return template(`
|
||||||
|
<div class="${classNames.item} ${data.highlighted ? classNames.highlightedState : classNames.itemSelectable}" data-item data-id="${data.id}" data-value="${data.value}">
|
||||||
|
<span class="selected-item-content">
|
||||||
|
<span class="selected-item-name">${name}</span>
|
||||||
|
<span class="selected-item-price">${priceHtml}</span>
|
||||||
|
</span>
|
||||||
|
<button type="button" class="${classNames.button}" aria-label="Remove item: '${data.value}'" data-button>X</button>
|
||||||
|
</div>
|
||||||
|
`);
|
||||||
|
},
|
||||||
|
choice: ({ classNames }, data) => {
|
||||||
|
const customProps = data.customProperties || {};
|
||||||
|
const name = customProps.name || data.label;
|
||||||
|
const price = customProps.price || 0;
|
||||||
|
const discountPrice = customProps.discountPrice;
|
||||||
|
|
||||||
|
let priceHtml = '';
|
||||||
|
if (discountPrice && discountPrice < price) {
|
||||||
|
priceHtml = `
|
||||||
|
<span class="procedure-price-discount">${discountPrice.toLocaleString()}원</span>
|
||||||
|
<span class="procedure-price-original">${price.toLocaleString()}원</span>
|
||||||
|
`;
|
||||||
|
} else {
|
||||||
|
priceHtml = `<span class="procedure-price">${price.toLocaleString()}원</span>`;
|
||||||
|
}
|
||||||
|
|
||||||
|
return template(`
|
||||||
|
<div class="${classNames.item} ${classNames.itemChoice} ${data.disabled ? classNames.itemDisabled : classNames.itemSelectable}" data-select-text="" data-choice ${data.disabled ? 'data-choice-disabled aria-disabled="true"' : 'data-choice-selectable'} data-id="${data.id}" data-value="${data.value}">
|
||||||
|
<div style="display: flex; justify-content: space-between; width: 100%; align-items: center;">
|
||||||
|
<span>${name}</span>
|
||||||
|
${priceHtml}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
`);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const selectElement = document.getElementById('procedure-select');
|
||||||
|
selectElement.addEventListener('change', updateTotalPrice);
|
||||||
|
selectElement.addEventListener('addItem', updateTotalPrice);
|
||||||
|
selectElement.addEventListener('removeItem', updateTotalPrice);
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateTotalPrice() {
|
||||||
|
if (!procedureChoices) return;
|
||||||
|
const selectedValues = procedureChoices.getValue(true);
|
||||||
|
let total = 0;
|
||||||
|
|
||||||
|
selectedValues.forEach(value => {
|
||||||
|
// Find item in local priceList (which is data passed to updateProcedureOptions)
|
||||||
|
// Note: priceList elements structure depends on how we mapped it.
|
||||||
|
// Oh wait, priceList = data; which comes from opener.treatmentList.
|
||||||
|
// Items in treatmentList have { muTreatmentProcedureId, treatmentProcedureName, price, discountPrice ... }
|
||||||
|
const item = priceList.find(p => (p.muTreatmentProcedureId || p.muTreatmentId) == value);
|
||||||
|
|
||||||
|
if (item) {
|
||||||
|
const basePrice = parseInt(item.price) || 0;
|
||||||
|
const discountPrice = parseInt(item.discountPrice) || 0;
|
||||||
|
const finalPrice = (discountPrice > 0 && discountPrice < basePrice) ? discountPrice : basePrice;
|
||||||
|
total += finalPrice;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
totalEl.textContent = total.toLocaleString() + '원';
|
||||||
|
reserveBtn.disabled = selectedValues.length === 0;
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
</html>
|
||||||
@@ -1,116 +1,191 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
xmlns:th="http://www.thymeleaf.org"
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
||||||
layout:decorate="~{/web/layout/homeLayout}">
|
|
||||||
<th:block layout:fragment="layout_css">
|
<th:block layout:fragment="layout_css">
|
||||||
<link href="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.css" rel="stylesheet">
|
<link rel="stylesheet" href="/css/web/ContentsBbsUpd.css">
|
||||||
<link rel="stylesheet" href="/css/web/ContentsBbsReg.css">
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
<link rel="stylesheet" href="/css/web/datepicker-fix.css">
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_top_script">
|
<th:block layout:fragment="layout_top_script">
|
||||||
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
<!-- Pagination usage removed -->
|
||||||
<script>
|
<script>
|
||||||
let menuClass = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
let categoryDivCd = "[[${param.categoryDivCd}]]"==""?"":"[[${param.categoryDivCd}]]";
|
let categoryDivCd = "[[${param.categoryDivCd}]]" == "" ? "" : "[[${param.categoryDivCd}]]";
|
||||||
|
|
||||||
let selectUseYn = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
let insertUseYn = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
let updateUseYn = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
let deleteUseYn = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
|
||||||
let categorytitle = "[[${title}]]";
|
let categorytitle = "[[${title}]]";
|
||||||
</script>
|
|
||||||
|
const CDN_URL = "[[${@environment.getProperty('url.cdn')}]]";
|
||||||
|
</script>
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_content">
|
<th:block layout:fragment="layout_content">
|
||||||
<!-- 센터쪽 -->
|
<!-- 센터쪽 -->
|
||||||
<div class="center_box">
|
<div class="center_box">
|
||||||
<p class="page_title">[[${title}]]</p>
|
<p class="page_title">[[${title}]]</p>
|
||||||
|
|
||||||
<!-- 테이블 -->
|
<!-- 테이블 -->
|
||||||
<div class="content_box">
|
<div class="content_box">
|
||||||
<div class="content clear">
|
<div class="update-container">
|
||||||
<div class="wp60">
|
<!-- Left Panel: Data Forms -->
|
||||||
<div class="top">
|
<div class="left-panel">
|
||||||
<label>썸네일 첨부파일</label>
|
<!-- Row 1: Category & Title -->
|
||||||
<label for="file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
|
<div class="form-grid-row">
|
||||||
</div>
|
<div class="form-group" style="flex: 0 0 150px;">
|
||||||
<div class="btm">
|
<label>카테고리</label>
|
||||||
<div class="img_box"><!-- img 미리보기 --></div>
|
<select name="category">
|
||||||
<input type="file" id="file" accept="image/jpeg, image/jpg, image/png" style="display: none;" multiple>
|
<option value="">선택하세요</option>
|
||||||
<button id="delete_btn">삭제</button>
|
<option th:each="category : ${categorylist}" th:value="${category.categoryNo}"
|
||||||
</div>
|
th:text="${category.categoryNm}"></option>
|
||||||
<p class="thumbnail-bottom-txt">
|
</select>
|
||||||
썸네일 하단글
|
<input type="hidden" id="categoryNo" />
|
||||||
</p>
|
|
||||||
<textarea id="thumbnail-bottom-txt" placeholder="썸네일 하단글을 입력해주세요." ></textarea>
|
|
||||||
<p class="content-file">
|
|
||||||
컨텐츠 첨부파일
|
|
||||||
<label for="content_file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
|
|
||||||
</p>
|
|
||||||
<input type="file" id="content_file" style="display: none;" placeholder="첨부파일을 입력해주세요."/>
|
|
||||||
<div class="file_box"><!-- img 미리보기 --></div>
|
|
||||||
<button id="content_delete_btn">삭제</button>
|
|
||||||
</div>
|
|
||||||
<div class="wp40">
|
|
||||||
<div class="consultation-info">
|
|
||||||
<p id="main_category">
|
|
||||||
카테고리
|
|
||||||
</p>
|
|
||||||
<select th:name="categorylist">
|
|
||||||
<option value="">선택하세요</option>
|
|
||||||
<option th:each="category : ${categorylist}" th:value="${category.categoryNo}" th:text="${category.categoryNm}"></option>
|
|
||||||
</select>
|
|
||||||
<p id="main_title">
|
|
||||||
제목
|
|
||||||
</p>
|
|
||||||
<input type="text" id="title" placeholder="제목을 입력해주세요."/>
|
|
||||||
<p id="main_content">
|
|
||||||
내용
|
|
||||||
</p>
|
|
||||||
<textarea id="content" placeholder="내용을 입력해주세요."></textarea>
|
|
||||||
<p id="main_hashtag">
|
|
||||||
해쉬태그
|
|
||||||
</p>
|
|
||||||
<input type="text" id="hashtag" placeholder="해쉬태그를 입력해주세요."/>
|
|
||||||
<div>
|
|
||||||
<label for="oldCrmItemId">OLD CRM 연동ID</label>
|
|
||||||
<input type="text" id="oldCrmItemId" placeholder="OLD_CRM_ITEM_ID"/>
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="form-group">
|
||||||
<label for="ordNo">홈페이지 출력순서</label>
|
<label>제목</label>
|
||||||
<input type="text" id="ordNo" />
|
<input type="text" id="title" placeholder="제목을 입력해주세요." />
|
||||||
</div>
|
|
||||||
<p id="main_procedure">
|
|
||||||
시술선택
|
|
||||||
<button class="add_btn ml50" onclick="javascript:listOpen();">
|
|
||||||
<img src="/image/web/add.svg" alt="추가">
|
|
||||||
</button>
|
|
||||||
<button class="add_btn" onclick="javascript:fn_removeRow();">
|
|
||||||
<img src="/image/web/subtract.svg" alt="삭제">
|
|
||||||
</button>
|
|
||||||
</p>
|
|
||||||
<div id="treatmentlist">
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="button_box">
|
|
||||||
<button class="registration_btn btnSave">등록</button>
|
<!-- Row 2: Content & Order -->
|
||||||
<button class="cancel_btn btnCancle">취소</button>
|
<div class="form-grid-row">
|
||||||
</div>
|
<div class="form-group" style="flex: 1;">
|
||||||
|
<label>내용</label>
|
||||||
|
<input type="text" id="content" placeholder="내용을 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
<div class="form-group" style="flex: 0 0 150px;">
|
||||||
|
<label>홈페이지 출력순서</label>
|
||||||
|
<input type="text" id="ordNo" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Row 3: Hashtag & Old ID -->
|
||||||
|
<div class="form-grid-row">
|
||||||
|
<div class="form-group">
|
||||||
|
<label>해쉬태그</label>
|
||||||
|
<input type="text" id="hashtag" placeholder="해쉬태그를 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label>OLD CRM 연동ID</label>
|
||||||
|
<input type="text" id="oldCrmItemId" placeholder="OLD_CRM_ITEM_ID" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Date Selection (Event Only) -->
|
||||||
|
<div class="form-grid-row" id="dateSelectionRow" style="display:none;">
|
||||||
|
<div class="form-group">
|
||||||
|
<label>시작일</label>
|
||||||
|
<input type="text" id="eventStartDt" placeholder="YYYY-MM-DD" readonly />
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label>종료일</label>
|
||||||
|
<input type="text" id="eventEndDt" placeholder="YYYY-MM-DD" readonly />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Row 4: Procedure Selection (Grid) -->
|
||||||
|
<div class="grid-section">
|
||||||
|
<div class="grid-header">
|
||||||
|
<label>시술선택</label>
|
||||||
|
<div class="grid-controls">
|
||||||
|
<button class="add_btn" onclick="javascript:listOpen();">
|
||||||
|
<img src="/image/web/add.svg" alt="추가">
|
||||||
|
</button>
|
||||||
|
<button class="add_btn" onclick="javascript:fn_removeRow();">
|
||||||
|
<img src="/image/web/subtract.svg" alt="삭제">
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="custom-grid-container">
|
||||||
|
<table class="treatment-table">
|
||||||
|
<colgroup>
|
||||||
|
<col style="width: 50px;">
|
||||||
|
<col style="width: auto;">
|
||||||
|
<col style="width: 120px;">
|
||||||
|
<col style="width: 120px;">
|
||||||
|
</colgroup>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>
|
||||||
|
<input type="checkbox" id="checkAll" onclick="fn_checkAll(this)">
|
||||||
|
</th>
|
||||||
|
<th>시술명</th>
|
||||||
|
<th>가격</th>
|
||||||
|
<th>할인가</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="treatmentListBody">
|
||||||
|
<!-- Rows will be added here dynamically -->
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Bottom Buttons -->
|
||||||
|
<div class="bottom-actions">
|
||||||
|
<button class="btn-basic btnPreview" onclick="fn_openPreview();"
|
||||||
|
style="width: 120px; height: 36px; border-radius: 4px; background: #fff; color: #333; border: 1px solid #ccc; margin-right: auto;">미리보기</button>
|
||||||
|
<button class="registration_btn btnSave"
|
||||||
|
style="width: 80px; height: 36px; border-radius: 4px; background: #3985EA; color: white;">등록</button>
|
||||||
|
<button class="cancel_btn btnCancle"
|
||||||
|
style="width: 80px; height: 36px; border-radius: 4px;">취소</button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Right Panel: Images -->
|
||||||
|
<div class="right-panel">
|
||||||
|
<!-- Thumbnail Section -->
|
||||||
|
<div class="panel-section">
|
||||||
|
<div class="top-label">
|
||||||
|
<span>썸네일 첨부파일</span>
|
||||||
|
<div>
|
||||||
|
<label for="file" class="file_btn" style="cursor: pointer;"><img
|
||||||
|
src="/image/web/add.svg" alt="파일찾기"></label>
|
||||||
|
<button id="delete_btn"
|
||||||
|
style="border:none; background:none; cursor:pointer; margin-left:5px; font-size:12px; color:#999;">삭제</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="img-preview-wrapper img_box">
|
||||||
|
<img id="thumbnailImg" src="" />
|
||||||
|
</div>
|
||||||
|
<input type="file" id="file" accept="image/jpeg, image/jpg, image/png" style="display: none;"
|
||||||
|
multiple>
|
||||||
|
|
||||||
|
<label style="margin-top: 10px; font-size: 13px; font-weight: 700;">썸네일 하단글</label>
|
||||||
|
<textarea id="thumbnailBottomTxt" placeholder="썸네일 하단글을 입력해주세요."></textarea>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Content File Section -->
|
||||||
|
<div class="panel-section">
|
||||||
|
<div class="top-label">
|
||||||
|
<span>컨텐츠 첨부파일</span>
|
||||||
|
<div>
|
||||||
|
<label for="content_file" class="file_btn" style="cursor: pointer;"><img
|
||||||
|
src="/image/web/add.svg" alt="파일찾기"></label>
|
||||||
|
<button id="content_delete_btn"
|
||||||
|
style="border:none; background:none; cursor:pointer; margin-left:5px; font-size:12px; color:#999;">삭제</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="img-preview-wrapper file_box">
|
||||||
|
<!-- Using same class for consistent styling -->
|
||||||
|
<img id="contentsImg" src="" />
|
||||||
|
</div>
|
||||||
|
<input type="file" id="content_file" style="display: none;" placeholder="첨부파일을 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<form id="excelForm" method="POST" target="_blank"></form>
|
<form id="excelForm" method="POST" target="_blank"></form>
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_popup">
|
<th:block layout:fragment="layout_popup">
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_script">
|
<th:block layout:fragment="layout_script">
|
||||||
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
<script src="/js/web/contentsBbs/ContentsBbsReg.js"></script>
|
||||||
<script src="/js/web/contentsBbs/ContentsBbsReg.js"></script>
|
<script src="/js/web/contentsBbs/ContentsBbsPop.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.js"></script>
|
|
||||||
<script src="/js/web/contentsBbs/ContentsBbsPop.js"></script>
|
|
||||||
</th:block>
|
</th:block>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
@@ -1,39 +1,31 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
xmlns:th="http://www.thymeleaf.org"
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
||||||
layout:decorate="~{/web/layout/homeLayout}">
|
|
||||||
<th:block layout:fragment="layout_css">
|
<th:block layout:fragment="layout_css">
|
||||||
<link rel="stylesheet" href="/css/web/webTreatmentPetitSelectList.css">
|
<link rel="stylesheet" href="/css/web/ContentsBbsSelectList.css">
|
||||||
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_top_script">
|
<th:block layout:fragment="layout_top_script">
|
||||||
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
||||||
<script>
|
<script>
|
||||||
let menuClass = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
let categoryDivCd = "[[${param.categoryDivCd}]]"==""?"":"[[${param.categoryDivCd}]]";
|
let categoryDivCd = "[[${param.categoryDivCd}]]" == "" ? "" : "[[${param.categoryDivCd}]]";
|
||||||
categoryDivCd = "[[${categoryDivCd}]]"==""?"":"[[${categoryDivCd}]]";
|
categoryDivCd = "[[${categoryDivCd}]]" == "" ? "" : "[[${categoryDivCd}]]";
|
||||||
|
|
||||||
let selectUseYn = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
let insertUseYn = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
let updateUseYn = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
let deleteUseYn = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
|
||||||
/* 검색 관련 변수 */
|
/* 검색 관련 변수 */
|
||||||
let webTreatmentPetitSearchKeywordParam0 = "[[${param.webTreatmentPetitSearchKeywordParam0}]]";
|
let webTreatmentPetitSearchKeywordParam0 = "[[${param.webTreatmentPetitSearchKeywordParam0}]]";
|
||||||
let webTreatmentPetitSearchKeywordParam1 = "[[${param.webTreatmentPetitSearchKeywordParam1}]]";
|
let webTreatmentPetitSearchKeywordParam1 = "[[${param.webTreatmentPetitSearchKeywordParam1}]]";
|
||||||
let webTreatmentPetitSearchKeywordParam2 = "[[${param.webTreatmentPetitSearchKeywordParam2}]]";
|
|
||||||
let webTreatmentPetitSearchKeywordParam3 = "[[${param.webTreatmentPetitSearchKeywordParam3}]]";
|
|
||||||
|
|
||||||
let webTreatmentPetitSort = "[[${param.webTreatmentPetitSort}]]";
|
let webTreatmentPetitSort = "[[${param.webTreatmentPetitSort}]]";
|
||||||
let webTreatmentPetitDir = "[[${param.webTreatmentPetitDir}]]";
|
let webTreatmentPetitDir = "[[${param.webTreatmentPetitDir}]]";
|
||||||
let webTreatmentPetitStart = "[[${param.webTreatmentPetitStart}]]"==""?0:"[[${param.webTreatmentPetitStart}]]";
|
let webTreatmentPetitStart = "[[${param.webTreatmentPetitStart}]]" == "" ? 0 : "[[${param.webTreatmentPetitStart}]]";
|
||||||
let webTreatmentPetitLimit = "[[${param.webTreatmentPetitLimit}]]"==""?500:"[[${param.webTreatmentPetitLimit}]]";
|
let webTreatmentPetitLimit = "[[${param.webTreatmentPetitLimit}]]" == "" ? 500 : "[[${param.webTreatmentPetitLimit}]]";
|
||||||
|
|
||||||
let webTreatmentPetitSearchStartDate = "[[${param.webTreatmentPetitSearchStartDate}]]";
|
|
||||||
let webTreatmentPetitSearchEndDate = "[[${param.webTreatmentPetitSearchEndDate}]]";
|
|
||||||
let webTreatmentPetitSearchDateType = "[[${param.webTreatmentPetitSearchDateType}]]"==""?"A":"[[${param.webTreatmentPetitSearchDateType}]]";
|
|
||||||
</script>
|
</script>
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_content">
|
<th:block layout:fragment="layout_content">
|
||||||
@@ -44,36 +36,33 @@
|
|||||||
<div class="filter_box">
|
<div class="filter_box">
|
||||||
<div class="form_box">
|
<div class="form_box">
|
||||||
|
|
||||||
<!-- 이름input -->
|
<!-- 카테고리 셀렉트박스 -->
|
||||||
|
<div class="select_box first dropdown">
|
||||||
|
<button class="label" type="button" data-toggle="dropdown" aria-haspopup="true"
|
||||||
|
aria-expanded="false">카테고리</button>
|
||||||
|
<input type="hidden" id="webTreatmentPetitSearchKeyword0">
|
||||||
|
<ul class="select_option_list dropdown-menu" id="categoryOptionList">
|
||||||
|
<li class="option_list_item" id="li_ALL">전체</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 제목 검색 input -->
|
||||||
<div class="search_list">
|
<div class="search_list">
|
||||||
<div class="search_box">
|
<div class="search_box">
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
<img src="/image/web/search_G.svg" alt="search" />
|
||||||
<input type="text" id="webTreatmentPetitSearchKeyword0" required placeholder="카테고리">
|
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
|
||||||
</div>
|
|
||||||
<div class="search_box">
|
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
|
||||||
<input type="text" id="webTreatmentPetitSearchKeyword1" required placeholder="제목">
|
<input type="text" id="webTreatmentPetitSearchKeyword1" required placeholder="제목">
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
||||||
</div>
|
</div>
|
||||||
<div class="search_box">
|
<button id="btnSearchWebTreatmentPetit" class="search_btn" data-toggle="modal"
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
data-target=".work_closed_modal" style="transition: all 0.2s ease-in-out 0s;">조회</button>
|
||||||
<input type="text" id="webTreatmentPetitSearchKeyword2" required placeholder="작성자">
|
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
|
||||||
</div>
|
|
||||||
<div class="search_box">
|
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
|
||||||
<input type="text" id="webTreatmentPetitSearchKeyword3" required placeholder="시술">
|
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
|
||||||
</div>
|
|
||||||
<button id="btnSearchWebTreatmentPetit" class="search_btn" data-toggle="modal" data-target=".work_closed_modal" style="transition: all 0.2s ease-in-out 0s;">조회</button>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="right_btn_box">
|
<div class="right_btn_box">
|
||||||
|
<button id="btnSaveOrdNo" class="treatmentpetit_btn" disabled
|
||||||
|
style="opacity: 0.5; margin-right: 5px;">
|
||||||
|
<img src="/image/web/notice_btn_icon.svg" alt="순서저장">순서저장
|
||||||
|
</button>
|
||||||
<button id="btnInsertWebTreatmentPetit" class="treatmentpetit_btn">
|
<button id="btnInsertWebTreatmentPetit" class="treatmentpetit_btn">
|
||||||
<img src="/image/web/notice_btn_icon.svg" alt="등록">등록
|
<img src="/image/web/notice_btn_icon.svg" alt="등록">등록
|
||||||
</button>
|
</button>
|
||||||
@@ -99,6 +88,7 @@
|
|||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_script">
|
<th:block layout:fragment="layout_script">
|
||||||
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
||||||
<script src="/js/web/contentsBbs/ContentsBbsSelectList.js"></script>
|
<script src="/js/web/contentsBbs/ContentsBbsSelectList.js?v=6"></script>
|
||||||
</th:block>
|
</th:block>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
@@ -1,128 +1,196 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
xmlns:th="http://www.thymeleaf.org"
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
||||||
layout:decorate="~{/web/layout/homeLayout}">
|
|
||||||
<th:block layout:fragment="layout_css">
|
<th:block layout:fragment="layout_css">
|
||||||
<link href="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.css" rel="stylesheet">
|
<link rel="stylesheet" href="/css/web/ContentsBbsUpd.css">
|
||||||
<link rel="stylesheet" href="/css/web/ContentsBbsReg.css">
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
<link rel="stylesheet" href="/css/web/datepicker-fix.css">
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_top_script">
|
<th:block layout:fragment="layout_top_script">
|
||||||
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
<!-- Pagination usage removed -->
|
||||||
<script>
|
<script>
|
||||||
let menuClass = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
|
|
||||||
let selectUseYn = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
let insertUseYn = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
let updateUseYn = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
let deleteUseYn = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
|
||||||
let categoryDivCd = "[[${param.categoryDivCd}]]";
|
let categoryDivCd = "[[${param.categoryDivCd}]]";
|
||||||
let categoryNo = "[[${param.categoryNo}]]";
|
let categoryNo = "[[${param.categoryNo}]]";
|
||||||
let postNo = "[[${param.postNo}]]";
|
let postNo = "[[${param.postNo}]]";
|
||||||
let categorytitle = "[[${title}]]";
|
let categorytitle = "[[${title}]]";
|
||||||
|
|
||||||
const CDN_URL = "[[${@environment.getProperty('url.cdn')}]]";
|
const CDN_URL = "[[${@environment.getProperty('url.cdn')}]]";
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_content">
|
<th:block layout:fragment="layout_content">
|
||||||
<!-- 센터쪽 -->
|
<!-- 센터쪽 -->
|
||||||
<div class="center_box">
|
<div class="center_box">
|
||||||
<p class="page_title">[[${title}]]</p>
|
<p class="page_title">[[${title}]]</p>
|
||||||
|
|
||||||
<!-- 테이블 -->
|
<!-- 테이블 -->
|
||||||
<div class="content_box">
|
<div class="content_box">
|
||||||
<div class="content clear">
|
<div class="update-container">
|
||||||
<div class="wp60">
|
<!-- Left Panel: Data Forms -->
|
||||||
<div class="top">
|
<div class="left-panel">
|
||||||
<label>썸네일 첨부파일</label>
|
<!-- Row 1: Category & Title -->
|
||||||
<label for="file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
|
<div class="form-grid-row">
|
||||||
</div>
|
<div class="form-group" style="flex: 0 0 150px;">
|
||||||
<div class="btm">
|
<label>카테고리</label>
|
||||||
<div class="img_box">
|
<select th:name="category" th:disabled="true">
|
||||||
<img id="thumbnailImg" src="" width="800px" height="450px" />
|
<option value="">선택하세요</option>
|
||||||
</div>
|
<option th:each="item : ${category}" th:value="${item['categoryNo']}"
|
||||||
<input type="file" id="file" accept="image/jpeg, image/jpg, image/png" style="display: none;" multiple>
|
th:text="${item['categoryNm']}"></option>
|
||||||
<button id="delete_btn">삭제</button>
|
</select>
|
||||||
</div>
|
<input type="hidden" id="categoryNo" />
|
||||||
<p class="thumbnail-bottom-txt">
|
|
||||||
썸네일 하단글
|
|
||||||
</p>
|
|
||||||
<textarea id="thumbnailBottomTxt" placeholder="썸네일 하단글을 입력해주세요." ></textarea>
|
|
||||||
<p class="content-file">
|
|
||||||
컨텐츠 첨부파일
|
|
||||||
<label for="content_file" class="file_btn"><img src="/image/web/add.svg" alt="파일찾기"></label>
|
|
||||||
</p>
|
|
||||||
<input type="file" id="content_file" style="display: none;" placeholder="첨부파일을 입력해주세요."/>
|
|
||||||
<div class="file_box">
|
|
||||||
<img id="contentsImg" src="" width="100%" height="100%" />
|
|
||||||
</div>
|
|
||||||
<button id="content_delete_btn">삭제</button>
|
|
||||||
</div>
|
|
||||||
<div class="wp40">
|
|
||||||
<div class="consultation-info">
|
|
||||||
<p id="main_category">
|
|
||||||
카테고리
|
|
||||||
</p>
|
|
||||||
<select th:name="category" th:disabled="true">
|
|
||||||
<option value="">선택하세요</option>
|
|
||||||
<option th:each="item : ${category}" th:value="${item['categoryNo']}" th:text="${item['categoryNm']}" ></option>
|
|
||||||
</select>
|
|
||||||
<!-- disabled된 select의 값을 전송하기 위한 hidden input -->
|
|
||||||
<input type="hidden" id="categoryNo" />
|
|
||||||
<p id="main_title">
|
|
||||||
제목
|
|
||||||
</p>
|
|
||||||
<input type="text" id="title" placeholder="제목을 입력해주세요."/>
|
|
||||||
<p id="main_content">
|
|
||||||
내용
|
|
||||||
</p>
|
|
||||||
<textarea id="content" placeholder="내용을 입력해주세요."></textarea>
|
|
||||||
<p id="main_hashtag">
|
|
||||||
해쉬태그
|
|
||||||
</p>
|
|
||||||
<input type="text" id="hashtag" placeholder="해쉬태그를 입력해주세요."/>
|
|
||||||
<div>
|
|
||||||
<label for="oldCrmItemId">OLD CRM 연동ID</label>
|
|
||||||
<input type="text" id="oldCrmItemId" placeholder="OLD_CRM_ITEM_ID"/>
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="form-group">
|
||||||
<label for="ordNo">홈페이지 출력순서</label>
|
<label>제목</label>
|
||||||
|
<input type="text" id="title" placeholder="제목을 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Row 2: Content & Order -->
|
||||||
|
<div class="form-grid-row">
|
||||||
|
<div class="form-group" style="flex: 1;">
|
||||||
|
<label>내용</label>
|
||||||
|
<input type="text" id="content" placeholder="내용을 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
<div class="form-group" style="flex: 0 0 70px;">
|
||||||
|
<label>출력순서</label>
|
||||||
<input type="text" id="ordNo" />
|
<input type="text" id="ordNo" />
|
||||||
</div>
|
</div>
|
||||||
<p id="main_procedure">
|
</div>
|
||||||
시술선택
|
|
||||||
<button class="add_btn ml50" onclick="javascript:listOpen();">
|
<!-- Row 3: Hashtag & Old ID -->
|
||||||
<img src="/image/web/add.svg" alt="추가">
|
<div class="form-grid-row">
|
||||||
</button>
|
<div class="form-group">
|
||||||
<button class="add_btn" onclick="javascript:fn_removeRow();">
|
<label>해쉬태그</label>
|
||||||
<img src="/image/web/subtract.svg" alt="삭제">
|
<input type="text" id="hashtag" placeholder="해쉬태그를 입력해주세요." />
|
||||||
</button>
|
</div>
|
||||||
</p>
|
<div class="form-group">
|
||||||
<div id="treatmentlist">
|
<label>OLD CRM 연동ID</label>
|
||||||
|
<input type="text" id="oldCrmItemId" placeholder="OLD_CRM_ITEM_ID" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="button_box">
|
|
||||||
<button class="registration_btn btnSave">수정</button>
|
<!-- Date Selection (Event Only) -->
|
||||||
<button class="cancel_btn btnCancle">취소</button>
|
<div class="form-grid-row" id="dateSelectionRow" style="display:none;">
|
||||||
</div>
|
<div class="form-group">
|
||||||
|
<label>시작일</label>
|
||||||
|
<input type="text" id="eventStartDt" placeholder="YYYY-MM-DD" readonly />
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label>종료일</label>
|
||||||
|
<input type="text" id="eventEndDt" placeholder="YYYY-MM-DD" readonly />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Row 4: Treatment Grid -->
|
||||||
|
<div class="grid-section">
|
||||||
|
<div class="grid-header">
|
||||||
|
<p>시술선택</p>
|
||||||
|
<div>
|
||||||
|
<button class="add_btn" onclick="javascript:listOpen();"
|
||||||
|
style="border:none; background:none; cursor:pointer;">
|
||||||
|
<img src="/image/web/add.svg" alt="추가">
|
||||||
|
</button>
|
||||||
|
<button class="add_btn" onclick="javascript:fn_removeRow();"
|
||||||
|
style="border:none; background:none; cursor:pointer; margin-left: 5px;">
|
||||||
|
<img src="/image/web/subtract.svg" alt="삭제">
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="custom-grid-container">
|
||||||
|
<table class="treatment-table">
|
||||||
|
<colgroup>
|
||||||
|
<col style="width: 50px;">
|
||||||
|
<col style="width: 250px;">
|
||||||
|
<col style="width: 120px;">
|
||||||
|
<col style="width: 120px;">
|
||||||
|
</colgroup>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>
|
||||||
|
<input type="checkbox" id="checkAll" onclick="fn_checkAll(this)">
|
||||||
|
</th>
|
||||||
|
<th>시술명</th>
|
||||||
|
<th>가격</th>
|
||||||
|
<th>할인가</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="treatmentListBody">
|
||||||
|
<!-- Rows will be added here dynamically -->
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Bottom Buttons -->
|
||||||
|
<div class="bottom-actions">
|
||||||
|
<button class="btn-basic btnPreview" onclick="fn_openPreview();"
|
||||||
|
style="width: 120px; height: 36px; border-radius: 4px; background: #fff; color: #333; border: 1px solid #ccc; margin-right: auto;">미리보기</button>
|
||||||
|
<button class="registration_btn btnSave"
|
||||||
|
style="width: 80px; height: 36px; border-radius: 4px; background: #3985EA; color: white;">수정</button>
|
||||||
|
<button class="cancel_btn btnCancle"
|
||||||
|
style="width: 80px; height: 36px; border-radius: 4px;">취소</button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
<!-- Right Panel: Images -->
|
||||||
|
<div class="right-panel">
|
||||||
|
<!-- Thumbnail Section -->
|
||||||
|
<div class="panel-section">
|
||||||
|
<div class="top-label">
|
||||||
|
<span>썸네일 첨부파일</span>
|
||||||
|
<div>
|
||||||
|
<label for="file" class="file_btn" style="cursor: pointer;"><img
|
||||||
|
src="/image/web/add.svg" alt="파일찾기"></label>
|
||||||
|
<button id="delete_btn"
|
||||||
|
style="border:none; background:none; cursor:pointer; margin-left:5px; font-size:12px; color:#999;">삭제</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="img-preview-wrapper img_box">
|
||||||
|
<img id="thumbnailImg" src="" />
|
||||||
|
</div>
|
||||||
|
<input type="file" id="file" accept="image/jpeg, image/jpg, image/png" style="display: none;"
|
||||||
|
multiple>
|
||||||
|
|
||||||
</div>
|
<label style="margin-top: 10px; font-size: 13px; font-weight: 700;">썸네일 하단글</label>
|
||||||
</div>
|
<textarea id="thumbnailBottomTxt" placeholder="썸네일 하단글을 입력해주세요."></textarea>
|
||||||
<form id="excelForm" method="POST" target="_blank"></form>
|
</div>
|
||||||
|
|
||||||
|
<!-- Content File Section -->
|
||||||
|
<div class="panel-section">
|
||||||
|
<div class="top-label">
|
||||||
|
<span>컨텐츠 첨부파일</span>
|
||||||
|
<div>
|
||||||
|
<label for="content_file" class="file_btn" style="cursor: pointer;"><img
|
||||||
|
src="/image/web/add.svg" alt="파일찾기"></label>
|
||||||
|
<button id="content_delete_btn"
|
||||||
|
style="border:none; background:none; cursor:pointer; margin-left:5px; font-size:12px; color:#999;">삭제</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="img-preview-wrapper file_box">
|
||||||
|
<!-- Using same class for consistent styling -->
|
||||||
|
<img id="contentsImg" src="" />
|
||||||
|
</div>
|
||||||
|
<input type="file" id="content_file" style="display: none;" placeholder="첨부파일을 입력해주세요." />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<form id="excelForm" method="POST" target="_blank"></form>
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_popup">
|
<th:block layout:fragment="layout_popup">
|
||||||
</th:block>
|
</th:block>
|
||||||
<th:block layout:fragment="layout_script">
|
<th:block layout:fragment="layout_script">
|
||||||
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
<script src="/js/web/contentsBbs/ContentsBbsUpd.js"></script>
|
||||||
<script src="/js/web/contentsBbs/ContentsBbsUpd.js"></script>
|
<script src="/js/web/contentsBbs/ContentsBbsPop.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/summernote@0.8.18/dist/summernote.min.js"></script>
|
|
||||||
<script src="/js/web/contentsBbs/ContentsBbsPop.js"></script>
|
|
||||||
</th:block>
|
</th:block>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,89 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
|
<th:block layout:fragment="layout_css">
|
||||||
|
<link rel="stylesheet" href="/css/web/webFeedbackSelectList.css">
|
||||||
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
|
<link rel="stylesheet" href="/css/web/sms_template.css">
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_top_script">
|
||||||
|
<script>
|
||||||
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
</script>
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_content">
|
||||||
|
<!-- 센터쪽 -->
|
||||||
|
<div class="center_box">
|
||||||
|
<p class="page_title">문자 상용구 관리</p>
|
||||||
|
|
||||||
|
<!-- 2패널 컨테이너 -->
|
||||||
|
<div class="sms_two_panel">
|
||||||
|
<!-- 좌측: 목록 -->
|
||||||
|
<div class="sms_left_panel">
|
||||||
|
<div class="sms_search_area">
|
||||||
|
<div class="sms_search_box">
|
||||||
|
<img src="/image/web/search_G.svg" alt="search" />
|
||||||
|
<input type="text" id="searchKeyword" placeholder="제목 또는 내용" />
|
||||||
|
</div>
|
||||||
|
<button id="searchBtn" class="sms_search_btn">조회</button>
|
||||||
|
<button type="button" id="newTemplateBtn" class="sms_new_btn">등록</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="smsTemplateGrid" class="sms_grid_box ag-theme-balham"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 우측: 상세/편집 -->
|
||||||
|
<div class="sms_right_panel">
|
||||||
|
<!-- 빈 상태 -->
|
||||||
|
<div class="sms_empty_state" id="emptyState">
|
||||||
|
<p>좌측 목록에서 상용구를 선택하거나<br />"등록" 버튼을 클릭하세요.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 상세 폼 -->
|
||||||
|
<div class="sms_detail_form" id="detailForm" style="display:none;">
|
||||||
|
<div class="sms_detail_title_bar">
|
||||||
|
<h3 id="detailTitle">상용구 등록</h3>
|
||||||
|
</div>
|
||||||
|
<input type="hidden" id="muSmsTemplateId" />
|
||||||
|
<div class="sms_form_row">
|
||||||
|
<label for="templateTitle">제목</label>
|
||||||
|
<input type="text" id="templateTitle" placeholder="상용구 제목을 입력하세요" maxlength="100" />
|
||||||
|
</div>
|
||||||
|
<div class="sms_form_row">
|
||||||
|
<label for="templateContent">내용</label>
|
||||||
|
<textarea id="templateContent" placeholder="상용구 내용을 입력하세요" rows="8"></textarea>
|
||||||
|
<div class="byte_info">
|
||||||
|
<span><span id="byteCount">0</span> byte</span>
|
||||||
|
<span class="type_badge sms" id="typeBadge">SMS</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="sms_form_row sms_info_row" id="infoRow" style="display:none;">
|
||||||
|
<span>등록자: <strong id="regName">-</strong></span>
|
||||||
|
<span>등록일: <strong id="regDate">-</strong></span>
|
||||||
|
<span>수정일: <strong id="modDate">-</strong></span>
|
||||||
|
</div>
|
||||||
|
<div class="sms_btn_group">
|
||||||
|
<button type="button" id="saveBtn" class="sms_save_btn">저장</button>
|
||||||
|
<button type="button" id="deleteBtn" class="sms_delete_btn" style="display:none;">삭제</button>
|
||||||
|
<button type="button" id="cancelBtn" class="sms_cancel_btn">취소</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<form id="smsTemplateForm" onsubmit="return false;"></form>
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_popup">
|
||||||
|
</th:block>
|
||||||
|
<th:block layout:fragment="layout_script">
|
||||||
|
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
||||||
|
<script src="/js/web/smsTemplate/smsTemplateSelectList.js"></script>
|
||||||
|
</th:block>
|
||||||
|
|
||||||
|
</html>
|
||||||
@@ -1,8 +1,6 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
xmlns:th="http://www.thymeleaf.org"
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
||||||
layout:decorate="~{/web/layout/homeLayout}">
|
|
||||||
<th:block layout:fragment="layout_css">
|
<th:block layout:fragment="layout_css">
|
||||||
<link rel="stylesheet" href="/css/web/webMainBannerSelectList.css">
|
<link rel="stylesheet" href="/css/web/webMainBannerSelectList.css">
|
||||||
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
@@ -10,27 +8,27 @@
|
|||||||
<th:block layout:fragment="layout_top_script">
|
<th:block layout:fragment="layout_top_script">
|
||||||
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
||||||
<script>
|
<script>
|
||||||
let menuClass = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
|
|
||||||
let selectUseYn = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
let insertUseYn = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
let updateUseYn = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
let deleteUseYn = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
|
||||||
/* 검색 관련 변수 */
|
/* 검색 관련 변수 */
|
||||||
let webMainBannerSearchKeywordParam = "[[${param.webMainBannerSearchKeywordParam}]]";
|
let webMainBannerSearchKeywordParam = "[[${param.webMainBannerSearchKeywordParam}]]";
|
||||||
let webMainBannerSearchType = "[[${param.webMainBannerSearchType}]]";
|
let webMainBannerSearchType = "[[${param.webMainBannerSearchType}]]";
|
||||||
let webMainBannerSort = "[[${param.webMainBannerSort}]]";
|
let webMainBannerSort = "[[${param.webMainBannerSort}]]";
|
||||||
let webMainBannerDir = "[[${param.webMainBannerDir}]]";
|
let webMainBannerDir = "[[${param.webMainBannerDir}]]";
|
||||||
let webMainBannerStart = "[[${param.webMainBannerStart}]]"==""?0:"[[${param.webMainBannerStart}]]";
|
let webMainBannerStart = "[[${param.webMainBannerStart}]]" == "" ? 0 : "[[${param.webMainBannerStart}]]";
|
||||||
let webMainBannerLimit = "[[${param.webMainBannerLimit}]]"==""?500:"[[${param.webMainBannerLimit}]]";
|
let webMainBannerLimit = "[[${param.webMainBannerLimit}]]" == "" ? 500 : "[[${param.webMainBannerLimit}]]";
|
||||||
|
|
||||||
let webMainBannerSearchStartDate = "[[${param.webMainBannerSearchStartDate}]]";
|
let webMainBannerSearchStartDate = "[[${param.webMainBannerSearchStartDate}]]";
|
||||||
let webMainBannerSearchEndDate = "[[${param.webMainBannerSearchEndDate}]]";
|
let webMainBannerSearchEndDate = "[[${param.webMainBannerSearchEndDate}]]";
|
||||||
let webMainBannerSearchDateType = "[[${param.webMainBannerSearchDateType}]]"==""?"A":"[[${param.webMainBannerSearchDateType}]]";
|
let webMainBannerSearchDateType = "[[${param.webMainBannerSearchDateType}]]" == "" ? "A" : "[[${param.webMainBannerSearchDateType}]]";
|
||||||
|
|
||||||
// CDN_URL 전역 정의
|
// CDN_URL 전역 정의
|
||||||
const CDN_URL = "[(${@environment.getProperty('url.cdn')})]";
|
const CDN_URL = "[(${@environment.getProperty('url.cdn')})]";
|
||||||
</script>
|
</script>
|
||||||
</th:block>
|
</th:block>
|
||||||
@@ -41,38 +39,11 @@
|
|||||||
|
|
||||||
<div class="filter_box">
|
<div class="filter_box">
|
||||||
<div class="form_box">
|
<div class="form_box">
|
||||||
<div class="select_box first dropdown">
|
|
||||||
<button class="label" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">기간</button>
|
|
||||||
<input type="hidden" id="webMainBannerSearchDateType">
|
|
||||||
<ul class="select_option_list dropdown-menu">
|
|
||||||
<li id="li_A" class="option_list_item first" >오늘</li>
|
|
||||||
<li id="li_B" class="option_list_item">최근30일</li>
|
|
||||||
<li id="li_C" class="option_list_item">최근90일</li>
|
|
||||||
<li id="li_D" class="option_list_item">이번주</li>
|
|
||||||
<li id="li_E" class="option_list_item">이번달</li>
|
|
||||||
<li id="li_F" class="option_list_item">올해</li>
|
|
||||||
<li id="li_G" class="option_list_item">지난주</li>
|
|
||||||
<li id="li_H" class="option_list_item">지난달</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 캘린더input -->
|
|
||||||
<div class="calendar_box">
|
|
||||||
<div class="date_box date" id="divWebMainBannerSearchStartDate">
|
|
||||||
<img src="/image/web/calendar.svg" alt="calendar"/>
|
|
||||||
<input type="date" class="date_picker" id="webMainBannerSearchStartDate">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<span class="slash">-</span>
|
|
||||||
|
|
||||||
<div class="date_box last date" id="divWebMainBannerSearchEndDate">
|
|
||||||
<img src="/image/web/calendar.svg" alt="calendar"/>
|
|
||||||
<input type="date" class="date_picker" id="webMainBannerSearchEndDate">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="select_box dropdown">
|
<div class="select_box dropdown">
|
||||||
<button class="label" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">카테고리 전체</button>
|
<button class="label" type="button" data-toggle="dropdown" aria-haspopup="true"
|
||||||
|
aria-expanded="false">카테고리 전체</button>
|
||||||
<input type="hidden" id="webMainBannerSearchType">
|
<input type="hidden" id="webMainBannerSearchType">
|
||||||
<ul class="select_option_list dropdown-menu">
|
<ul class="select_option_list dropdown-menu">
|
||||||
<li class="option_list_item" id="li_ALL">구분 전체</li>
|
<li class="option_list_item" id="li_ALL">구분 전체</li>
|
||||||
@@ -86,7 +57,7 @@
|
|||||||
<!-- 이름input -->
|
<!-- 이름input -->
|
||||||
<div class="search_list">
|
<div class="search_list">
|
||||||
<div class="search_box">
|
<div class="search_box">
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
<img src="/image/web/search_G.svg" alt="search" />
|
||||||
<input type="text" id="webMainBannerSearchKeyword" required placeholder="제목">
|
<input type="text" id="webMainBannerSearchKeyword" required placeholder="제목">
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
||||||
@@ -122,4 +93,5 @@
|
|||||||
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
||||||
<script src="/js/web/webmainbanner/webMainBannerSelectList.js"></script>
|
<script src="/js/web/webmainbanner/webMainBannerSelectList.js"></script>
|
||||||
</th:block>
|
</th:block>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
@@ -1,8 +1,6 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
|
||||||
xmlns:th="http://www.thymeleaf.org"
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorate="~{/web/layout/homeLayout}">
|
||||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
||||||
layout:decorate="~{/web/layout/homeLayout}">
|
|
||||||
<th:block layout:fragment="layout_css">
|
<th:block layout:fragment="layout_css">
|
||||||
<link rel="stylesheet" href="/css/web/webPopupSelectList.css">
|
<link rel="stylesheet" href="/css/web/webPopupSelectList.css">
|
||||||
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
<link rel="stylesheet" href="/css/web/grid.css?v1.1">
|
||||||
@@ -10,26 +8,26 @@
|
|||||||
<th:block layout:fragment="layout_top_script">
|
<th:block layout:fragment="layout_top_script">
|
||||||
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
<script src="/js/web/jquery.twbsPagination.js" type="text/javascript"></script>
|
||||||
<script>
|
<script>
|
||||||
let menuClass = "[[${param.menuClass}]]"==""?"":"[[${param.menuClass}]]";
|
let menuClass = "[[${param.menuClass}]]" == "" ? "" : "[[${param.menuClass}]]";
|
||||||
|
|
||||||
let selectUseYn = "[[${selectUseYn}]]"==""?"N":"[[${selectUseYn}]]";
|
let selectUseYn = "[[${selectUseYn}]]" == "" ? "N" : "[[${selectUseYn}]]";
|
||||||
let insertUseYn = "[[${insertUseYn}]]"==""?"N":"[[${insertUseYn}]]";
|
let insertUseYn = "[[${insertUseYn}]]" == "" ? "N" : "[[${insertUseYn}]]";
|
||||||
let updateUseYn = "[[${updateUseYn}]]"==""?"N":"[[${updateUseYn}]]";
|
let updateUseYn = "[[${updateUseYn}]]" == "" ? "N" : "[[${updateUseYn}]]";
|
||||||
let deleteUseYn = "[[${deleteUseYn}]]"==""?"N":"[[${deleteUseYn}]]";
|
let deleteUseYn = "[[${deleteUseYn}]]" == "" ? "N" : "[[${deleteUseYn}]]";
|
||||||
let downloadUseYn = "[[${downloadUseYn}]]"==""?"N":"[[${downloadUseYn}]]";
|
let downloadUseYn = "[[${downloadUseYn}]]" == "" ? "N" : "[[${downloadUseYn}]]";
|
||||||
|
|
||||||
/* 검색 관련 변수 */
|
/* 검색 관련 변수 */
|
||||||
let webPopupSearchKeywordParam = "[[${param.webPopupSearchKeywordParam}]]";
|
let webPopupSearchKeywordParam = "[[${param.webPopupSearchKeywordParam}]]";
|
||||||
let webPopupSort = "[[${param.webPopupSort}]]";
|
let webPopupSort = "[[${param.webPopupSort}]]";
|
||||||
let webPopupDir = "[[${param.webPopupDir}]]";
|
let webPopupDir = "[[${param.webPopupDir}]]";
|
||||||
let webPopupStart = "[[${param.webPopupStart}]]"==""?0:"[[${param.webPopupStart}]]";
|
let webPopupStart = "[[${param.webPopupStart}]]" == "" ? 0 : "[[${param.webPopupStart}]]";
|
||||||
let webPopupLimit = "[[${param.webPopupLimit}]]"==""?500:"[[${param.webPopupLimit}]]";
|
let webPopupLimit = "[[${param.webPopupLimit}]]" == "" ? 500 : "[[${param.webPopupLimit}]]";
|
||||||
|
|
||||||
let webPopupSearchStartDate = "[[${param.webPopupSearchStartDate}]]";
|
let webPopupSearchStartDate = "[[${param.webPopupSearchStartDate}]]";
|
||||||
let webPopupSearchEndDate = "[[${param.webPopupSearchEndDate}]]";
|
let webPopupSearchEndDate = "[[${param.webPopupSearchEndDate}]]";
|
||||||
let webPopupSearchDateType = "[[${param.webPopupSearchDateType}]]"==""?"A":"[[${param.webPopupSearchDateType}]]";
|
let webPopupSearchDateType = "[[${param.webPopupSearchDateType}]]" == "" ? "A" : "[[${param.webPopupSearchDateType}]]";
|
||||||
|
|
||||||
// CDN_URL 전역 정의
|
// CDN_URL 전역 정의
|
||||||
const CDN_URL = "[(${@environment.getProperty('url.cdn')})]";
|
const CDN_URL = "[(${@environment.getProperty('url.cdn')})]";
|
||||||
</script>
|
</script>
|
||||||
</th:block>
|
</th:block>
|
||||||
@@ -40,11 +38,16 @@
|
|||||||
|
|
||||||
<div class="filter_box">
|
<div class="filter_box">
|
||||||
<div class="form_box">
|
<div class="form_box">
|
||||||
<select id="homepageDivCd">
|
<div class="select_box first dropdown">
|
||||||
<option value="">홈페이지 구분</option>
|
<button class="label" type="button" data-toggle="dropdown" aria-haspopup="true"
|
||||||
<option value="01">다이어트센터</option>
|
aria-expanded="false">홈페이지 구분</button>
|
||||||
<option value="02">쁘띠센터</option>
|
<input type="hidden" id="homepageDivCd">
|
||||||
</select>
|
<ul class="select_option_list dropdown-menu">
|
||||||
|
<li class="option_list_item" id="li_ALL">홈페이지 구분</li>
|
||||||
|
<li class="option_list_item" id="li_01">다이어트센터</li>
|
||||||
|
<li class="option_list_item" id="li_02">쁘띠센터</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- 캘린더input -->
|
<!-- 캘린더input -->
|
||||||
<!--<div class="calendar_box">
|
<!--<div class="calendar_box">
|
||||||
@@ -64,12 +67,13 @@
|
|||||||
<!-- 이름input -->
|
<!-- 이름input -->
|
||||||
<div class="search_list">
|
<div class="search_list">
|
||||||
<div class="search_box">
|
<div class="search_box">
|
||||||
<img src="/image/web/search_G.svg" alt="search"/>
|
<img src="/image/web/search_G.svg" alt="search" />
|
||||||
<input type="text" id="webPopupSearchKeyword" required placeholder="제목">
|
<input type="text" id="webPopupSearchKeyword" required placeholder="제목">
|
||||||
|
|
||||||
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
<div class="search_list"></div><!-- 검색내역 나오는곳 -->
|
||||||
</div>
|
</div>
|
||||||
<button id="btnSearchWebPopup" class="search_btn" data-toggle="modal" data-target=".work_closed_modal" style="transition: all 0.2s ease-in-out 0s;">조회</button>
|
<button id="btnSearchWebPopup" class="search_btn" data-toggle="modal"
|
||||||
|
data-target=".work_closed_modal" style="transition: all 0.2s ease-in-out 0s;">조회</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="right_btn_box">
|
<div class="right_btn_box">
|
||||||
@@ -100,4 +104,5 @@
|
|||||||
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
<script src="/js/web/ag-grid-community-29.3.5.min.js"></script>
|
||||||
<script src="/js/web/webpopup/webPopupSelectList.js"></script>
|
<script src="/js/web/webpopup/webPopupSelectList.js"></script>
|
||||||
</th:block>
|
</th:block>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
Reference in New Issue
Block a user