fbaee16f by sayhoChun

project finished

1 parent fd91b0e8
......@@ -13,23 +13,17 @@
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminEtc.php" ; ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/php/AnyGo.php" ;?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/ApiStatic.php" ;?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminProductionSpec.php" ; ?>
<?
$cmd = $_REQUEST[cmd] ;
// Ajax , ToO , ToS , ToPbyRef , ToOandClose , ReOandClose , ReOandToS ,
// Close , ToP , RePa , None
// $url = pack("H*",$_REQUEST[rurl]);
// echo $url ;
// echo $cmd . " ////////////// ";
$nextDisable = false ; // 디버깅용
$arr = explode(".", $cmd) ;
if( sizeof($arr) != 2 )
echo "[ControlException ] Cmd 형식이 맞지 않습니다." ;
else
......@@ -39,11 +33,8 @@
//var_dump();
$obj = new ReflectionClass($clsNm) ;
$obj= $obj->newInstance($_REQUEST) ;
$method = new ReflectionMethod($clsNm,$mtdNm) ;
$flow = $_REQUEST[flow] ;
if( $flow == "Ajax" || $flow == "" ) // JSON 이나 AJAX 일경우
echo $method->invoke($obj) ;
else
......@@ -54,18 +45,13 @@
$rurl = $_REQUEST[rurl] ;
$msg = $_REQUEST[msg] ;
$flow = $_REQUEST[flow] ;
if( $flow == "" )
echo "[ControlException ] flow 형식이 맞지 않습니다." ;
else
{
go("NORMAL",$flow,$msg,$rurl) ;
}
}
}
}
?>
\ No newline at end of file
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminUser.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBoard.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftBoardManage.php" ?>
<?
$obj = new AdminUser($_REQUEST) ;
$obj = new AdminBoard($_REQUEST) ;
//$list = $obj->getListOfUser() ;
$list = $obj->getListOfProductionPortrait() ;
$boardType=$_REQUEST["boardType"];
$vnum = $obj->virtualNum ;
?>
......@@ -73,11 +73,11 @@
// 단체 삭제
$(".jDelUserMulti").click2(function(){
$(".jDelMulti").click2(function(){
var noArr = new Array();
var noCount = $(".jUserNo:checked").length;
var noCount = $(".jNo:checked").length;
if(noCount == 0)
{
......@@ -90,10 +90,10 @@
{
for(var i = 0; i < noCount; i++ )
{
noArr[i] = $(".jUserNo:checked:eq(" + i + ")").val();
noArr[i] = $(".jNo:checked:eq(" + i + ")").val();
}
deleteUser(noArr);
deleteAction(noArr);
}
});
......@@ -130,10 +130,10 @@
function deleteUser(noArr)
function deleteAction(noArr)
{
$.ajax({
url : "/action_front.php?cmd=AdminUser.deleteUser",
url : "/action_front.php?cmd=AdminBoard.deleteProductionPortrait",
async : false,
cache : false,
dataType : "json",
......@@ -184,16 +184,16 @@
<?=$vnum--?>
</td>
<td class="center">
<input type="checkbox" class="jUserNo" value="<?=$list[$i]["no"] ?>" >
<input type="checkbox" class="jNo" value="<?=$list[$i]["ppNo"] ?>" >
</td>
<td class="center">
<?=$list[$i]["title"]?>
</td>
<td class="center">
<?=$list[$i]["regDate"]?>
</td>
<td class="center">
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["no"]?>" />
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["ppNo"]?>" />
</td>
</tr>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminOperate.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBoard.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftBoardManage.php" ?>
<?
$obj = new AdminOperate($_REQUEST, "");
//$info = $obj->getInfoOfShop();
$obj = new AdminBoard($_REQUEST, "");
$info = $obj->getInfoOfProductionPortrait();
//$cateCodeList = $obj->getShopCategoryCodeList();
//$shopImgList = $obj->getShopImgList($info["no"]);
......@@ -17,6 +17,7 @@
<script type="text/javascript">
var _rurl = "<?=$rurl?>";
var _no = "<?=$_REQUEST[no]?>";
var total = 10;
function MultiArticle(sTitle, sC, sCt, sImg){
this.title = sTitle;
......@@ -29,10 +30,26 @@
var multiArray = new Array();
for(var i = 1; i <= 10; i++){
for(var i = 1; i <= total; i++){
multiArray[i] = new MultiArticle("", i, "", 0);
}
$.ajax({
url : "/action_front.php?cmd=AdminBoard.getInfoOfProductionPortraitForJson",
dataType : "json",
data : {no : $("#articleNum").val()},
success : function(data){
for(var i = 1; i <= total; i++){
multiArray[i] = new MultiArticle(data['title'], i, data['content' + i], 0);
}
$("#mContent").val(multiArray[1].contents);
},
error : function(param1, param2, param3){
alert(param1 + "<br>" + param2 + "<br>" + param3);
}
});
init();
<?if($admin_type == 3) { ?>
......@@ -74,13 +91,11 @@
$("#category").click(function(){
var currentNum = $(this).val();
multiArray[currentNum].title = $("#mTitle").val();
multiArray[currentNum].contents = $("#mContent").val();
});
$("#category").change(function(){
var currentNum = $(this).val();
$("#mTitle").val(multiArray[currentNum].title);
$("#mContent").val(multiArray[currentNum].contents);
toggleHide(currentNum);
......@@ -93,10 +108,22 @@
}
}
$(".jSave").click2(function(){
function pickupRows(){
var noArr = new Array();
multiArray[$("#category").val()].contents=$("#mContent").val();
for(var i = 1; i <= 10; i++ ){
$("#content" + (i)).val(multiArray[i]["contents"]);
}
}
$(".jSave").click2(function(){
pickupRows();
$("#jData").ajaxSubmit({
url:"/action_front.php?cmd=AdminOperate.saveShop",
url:"/action_front.php?cmd=AdminBoard.saveProductionPortrait",
type : "post",
forceSync : true,
dataType : "json",
......@@ -172,7 +199,20 @@
<div class="data" style="width:80%;">
<form id="jData" method="post" enctype="multipart/form-data">
<input type="hidden" name="no" value="<?=$_REQUEST[no]?>" />
<input type="hidden" name="no" id="articleNum" value="<?=$_REQUEST[no]?>" />
<input type="hidden" id="content1" name="content1" value="" />
<input type="hidden" id="content2" name="content2" value="" />
<input type="hidden" id="content3" name="content3" value="" />
<input type="hidden" id="content4" name="content4" value="" />
<input type="hidden" id="content5" name="content5" value="" />
<input type="hidden" id="content6" name="content6" value="" />
<input type="hidden" id="content7" name="content7" value="" />
<input type="hidden" id="content8" name="content8" value="" />
<input type="hidden" id="content9" name="content9" value="" />
<input type="hidden" id="content10" name="content10" value="" />
<table class="datav" style="width:100%;">
<colgroup>
<col width="10%" />
......@@ -181,7 +221,7 @@
<tr>
<th style="height:25px;">제목</th>
<td class="l">
<input type="text" id="mTitle" class="wl" style="width:70%;" value="" />
<input type="text" name="title" id="mTitle" class="wl" style="width:70%;" value="<?=$info["title"]?>" />
</td>
</tr>
<tr>
......@@ -204,7 +244,7 @@
<tr>
<th style="height:25px;">내용</th>
<td class="l">
<textarea name="special_contract" rows="7" id="mContent" style="width:90%;resize:vertical;"><?=$info["special_contract"]?></textarea>
<textarea rows="7" id="mContent" style="width:90%;resize:vertical;"><?=$info["special_contract"]?></textarea>
</td>
</tr>
......@@ -214,91 +254,101 @@
<?
$fileIndex = "101";
$fileName = "img01";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP1"] == "" ? "" : $info["imgPathPP1"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP1" value="<?=$info["imgPathPP1"]?>" />
</td>
<td class="imgFiles" no=2>
<?
$fileIndex = "102";
$fileName = "img02";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP2"] == "" ? "" : $info["imgPathPP2"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP2" value="<?=$info["imgPathPP2"]?>" />
</td>
<td class="imgFiles" no=3>
<?
$fileIndex = "103";
$fileName = "img03";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP3"] == "" ? "" : $info["imgPathPP3"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP3" value="<?=$info["imgPathPP3"]?>" />
</td>
<td class="imgFiles" no=4>
<?
$fileIndex = "104";
$fileName = "img04";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP4"] == "" ? "" : $info["imgPathPP4"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP4" value="<?=$info["imgPathPP4"]?>" />
</td>
<td class="imgFiles" no=5>
<?
$fileIndex = "105";
$fileName = "img05";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP5"] == "" ? "" : $info["imgPathPP5"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP5" value="<?=$info["imgPathPP5"]?>" />
</td>
<td class="imgFiles" no=6>
<?
$fileIndex = "106";
$fileName = "img06";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP6"] == "" ? "" : $info["imgPathPP6"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP6" value="<?=$info["imgPathPP6"]?>" />
</td>
<td class="imgFiles" no=7>
<?
$fileIndex = "107";
$fileName = "img07";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP7"] == "" ? "" : $info["imgPathPP7"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP7" value="<?=$info["imgPathPP7"]?>" />
</td>
<td class="imgFiles" no=8>
<?
$fileIndex = "108";
$fileName = "img08";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP8"] == "" ? "" : $info["imgPathPP8"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP8" value="<?=$info["imgPathPP8"]?>" />
</td>
<td class="imgFiles" no=9>
<?
$fileIndex = "109";
$fileName = "img09";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP9"] == "" ? "" : $info["imgPathPP9"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP9" value="<?=$info["imgPathPP9"]?>" />
</td>
<td class="imgFiles" no=10>
<?
$fileIndex = "110";
$fileName = "img10";
$filePath = ($shopImgList[0]["file_vir_name"] == "" ? "" : $shopImgList[0]["file_vir_name"]);
$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
$filePath = ($info["imgPathPP10"] == "" ? "" : $info["imgPathPP10"]);
//$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]);
include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php";
?>
<input type="hidden" name="imgPathPP10" value="<?=$info["imgPathPP10"]?>" />
</td>
</tr>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminUser.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBoard.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftCustomerService.php" ?>
<?
$obj = new AdminUser($_REQUEST) ;
$obj = new AdminBoard($_REQUEST) ;
//$list = $obj->getListOfUser() ;
$boardType=$_REQUEST["boardType"];
$list = $obj->getListOfCS() ;
$vnum = $obj->virtualNum ;
?>
<script>
......@@ -73,11 +72,11 @@
// 단체 삭제
$(".jDelUserMulti").click2(function(){
$(".jDelMulti").click2(function(){
var noArr = new Array();
var noCount = $(".jUserNo:checked").length;
var noCount = $(".jNo:checked").length;
if(noCount == 0)
{
......@@ -90,7 +89,7 @@
{
for(var i = 0; i < noCount; i++ )
{
noArr[i] = $(".jUserNo:checked:eq(" + i + ")").val();
noArr[i] = $(".jNo:checked:eq(" + i + ")").val();
}
deleteUser(noArr);
......@@ -121,9 +120,9 @@
$("#jCheckAll").change(function(){
if($(this).is(":checked"))
$(".jUserNo").prop("checked", true);
$(".jNo").prop("checked", true);
else
$(".jUserNo").prop("checked", false);
$(".jNo").prop("checked", false);
});
}) ;
......@@ -133,7 +132,7 @@
function deleteUser(noArr)
{
$.ajax({
url : "/action_front.php?cmd=AdminUser.deleteUser",
url : "/action_front.php?cmd=AdminBoard.deleteCS",
async : false,
cache : false,
dataType : "json",
......@@ -184,16 +183,19 @@
<?=$vnum--?>
</td>
<td class="center">
<input type="checkbox" class="jUserNo" value="<?=$list[$i]["no"] ?>" >
<input type="checkbox" class="jNo" value="<?=$list[$i]["csNo"] ?>" >
</td>
<td class="center">
<?=$list[$i]["userName"]?>
</td>
<td class="center">
<?=$list[$i]["title"]?>
</td>
<td>
<?=$list[$i]["regDate"]?>
</td>
<td class="center">
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["no"]?>" />
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["csNo"]?>" />
</td>
</tr>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminPush.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBoard.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftCustomerService.php" ?>
<?
$obj = new AdminPush($_REQUEST, "") ;
$obj = new AdminBoard($_REQUEST, "") ;
//$list = $obj->getListOfAdminPush() ;
$info = $obj->getInfoOfCS() ;
$commentList = $obj->getListOfCSComment();
$vnum = $obj->virtualNum ;
$rurl = pack("H*", $_REQUEST["rurl"]) ;
?>
<script>
$(document).ready(function(){
var _rurl = "<?=$rurl?>";
//=====프레입웤 변수들==================================================================================//
var FORM_TARGET_CLS_NM = "DIV#Contents" ; // 폼을 동적 wrap 할 타겟 ID이름
var FORM_NAME = "nf" ; // 폼이름
......@@ -36,230 +38,28 @@
jForm.submit() ;
});
$(".jSave").click2(function(){
$(".jSearch").click2(function(){
jForm.ci() ;
jForm.submit() ;
});
$(".jSearchGroup").click2(function(){
var title = "그룹 검색";
$('#jDialogArea').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jSearchPrivate").click2(function(){
var title = "회원 검색";
$('#jDialogAreaP').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jTargetSearchBtn").click2(function(){
var search_text = $("#jTargetSearchText").val();
var ajax_url = "/admin/entity/entityGroupSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultArea").html(data);
setSearchAreaEventHandler();
$("#jData").ajaxSubmit({
url:"/action_front.php?cmd=AdminBoard.saveCS",
type : "post",
forceSync : true,
dataType : "json",
success : function(data){
alert(data.returnMessage);
location.href = _rurl;
}
});
});
$(".jTargetSearchPBtn").click2(function(){
var search_text = $("#jTargetSearchTextP").val();
var ajax_url = "/admin/entity/entityPrivateSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultAreaP").html(data);
setSearchAreaEventHandler();
}
});
$(".jCancel").click2(function(){
location.href = _rurl;
});
$("#push_target_type").change(function(){
resetTargetData();
if($(this).val() == "1")
{
$("#jGroupArea").hide();
$("#jPrivateArea").hide();
}
else if($(this).val() == "2")
{
$("#jGroupArea").show();
$("#jPrivateArea").hide();
}else{
$("#jGroupArea").hide();
$("#jPrivateArea").show();
}
});
$(".jSave").click2(function(){
var push_msg = $("#push_msg").val();
var push_target_type = $("#push_target_type").val();
var group_no = $("#group_no").val();
if(push_target_type == "2" && group_no == "")
{
alert("그룹을 선택해주세요.");
return false;
}
if(push_msg == "")
{
alert("푸시 내용을 입력해주세요.");
return false;
}
$.ajax({
url : "/action_front.php?cmd=AdminPush.sendAdminPush",
async : true,
cache : false,
dataType : "json",
data : {
"push_msg" : push_msg,
"push_target_type" : push_target_type,
"group_no" : group_no
}, success : function(data) {
alert(data.returnMessage) ;
if(data.returnCode == 1) {
location.reload();
}
}
});
});
}) ;
function setSearchAreaEventHandler()
{
$(".jTargetNo").unbind("change");
$(".jTargetNo").change(function(){
$(".jTargetNo").prop("checked", false);
$(this).prop("checked", true);
});
}
function resetTargetData()
{
$("#group_no").val("");
$("#group_name").val("");
}
......@@ -274,7 +74,8 @@
</h2>
<div class="data">
<form id="jData" method="post" enctype="multipart/form-data">
<input type="hidden" name="csNo" value="<?=$_REQUEST[no]?>" />
<table class="datav" style="width:100%;">
<colgroup>
<col width="30%" />
......@@ -283,7 +84,7 @@
<tr>
<th style="height:25px;">내용</th>
<td class="l">
<textarea rows="5" style="width:95%;" id="push_msg"></textarea>
<textarea name="content" rows="5" style="width:95%;" ></textarea>
</td>
</tr>
</table>
......@@ -291,7 +92,7 @@
<div class="btngroupright" style="width:100%;">
<span class="button bigrounded blue jSave" >등록</span>
</div>
</form>
<h3>히스토리</h3>
<table class="datacList">
<thead>
......@@ -301,72 +102,51 @@
</tr>
</thead>
<tbody><!-- 10줄 리스트// 마지막 tr에 class="last" 넣어주세요 -->
<? for($i=0; $i<sizeof($list); $i++){ ?>
<tr class="<?=(sizeof($list)-1 == $i) ? "last" : "datacLists"?>">
<? for($i=0; $i<sizeof($commentList); $i++){ ?>
<tr class="<?=(sizeof($commentList)-1 == $i) ? "last" : "datacLists"?>">
<td class="center">
<?=$commentList[$i]["userName"]?>
</td>
<td class="center">
<?=$list[$i]["push_msg"]?>
<?=$commentList[$i]["content"]?>
</td>
</tr>
<? } ?>
<?if(sizeof($list) == 0){?>
<tr class="last">
<td class="no center" colspan="11">No Data</td>
</tr>
<?}?>
</tbody>
</table>
<!-- Pagination -->
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/pageNavigation.php" ?>
<!--//Pagination -->
</div>
<div id="jDialogArea" style="display:none;">
<table class="datacList" style="width:100%;">
<thead>
<tr>
<td class="no" colspan="2" style="text-align:center; height:35px;">
<input type="text" id="jTargetSearchText" style="width:50%;" placeholder="검색어를 입력해야 결과가 노출 됩니다.">
<input type="button" class="button searchsmall white jTargetSearchBtn" value="검색" />
<?if(sizeof(info)>0){?>
<tr class="last">
<td class="center">
<?=$info["userName"]?>
</td>
</tr>
</thead>
<thead>
<tr>
<th class="no" colspan="2">검색결과</th>
</tr>
</thead>
<tbody id="jSearchResultArea"><!-- 10줄 리스트// 마지막 tr에 class="last" 넣어주세요 -->
</tbody>
</table>
</div>
<div id="jDialogAreaP" style="display:none;">
<table class="datacList" style="width:100%;">
<thead>
<tr>
<td class="no" colspan="2" style="text-align:center; height:35px;">
<input type="text" id="jTargetSearchTextP" style="width:50%;" placeholder="검색어를 입력해야 결과가 노출 됩니다.">
<input type="button" class="button searchsmall white jTargetSearchPBtn" value="검색" />
<td class="center">
<?=$info["content"]?>
</td>
</tr>
</thead>
<thead>
<tr>
<th class="no" colspan="2">검색결과</th>
</tr>
</thead>
<tbody id="jSearchResultAreaP"><!-- 10줄 리스트// 마지막 tr에 class="last" 넣어주세요 -->
<?}?>
</tbody>
</table>
<center>
<div class="data">
<?if($info["imgPathCS1"] != ""){?>
<img alt="" src="/720/<?=$info["imgPathCS1"]?>" style="width:15%; height:600%;">
<?}?>
<?if($info["imgPathCS2"] != ""){?>
<img alt="" src="/720/<?=$info["imgPathCS2"]?>" style="width:15%; height:600%;">
<?}?>
<?if($info["imgPathCS3"] != ""){?>
<img alt="" src="/720/<?=$info["imgPathCS3"]?>" style="width:15%; height:600%;">
<?}?>
<?if($info["imgPathCS4"] != ""){?>
<img alt="" src="/720/<?=$info["imgPathCS4"]?>" style="width:15%; height:600%;">
<?}?>
<?if($info["imgPathCS5"] != ""){?>
<img alt="" src="/720/<?=$info["imgPathCS5"]?>" style="width:15%; height:600%;">
<?}?>
</div>
</center>
</div>
</div>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminOperate.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminProductionSpec.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftProductionSpecManage.php" ?>
<?
$obj = new AdminOperate($_REQUEST, "") ;
//$list = $obj->getListOfRoomForPayment();
$obj = new AdminProductionSpec($_REQUEST) ;
$list=$obj->getListOfProductionSpec();
$vnum = $obj->virtualNum ;
?>
<script>
......@@ -90,7 +89,6 @@
});
// 단체 삭제
$(".jDelMulti").click2(function(){
......@@ -133,7 +131,7 @@
function deleteAction(noArr)
{
$.ajax({
url : "/action_front.php?cmd=AdminRent.delBuilding",
url : "/action_front.php?cmd=AdminProductionSpec.deleteProductionSpec",
async : false,
cache : false,
dataType : "json",
......@@ -141,7 +139,11 @@
"no" : noArr
},
success : function(data){
alert("삭제되었습니다");
location.reload();
},
error : function(a, b, c){
alert(a+b+c);
}
});
}
......@@ -163,13 +165,16 @@
<label>
<span>조회 조건</span>
<select value="asda" style="margin-right:20px;">
<option>asdasd</option>
<select name="searchType" style="margin-right:20px;">
<option value="">전체</option>
<option value="CN" <?=$_REQUEST[searchType] == "CN" ? "SELECTED" : ""?>>상호명</option>
<option value="PN" <?=$_REQUEST[searchType] == "PN" ? "SELECTED" : ""?>>제품명</option>
<option value="MN" <?=$_REQUEST[searchType] == "MN" ? "SELECTED" : ""?>>담당자</option>
</select>
</label>
<label>
<input type="text" id="search_room" name="search_room" class="wm" value="<?=$_REQUEST['search_room']?>" />
<input type="text" id="searchText" name="searchText" class="wm" value="<?=$_REQUEST['searchText']?>" />
</label>
......@@ -181,9 +186,9 @@
<label>
<span>기간 설정</span>
<input type="text" value="<?=$_REQUEST['rent_date_former']?>" id="rent_date_former" name="rent_date_former" class="jRsvDate" />
<input type="text" value="<?=$_REQUEST['dateFormer']?>" id="dateFormer" name="dateFormer" class="jRsvDate" />
&nbsp;~&nbsp;
<input type="text" value="<?=$_REQUEST['rent_date_latter']?>" id="rent_date_latter" name="rent_date_latter" class="jRsvDate" />
<input type="text" value="<?=$_REQUEST['dateLatter']?>" id="dateLatter" name="dateLatter" class="jRsvDate" />
</label>
......@@ -215,56 +220,29 @@
<?=$vnum--?>
</td>
<td class="center">
<input type="checkbox" class="jNo" value="<?=$list[$i]["no"] ?>" >
</td>
<!--//건물이름-->
<td class="center">
<?=$list[$i]["Bname"]?>
<input type="checkbox" class="jNo" value="<?=$list[$i]["productionNo"] ?>" >
</td>
<!--//호실 -->
<td class="center">
<?=$list[$i]["Rname"]?>
<?=$list[$i]["regDate"]?>
</td>
<!--//지난달 월세 -->
<td class="center">
<?
if($list[$i]["rent_paid"]==NULL) echo "";
else if($list[$i]["rent_paid"]==0) echo "연체";
else if($list[$i]["rent_paid"]==1) echo "납입";
else echo "청구중";
?>
<?=$list[$i]["companyName"]?>
</td>
<!--//월 납입일 -->
<td class="center">
<?=$list[$i]["monthly_rent_date"]?>
</td>
<!--//지난달 공과금 -->
<td class="center">
<?
if($list[$i]["bill_paid"]==NULL) echo "";
else if($list[$i]["bill_paid"]==0) echo "연체";
else if($list[$i]["bill_paid"]==1) echo "납입";
else echo "청구중";
?>
<?=$list[$i]["productName"]?>
</td>
<!--//공과금 납입일 -->
<td class="center">
<?=$list[$i]["billing_date"]?>
</td>
<!--//퇴실예정일 -->
<td class="center">
<?=$list[$i]["leaving_due_date"]?>
<?=$list[$i]["userName"]?>
</td>
<td class="center">
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["no"]?>" />
<input type="button" class="button searchsmall white jView" value="상세보기" no="<?=$list[$i]["productionNo"]?>" />
</td>
</tr>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminRent.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminProductionSpec.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?>
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftProductionSpecManage.php" ?>
<?
$obj = new AdminRent($_REQUEST, "");
//$info = $obj->getInfoOfRoom();
//$user_list = $obj->getListOfUserForRoom();
//$bill_info = $obj->getInfoOfBill();
$obj = new AdminProductionSpec($_REQUEST, "");
$info = $obj->getInfoOfProductionSpec();
$managerList= $obj->getListOfManager();
$addCount = 0;
$rurl = pack("H*", $_REQUEST["rurl"]) ;
?>
......@@ -46,14 +46,12 @@
}
});
$(".jCancel").click2(function(){
location.href = _rurl;
});
$(".jAdd").click(function(){
if($("#addContent").val()=="") return;
if(addCounter == THRESHOLD) {
alert("특수사항은 최대 " + THRESHOLD + "개까지 추가할 있습니다.");
return;
......@@ -74,31 +72,23 @@
for(var i = 0; i < noCount; i++ ){
noArr[i] = $(".added:eq(" + i + ")").val();
$("#specialAddition" + (i + 1)).val(noArr[i]);
}
alert(noArr);
}
$(".test").click(function(){
pickupRows();
});
$(document).on("click", ".adddel", function(){
$(".dynamicRow[no="+$(this).attr("no")+"]").remove();
addCounter--;
});
$(".jClose").click2(function(){
window.close();
});
$(".jMod").click2(function(){
pickupRows();
var data = $("#jData").serialize();
$.ajax({
url : "/action_front.php?cmd=AdminRent.saveRoom",
url : "/action_front.php?cmd=AdminProductionSpec.saveProductionSpec",
async : false,
cache : false,
dataType : "json",
......@@ -128,9 +118,14 @@
<div class="data" style="width:100%;">
<form id="jData">
<input type="hidden" name="no" value="<?=$_REQUEST[no]?>" />
<input type="hidden" name="building_fk" value="<?=$_GET["Bno"]?>" />
<input type="hidden" name="current_contractor" value="<?=$info["user_fk"]?>" />
<input type="hidden" id="specialAddition1" name="specialAddition1" value="" />
<input type="hidden" id="specialAddition2" name="specialAddition2" value="" />
<input type="hidden" id="specialAddition3" name="specialAddition3" value="" />
<input type="hidden" id="specialAddition4" name="specialAddition4" value="" />
<input type="hidden" id="specialAddition5" name="specialAddition5" value="" />
<input type="hidden" name="productionNo" value="<?=$_REQUEST[no]?>" />
<table class="datav" style="width:100%;">
<colgroup>
<col width="10%" />
......@@ -146,22 +141,16 @@
<!-- 호실 -->
<th style="height:25px;">작성 날짜</th>
<td class="center">
<?php
$formattedDate = date('Y-m-d', strtotime($info["move_in_date"]));
if($formattedDate == "1970-01-01") $formattedDate = "";
?>
<input type="text" name="move_in_date" value="<?=$formattedDate?>" class="jRsvDate" />
<input type="text" name="requestDate" value="<?=$info["requestDate"]?>" />
</td>
<!-- 관리유형 -->
<th style="height:25px;">담당자</th>
<td class="center" colspan='3'>
<select name="manage_type" class="wm">
<option value="">선택</option>
<option value="<?=$obj->BUILDING_MANAGE_TYPE_LONG_CONS?>" <?=$info["manage_type"] == $obj->BUILDING_MANAGE_TYPE_LONG_CONS ? "SELECTED" : ""?>>장기위탁</option>
<option value="<?=$obj->BUILDING_MANAGE_TYPE_SHORT_CONS?>" <?=$info["manage_type"] == $obj->BUILDING_MANAGE_TYPE_SHORT_CONS ? "SELECTED" : ""?>>단기위탁</option>
<option value="<?=$obj->BUILDING_MANAGE_TYPE_LONG_SELF?>" <?=$info["manage_type"] == $obj->BUILDING_MANAGE_TYPE_LONG_SELF ? "SELECTED" : ""?>>장기자기</option>
<option value="<?=$obj->BUILDING_MANAGE_TYPE_SHORT_SELF?>" <?=$info["manage_type"] == $obj->BUILDING_MANAGE_TYPE_SHORT_SELF ? "SELECTED" : ""?>>단기자기</option>
<select name="managerFk" class="wm">
<? for($i=0; $i<sizeof($managerList); $i++){ ?>
<option value='<?=$managerList[$i]["userNo"]?>' <?=$managerList[$i]["userNo"] == $info["userFk"] ? "SELECTED" : ""?>><?=$managerList[$i]["userName"]?></option>
<? } ?>
</select>
</td>
......@@ -184,35 +173,36 @@
<!-- 입주자 -->
<th style="height:25px;">성명</th>
<td class="center">
<input type="text" name="contractor_tel" class="wm" value="<?=$info["contractor_tel"]?>" />
<input type="text" name="customerName" class="wm" value="<?=$info["customerName"]?>" />
</td>
<!-- 연락처 -->
<th style="height:25px;">상호</th>
<td class="center">
<input type="text" name="contractor_tel" class="wm" value="<?=$info["contractor_tel"]?>" />
<input type="text" name="companyName" class="wm" value="<?=$info["companyName"]?>" />
</td>
<!-- 반환계좌 / 입금주 -->
<th style="height:25px;">연락처</th>
<td class="center" colspan='3'>
<input type="text" style="width:50px"/>&nbsp; - &nbsp;<input type="text" style="width:50px"/>&nbsp; - &nbsp;<input type="text" style="width:50px"/>
<input type="text" name="telephone1" style="width:50px" value="<?=substr($info["telephone"], 0, 3)?>"/>&nbsp; - &nbsp;
<input type="text" name="telephone2" style="width:50px" value="<?=substr($info["telephone"], 3, 4)?>"/>&nbsp; - &nbsp;
<input type="text" name="telephone3" style="width:50px" value="<?=substr($info["telephone"], 7, 4)?>"/>
</td>
</tr>
<tr>
<!-- 계약일 -->
<th style="height:25px;">차종</th>
<td class="center" colspan='7'>
<input type="text" style="width:5%;" /> TON
<input type="text" style="margin-right:50px;"/>
<input type="radio" name="chk_info" value="HTML">현대
<input type="radio" name="chk_info" value="CSS">대우
<input type="radio" name="chk_info" value="웹디자인">볼보
<input type="radio" name="chk_info" value="웹디자인">스카니아
<input type="radio" name="chk_info" value="웹디자인">벤츠
<input type="radio" name="chk_info" value="웹디자인">볼보
<input type="radio" name="chk_info" value="웹디자인">
<input type="text" name="vehicleTON" style="width:5%;" value="<?=$info["vehicleTON"]?>" /> TON
<input type="text" name="vehicleText" style="margin-right:50px;" value="<?=$info["vehicleText"]?>"/>
<input type="radio" name="vehicleType" value="HY" <?=$info["vehicleType"] == "HY" ? "CHECKED" : "" ?>>현대
<input type="radio" name="vehicleType" value="DW" <?=$info["vehicleType"] == "DW" ? "CHECKED" : "" ?>>대우
<input type="radio" name="vehicleType" value="VV" <?=$info["vehicleType"] == "VV" ? "CHECKED" : "" ?>>볼보
<input type="radio" name="vehicleType" value="SC" <?=$info["vehicleType"] == "SC" ? "CHECKED" : "" ?>>스카니아
<input type="radio" name="vehicleType" value="MB" <?=$info["vehicleType"] == "MB" ? "CHECKED" : "" ?>>벤츠
<input type="radio" name="vehicleType" value="MA" <?=$info["vehicleType"] == "MA" ? "CHECKED" : "" ?>>
</td>
</tr>
......@@ -234,7 +224,7 @@
<!-- 보증금 -->
<th style="height:25px;">제품명</th>
<td class="center" colspan='7'>
<input type="text" name="deposit" class="wm" value="<?=$info["deposit"]?>" />
<input type="text" name="productName" class="wm" value="<?=$info["productName"]?>" />
</td>
......@@ -243,33 +233,29 @@
<!-- 기본관리비 -->
<th style="height:25px;">TYPE</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">R
<input type="radio" name="chk_info" value="CSS">
<input type="radio" name="chk_info" value="웹디자인">판넬
<input type="text" style="margin-left:50px;"/>
<input type="radio" name="type" value="R" <?=$info["type"] == "R" ? "CHECKED" : "" ?>>R
<input type="radio" name="type" value="A" <?=$info["type"] == "A" ? "CHECKED" : "" ?>>
<input type="radio" name="type" value="P" <?=$info["type"] == "P" ? "CHECKED" : "" ?>>판넬
<input type="text" name="typeValue" style="margin-left:50px;" value="<?=$info["typeValue"]?>"/>
</td>
</tr>
<tr>
<!-- 렌트2 -->
<th style="height:25px;">내장</th>
<td class="center">
<input type="text" name="rent_2" class="wm" value="<?=$info["rent_2"]?>" />
<input type="text" name="internalLength" class="wm" value="<?=$info["internalLength"]?>" />
</td>
<!-- 기타 -->
<th style="height:25px;">내고</th>
<td class="center">
<input type="text" name="etc" class="wm" value="<?=$info["etc"]?>" />
<input type="text" name="internalHeight" class="wm" value="<?=$info["internalHeight"]?>" />
</td>
<!-- 월세입금일-->
<th style="height:25px;">내폭</th>
<td class="center" colspan='2'>
<select name="monthly_rent_date" class="wm">
<? for($i=1; $i<=31; $i++){ ?>
<option value='<?=$i?>' <?=$info["monthly_rent_date"] == $i ? "SELECTED" : ""?>><?=$i?></option>
<? } ?>
</select>
<input type="text" name="internalWidth" class="wm" value="<?=$info["internalWidth"]?>" />
</td>
......@@ -278,50 +264,50 @@
<!-- 전기 검침일-->
<th style="height:25px;">AL코일</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">GRP
<input type="radio" name="chk_info" value="CSS">AL
<input type="text" style='margin-left:50px;'/>
<input type="radio" name="alCoil" value="G" <?=$info["alCoil"] == "G" ? "CHECKED" : "" ?>>GRP
<input type="radio" name="alCoil" value="A" <?=$info["alCoil"] == "A" ? "CHECKED" : "" ?>>AL
<input type="text" name="alCoilValue" style='margin-left:50px;' value="<?=$info["alCoilValue"]?>"/>
</td>
</tr>
<tr>
<th style="height:25px;">내부바닥</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">체크
<input type="radio" name="chk_info" value="CSS">민판
<input type="text" style='width:5%;'/> T
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="floor" value="C" <?=$info["floor"] == "C" ? "CHECKED" : "" ?>>체크
<input type="radio" name="floor" value="P" <?=$info["floor"] == "P" ? "CHECKED" : "" ?>>민판
<input type="text" name="floorValueT" style='width:5%;' value="<?=$info["floorValueT"]?>"/> T
<input type="text" name="floorValue" style='margin-left:45px;' value="<?=$info["floorValueText"]?>" />
</td>
</tr>
<tr>
<th style="height:25px;">누름천막</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">없음
<input type="radio" name="chk_info" value="CSS">고정식
<input type="radio" name="chk_info" value="CSS">이동식
<input type="radio" name="tent" value="0" <?=$info["tent"] == "0" ? "CHECKED" : "" ?>>없음
<input type="radio" name="tent" value="1" <?=$info["tent"] == "1" ? "CHECKED" : "" ?>>고정식
<input type="radio" name="tent" value="2" <?=$info["tent"] == "2" ? "CHECKED" : "" ?>>이동식
</td>
</tr>
<tr>
<th style="height:25px;">내부옆판</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">있음
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="sideBoard" value="1" <?=$info["sideBoard"] == "1" ? "CHECKED" : "" ?>>있음
<input type="radio" name="sideBoard" value="0" <?=$info["sideBoard"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="sideBoardValue" style='margin-left:45px;' value="<?=$info["sideBoardValue"]?>"/>
</td>
</tr>
<tr>
<th style="height:25px;">바람막이</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">있음
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="windStopper" value="1" <?=$info["windStopper"] == "1" ? "CHECKED" : "" ?>>있음
<input type="radio" name="windStopper" value="0" <?=$info["windStopper"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="windStopperValue" style='margin-left:45px;' value="<?=$info["windStopperValue"]?>"/>
</td>
</tr>
<tr>
<th style="height:25px;">냉동기</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">있음
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="freezer" value="1" <?=$info["freezer"] == "1" ? "CHECKED" : "" ?>>있음
<input type="radio" name="freezer" value="0" <?=$info["freezer"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="freezerValue" style='margin-left:45px;' value="<?=$info["freezerValue"]?>"/>
</td>
</tr>
<!-- 게이트 -->
......@@ -329,84 +315,84 @@
<th style="height:25px;" rowspan='2'>게이트</th>
<td class="center" colspan='7'>
-형태
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>구형
<input type="radio" name="chk_info" value="CSS">신형
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="gateType" value="0" style='margin-left:50px;' <?=$info["gateType"] == "0" ? "CHECKED" : "" ?>>구형
<input type="radio" name="gateType" value="1" <?=$info["gateType"] == "1" ? "CHECKED" : "" ?>>신형
<input type="text" name="gateValue" style='margin-left:45px;' value="<?=$info["gateValue"]?>" />
</td>
</tr>
<tr>
<td class="center" colspan='7'>
-사이즈
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>600
<input type="radio" name="chk_info" value="CSS">700
<input type="radio" name="chk_info" value="CSS">800
<input type="radio" name="gateSize" value="0" style='margin-left:50px;' <?=$info["gateSize"] == "0" ? "CHECKED" : "" ?>>600
<input type="radio" name="gateSize" value="1" <?=$info["gateSize"] == "1" ? "CHECKED" : "" ?>>700
<input type="radio" name="gateSize" value="2" <?=$info["gateSize"] == "2" ? "CHECKED" : "" ?>>800
</td>
</tr>
<tr>
<th style="height:25px;">L&LOAD</th>
<td class="center" colspan='3'>
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>SUS
<input type="radio" name="chk_info" value="CSS">일반
<input type="radio" name="load" value="S" style='margin-left:50px;' <?=$info["load"] == "S" ? "CHECKED" : "" ?>>SUS
<input type="radio" name="load" value="N" <?=$info["load"] == "N" ? "CHECKED" : "" ?>>일반
</td>
<th style="height:25px;">앞/뒤틀 형식</th>
<td class="center" colspan='3'>
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>SUS
<input type="radio" name="chk_info" value="CSS">일반
<input type="radio" name="frontBack" value="S" style='margin-left:50px;' <?=$info["frontBack"] == "S" ? "CHECKED" : "" ?>>SUS
<input type="radio" name="frontBack" value="N" <?=$info["frontBack"] == "N" ? "CHECKED" : "" ?>>일반
</td>
</tr>
<tr>
<th style="height:25px;" rowspan='2'>E트랙</th>
<td class="center" colspan='7'>
-게이트
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>있음
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="eTrackGate" value="1" style='margin-left:50px;' <?=$info["eTrackGate"] == "1" ? "CHECKED" : "" ?>>있음
<input type="radio" name="eTrackGate" value="0" <?=$info["eTrackGate"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="eTrackValue" style='margin-left:45px;' value="<?=$info["eTrackValue"]?>"/>
</td>
</tr>
<tr>
<td class="center" colspan='7'>
-날개
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>있을
<input type="radio" name="chk_info" value="CSS">없음
<input type="radio" name="eTrackWing" value="1" style='margin-left:50px;' <?=$info["eTrackWing"] == "1" ? "CHECKED" : "" ?>>있을
<input type="radio" name="eTrackWing" value="0" <?=$info["eTrackWing"] == "0" ? "CHECKED" : "" ?>>없음
</td>
</tr>
<tr>
<th style="height:25px;">공구통</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">
<input type="radio" name="chk_info" value="CSS">
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="toolBucket" value="1" <?=$info["toolBucket"] == "1" ? "CHECKED" : "" ?>>
<input type="radio" name="toolBucket" value="2" <?=$info["toolBucket"] == "2" ? "CHECKED" : "" ?>>
<input type="radio" name="toolBucket" value="0" <?=$info["toolBucket"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="toolBucketValue" style='margin-left:45px;' value="<?=$info["toolBucketValue"]?>"/>
</td>
</tr>
<tr>
<th style="height:25px;">범퍼발판</th>
<td class="center" colspan='3'>
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>1개
<input type="radio" name="chk_info" value="CSS">2개
<input type="radio" name="bumperFootHold" value="1" style='margin-left:50px;' <?=$info["bumperFootHold"] == "1" ? "CHECKED" : "" ?>>1개
<input type="radio" name="bumperFootHold" value="2" <?=$info["bumperFootHold"] == "2" ? "CHECKED" : "" ?>>2개
</td>
<th style="height:25px;">윙보호장치</th>
<td class="center" colspan='3'>
<input type="radio" name="chk_info" value="HTML" style='margin-left:50px;'>1개
<input type="radio" name="chk_info" value="CSS">2개
<input type="radio" name="wingProtector" value="1" style='margin-left:50px;' <?=$info["wingProtector"] == "1" ? "CHECKED" : "" ?>>1개
<input type="radio" name="wingProtector" value="2" <?=$info["wingProtector"] == "2" ? "CHECKED" : "" ?>>2개
</td>
</tr>
<tr>
<th style="height:25px;">축(장착여부)</th>
<td class="center" colspan='7'>
<input type="radio" name="chk_info" value="HTML">있음
<input type="radio" name="chk_info" value="CSS">없음
<input type="text" style='margin-left:45px;'/>
<input type="radio" name="axis" value="1" <?=$info["axis"] == "1" ? "CHECKED" : "" ?>>있음
<input type="radio" name="axis" value="0" <?=$info["axis"] == "0" ? "CHECKED" : "" ?>>없음
<input type="text" name="axisValue" style='margin-left:45px;' value="<?=$info["axisValue"]?>"/>
</td>
</tr>
<tr>
<th style="height:25px;">견적금액</th>
<td class="center" colspan='7'>
<input type="text" />
<input type="text" name="balance" value="<?=$info["balance"]?>" />
</td>
</tr>
</table>
......@@ -426,13 +412,44 @@
</td>
</tr>
<?if($info['specialAddition1'] != ""){?>
<tr no="<?=$addCount?>" class='dynamicRow'><td></td><td><input type='text' class='added' readonly value="<?=$info['specialAddition1']?>" />
<span class='button bigrounded gray adddel' no="<?=$addCount?>" style='color:white; width:70px'>&nbsp;X&nbsp;</span></td></tr>
<?
$addCount++;
}?>
<?if($info['specialAddition2'] != ""){?>
<tr no="<?=$addCount?>" class='dynamicRow'><td></td><td><input type='text' class='added' readonly value="<?=$info['specialAddition2']?>" />
<span class='button bigrounded gray adddel' no="<?=$addCount?>" style='color:white; width:70px'>&nbsp;X&nbsp;</span></td></tr>
<?
$addCount++;
}?>
<?if($info['specialAddition3'] != ""){?>
<tr no="<?=$addCount?>" class='dynamicRow'><td></td><td><input type='text' class='added' readonly value="<?=$info['specialAddition3']?>" />
<span class='button bigrounded gray adddel' no="<?=$addCount?>" style='color:white; width:70px'>&nbsp;X&nbsp;</span></td></tr>
<?
$addCount++;
}?>
<?if($info['specialAddition4'] != ""){?>
<tr no="<?=$addCount?>" class='dynamicRow'><td></td><td><input type='text' class='added' readonly value="<?=$info['specialAddition4']?>" />
<span class='button bigrounded gray adddel' no="<?=$addCount?>" style='color:white; width:70px'>&nbsp;X&nbsp;</span></td></tr>
<?
$addCount++;
}?>
<?if($info['specialAddition5'] != ""){?>
<tr no="<?=$addCount?>" class='dynamicRow'><td></td><td><input type='text' class='added' readonly value="<?=$info['specialAddition5']?>" />
<span class='button bigrounded gray adddel' no="<?=$addCount?>" style='color:white; width:70px'>&nbsp;X&nbsp;</span></td></tr>
<?
$addCount++;
}?>
<script>addCounter = <?=$addCount != "" ? $addCount : 0?>;</script>
</table>
</form>
<div class="btngroupcenter">
<span class="button bigrounded blue test btnleft_y"></span>
<span class="button bigrounded blue jCancel btnleft_y">목록으로 </span>
<span class="button bigrounded blue jClose btnleft_y">닫기 </span>
<span class="button bigrounded blue jMod btnright_y" >저장</span>
</div>
......
......@@ -6,11 +6,21 @@
//$list = $obj->getListOfAdminPush() ;
$vnum = $obj->virtualNum ;
$rurl = pack("H*", $_REQUEST["rurl"]) ;
?>
<script>
var _rurl = "<?=$rurl?>";
$(document).ready(function(){
$.ajax({
url : "/setting/agree.txt",
dataType : "html",
success : function(data){
$("#content").val(data);
}});
//=====프레입웤 변수들==================================================================================//
var FORM_TARGET_CLS_NM = "DIV#Contents" ; // 폼을 동적 wrap 할 타겟 ID이름
var FORM_NAME = "nf" ; // 폼이름
......@@ -42,224 +52,48 @@
jForm.submit() ;
});
$(".jSearchGroup").click2(function(){
var title = "그룹 검색";
$('#jDialogArea').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jSearchPrivate").click2(function(){
var title = "회원 검색";
$('#jDialogAreaP').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jTargetSearchBtn").click2(function(){
var search_text = $("#jTargetSearchText").val();
var ajax_url = "/admin/entity/entityGroupSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
$("#type").change(function(){
if($("#type").val() == "PR"){
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultArea").html(data);
setSearchAreaEventHandler();
url : "/setting/privacy.txt",
dataType : "html",
success : function(data){
$("#content").val(data);
}
});
});
$(".jTargetSearchPBtn").click2(function(){
var search_text = $("#jTargetSearchTextP").val();
var ajax_url = "/admin/entity/entityPrivateSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
else{
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultAreaP").html(data);
setSearchAreaEventHandler();
url : "/setting/agree.txt",
dataType : "html",
success : function(data){
$("#content").val(data);
}
});
});
$("#push_target_type").change(function(){
resetTargetData();
if($(this).val() == "1")
{
$("#jGroupArea").hide();
$("#jPrivateArea").hide();
}
else if($(this).val() == "2")
{
$("#jGroupArea").show();
$("#jPrivateArea").hide();
}else{
$("#jGroupArea").hide();
$("#jPrivateArea").show();
}
});
$(".jSave").click2(function(){
var push_msg = $("#push_msg").val();
var push_target_type = $("#push_target_type").val();
var group_no = $("#group_no").val();
if(push_target_type == "2" && group_no == "")
{
alert("그룹을 선택해주세요.");
return false;
if(confirm("내용을 저장하시겠습니까?")){
$("#jData").ajaxSubmit({
url:"/action_front.php?cmd=AdminPush.saveAgreement",
type : "post",
forceSync : true,
dataType : "json",
success : function(data){
alert(data.returnMessage);
location.href = _rurl;
}
if(push_msg == "")
{
alert("푸시 내용을 입력해주세요.");
return false;
});
}
$.ajax({
url : "/action_front.php?cmd=AdminPush.sendAdminPush",
async : true,
cache : false,
dataType : "json",
data : {
"push_msg" : push_msg,
"push_target_type" : push_target_type,
"group_no" : group_no
}, success : function(data) {
alert(data.returnMessage) ;
if(data.returnCode == 1) {
location.reload();
}
}
});
});
}) ;
function setSearchAreaEventHandler()
{
$(".jTargetNo").unbind("change");
$(".jTargetNo").change(function(){
$(".jTargetNo").prop("checked", false);
$(this).prop("checked", true);
});
}
function resetTargetData()
{
$("#group_no").val("");
$("#group_name").val("");
}
......@@ -271,28 +105,31 @@
<h1>약관 관리</h1>
<h2>푸시관리 > <span>약관관리</span></h2>
<div class="data">
<form id="jData" method="post" enctype="multipart/form-data">
<table class="datav" style="width:100%;">
<colgroup>
<col width="20%" />
<col width="80%" />
</colgroup>
<tr>
<th style="height:25px;">제목</th>
<td class="l">
<input type="text" style="width:95%"/>
<th style="height:25px;">약관 종류</th>
<td>
<select id="type" name="type">
<option value="AG">이용약관</option>
<option value="PR">개인정보처리방침</option>
</select>
</td>
</tr>
<tr>
<th style="height:25px;">내용</th>
<td class="l">
<textarea rows="25" style="width:95%;" id="push_msg"></textarea>
<textarea rows="25" style="width:95%;" id="content" name="content"><?=$info?></textarea>
</td>
</tr>
</table>
</form>
<div class="btngroupcenter" style="width:100%;">
<span class="button bigrounded blue jSave" >전송</span>
<span class="button bigrounded blue jSave" >등록</span>
</div>
......
......@@ -23,189 +23,12 @@
var jForm = $(FORM_TARGET_CLS_NM).mf({ "name" : FORM_NAME , "method" : FORM_METHOD , "action" : FORM_ACTION , "useFile" : FORM_USE_FILE }) ;
// 페이징
$(".jPage").click2(function(){
jForm.ci() ;
jForm.mi("page",$(this).attr("page")) ;
jForm.submit() ;
}) ;
$(".jAutoSearch").change(function(){
jForm.ci() ;
jForm.submit() ;
});
$(".jSearch").click2(function(){
jForm.ci() ;
jForm.submit() ;
});
$(".jSearchGroup").click2(function(){
var title = "그룹 검색";
$('#jDialogArea').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jSearchPrivate").click2(function(){
var title = "회원 검색";
$('#jDialogAreaP').dialog({
modal : true,
title : title,
open : function(event, ui) { $(".ui-dialog-titlebar-close").hide(); },
width : 400,
height : 500,
resizable : false,
buttons: [
{
text: "확인",
click: function() {
var group_no = $(".jTargetNo:checked").val();
var group_name = $(".jTargetNo:checked").parents("tr").find(".jTargetName").attr("data");
if(group_no == undefined)
{
alert("대상을 선택해주세요.");
return false;
}
else
{
$("#group_no").val(group_no);
$("#group_name").val(group_name);
$( this ).dialog( "close" );
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
}
}
},
{
text: "닫기",
click: function() {
$("#jTargetSearchText").val("");
$("#jSearchResultArea").empty();
$( this ).dialog( "close" );
}
}
],
closeOnEscape: false
});
});
$(".jTargetSearchBtn").click2(function(){
var search_text = $("#jTargetSearchText").val();
var ajax_url = "/admin/entity/entityGroupSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultArea").html(data);
setSearchAreaEventHandler();
}
});
});
$(".jTargetSearchPBtn").click2(function(){
var search_text = $("#jTargetSearchTextP").val();
var ajax_url = "/admin/entity/entityPrivateSearch.php";
if(search_text == "")
{
alert("검색어를 입력해주세요.");
return false;
}
$.ajax({
url : ajax_url,
data : {
"search_text" : search_text
},
dataType:"html",
success : function(data)
{
$("#jSearchResultAreaP").html(data);
setSearchAreaEventHandler();
}
});
});
$("#push_target_type").change(function(){
resetTargetData();
if($(this).val() == "1")
{
$("#jGroupArea").hide();
$("#jPrivateArea").hide();
}
else if($(this).val() == "2")
{
$("#jGroupArea").show();
$("#jPrivateArea").hide();
}else{
$("#jGroupArea").hide();
$("#jPrivateArea").show();
}
});
$(".jSave").click2(function(){
var push_msg = $("#push_msg").val();
var push_target_type = $("#push_target_type").val();
......@@ -230,8 +53,7 @@
dataType : "json",
data : {
"push_msg" : push_msg,
"push_target_type" : push_target_type,
"group_no" : group_no
"push_target_type" : push_target_type
}, success : function(data) {
alert(data.returnMessage) ;
if(data.returnCode == 1) {
......@@ -245,24 +67,6 @@
});
}) ;
function setSearchAreaEventHandler()
{
$(".jTargetNo").unbind("change");
$(".jTargetNo").change(function(){
$(".jTargetNo").prop("checked", false);
$(this).prop("checked", true);
});
}
function resetTargetData()
{
$("#group_no").val("");
$("#group_name").val("");
}
</script>
......@@ -281,32 +85,14 @@
<tr>
<th style="height:25px;">제목</th>
<td class="l">
<input type="text" style="width:95%"/>
</td>
</tr>
<tr id="jGroupArea" style="display:none;">
<th style="height:25px;">그룹</th>
<td class="l">
<input type="hidden" id="group_no" />
<input type="text" disabled="disabled" id="group_name"/>
<input type="button" class="button searchsmall white jSearchGroup" value="그룹검색" />
</td>
</tr>
<tr id="jPrivateArea" style="display:none;">
<th style="height:25px;">개인</th>
<td class="l">
<input type="hidden" id="group_no" />
<input type="text" disabled="disabled" id="group_name"/>
<input type="button" class="button searchsmall white jSearchPrivate" value="회원검색" />
<input type="text" name="title" style="width:95%"/>
</td>
</tr>
<tr>
<th style="height:25px;">내용</th>
<td class="l">
<textarea rows="3" style="width:95%;" id="push_msg"></textarea>
<textarea rows="5" name="pushMessage" style="width:95%;" id="pushMessage"></textarea>
</td>
</tr>
</table>
......@@ -315,53 +101,7 @@
<span class="button bigrounded blue jSave" >전송</span>
</div>
<h3>푸시 이력</h3>
<table class="datacList">
<thead>
<tr>
<th class="no" width="5%">No</th>
<th width="65%">메세지</th>
<th width="10%">전송시간</th>
</tr>
</thead>
<tbody><!-- 10줄 리스트// 마지막 tr에 class="last" 넣어주세요 -->
<? for($i=0; $i<sizeof($list); $i++){ ?>
<tr class="<?=(sizeof($list)-1 == $i) ? "last" : "datacLists"?>">
<td class="no center">
<?=$vnum--?>
</td>
<td class="center">
<?
if($list[$i]["push_target_type"] == "1")
echo "전체";
else if($list[$i]["push_target_type"] == "2")
echo "그룹";
else if($list[$i]["push_target_type"] == "3")
echo "개인";
?>
</td>
<td class="center">
<?=$list[$i]["push_msg"]?>
</td>
<td class="center">
<?=$list[$i]["push_count"]?>
</td>
<td class="center">
<?=$list[$i]["push_dt"]?>
</td>
</tr>
<? } ?>
<?if(sizeof($list) == 0){?>
<tr class="last">
<td class="no center" colspan="11">No Data</td>
</tr>
<?}?>
</tbody>
</table>
<!-- Pagination -->
<? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/pageNavigation.php" ?>
<!--//Pagination -->
</div>
......
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBase.php" ;?>
<?
if (! class_exists("AdminProductionSpec")){
class AdminProductionSpec extends AdminBase{
function __construct($req)
{
parent::__construct($req);
}
function getListOfProductionSpec(){
$searchType=$this->req["searchType"];
$searchText=$this->req["searchText"];
$dateFormer=$this->req["dateFormer"];
$dateLatter=$this->req["dateLatter"];
$where=" WHERE PS.status=1";
if($searchType=="CN")
$where.=" AND companyName LIKE '%{$searchText}%'";
else if($searchType=="PN")
$where.=" AND productName LIKE '%{$searchText}%'";
else if($searchType=="MN")
$where.=" AND userName LIKE '%{$searchText}%'";
else if($searchType=="")
$where.=" AND (companyName LIKE '%{$searchText}%' OR productName LIKE '%{$searchText}%' OR userName LIKE '%{$searchText}%')";
if($dateFormer != "")
$where.=" AND DATE_FORMAT(PS.regDate, '%Y%m%d') >= DATE_FORMAT('{$dateFormer}', '%Y%m%d')";
if($dateLatter != "")
$where.=" AND DATE_FORMAT(PS.regDate, '%Y%m%d') <= DATE_FORMAT('{$dateLatter}', '%Y%m%d')";
$sql="
SELECT COUNT(*) AS rn
FROM tblProductionSpec PS
JOIN tblUser U ON PS.userFk=U.userNo
{$where}
ORDER BY PS.regDate DESC
";
$this->initPage();
$this->rownum=$this->getValue($sql, 'rn');
$this->setPage($this->rownum);
$limit=" LIMIT {$this->startNum}, {$this->endNum} ;";
$sql="
SELECT productionNo, DATE_FORMAT(PS.requestDate, '%Y-%m-%d') AS requestDate, PS.companyName, PS.productName, U.userName
FROM tblProductionSpec PS
JOIN tblUser U ON PS.userFk=U.userNo
{$where}
ORDER BY PS.productionNo DESC
{$limit}
";
$result=$this->getArray($sql);
//echo json_encode($result);
return $result;
}
function getInfoOfProductionSpec(){
$productionNo=$this->req["no"];
$sql="
SELECT *
FROM tblProductionSpec
WHERE productionNo='{$productionNo}'
";
$result=$this->getRow($sql);
//echo json_encode($result);
return $result;
}
function getListOfManager(){
$sql="
SELECT userNo, userName
FROM tblUser
WHERE userType=2 AND status=1
ORDER BY userNo ASC
";
$result=$this->getArray($sql);
return $result;
}
function saveProductionSpec(){
$productionNo=$this->req["productionNo"];
$managerFk=$this->req["managerFk"];
$requestDate=$this->req["requestDate"];
$customerName=$this->req["customerName"];
$companyName=$this->req["companyName"];
$vehicleTON=$this->req["vehicleTON"];
$vehicleText=$this->req["vehicleText"];
$vehicleType=$this->req["vehicleType"];
$productName=$this->req["productName"];
$telephone=$this->req["telephone1"].$this->req["telephone2"].$this->req["telephone3"];
$type=$this->req["type"];
$typeValue=$this->req["typeValue"];
$internalLength=$this->req["internalLength"];
$internalHeight=$this->req["internalHeight"];
$internalWidth=$this->req["internalWidth"];
$alCoil=$this->req["alCoil"];
$alCoilValue=$this->req["alCoilValue"];
$floor=$this->req["floor"];
$floorValueT=$this->req["floorValueT"];
$floorValueText=$this->req["floorValueText"];
$tent=$this->req["tent"];
$sideBoard=$this->req["sideBoard"];
$sideBoardValue=$this->req["sideBoardValue"];
$windStopper=$this->req["windStopper"];
$windStopperValue=$this->req["windStopperValue"];
$freezer=$this->req["freezer"];
$freezerValue=$this->req["freezerValue"];
$gateType=$this->req["gateType"];
$gateSize=$this->req["gateSize"];
$gateValue=$this->req["gateValue"];
$load=$this->req["load"];
$frontBack=$this->req["frontBack"];
$eTrackGate=$this->req["eTrackGate"];
$eTrackWing=$this->req["eTrackWing"];
$eTrackValue=$this->req["eTrackValue"];
$toolBucket=$this->req["toolBucket"];
$toolBucketValue=$this->req["toolBucketValue"];
$bumperFootHold=$this->req["bumperFootHold"];
$wingProtector=$this->req["wingProtector"];
$axis=$this->req["axis"];
$axisValue=$this->req["axisValue"];
$balance=$this->req["balance"];
$specialAddition1=$this->req["specialAddition1"];
$specialAddition2=$this->req["specialAddition2"];
$specialAddition3=$this->req["specialAddition3"];
$specialAddition4=$this->req["specialAddition4"];
$specialAddition5=$this->req["specialAddition5"];
$sql = "
UPDATE `tblProductionSpec`
SET
`userFk` = '{$managerFk}',
`requestDate` = '{$requestDate}',
`customerName` = '{$customerName}',
`companyName` = '{$companyName}',
`vehicleTON` = '{$vehicleTON}',
`vehicleText` = '{$vehicleText}',
`vehicleType` = '{$vehicleType}',
`productName` = '{$productName}',
`telephone` = '{$telephone}',
`type` = '{$type}',
`typeValue` = '{$typeValue}',
`internalLength` = '{$internalLength}',
`internalHeight` = '{$internalHeight}',
`internalWidth` = '{$internalWidth}',
`alCoil` = '{$alCoil}',
`alCoilValue` = '{$alCoilValue}',
`floor` = '{$floor}',
`floorValueT` = '{$floorValueT}',
`floorValueText` = '{$floorValueText}',
`tent` = '{$tent}',
`sideBoard` = '{$sideBoard}',
`sideBoardValue` = '{$sideBoardValue}',
`windStopper` = '{$windStopper}',
`windStopperValue` = '{$windStopperValue}',
`freezer` = '{$freezer}',
`freezerValue` = '{$freezerValue}',
`gateType` = '{$gateType}',
`gateSize` = '{$gateSize}',
`gateValue` = '{$gateValue}',
`load` = '{$load}',
`frontBack` = '{$frontBack}',
`eTrackGate` = '{$eTrackGate}',
`eTrackWing` = '{$eTrackWing}',
`eTrackValue` = '{$eTrackValue}',
`toolBucket` = '{$toolBucket}',
`toolBucketValue` = '{$toolBucketValue}',
`bumperFootHold` = '{$bumperFootHold}',
`wingProtector` = '{$wingProtector}',
`axis` = '{$axis}',
`axisValue` = '{$axisValue}',
`balance` = '{$balance}',
`specialAddition1` = '{$specialAddition1}',
`specialAddition2` = '{$specialAddition2}',
`specialAddition3` = '{$specialAddition3}',
`specialAddition4` = '{$specialAddition4}',
`specialAddition5` = '{$specialAddition5}'
WHERE `productionNo` = '{$productionNo}';
";
$this->update($sql);
return $this->makeResultJson(1, "저장되었습니다");
}
function deleteProductionSpec(){
$noArr = $this->req["no"];
$noStr = implode(',', $noArr);
$sql = "
UPDATE tblProductionSpec
SET status = 0
WHERE `productionNo` IN({$noStr})
";
$this->update($sql);
}
}
}
?>
\ No newline at end of file
......@@ -123,55 +123,28 @@ if(!class_exists("AdminPush")){
function sendAdminPush()
{
$push_msg = $this->req["push_msg"];
$group_no = $this->req["group_no"];
$push_target_type = $this->req["push_target_type"];
$push_msg = $this->req["pushMessage"];
$push_code = $this->getBulkPushCode();
$push_succeed=0;
if($push_target_type == "1"){
$sql = "
INSERT INTO tbl_push_target_bulk(push_code, registration_key, device_type_id, app_type)
INSERT INTO tbl_push_target_bulk(push_code, registration_key, device_type_id)
(
SELECT '{$push_code}', registration_key, device_type_id, app_type
FROM tbl_user U
WHERE U.status = 'Y' AND U.registration_key != '' AND is_push = 1
SELECT '{$push_code}', registrationKey, deviceTypeID
FROM tblUser U
WHERE U.status = 1 AND U.registrationKey != '' AND push = 1
)
";
$push_count = $this->update($sql);
$sql="SELECT count(*) as rn
FROM tbl_user U
WHERE U.status = 'Y' AND U.registration_key != '' AND is_push = 1";
$result=$this->getRow($sql);
$push_succeed = $result["rn"];
}
else
{
$sql = "
INSERT INTO tbl_push_target_bulk(push_code, registration_key, device_type_id, app_type)
(
SELECT '{$push_code}', registration_key, device_type_id, app_type
FROM tbl_user U
WHERE U.group_fk = '{$group_no}' AND U.status = 'Y' AND U.registration_key != '' AND is_push = 1
)
";
$push_count = $this->update($sql);
$sql="SELECT count(*) as rn
FROM tbl_user U
WHERE U.status = 'Y' AND U.registration_key != '' AND is_push = 1";
FROM tblUser U
WHERE U.status = 1 AND U.registrationKey != '' AND push = 1";
$result=$this->getRow($sql);
$push_succeed = $result["rn"];
}
$sql = "
INSERT INTO tbl_push_log(push_target_type, group_fk, push_msg, push_count, push_dt)
VALUES('{$push_target_type}', '{$group_no}', '{$push_msg}', '{$push_succeed}', NOW())
";
$this->update($sql);
$push_msg = $this->req["push_msg"];
$group_no = $this->req["group_no"];
$push_target_type = $this->req["push_target_type"];
$push_msg = $this->req["pushMessage"];
// 푸시 전송
$params = Array(
......@@ -224,6 +197,29 @@ if(!class_exists("AdminPush")){
return $result;
}
function saveAgreement(){
$type=$this->req["type"];
$content=$this->req["content"];
if($type == "AG"){
$filePath = $this->agreeInfoPath;
$files = fopen($filePath, "w");
fwrite($files, $content);
fclose($files);
return $this->makeResultJson(1, "약관이 저장되었습니다");
}
else if($type == "PR"){
$filePath = $this->privacyInfoPath;
$files = fopen($filePath, "w");
fwrite($files, $content);
fclose($files);
return $this->makeResultJson(1, "개인정보처리방침이 저장되었습니다");
}
}
} // class end
}
?>
\ No newline at end of file
......
......@@ -316,6 +316,283 @@ if (! class_exists("AdminBoard")){
$this->update($sql);
}
function getListOfCS(){
$sql="
SELECT COUNT(*) AS rn
FROM tblCustomerService CS
JOIN tblUser U ON CS.userFk=U.userNo
WHERE CS.status=1 AND U.status=1
";
$this->initPage();
$this->rownum=$this->getValue($sql, 'rn');
$this->setPage($this->rownum);
$limit=" LIMIT {$this->startNum}, {$this->endNum} ;";
$sql="
SELECT CS.*, U.userName
FROM tblCustomerService CS
JOIN tblUser U ON CS.userFk=U.userNo
WHERE CS.status=1 AND U.status=1
ORDER BY CS.regDate DESC
{$limit}
";
$result=$this->getArray($sql);
return $result;
}
function getInfoOfCS(){
$csNo=$this->req["no"];
$sql="
SELECT CS.*, U.userName
FROM tblCustomerService CS
JOIN tblUser U ON CS.userFk=U.userNo
WHERE CS.csNo='{$csNo}'
";
$result=$this->getRow($sql);
return $result;
}
function saveCS(){
$targetFk=$this->req["csNo"];
$content=$this->req["content"];
$sql="
INSERT INTO tblComment(userFk, targetFk, commentGroup, gOrder, depth, content, commentType, status, regDate)
VALUES
(
0,
'{$targetFk}',
0,
1,
1,
'{$content}',
'CS',
1,
NOW()
)
";
$this->update($sql);
$currentNo=$this->mysql_insert_id();
$sql="
UPDATE tblComment
SET commentGroup='{$currentNo}'
WHERE commentNo='{$currentNo}'
";
$this->update($sql);
return $this->makeResultJson("1", "저장되었습니다");
}
function deleteCS(){
$noArr = $this->req["no"];
$noStr = implode(',', $noArr);
$sql = "
UPDATE tblCustomerService
SET status = 0
WHERE `csNo` IN({$noStr})
";
$this->update($sql);
}
function getListOfCSComment(){
$no=$this->req["no"];
if($no != ""){
$sql="
SELECT C.*, IFNULL(U.userName, '관리자') AS userName
FROM tblComment C
LEFT JOIN tblUser U ON C.userFk=U.userNo
WHERE C.commentType='CS' AND C.targetFk='{$no}' AND C.status=1
ORDER BY commentGroup DESC, gOrder ASC
";
$result=$this->getArray($sql);
//echo json_encode($result);
return $result;
}
}
function getListOfProductionPortrait(){
$sql="
SELECT COUNT(*) AS rn
FROM tblProductionPortrait
WHERE status=1
";
$this->initPage();
$this->rownum=$this->getValue($sql, 'rn');
$this->setPage($this->rownum);
$limit=" LIMIT {$this->startNum}, {$this->endNum} ;";
$sql="
SELECT ppNo, title, regDate
FROM tblProductionPortrait
WHERE status=1
ORDER BY ppNo DESC
{$limit}
";
$result=$this->getArray($sql);
return $result;
}
function getInfoOfProductionPortrait(){
$ppNo=$this->req["no"];
$sql="
SELECT *
FROM tblProductionPortrait
WHERE ppNo='{$ppNo}'
";
$result=$this->getRow($sql);
return $result;
}
function getInfoOfProductionPortraitForJson(){
$ppNo=$this->req["no"];
$sql="
SELECT *
FROM tblProductionPortrait
WHERE ppNo='{$ppNo}'
";
$result=$this->getRow($sql);
return json_encode($result);
}
function saveProductionPortrait(){
$ppNo=$this->req["no"];
$title=$this->req["title"];
$content1=$this->req["content1"];
$content2=$this->req["content2"];
$content3=$this->req["content3"];
$content4=$this->req["content4"];
$content5=$this->req["content5"];
$content6=$this->req["content6"];
$content7=$this->req["content7"];
$content8=$this->req["content8"];
$content9=$this->req["content9"];
$content10=$this->req["content10"];
$imgResult = $this->inFn_Common_fileSave($_FILES);
$imgPathPP1 = $imgResult["img01"]["saveURL"] != "" ? $imgResult["img01"]["saveURL"] : $this->req["imgPathPP1"];
$imgPathPP2 = $imgResult["img02"]["saveURL"] != "" ? $imgResult["img02"]["saveURL"] : $this->req["imgPathPP2"];
$imgPathPP3 = $imgResult["img03"]["saveURL"] != "" ? $imgResult["img03"]["saveURL"] : $this->req["imgPathPP3"];
$imgPathPP4 = $imgResult["img04"]["saveURL"] != "" ? $imgResult["img04"]["saveURL"] : $this->req["imgPathPP4"];
$imgPathPP5 = $imgResult["img05"]["saveURL"] != "" ? $imgResult["img05"]["saveURL"] : $this->req["imgPathPP5"];
$imgPathPP6 = $imgResult["img06"]["saveURL"] != "" ? $imgResult["img06"]["saveURL"] : $this->req["imgPathPP6"];
$imgPathPP7 = $imgResult["img07"]["saveURL"] != "" ? $imgResult["img07"]["saveURL"] : $this->req["imgPathPP7"];
$imgPathPP8 = $imgResult["img08"]["saveURL"] != "" ? $imgResult["img08"]["saveURL"] : $this->req["imgPathPP8"];
$imgPathPP9 = $imgResult["img09"]["saveURL"] != "" ? $imgResult["img09"]["saveURL"] : $this->req["imgPathPP9"];
$imgPathPP10 = $imgResult["img10"]["saveURL"] != "" ? $imgResult["img10"]["saveURL"] : $this->req["imgPathPP10"];
if($ppNo==""){
$sql="
INSERT INTO `tblProductionPortrait`
(
`title`,
`content1`,
`content2`,
`content3`,
`content4`,
`content5`,
`content6`,
`content7`,
`content8`,
`content9`,
`content10`,
`imgPathPP1`,
`imgPathPP2`,
`imgPathPP3`,
`imgPathPP4`,
`imgPathPP5`,
`imgPathPP6`,
`imgPathPP7`,
`imgPathPP8`,
`imgPathPP9`,
`imgPathPP10`,
`status`,
`regDate`
)
VALUES
(
'{$title}',
'{$content1}',
'{$content2}',
'{$content3}',
'{$content4}',
'{$content5}',
'{$content6}',
'{$content7}',
'{$content8}',
'{$content9}',
'{$content10}',
'{$imgPathPP1}',
'{$imgPathPP2}',
'{$imgPathPP3}',
'{$imgPathPP4}',
'{$imgPathPP5}',
'{$imgPathPP6}',
'{$imgPathPP7}',
'{$imgPathPP8}',
'{$imgPathPP9}',
'{$imgPathPP10}',
1,
NOW()
);
";
$this->update($sql);
return $this->makeResultJson(1, "등록되었습니다");
}
else{
$sql="
UPDATE `tblProductionPortrait`
SET
`title` = '{$title}',
`content1` = '{$content1}',
`content2` = '{$content2}',
`content3` = '{$content3}',
`content4` = '{$content4}',
`content5` = '{$content5}',
`content6` = '{$content6}',
`content7` = '{$content7}',
`content8` = '{$content8}',
`content9` = '{$content9}',
`content10` = '{$content10}',
`imgPathPP1` = '{$imgPathPP1}',
`imgPathPP2` = '{$imgPathPP2}',
`imgPathPP3` = '{$imgPathPP3}',
`imgPathPP4` = '{$imgPathPP4}',
`imgPathPP5` = '{$imgPathPP5}',
`imgPathPP6` = '{$imgPathPP6}',
`imgPathPP7` = '{$imgPathPP7}',
`imgPathPP8` = '{$imgPathPP8}',
`imgPathPP9` = '{$imgPathPP9}',
`imgPathPP10` = '{$imgPathPP10}'
WHERE `ppNo` = '{$ppNo}';
";
$this->update($sql);
return $this->makeResultJson(1, "수정되었습니다");
}
}
function deleteProductionPortrait(){
$noArr = $this->req["no"];
$noStr = implode(',', $noArr);
$sql = "
UPDATE tblProductionPortrait
SET status = 0
WHERE `ppNo` IN({$noStr})
";
$this->update($sql);
}
}
}
......
......@@ -55,13 +55,8 @@ if(! class_exists("Push") ) {
foreach($pushKeyArr as $key => $pushKey){
if($pushKey["device_type_id"] != "2" && strlen($pushKey["registration_key"]) > 32){
if($pushKey["app_type"] == 1){
array_push($gcmKeyArr, $pushKey["registration_key"]);
}
else{
array_push($gcmKeyArr2, $pushKey["registration_key"]);
}
}
if($pushKey["device_type_id"] == "2" && strlen($pushKey["registration_key"]) > 32){
array_push($apnsKeyArr, $pushKey["registration_key"]);
......
......@@ -21,8 +21,7 @@
{
$targetData = Array(
"registration_key" => $pushTargetList[$i]["registration_key"],
"device_type_id" => $pushTargetList[$i]["device_type_id"],
"app_type" => $pushTargetList[$i]["app_type"]
"device_type_id" => $pushTargetList[$i]["device_type_id"]
);
$paramsStr = urlencode(json_encode($targetData));
$paramsArr[floor($i/$push_send_size)] .= "&targetList[]={$paramsStr}";
......