Initial commit: WACE PLM with database initialization features
- Add Docker Compose configurations for dev, prod, and standalone environments - Add database initialization scripts (init-db.sh, init-db-docker.sh) - Add enhanced start-docker-linux.sh with DB init support - Add comprehensive database initialization guide - Support for automatic dbexport.pgsql import on first run - Include safety checks for production environment
This commit is contained in:
@@ -0,0 +1,172 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8"
|
||||
pageEncoding="UTF-8"%>
|
||||
<%@ page import="com.pms.common.utils.*"%>
|
||||
<%@ page import="java.util.*"%>
|
||||
<%@include file="/init.jsp"%>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<title><%=Constants.SYSTEM_NAME%></title>
|
||||
<script>
|
||||
$(function(){
|
||||
$(document).ready(function(){
|
||||
var actionType = "${actionType}";
|
||||
if(actionType == 'modify'){
|
||||
$('#overlapCheckId').remove();
|
||||
$('#overlapStatus').remove();
|
||||
}
|
||||
});
|
||||
|
||||
//닫기
|
||||
$("#btnClose").click(function(){
|
||||
self.close(0);
|
||||
});
|
||||
|
||||
//저장
|
||||
$("#btnSave").click(function(){
|
||||
if(fn_validate()){
|
||||
if(confirm("저장하시겠습니까?")){
|
||||
fnc_regionSubmit();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
//중복확인
|
||||
$("#overlapCheckId").click(function(){
|
||||
fnc_overlapCheck();
|
||||
});
|
||||
|
||||
//엔터키로 조회
|
||||
$("input").keyup(function(e){
|
||||
if(e.keyCode == 13){
|
||||
fnc_regionSubmit();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
//중복확인
|
||||
function fnc_overlapCheck(){
|
||||
var result;
|
||||
var regionName = $('#regionName').val();
|
||||
if(!fnc_valitate('form1')){
|
||||
$('#overlapStatus').empty();
|
||||
$('#regionName').focus();
|
||||
}else{
|
||||
$.ajax({
|
||||
url:"/admin/regionOverlapCheck.do",
|
||||
type:"POST",
|
||||
data:{"search_regionName":regionName},
|
||||
dataType:"json",
|
||||
async:false,
|
||||
success:function(overlap){
|
||||
if(overlap.REGION_NAME == regionName){
|
||||
$('#overlapStatus').text("등록된 정보입니다.");
|
||||
$('#regionName').focus();
|
||||
}else{
|
||||
$('#overlapStatus').text("등록 가능한 정보입니다.");
|
||||
$('#regionName').focus();
|
||||
}
|
||||
|
||||
result = overlap;
|
||||
},
|
||||
error: function(jqxhr, status, error){
|
||||
}
|
||||
});
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
//저장
|
||||
function fnc_regionSubmit(){
|
||||
var regionName = $('#regionName').val();
|
||||
var regionDescription = $('#regionDescription').val();
|
||||
var regionObjid = $('#regionObjid').val();
|
||||
var status = $('#status').val();
|
||||
var actionType = "${param.actionType}";
|
||||
|
||||
var overlap = fnc_overlapCheck();
|
||||
|
||||
if(overlap.REGION_NAME == regionName && actionType == 'regist'){
|
||||
Swal.fire("등록된 정보입니다.");
|
||||
$('#regionName').focus();
|
||||
}else if(overlap.OBJID == regionObjid || overlap.REGION_NAME == undefined){
|
||||
$.ajax({
|
||||
url:"/admin/mergeRegion.do",
|
||||
type:"POST",
|
||||
data:{"regionName":regionName, "regionObjid":regionObjid, "status":status,
|
||||
"actionType":actionType, "regionDescription":regionDescription},
|
||||
dataType:"text",
|
||||
async:false,
|
||||
success:function(data){
|
||||
opener.fn_search();
|
||||
self.close(0);
|
||||
},
|
||||
error: function(jqxhr, status, error){
|
||||
}
|
||||
});
|
||||
}else{
|
||||
Swal.fire("등록된 정보입니다.");
|
||||
}
|
||||
}
|
||||
|
||||
//정합성체크
|
||||
function fn_validate(){
|
||||
if($("#regionName").val() == null || $("#regionName").val() == ""){
|
||||
Swal.fire("적용사양명을 입력해 주시기 바랍니다.");
|
||||
$("#regionName").focus();
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<form id="form1" name="form1" method="post">
|
||||
<input type="hidden" id="regionObjid" name="regionObjid" value="${regionInfo.OBJID}">
|
||||
<section id="commonSection" class="admin_applySpec_min">
|
||||
<div class="admin_title">
|
||||
<h2>적용사양 관리</h2>
|
||||
</div>
|
||||
<div id="adminPopupFormWrap">
|
||||
<table id="adminPopupForm">
|
||||
<colgroup>
|
||||
<col width="37%" />
|
||||
<col width="63%" />
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><label>적용사양명</label></td>
|
||||
<td><input type="text" title="적용사양" id="regionName" value="${regionInfo.REGION_NAME}" maxlength="50" required></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><label>설명</label></td>
|
||||
<td><input type="text" id="regionDescription" value="${regionInfo.DESCRIPTION}" maxlength="20"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><label>활성화 여부</label></td>
|
||||
<td>
|
||||
<select name="status" id="status">
|
||||
<option value="active" ${regionInfo.STATUS eq 'active'?'selected':''}>활성화</option>
|
||||
<option value="inActive" ${regionInfo.STATUS eq 'inActive'?'selected':''}>비활성화</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div id="adminPopupBtnWrap">
|
||||
<span id="overlapStatus"></span>
|
||||
<input type="button" value="저장" class="btns" id="btnSave">
|
||||
<input type="button" value="중복확인" class="btns" id="overlapCheckId">
|
||||
</div>
|
||||
</div>
|
||||
<div class="btnCenterWrap">
|
||||
<center class="center_btns_wrap">
|
||||
<input type="button" value="닫기" name="" id="btnClose" class="btns" onclick="javascript:self.close();">
|
||||
</center>
|
||||
</div>
|
||||
</section>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user