horfix) additional development
Showing
36 changed files
with
1021 additions
and
22 deletions
.idea/KCSpecialVehicle.iml
0 → 100644
1 | <?xml version="1.0" encoding="UTF-8"?> | ||
2 | <module type="WEB_MODULE" version="4"> | ||
3 | <component name="NewModuleRootManager"> | ||
4 | <content url="file://$MODULE_DIR$" /> | ||
5 | <orderEntry type="inheritedJdk" /> | ||
6 | <orderEntry type="sourceFolder" forTests="false" /> | ||
7 | </component> | ||
8 | </module> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
.idea/modules.xml
0 → 100644
1 | <?xml version="1.0" encoding="UTF-8"?> | ||
2 | <project version="4"> | ||
3 | <component name="ProjectModuleManager"> | ||
4 | <modules> | ||
5 | <module fileurl="file://$PROJECT_DIR$/.idea/KCSpecialVehicle.iml" filepath="$PROJECT_DIR$/.idea/KCSpecialVehicle.iml" /> | ||
6 | </modules> | ||
7 | </component> | ||
8 | </project> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
.idea/vcs.xml
0 → 100644
.idea/workspace.xml
0 → 100644
This diff is collapsed.
Click to expand it.
No preview for this file type
100/20171010/201710100306381925904.png
0 → 100644
1.72 KB
100/20171010/201710100320591411346.png
0 → 100644
1.72 KB
320/20171010/201710100306381925904.png
0 → 100644
9.71 KB
320/20171010/201710100320591411346.png
0 → 100644
9.71 KB
480/20171010/201710100306381925904.png
0 → 100644
19.6 KB
480/20171010/201710100320591411346.png
0 → 100644
19.6 KB
640/20171010/201710100306381925904.png
0 → 100644
32.3 KB
640/20171010/201710100320591411346.png
0 → 100644
32.3 KB
720/20171010/201710100306381925904.png
0 → 100644
39.4 KB
720/20171010/201710100320591411346.png
0 → 100644
39.4 KB
... | @@ -170,6 +170,9 @@ | ... | @@ -170,6 +170,9 @@ |
170 | case "EV": | 170 | case "EV": |
171 | echo "이벤트"; | 171 | echo "이벤트"; |
172 | break; | 172 | break; |
173 | case "SM": | ||
174 | echo "직원/영업사원 전용게시판"; | ||
175 | break; | ||
173 | } | 176 | } |
174 | ?> | 177 | ?> |
175 | </h1> | 178 | </h1> |
... | @@ -184,6 +187,9 @@ | ... | @@ -184,6 +187,9 @@ |
184 | case "EV": | 187 | case "EV": |
185 | echo "이벤트"; | 188 | echo "이벤트"; |
186 | break; | 189 | break; |
190 | case "SM": | ||
191 | echo "직원/영업사원 전용게시판"; | ||
192 | break; | ||
187 | } | 193 | } |
188 | ?> | 194 | ?> |
189 | </span> | 195 | </span> | ... | ... |
... | @@ -112,8 +112,10 @@ | ... | @@ -112,8 +112,10 @@ |
112 | <? | 112 | <? |
113 | if($_REQUEST["boardType"] == "NO") | 113 | if($_REQUEST["boardType"] == "NO") |
114 | echo "공지사항"; | 114 | echo "공지사항"; |
115 | else if($_REQUEST["boardType"] == "EV") | ||
116 | echo "이벤트"; | ||
115 | else | 117 | else |
116 | echo "이벤트" | 118 | echo "직원/영업사원 전용게시판"; |
117 | ?> | 119 | ?> |
118 | > | 120 | > |
119 | <span><? | 121 | <span><? | ... | ... |
... | @@ -227,6 +227,18 @@ | ... | @@ -227,6 +227,18 @@ |
227 | </td> | 227 | </td> |
228 | </tr> | 228 | </tr> |
229 | <tr> | 229 | <tr> |
230 | <th style="height:25px;">하위메뉴</th> | ||
231 | <td class="l"> | ||
232 | <select name="productionType"> | ||
233 | <option value="WB" <?=$info["productionType"] == "WB"?"selected" : ""?>>윙바디</option> | ||
234 | <option value="UW" <?=$info["productionType"] == "UW"?"selected" : ""?>>상승윙바디</option> | ||
235 | <option value="FW" <?=$info["productionType"] == "FW"?"selected" : ""?>>냉동윙바디</option> | ||
236 | <option value="FC" <?=$info["productionType"] == "FC"?"selected" : ""?>>냉동컨테이저/탑</option> | ||
237 | <option value="SP" <?=$info["productionType"] == "SP"?"selected" : ""?>>특수차량</option> | ||
238 | </select> | ||
239 | </td> | ||
240 | </tr> | ||
241 | <tr> | ||
230 | <th style="height:25px;">카테고리</th> | 242 | <th style="height:25px;">카테고리</th> |
231 | <td> | 243 | <td> |
232 | <select id="category"> | 244 | <select id="category"> | ... | ... |
admin/boardManage/vehicleSpecification.php
0 → 100644
1 | <?php | ||
2 | /** | ||
3 | * Created by PhpStorm. | ||
4 | * User: p | ||
5 | * Date: 2017-10-10 | ||
6 | * Time: 오후 3:10 | ||
7 | */ | ||
8 | ?> | ||
9 | |||
10 | |||
11 | <? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminBoard.php" ?> | ||
12 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?> | ||
13 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftBoardManage.php" ?> | ||
14 | <? | ||
15 | $obj = new AdminBoard($_REQUEST, ""); | ||
16 | $info = $obj->getInfoOfVehicleSpecification(); | ||
17 | |||
18 | $rurl = pack("H*", $_REQUEST["rurl"]) ; | ||
19 | ?> | ||
20 | <script src="/admin/inc/fileUpload/fileUploadJS.js"></script> | ||
21 | <script type="text/javascript"> | ||
22 | var _rurl = "<?=$rurl?>"; | ||
23 | var _no = "<?=$_REQUEST[no]?>"; | ||
24 | |||
25 | $(document).ready(function(){ | ||
26 | |||
27 | initFileUpload(101); | ||
28 | |||
29 | //=====프레입웤 변수들==================================================================================// | ||
30 | var FORM_TARGET_CLS_NM = ".data" ; // 폼을 동적 wrap 할 타겟 ID이름 | ||
31 | var FORM_NAME = "alf" ; // 폼이름 | ||
32 | var FORM_METHOD = "POST" ; // 폼 메쏘드 | ||
33 | var FORM_USE_FILE = false ; // 파일폼 사용 여부 | ||
34 | var FORM_ACTION = "/action_front.php" ; | ||
35 | |||
36 | |||
37 | var NEXT_CMD = "" ; // 다은 수행 할 cmd | ||
38 | //=====================================================================================================// | ||
39 | |||
40 | var jForm = $(FORM_TARGET_CLS_NM).mf({ "name" : FORM_NAME , "method" : FORM_METHOD , "action" : FORM_ACTION , "useFile" : FORM_USE_FILE }) ; | ||
41 | |||
42 | $(".jCancel").click2(function(){ | ||
43 | location.href = _rurl; | ||
44 | }); | ||
45 | |||
46 | |||
47 | $(".jSave").click2(function(){ | ||
48 | if(confirm("내용을 저장하시겠습니까?")){ | ||
49 | $("#jData").ajaxSubmit({ | ||
50 | url:"/action_front.php?cmd=AdminBoard.saveVehicleSpecification", | ||
51 | type : "post", | ||
52 | forceSync : true, | ||
53 | dataType : "json", | ||
54 | success : function(data){ | ||
55 | alert(data.returnMessage); | ||
56 | location.href = _rurl; | ||
57 | } | ||
58 | |||
59 | }); | ||
60 | } | ||
61 | |||
62 | }); | ||
63 | |||
64 | }) ; | ||
65 | |||
66 | </script> | ||
67 | |||
68 | <div id="Contents" class="notice"> | ||
69 | |||
70 | <h1>특장 제원표</h1> | ||
71 | |||
72 | <!-- location area --> | ||
73 | <h2> | ||
74 | 게시물관리 > <span>특장 제원표</span> | ||
75 | </h2> | ||
76 | <!-- location area --> | ||
77 | |||
78 | |||
79 | <div class="data" style="width:80%;"> | ||
80 | |||
81 | <form id="jData" method="post" enctype="multipart/form-data"> | ||
82 | <table class="datav" style="width:100%;"> | ||
83 | <colgroup> | ||
84 | <col width="10%" /> | ||
85 | <col width="90%" /> | ||
86 | </colgroup> | ||
87 | <tr> | ||
88 | <th style="height:25px;">내용</th> | ||
89 | <td class="l"> | ||
90 | <textarea name="content" rows="7" style="width:90%;resize:vertical;"><?=$info["content"]?></textarea> | ||
91 | </td> | ||
92 | </tr> | ||
93 | |||
94 | <tr> | ||
95 | <th style="height:25px;">이미지</th> | ||
96 | <td class="l"> | ||
97 | <? | ||
98 | $fileIndex = "101"; | ||
99 | $fileName = "imgPath1"; | ||
100 | $filePath = ($info["imgPath1"] == "" ? "" : $info["imgPath1"]); | ||
101 | //$fileNumber = ($shopImgList[0]["no"] == "" ? "0" : $shopImgList[0]["no"]); | ||
102 | include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/fileUpload/fileUpload.php"; | ||
103 | ?> | ||
104 | <input type="hidden" name="imgPath1" value="<?=$info["imgPath1"]?>" /> | ||
105 | </td> | ||
106 | </tr> | ||
107 | </table> | ||
108 | </form> | ||
109 | |||
110 | <div class="btngroupcenter"> | ||
111 | <!-- <span class="button bigrounded blue jCancel">취소 </span>--> | ||
112 | <span class="button bigrounded blue jSave" >저장</span> | ||
113 | </div> | ||
114 | |||
115 | </div> | ||
116 | </div> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
... | @@ -29,10 +29,18 @@ $(document).ready(function(){ | ... | @@ -29,10 +29,18 @@ $(document).ready(function(){ |
29 | <a href="/admin/boardManage/certificateList.php">기관인정서</a> | 29 | <a href="/admin/boardManage/certificateList.php">기관인정서</a> |
30 | </li> | 30 | </li> |
31 | 31 | ||
32 | <li matchUrl="/admin/boardManage/vehicleSpecification.php"> | ||
33 | <a href="/admin/boardManage/vehicleSpecification.php">특장 제원표</a> | ||
34 | </li> | ||
35 | |||
32 | <li matchUrl="/admin/boardManage/productionPortrait.php"> | 36 | <li matchUrl="/admin/boardManage/productionPortrait.php"> |
33 | <a href="/admin/boardManage/productionPortrait.php">제작사진</a> | 37 | <a href="/admin/boardManage/productionPortrait.php">제작사진</a> |
34 | </li> | 38 | </li> |
35 | 39 | ||
40 | <li matchUrl="/admin/boardManage/boardList.php"> | ||
41 | <a href="/admin/boardManage/boardList.php?boardType=SM">직원/영업사원 전용게시판</a> | ||
42 | </li> | ||
43 | |||
36 | </ul> | 44 | </ul> |
37 | 45 | ||
38 | 46 | ... | ... |
... | @@ -25,6 +25,9 @@ $(document).ready(function(){ | ... | @@ -25,6 +25,9 @@ $(document).ready(function(){ |
25 | <a href="/admin/userManage/userManagerList.php">직원</a> | 25 | <a href="/admin/userManage/userManagerList.php">직원</a> |
26 | </li> | 26 | </li> |
27 | 27 | ||
28 | <li matchUrl="/admin/userManage/userSalesList.php"> | ||
29 | <a href="/admin/userManage/userSalesList.php">영업사원</a> | ||
30 | </li> | ||
28 | </ul> | 31 | </ul> |
29 | 32 | ||
30 | 33 | ... | ... |
... | @@ -150,7 +150,7 @@ $(document).ready(function() { | ... | @@ -150,7 +150,7 @@ $(document).ready(function() { |
150 | else if ($(this).attr("style") == "background: rgb(255, 113, 113);") | 150 | else if ($(this).attr("style") == "background: rgb(255, 113, 113);") |
151 | $("[name=isAvail][value=-1]").prop("checked", true); | 151 | $("[name=isAvail][value=-1]").prop("checked", true); |
152 | else | 152 | else |
153 | $("[name=isAvail][value=0]").prop("checked", true); | 153 | $("[name=isAvail][value=1]").prop("checked", true); |
154 | 154 | ||
155 | targetDate = $(this).attr("data-date"); | 155 | targetDate = $(this).attr("data-date"); |
156 | 156 | ||
... | @@ -287,7 +287,7 @@ function myFunction(pageY, pageX) { | ... | @@ -287,7 +287,7 @@ function myFunction(pageY, pageX) { |
287 | <br><br><br> | 287 | <br><br><br> |
288 | <input type=radio name="isAvail" value="1" style="float:left;"/>제작 가능<br><br> | 288 | <input type=radio name="isAvail" value="1" style="float:left;"/>제작 가능<br><br> |
289 | <input type=radio name="isAvail" value="-1" style="float:left;"/>제작 불가능<br><br> | 289 | <input type=radio name="isAvail" value="-1" style="float:left;"/>제작 불가능<br><br> |
290 | <input type=radio name="isAvail" value="0" checked style="float:left;"/>없음<br> | 290 | <!-- <input type=radio name="isAvail" value="0" checked style="float:left;"/>없음<br>--> |
291 | <span style="text-align:center; width:100%; display:inline-block; margin-top: 20px;"> | 291 | <span style="text-align:center; width:100%; display:inline-block; margin-top: 20px;"> |
292 | <button class="jSave" style="width: 35%; background-color: #8C8C8C; border : none; color:#FFFFFF; border-radius: 5px;">저장</button> | 292 | <button class="jSave" style="width: 35%; background-color: #8C8C8C; border : none; color:#FFFFFF; border-radius: 5px;">저장</button> |
293 | <button class="jClose" style="width: 35%; background-color: #8C8C8C; border : none; color:#FFFFFF; border-radius: 5px;">닫기</button> | 293 | <button class="jClose" style="width: 35%; background-color: #8C8C8C; border : none; color:#FFFFFF; border-radius: 5px;">닫기</button> | ... | ... |
admin/userManage/userSalesList.php
0 → 100644
1 | <?php | ||
2 | /** | ||
3 | * Created by PhpStorm. | ||
4 | * User: p | ||
5 | * Date: 2017-10-10 | ||
6 | * Time: 오후 1:48 | ||
7 | */ | ||
8 | ?> | ||
9 | |||
10 | <? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminUser.php" ?> | ||
11 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?> | ||
12 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftUserManage.php" ?> | ||
13 | <? | ||
14 | $obj = new AdminUser($_REQUEST) ; | ||
15 | |||
16 | $list = $obj->getListOfSales() ; | ||
17 | $vnum = $obj->virtualNum ; | ||
18 | |||
19 | //echo json_encode($list); | ||
20 | ?> | ||
21 | <script> | ||
22 | |||
23 | $(document).ready(function(){ | ||
24 | |||
25 | //=====프레입웤 변수들==================================================================================// | ||
26 | var FORM_TARGET_CLS_NM = "DIV#Contents" ; // 폼을 동적 wrap 할 타겟 ID이름 | ||
27 | var FORM_NAME = "nf" ; // 폼이름 | ||
28 | var FORM_METHOD = "GET" ; // 폼 메쏘드 | ||
29 | var FORM_USE_FILE = false ; // 파일폼 사용 여부 | ||
30 | var FORM_ACTION = document.URL ; | ||
31 | |||
32 | var NEXT_CMD = "" ; // 다은 수행 할 cmd | ||
33 | //=====================================================================================================// | ||
34 | |||
35 | var jForm = $(FORM_TARGET_CLS_NM).mf({ "name" : FORM_NAME , "method" : FORM_METHOD , "action" : FORM_ACTION , "useFile" : FORM_USE_FILE }) ; | ||
36 | |||
37 | // 페이징 | ||
38 | $(".jPage").click2(function(){ | ||
39 | jForm.ci() ; | ||
40 | jForm.mi("page",$(this).attr("page")) ; | ||
41 | jForm.submit() ; | ||
42 | }) ; | ||
43 | |||
44 | |||
45 | $(".jAutoSearch").change(function(){ | ||
46 | jForm.ci() ; | ||
47 | jForm.submit() ; | ||
48 | }); | ||
49 | |||
50 | |||
51 | $(".jSearch").click2(function(){ | ||
52 | jForm.ci() ; | ||
53 | jForm.submit() ; | ||
54 | }); | ||
55 | |||
56 | $(".jViewUser").click2(function(){ | ||
57 | var no = $(this).attr("no"); | ||
58 | location.href = "/admin/userManage/userSalesView.php?isMS=0&no=" + no + "&rurl=" + jQuery.rich.bin2hex(document.URL); | ||
59 | }); | ||
60 | |||
61 | // 회원 탈퇴 | ||
62 | $(".jDelUser").click2(function(){ | ||
63 | var no = $(this).attr("no"); | ||
64 | var noArr = new Array(no); | ||
65 | if(confirm("정말 삭제하시겠습니까?")) | ||
66 | { | ||
67 | deleteUser(noArr); | ||
68 | } | ||
69 | }) ; | ||
70 | |||
71 | $(".jAdd").click2(function(){ | ||
72 | location.href="/admin/userManage/userSalesView.php?"+"rurl="+jQuery.rich.bin2hex(document.URL); | ||
73 | }) ; | ||
74 | |||
75 | |||
76 | // 단체 삭제 | ||
77 | $(".jDelUserMulti").click2(function(){ | ||
78 | |||
79 | |||
80 | var noArr = new Array(); | ||
81 | var noCount = $(".jUserNo:checked").length; | ||
82 | |||
83 | if(noCount == 0) | ||
84 | { | ||
85 | alert("삭제할 관리자를 하나 이상 선택해주세요."); | ||
86 | return false; | ||
87 | } | ||
88 | |||
89 | |||
90 | if(confirm("정말 삭제하시겠습니까?")) | ||
91 | { | ||
92 | for(var i = 0; i < noCount; i++ ) | ||
93 | { | ||
94 | noArr[i] = $(".jUserNo:checked:eq(" + i + ")").val(); | ||
95 | } | ||
96 | |||
97 | deleteUser(noArr); | ||
98 | } | ||
99 | |||
100 | }); | ||
101 | |||
102 | $(".jInitialize").click2(function(){ | ||
103 | |||
104 | var no = $(this).attr("no"); | ||
105 | if(confirm("초기화를 하시겠습니까? \n변경 후 수정은 불가능합니다")){ | ||
106 | $.ajax({ | ||
107 | url : "/action_front.php?cmd=AdminUser.initializePwd", | ||
108 | async : false, | ||
109 | cache : false, | ||
110 | dataType : "json", | ||
111 | data : { | ||
112 | "userNo" : no | ||
113 | }, | ||
114 | success : function(data){ | ||
115 | alert(data.returnMessage); | ||
116 | location.reload(); | ||
117 | /* | ||
118 | if(_no != "") | ||
119 | location.reload(); | ||
120 | else | ||
121 | location.href = _rurl; | ||
122 | */ | ||
123 | } | ||
124 | }); | ||
125 | } | ||
126 | }); | ||
127 | |||
128 | $(".jBtnMS").click2(function(){ | ||
129 | var no = $(this).attr("no"); | ||
130 | var member_type = $(this).attr("member_type"); | ||
131 | |||
132 | $.ajax({ | ||
133 | url : "/action_front.php?cmd=AdminUser.processRequestMemberShipUser", | ||
134 | async : false, | ||
135 | cache : false, | ||
136 | dataType : "json", | ||
137 | data : { | ||
138 | "no" : no | ||
139 | , "member_type" : member_type | ||
140 | }, | ||
141 | success : function(data){ | ||
142 | alert(data.returnMessage); | ||
143 | location.reload(); | ||
144 | } | ||
145 | }); | ||
146 | }); | ||
147 | |||
148 | |||
149 | $("#jCheckAll").change(function(){ | ||
150 | if($(this).is(":checked")) | ||
151 | $(".jUserNo").prop("checked", true); | ||
152 | else | ||
153 | $(".jUserNo").prop("checked", false); | ||
154 | }); | ||
155 | |||
156 | }) ; | ||
157 | |||
158 | |||
159 | |||
160 | function deleteUser(noArr) | ||
161 | { | ||
162 | $.ajax({ | ||
163 | url : "/action_front.php?cmd=AdminUser.deleteUser", | ||
164 | async : false, | ||
165 | cache : false, | ||
166 | dataType : "json", | ||
167 | data : { | ||
168 | "no" : noArr | ||
169 | }, | ||
170 | success : function(data){ | ||
171 | alert("삭제되었습니다"); | ||
172 | location.reload(); | ||
173 | } | ||
174 | }); | ||
175 | } | ||
176 | |||
177 | |||
178 | |||
179 | </script> | ||
180 | |||
181 | |||
182 | <div id="Contents" class="notice"> | ||
183 | |||
184 | <h1>영업사원</h1> | ||
185 | |||
186 | <div class="data"> | ||
187 | <fieldset class="search"> | ||
188 | |||
189 | <div class="jSearchArea" > | ||
190 | |||
191 | <label> | ||
192 | <span>조회 조건</span> | ||
193 | <select name="searchType"> | ||
194 | <option value="">전체 </option> | ||
195 | <option value="userName" <?=$_REQUEST["searchType"] == "userName" ? "SELECTED" : ""?>>이름</option> | ||
196 | <option value="userID" <?=$_REQUEST["searchType"] == "userID" ? "SELECTED" : ""?>>아이디</option> | ||
197 | <option value="nickName" <?=$_REQUEST["searchType"] == "nickName" ? "SELECTED" : ""?>>닉네임</option> | ||
198 | </select> | ||
199 | <input type="text" id="searchText" name="searchText" class="wm" value="<?=$_REQUEST['searchText']?>" /> | ||
200 | </label> | ||
201 | |||
202 | <input type="button" class="button smallgrounded blue jSearch btnright_y" value="검색" /> | ||
203 | </div> | ||
204 | |||
205 | </fieldset> | ||
206 | |||
207 | |||
208 | <div class="btngroupright"> | ||
209 | <input type="button" class="button smallrounded blue jAdd" value="등록" /> | ||
210 | <input type="button" class="button smallrounded blue jDelUserMulti" value="삭제" /> | ||
211 | </div> | ||
212 | |||
213 | <table class="datacList"> | ||
214 | <thead> | ||
215 | <tr> | ||
216 | <th class="no" width="5%">No</th> | ||
217 | <th width="2%"><input type="checkbox" id="jCheckAll"></th> | ||
218 | <th width="6%">이름</th> | ||
219 | <th width="10%">아이디</th> | ||
220 | <th width="10%">닉네임</th> | ||
221 | <th width="10%">전화번호</th> | ||
222 | <th width="6%">비밀번호 <br>초기화</th> | ||
223 | </tr> | ||
224 | </thead> | ||
225 | <tbody><!-- 10줄 리스트// 마지막 tr에 class="last" 넣어주세요 --> | ||
226 | <? for($i=0; $i<sizeof($list); $i++){ ?> | ||
227 | <tr class="<?=(sizeof($list)-1 == $i) ? "last" : "datacLists"?>"> | ||
228 | <td class="no center"> | ||
229 | <?=$vnum--?> | ||
230 | </td> | ||
231 | |||
232 | <td class="center"> | ||
233 | <input type="checkbox" class="jUserNo" value="<?=$list[$i]["userNo"] ?>" > | ||
234 | </td> | ||
235 | <td class="center"> | ||
236 | <?=$list[$i]["userName"]?> | ||
237 | </td> | ||
238 | <td class="center"> | ||
239 | <?=$list[$i]["userID"]?> | ||
240 | </td> | ||
241 | <td class="center"> | ||
242 | <?=$list[$i]["nickName"]?> | ||
243 | </td> | ||
244 | <td class="center"> | ||
245 | <?=$list[$i]["userTel"]?> | ||
246 | </td> | ||
247 | <td class="center"> | ||
248 | <input type="button" class="button searchsmall white jInitialize" value="초기화" no="<?=$list[$i]["userNo"]?>" /> | ||
249 | </td> | ||
250 | </tr> | ||
251 | <? } ?> | ||
252 | <?if(sizeof($list) == 0){?> | ||
253 | <tr class="last"> | ||
254 | <td class="no center" colspan="11">No Data</td> | ||
255 | </tr> | ||
256 | <?}?> | ||
257 | </tbody> | ||
258 | </table> | ||
259 | |||
260 | <!-- Pagination --> | ||
261 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/pageNavigation.php" ?> | ||
262 | <!--//Pagination --> | ||
263 | |||
264 | </div> | ||
265 | |||
266 | <div id="jDialogArea" style="display:none;"> | ||
267 | <table class="datav" style="width:100%;"> | ||
268 | <tr> | ||
269 | <th style="height:25px; width:70px;">포인트</th> | ||
270 | <td> | ||
271 | <input type="input" id="jAddHeartPoint" value="" style="width:100%;"/> | ||
272 | </td> | ||
273 | </tr> | ||
274 | </table> | ||
275 | </div> | ||
276 | |||
277 | </div> | ||
278 | |||
279 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/footer.php" ?> |
admin/userManage/userSalesView.php
0 → 100644
1 | <?php | ||
2 | /** | ||
3 | * Created by PhpStorm. | ||
4 | * User: p | ||
5 | * Date: 2017-10-10 | ||
6 | * Time: 오후 1:56 | ||
7 | */ | ||
8 | ?> | ||
9 | |||
10 | |||
11 | <? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/AdminUser.php" ?> | ||
12 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/header.php" ?> | ||
13 | <? include $_SERVER["DOCUMENT_ROOT"] . "/admin/inc/php/leftUserManage.php" ?> | ||
14 | <? | ||
15 | $obj = new AdminUser($_REQUEST, ""); | ||
16 | //$userInfo = $obj->getInfoOfUser(); | ||
17 | |||
18 | $rurl = pack("H*", $_REQUEST["rurl"]) ; | ||
19 | ?> | ||
20 | <script language="javascript"> | ||
21 | var _rurl = "<?=$rurl != "" ? $rurl : 0?>"; | ||
22 | var _no = "<?=$_REQUEST[no] != "" ? $_REQUEST[no] : 0?>"; | ||
23 | |||
24 | |||
25 | $(document).ready(function(){ | ||
26 | |||
27 | $(".jCancel").click2(function(){ | ||
28 | location.href = _rurl; | ||
29 | }); | ||
30 | |||
31 | |||
32 | $(".jDelUser").click2(function(){ | ||
33 | var noArr = new Array(_no); | ||
34 | |||
35 | if(confirm("정말 삭제하시겠습니까?")) | ||
36 | { | ||
37 | deleteUser(noArr); | ||
38 | } | ||
39 | }); | ||
40 | |||
41 | $( '[name=userID]' ).live("blur keyup", function() { | ||
42 | $(this).val( $(this).val().replace( /[ㄱ-ㅎ|ㅏ-ㅣ|가-힣]/g, '' ) ); | ||
43 | }); | ||
44 | |||
45 | $( '[name=userPwd]' ).live("blur keyup", function() { | ||
46 | $(this).val( $(this).val().replace( /[ㄱ-ㅎ|ㅏ-ㅣ|가-힣]/g, '' ) ); | ||
47 | }); | ||
48 | |||
49 | |||
50 | |||
51 | $(".jAdd").click2(function(){ | ||
52 | var data = $("#jData").serialize(); | ||
53 | |||
54 | var userID=$("[name=userID]").val(); | ||
55 | var userPwd=$("[name=userPwd]").val(); | ||
56 | var userName=$("[name=userName]").val(); | ||
57 | var nickName=$("[name=nickName]").val(); | ||
58 | var userTel1=$("[name=userTel1]").val(); | ||
59 | var userTel2=$("[name=userTel2]").val(); | ||
60 | var userTel3=$("[name=userTel3]").val(); | ||
61 | if(userID=="" || userPwd=="" || userName=="" || nickName=="" || userTel1=="" || userTel1=="" || userTel1==""){ | ||
62 | alert("위 항목을 모두 입력해 주십시오"); | ||
63 | return; | ||
64 | } | ||
65 | |||
66 | if(userID.length<6){ | ||
67 | alert("아이디는 영문+숫자조합 6자리 이상이어야 합니다"); | ||
68 | return; | ||
69 | } | ||
70 | |||
71 | if(userPwd.length<4){ | ||
72 | alert("비밀번호는 영문+숫자조합 4자리 이상이어야 합니다"); | ||
73 | return; | ||
74 | } | ||
75 | |||
76 | if(confirm("영업사원 회원 계정을 등록하시겠습니까?")){ | ||
77 | $.ajax({ | ||
78 | url : "/action_front.php?cmd=AdminUser.saveSalesman", | ||
79 | async : false, | ||
80 | cache : false, | ||
81 | dataType : "json", | ||
82 | data : data, | ||
83 | success : function(data){ | ||
84 | alert(data.returnMessage); | ||
85 | if(data.returnCode == "1") | ||
86 | location.href=_rurl; | ||
87 | |||
88 | /* | ||
89 | if(_no != "") | ||
90 | location.reload(); | ||
91 | else | ||
92 | location.href = _rurl; | ||
93 | */ | ||
94 | } | ||
95 | }); | ||
96 | } | ||
97 | |||
98 | |||
99 | }); | ||
100 | |||
101 | $(".jCheckIDRedundancy").click2(function(){ | ||
102 | var data = $("#jData").serialize(); | ||
103 | $.ajax({ | ||
104 | url : "/action_front.php?cmd=AdminUser.checkIDRedundancy", | ||
105 | async : false, | ||
106 | cache : false, | ||
107 | dataType : "json", | ||
108 | data : data, | ||
109 | success : function(data){ | ||
110 | alert(data.returnMessage); | ||
111 | } | ||
112 | }); | ||
113 | |||
114 | }); | ||
115 | |||
116 | $(".jCheckNickRedundancy").click2(function(){ | ||
117 | var data = $("#jData").serialize(); | ||
118 | $.ajax({ | ||
119 | url : "/action_front.php?cmd=AdminUser.checkNickRedundancy", | ||
120 | async : false, | ||
121 | cache : false, | ||
122 | dataType : "json", | ||
123 | data : data, | ||
124 | success : function(data){ | ||
125 | alert(data.returnMessage); | ||
126 | } | ||
127 | }); | ||
128 | |||
129 | }); | ||
130 | |||
131 | |||
132 | |||
133 | }) ; | ||
134 | |||
135 | |||
136 | |||
137 | function deleteUser(noArr) | ||
138 | { | ||
139 | $.ajax({ | ||
140 | url : "/action_front.php?cmd=AdminUser.deleteUser", | ||
141 | async : false, | ||
142 | cache : false, | ||
143 | dataType : "json", | ||
144 | data : { | ||
145 | "no" : noArr | ||
146 | }, | ||
147 | success : function(data){ | ||
148 | //alert("삭제되었습니다"); | ||
149 | location.href = _rurl; | ||
150 | } | ||
151 | }); | ||
152 | } | ||
153 | |||
154 | </script> | ||
155 | |||
156 | <div id="Contents" class="notice"> | ||
157 | |||
158 | <h1>영업사원 등록</h1> | ||
159 | |||
160 | <!-- location area --> | ||
161 | <h2> | ||
162 | 회원 관리 > 영업사원 > <span>등록</span> | ||
163 | </h2> | ||
164 | <!-- location area --> | ||
165 | |||
166 | <form id="jData"> | ||
167 | <div class="jData" style="width:50%;"> | ||
168 | <table class="datav" style="width:100%;"> | ||
169 | <colgroup> | ||
170 | <col width="30%" /> | ||
171 | <col width="70%" /> | ||
172 | </colgroup> | ||
173 | <tr> | ||
174 | <th style="height:25px;">아이디</th> | ||
175 | <td > | ||
176 | <input name="userID" type="text" style="width:200px"/> | ||
177 | <span class="button bigrounded blue jCheckIDRedundancy" style="color:white; width:70px"> 중복확인 </span> | ||
178 | </td> | ||
179 | </tr> | ||
180 | <tr> | ||
181 | <th style="height:25px;">비밀번호</th> | ||
182 | <td > | ||
183 | <input name="userPwd" type="text" style="width:200px"/> | ||
184 | </td> | ||
185 | </tr> | ||
186 | <tr> | ||
187 | <th style="height:25px;">영업사원명</th> | ||
188 | <td class="l"> | ||
189 | <input name="userName" type="text" style="width:200px" /> | ||
190 | </td> | ||
191 | </tr> | ||
192 | <tr> | ||
193 | <th style="height:25px;">닉네임</th> | ||
194 | <td class="l"> | ||
195 | <input name="nickName" type="text" style="width:200px" /> | ||
196 | <span class="button bigrounded blue jCheckNickRedundancy" style="color:white; width:70px"> 중복확인 </span> | ||
197 | </td> | ||
198 | </tr> | ||
199 | <tr> | ||
200 | <th style="height:25px;">전화번호</th> | ||
201 | <td class="l"> | ||
202 | <input name="userTel1" type="text" style="width:50px"/> - <input name="userTel2" type="text" style="width:50px"/> - <input name="userTel3" type="text" style="width:50px"/> | ||
203 | </td> | ||
204 | </tr> | ||
205 | |||
206 | </table> | ||
207 | |||
208 | <div class="btngroupcenter"> | ||
209 | <span class="button bigrounded blue jAdd">등록</span> | ||
210 | </div> | ||
211 | |||
212 | </div> | ||
213 | </form> | ||
214 | </div> |
... | @@ -123,7 +123,7 @@ if(!class_exists("AdminPush")){ | ... | @@ -123,7 +123,7 @@ if(!class_exists("AdminPush")){ |
123 | 123 | ||
124 | function sendAdminPush() | 124 | function sendAdminPush() |
125 | { | 125 | { |
126 | $push_msg = $this->req["pushMessage"]; | 126 | $push_msg = $this->req["push_msg"]; |
127 | $push_code = $this->getBulkPushCode(); | 127 | $push_code = $this->getBulkPushCode(); |
128 | $push_succeed=0; | 128 | $push_succeed=0; |
129 | 129 | ||
... | @@ -144,7 +144,6 @@ if(!class_exists("AdminPush")){ | ... | @@ -144,7 +144,6 @@ if(!class_exists("AdminPush")){ |
144 | $push_succeed = $result["rn"]; | 144 | $push_succeed = $result["rn"]; |
145 | 145 | ||
146 | 146 | ||
147 | $push_msg = $this->req["pushMessage"]; | ||
148 | 147 | ||
149 | // 푸시 전송 | 148 | // 푸시 전송 |
150 | $params = Array( | 149 | $params = Array( | ... | ... |
... | @@ -360,11 +360,8 @@ if(!class_exists("AdminUser")){ | ... | @@ -360,11 +360,8 @@ if(!class_exists("AdminUser")){ |
360 | $login_type = $this->admUser["admin_type"]; | 360 | $login_type = $this->admUser["admin_type"]; |
361 | $target_fk = $this->admUser["target_fk"]; | 361 | $target_fk = $this->admUser["target_fk"]; |
362 | 362 | ||
363 | |||
364 | $where = " WHERE status = 1 AND userType=2"; | 363 | $where = " WHERE status = 1 AND userType=2"; |
365 | 364 | ||
366 | |||
367 | |||
368 | if($searchType == "userName"){ | 365 | if($searchType == "userName"){ |
369 | $where.=" AND userName LIKE '%{$searchText}%'"; | 366 | $where.=" AND userName LIKE '%{$searchText}%'"; |
370 | } | 367 | } |
... | @@ -379,7 +376,62 @@ if(!class_exists("AdminUser")){ | ... | @@ -379,7 +376,62 @@ if(!class_exists("AdminUser")){ |
379 | $where.=" AND userNo=0"; | 376 | $where.=" AND userNo=0"; |
380 | } | 377 | } |
381 | 378 | ||
379 | if($this->req["page"] != "-1") | ||
380 | { | ||
381 | //최초 페이지 설정 | ||
382 | $this->initPage() ; | ||
383 | |||
384 | $sql = " | ||
385 | SELECT COUNT(*) AS rn | ||
386 | FROM tblUser U | ||
387 | {$where} | ||
388 | "; | ||
389 | |||
390 | $this->rownum = $this->getValue($sql, 'rn'); | ||
391 | |||
392 | //총 로우수를 획득후 페이지 최종 설정 | ||
393 | $this->setPage($this->rownum) ; | ||
382 | 394 | ||
395 | $limit = " LIMIT {$this->startNum}, {$this->endNum} ; "; | ||
396 | } | ||
397 | |||
398 | $sql = " | ||
399 | SELECT | ||
400 | U.* | ||
401 | FROM tblUser U | ||
402 | {$where} | ||
403 | ORDER BY U.regDate DESC | ||
404 | {$limit} | ||
405 | "; | ||
406 | |||
407 | $result = $this->getArray($sql); | ||
408 | |||
409 | //echo json_encode($result); | ||
410 | return $result; | ||
411 | } | ||
412 | |||
413 | function getListOfSales(){ | ||
414 | $searchText = $this->req["searchText"]; | ||
415 | $searchType=$this->req["searchType"]; | ||
416 | |||
417 | $login_type = $this->admUser["admin_type"]; | ||
418 | $target_fk = $this->admUser["target_fk"]; | ||
419 | |||
420 | $where = " WHERE status = 1 AND userType=3"; | ||
421 | |||
422 | if($searchType == "userName"){ | ||
423 | $where.=" AND userName LIKE '%{$searchText}%'"; | ||
424 | } | ||
425 | if($searchType == "userID"){ | ||
426 | $where.=" AND userID LIKE '%{$searchText}%'"; | ||
427 | } | ||
428 | if($searchType == "nickName"){ | ||
429 | $where.=" AND nickName LIKE '%{$searchText}%'"; | ||
430 | } | ||
431 | |||
432 | if($searchText=="" && $searchType != ""){ | ||
433 | $where.=" AND userNo=0"; | ||
434 | } | ||
383 | 435 | ||
384 | if($this->req["page"] != "-1") | 436 | if($this->req["page"] != "-1") |
385 | { | 437 | { |
... | @@ -525,6 +577,70 @@ if(!class_exists("AdminUser")){ | ... | @@ -525,6 +577,70 @@ if(!class_exists("AdminUser")){ |
525 | return $this->makeResultJson(1, "등록되었습니다"); | 577 | return $this->makeResultJson(1, "등록되었습니다"); |
526 | } | 578 | } |
527 | 579 | ||
580 | function saveSalesman(){ | ||
581 | $userID=$this->req["userID"]; | ||
582 | $userPwd=md5($this->req["userPwd"]); | ||
583 | $userName=$this->req["userName"]; | ||
584 | $nickName=$this->req["nickName"]; | ||
585 | $userTel1=$this->req["userTel1"]; | ||
586 | $userTel2=$this->req["userTel2"]; | ||
587 | $userTel3=$this->req["userTel3"]; | ||
588 | |||
589 | $userTel=$userTel1.$userTel2.$userTel3; | ||
590 | |||
591 | $sql=" | ||
592 | SELECT * | ||
593 | FROM tblUser | ||
594 | WHERE userID='{$userID}' AND status=1 | ||
595 | LIMIT 0, 1 | ||
596 | "; | ||
597 | $result=$this->getRow($sql); | ||
598 | |||
599 | if($result != null) | ||
600 | return $this->makeResultJson(-100, "사용할 수 없는 아이디 입니다"); | ||
601 | |||
602 | $sql=" | ||
603 | SELECT * | ||
604 | FROM tblUser | ||
605 | WHERE nickName='{$nickName}' AND status=1 | ||
606 | LIMIT 0, 1 | ||
607 | "; | ||
608 | $result=$this->getRow($sql); | ||
609 | |||
610 | if($result != null) | ||
611 | return $this->makeResultJson(-100, "사용할 수 없는 닉네임 입니다"); | ||
612 | |||
613 | $sql=" | ||
614 | INSERT INTO `tblUser` | ||
615 | ( | ||
616 | `userType`, | ||
617 | `userID`, | ||
618 | `userPwd`, | ||
619 | `userName`, | ||
620 | `nickName`, | ||
621 | `userTel`, | ||
622 | `push`, | ||
623 | `status`, | ||
624 | `regDate`) | ||
625 | VALUES | ||
626 | ( | ||
627 | 3, | ||
628 | '{$userID}', | ||
629 | '{$userPwd}', | ||
630 | '{$userName}', | ||
631 | '{$nickName}', | ||
632 | '{$userTel}', | ||
633 | 1, | ||
634 | 1, | ||
635 | NOW()); | ||
636 | "; | ||
637 | |||
638 | $this->update($sql); | ||
639 | |||
640 | |||
641 | return $this->makeResultJson(1, "등록되었습니다"); | ||
642 | } | ||
643 | |||
528 | 644 | ||
529 | 645 | ||
530 | 646 | ... | ... |
... | @@ -443,8 +443,8 @@ if(! class_exists("ApiBase") ) { | ... | @@ -443,8 +443,8 @@ if(! class_exists("ApiBase") ) { |
443 | $Upload = new UploadUtil(); | 443 | $Upload = new UploadUtil(); |
444 | $uploadResult = $Upload->uploadOneFile($_FILES["file"], $this->fileSavePath, "", true); | 444 | $uploadResult = $Upload->uploadOneFile($_FILES["file"], $this->fileSavePath, "", true); |
445 | 445 | ||
446 | $logData = "Api : fileUpload // file : {$_FILES["file"]["name"]} //uploadResult : {$uploadResult["returnMessage"]} // returnCode : {$uploadResult["returnCode"]} // savePath : {$uploadResult["fileInfo"]["savePath"]} // re_name : {$uploadResult["fileInfo"]["re_name"]}"; | 446 | // $logData = "Api : fileUpload // file : {$_FILES["file"]["name"]} //uploadResult : {$uploadResult["returnMessage"]} // returnCode : {$uploadResult["returnCode"]} // savePath : {$uploadResult["fileInfo"]["savePath"]} // re_name : {$uploadResult["fileInfo"]["re_name"]}"; |
447 | LogUtil::writeFileLog($this->logPath, $logData); | 447 | // LogUtil::writeFileLog($this->logPath, $logData); |
448 | 448 | ||
449 | if( $uploadResult['returnCode'] == "1" ){ | 449 | if( $uploadResult['returnCode'] == "1" ){ |
450 | 450 | ... | ... |
... | @@ -304,6 +304,89 @@ if (! class_exists("ApiBoard")) | ... | @@ -304,6 +304,89 @@ if (! class_exists("ApiBoard")) |
304 | return $this->makeResultJson("1", "삭제되었습니다"); | 304 | return $this->makeResultJson("1", "삭제되었습니다"); |
305 | } | 305 | } |
306 | 306 | ||
307 | //직원/영업사원 전용 게시판 리스트 | ||
308 | function getListOfStaffBoard(){ | ||
309 | $sql=" | ||
310 | SELECT COUNT(*) rn FROM tblStaffBoard WHERE status=1 ORDER BY regDate DESC | ||
311 | "; | ||
312 | $cnt = $this->getValue($sql, "rn"); | ||
313 | $this->rownum=$cnt; | ||
314 | |||
315 | $this->initPageForDevice(); | ||
316 | $this->setPageForDevice($this->rownum); | ||
317 | |||
318 | $sql=" | ||
319 | SELECT * FROM tblStaffBoard WHERE status=1 ORDER BY regDate DESC | ||
320 | LIMIT {$this->startNum}, {$this->endNum} | ||
321 | "; | ||
322 | |||
323 | $result = $this->getArray($sql); | ||
324 | |||
325 | return $this->makeResultJson(1, "", $result, Array("totalCount"=>$cnt)); | ||
326 | } | ||
327 | |||
328 | //직원/영업사원 전용 게시물 작성 및 수정 | ||
329 | function saveStaffBoard(){ | ||
330 | $no = $this->req["no"]; | ||
331 | |||
332 | $userNo = $this->appUser["no"]; | ||
333 | $title = $this->req["title"]; | ||
334 | $content = $this->req["content"]; | ||
335 | $imgPath1 = $this->req["imgPath1"]; | ||
336 | $imgPath2 = $this->req["imgPath2"]; | ||
337 | $imgPath3 = $this->req["imgPath3"]; | ||
338 | $imgPath4 = $this->req["imgPath4"]; | ||
339 | $imgPath5 = $this->req["imgPath5"]; | ||
340 | |||
341 | if($no == ""){ | ||
342 | $sql=" | ||
343 | INSERT INTO tblStaffBoard(userFk, title, content, imgPathSBoard1, imgPathSBoard2, imgPathSBoard3, imgPathSBoard4, imgPathSBoard5, status, regDate) | ||
344 | VALUES | ||
345 | ( | ||
346 | '{$userNo}', | ||
347 | '{$title}', | ||
348 | '{$content}', | ||
349 | '{$imgPath1}', | ||
350 | '{$imgPath2}', | ||
351 | '{$imgPath3}', | ||
352 | '{$imgPath4}', | ||
353 | '{$imgPath5}', | ||
354 | 1, | ||
355 | NOW() | ||
356 | ) | ||
357 | "; | ||
358 | |||
359 | $retMsg = "등록되었습니다"; | ||
360 | } | ||
361 | else{ | ||
362 | $sql=" | ||
363 | UPDATE tblStaffBoard | ||
364 | SET | ||
365 | title = '{$title}', | ||
366 | content = '{$content}', | ||
367 | imgPathSBoard1 = '{$imgPath1}', | ||
368 | imgPathSBoard2 = '{$imgPath1}', | ||
369 | imgPathSBoard3 = '{$imgPath1}', | ||
370 | imgPathSBoard4 = '{$imgPath1}', | ||
371 | imgPathSBoard5 = '{$imgPath1}', | ||
372 | "; | ||
373 | $retMsg = "수정되었습니다"; | ||
374 | } | ||
375 | |||
376 | $this->update($sql); | ||
377 | |||
378 | return $this->makeResultJson(1,$retMsg); | ||
379 | } | ||
380 | |||
381 | //직원/영업사원 전용 게시물 상세정보 | ||
382 | function getInfoOfStaffBoard(){ | ||
383 | $no = $this->req["no"]; | ||
384 | $sql=" SELECT * FROM tblStaffBoard WHERE sBoardNo = '{$no}'"; | ||
385 | $result = $this->getRow($sql); | ||
386 | |||
387 | return $this->makeResultJson(1, "", $result); | ||
388 | } | ||
389 | |||
307 | //고객센터 게시물 저장 | 390 | //고객센터 게시물 저장 |
308 | function saveCS(){ | 391 | function saveCS(){ |
309 | // $imgResult = $this->inFn_Common_fileSave($_FILES); | 392 | // $imgResult = $this->inFn_Common_fileSave($_FILES); |
... | @@ -584,8 +667,8 @@ if (! class_exists("ApiBoard")) | ... | @@ -584,8 +667,8 @@ if (! class_exists("ApiBoard")) |
584 | $content=$this->req["content"]; | 667 | $content=$this->req["content"]; |
585 | $parentNo=$this->req["parentNo"]; //부모 댓글의 기본키 | 668 | $parentNo=$this->req["parentNo"]; //부모 댓글의 기본키 |
586 | 669 | ||
587 | $logData = "Api : saveComment // userFk : {$userFk} "; | 670 | // $logData = "Api : saveComment // userFk : {$userFk} "; |
588 | LogUtil::writeFileLog($this->logPath, $logData); | 671 | // LogUtil::writeFileLog($this->logPath, $logData); |
589 | 672 | ||
590 | 673 | ||
591 | if(empty($parentNo)){ //부모가 없을 때 | 674 | if(empty($parentNo)){ //부모가 없을 때 |
... | @@ -1019,10 +1102,18 @@ if (! class_exists("ApiBoard")) | ... | @@ -1019,10 +1102,18 @@ if (! class_exists("ApiBoard")) |
1019 | } | 1102 | } |
1020 | 1103 | ||
1021 | function getListOfProductionPortrait(){ | 1104 | function getListOfProductionPortrait(){ |
1105 | $type = $this->req["type"]; | ||
1106 | |||
1107 | $where = "WHERE status=1"; | ||
1108 | |||
1109 | if($type) | ||
1110 | $where.=" AND productionType = '{$type}'"; | ||
1111 | |||
1112 | |||
1022 | $sql=" | 1113 | $sql=" |
1023 | SELECT COUNT(*) AS rn | 1114 | SELECT COUNT(*) AS rn |
1024 | FROM tblProductionPortrait | 1115 | FROM tblProductionPortrait |
1025 | WHERE status=1 | 1116 | {$where} |
1026 | ORDER BY regDate DESC | 1117 | ORDER BY regDate DESC |
1027 | "; | 1118 | "; |
1028 | $this->initPageForDevice(); | 1119 | $this->initPageForDevice(); |
... | @@ -1034,7 +1125,7 @@ if (! class_exists("ApiBoard")) | ... | @@ -1034,7 +1125,7 @@ if (! class_exists("ApiBoard")) |
1034 | $sql=" | 1125 | $sql=" |
1035 | SELECT ppNo, title, regDate | 1126 | SELECT ppNo, title, regDate |
1036 | FROM tblProductionPortrait | 1127 | FROM tblProductionPortrait |
1037 | WHERE status=1 | 1128 | {$where} |
1038 | ORDER BY regDate DESC | 1129 | ORDER BY regDate DESC |
1039 | LIMIT {$this->startNum}, {$this->endNum} | 1130 | LIMIT {$this->startNum}, {$this->endNum} |
1040 | "; | 1131 | "; | ... | ... |
... | @@ -32,6 +32,17 @@ if (! class_exists("ApiStatic")){ | ... | @@ -32,6 +32,17 @@ if (! class_exists("ApiStatic")){ |
32 | return $this->makeResultJson("1", "", $list); | 32 | return $this->makeResultJson("1", "", $list); |
33 | } | 33 | } |
34 | 34 | ||
35 | function getVehicleSpecification(){ | ||
36 | $sql=" | ||
37 | SELECT * | ||
38 | FROM tblVehicleSpecification | ||
39 | WHERE specNo='1' | ||
40 | "; | ||
41 | $result = $this->getRow($sql); | ||
42 | |||
43 | return $this->makeResultJson(1, "", $result); | ||
44 | } | ||
45 | |||
35 | function getInfoOfOrganizationCert(){ | 46 | function getInfoOfOrganizationCert(){ |
36 | $certNo=$this->req["certNo"]; | 47 | $certNo=$this->req["certNo"]; |
37 | $sql=" | 48 | $sql=" | ... | ... |
... | @@ -54,6 +54,28 @@ if (! class_exists("AdminBoard")){ | ... | @@ -54,6 +54,28 @@ if (! class_exists("AdminBoard")){ |
54 | $result=$this->getArray($sql); | 54 | $result=$this->getArray($sql); |
55 | return $result; | 55 | return $result; |
56 | } | 56 | } |
57 | |||
58 | else if($boardType == "SM"){ | ||
59 | $sql=" | ||
60 | SELECT COUNT(*) AS rn | ||
61 | FROM tblStaffBoard | ||
62 | WHERE status=1 | ||
63 | "; | ||
64 | $this->initPage(); | ||
65 | $this->rownum=$this->getValue($sql, 'rn'); | ||
66 | $this->setPage($this->rownum); | ||
67 | $limit=" LIMIT {$this->startNum}, {$this->endNum} ;"; | ||
68 | |||
69 | $sql=" | ||
70 | SELECT sBoardNo AS no, title, DATE_FORMAT(regDate, '%Y%m%d') AS regDate | ||
71 | FROM tblStaffBoard | ||
72 | WHERE status=1 | ||
73 | ORDER BY regDate DESC | ||
74 | {$limit} | ||
75 | "; | ||
76 | $result=$this->getArray($sql); | ||
77 | return $result; | ||
78 | } | ||
57 | } | 79 | } |
58 | 80 | ||
59 | function getInfoOfBoard(){ | 81 | function getInfoOfBoard(){ |
... | @@ -79,6 +101,16 @@ if (! class_exists("AdminBoard")){ | ... | @@ -79,6 +101,16 @@ if (! class_exists("AdminBoard")){ |
79 | $result=$this->getRow($sql); | 101 | $result=$this->getRow($sql); |
80 | return $result; | 102 | return $result; |
81 | } | 103 | } |
104 | else if($boardType == "SM"){ | ||
105 | $sql=" | ||
106 | SELECT sBoardNo AS no, title, imgPathSBoard1 AS imgPath1, imgPathSBoard2 AS imgPath2, imgPathSBoard3 AS imgPath3, imgPathSBoard4 AS imgPath4, imgPathSBoard5 AS imgPath5, content, regDate | ||
107 | FROM tblStaffBoard | ||
108 | WHERE sBoardNo='{$boardNo}' | ||
109 | "; | ||
110 | |||
111 | $result=$this->getRow($sql); | ||
112 | return $result; | ||
113 | } | ||
82 | } | 114 | } |
83 | 115 | ||
84 | function getListOfEComment($boardNo){ | 116 | function getListOfEComment($boardNo){ |
... | @@ -173,6 +205,35 @@ if (! class_exists("AdminBoard")){ | ... | @@ -173,6 +205,35 @@ if (! class_exists("AdminBoard")){ |
173 | $this->update($sql); | 205 | $this->update($sql); |
174 | return $this->makeResultJson(1, "이벤트가 저장되었습니다"); | 206 | return $this->makeResultJson(1, "이벤트가 저장되었습니다"); |
175 | } | 207 | } |
208 | else if($boardType == "SM"){ | ||
209 | $sql=" | ||
210 | INSERT INTO `tblStaffBoard` | ||
211 | ( | ||
212 | `title`, | ||
213 | `imgPathSBoard1`, | ||
214 | `imgPathSBoard2`, | ||
215 | `imgPathSBoard3`, | ||
216 | `imgPathSBoard4`, | ||
217 | `imgPathSBoard5`, | ||
218 | `content`, | ||
219 | `status`, | ||
220 | `regDate`) | ||
221 | VALUES | ||
222 | ( | ||
223 | '{$title}', | ||
224 | '{$imgPath1}', | ||
225 | '{$imgPath2}', | ||
226 | '{$imgPath3}', | ||
227 | '{$imgPath4}', | ||
228 | '{$imgPath5}', | ||
229 | '{$content}', | ||
230 | 1, | ||
231 | NOW() | ||
232 | ); | ||
233 | "; | ||
234 | $this->update($sql); | ||
235 | return $this->makeResultJson(1, "직원/영업사원 전용 게시물이 저장되었습니다"); | ||
236 | } | ||
176 | } | 237 | } |
177 | else{ | 238 | else{ |
178 | if($boardType=="NO"){ | 239 | if($boardType=="NO"){ |
... | @@ -207,6 +268,22 @@ if (! class_exists("AdminBoard")){ | ... | @@ -207,6 +268,22 @@ if (! class_exists("AdminBoard")){ |
207 | $this->update($sql); | 268 | $this->update($sql); |
208 | return $this->makeResultJson(1, "이벤트가 수정되었습니다"); | 269 | return $this->makeResultJson(1, "이벤트가 수정되었습니다"); |
209 | } | 270 | } |
271 | else if($boardType == "SM"){ | ||
272 | $sql=" | ||
273 | UPDATE `tblStaffBoard` | ||
274 | SET | ||
275 | `title` = '{$title}', | ||
276 | `imgPathSBoard1` = '{$imgPath1}', | ||
277 | `imgPathSBoard2` = '{$imgPath2}', | ||
278 | `imgPathSBoard3` = '{$imgPath3}', | ||
279 | `imgPathSBoard4` = '{$imgPath4}', | ||
280 | `imgPathSBoard5` = '{$imgPath5}', | ||
281 | `content` = '{$content}' | ||
282 | WHERE `sBoardNo` = '{$no}'; | ||
283 | "; | ||
284 | $this->update($sql); | ||
285 | return $this->makeResultJson(1, "직원/영업사원 전용 게시물이 수정되었습니다"); | ||
286 | } | ||
210 | } | 287 | } |
211 | } | 288 | } |
212 | 289 | ||
... | @@ -231,6 +308,14 @@ if (! class_exists("AdminBoard")){ | ... | @@ -231,6 +308,14 @@ if (! class_exists("AdminBoard")){ |
231 | "; | 308 | "; |
232 | $this->update($sql); | 309 | $this->update($sql); |
233 | } | 310 | } |
311 | else if($boardType == "SM"){ | ||
312 | $sql=" | ||
313 | UPDATE tblStaffBoard | ||
314 | SET status = 0 | ||
315 | WHERE `sBoardNo` IN({$noStr}) | ||
316 | "; | ||
317 | $this->update($sql); | ||
318 | } | ||
234 | 319 | ||
235 | } | 320 | } |
236 | 321 | ||
... | @@ -303,6 +388,37 @@ if (! class_exists("AdminBoard")){ | ... | @@ -303,6 +388,37 @@ if (! class_exists("AdminBoard")){ |
303 | } | 388 | } |
304 | } | 389 | } |
305 | 390 | ||
391 | //특장 제원표 저장 | ||
392 | function saveVehicleSpecification(){ | ||
393 | $imgResult = $this->inFn_Common_fileSave($_FILES); | ||
394 | $imgPathSpec = $imgResult["imgPath1"]["saveURL"] != "" ? $imgResult["imgPath1"]["saveURL"] : $this->req["imgPath"]; | ||
395 | |||
396 | $content = $this->req["content"]; | ||
397 | |||
398 | $sql=" | ||
399 | INSERT INTO tblVehicleSpecification(specNo, content, imgPath1) | ||
400 | VALUES ( | ||
401 | 1, | ||
402 | '{$content}', | ||
403 | '{$imgPathSpec}' | ||
404 | ) | ||
405 | ON DUPLICATE KEY UPDATE | ||
406 | content='{$content}', | ||
407 | imgPath1 = '{$imgPathSpec}' | ||
408 | "; | ||
409 | |||
410 | $this->update($sql); | ||
411 | |||
412 | return $this->makeResultJson(1, "저장되었습니다"); | ||
413 | } | ||
414 | |||
415 | //특장 제원표 정보 | ||
416 | function getInfoOfVehicleSpecification(){ | ||
417 | $sql="SELECT * FROM tblVehicleSpecification WHERE specNo = '1'"; | ||
418 | $result = $this->getRow($sql); | ||
419 | return $result; | ||
420 | } | ||
421 | |||
306 | function deleteCert(){ | 422 | function deleteCert(){ |
307 | $noArr = $this->req["no"]; | 423 | $noArr = $this->req["no"]; |
308 | 424 | ||
... | @@ -466,6 +582,7 @@ if (! class_exists("AdminBoard")){ | ... | @@ -466,6 +582,7 @@ if (! class_exists("AdminBoard")){ |
466 | 582 | ||
467 | function saveProductionPortrait(){ | 583 | function saveProductionPortrait(){ |
468 | $ppNo=$this->req["no"]; | 584 | $ppNo=$this->req["no"]; |
585 | $productionType = $this->req["productionType"]; | ||
469 | $title=$this->req["title"]; | 586 | $title=$this->req["title"]; |
470 | $content1=$this->req["content1"]; | 587 | $content1=$this->req["content1"]; |
471 | $content2=$this->req["content2"]; | 588 | $content2=$this->req["content2"]; |
... | @@ -495,6 +612,7 @@ if (! class_exists("AdminBoard")){ | ... | @@ -495,6 +612,7 @@ if (! class_exists("AdminBoard")){ |
495 | $sql=" | 612 | $sql=" |
496 | INSERT INTO `tblProductionPortrait` | 613 | INSERT INTO `tblProductionPortrait` |
497 | ( | 614 | ( |
615 | `productionType`, | ||
498 | `title`, | 616 | `title`, |
499 | `content1`, | 617 | `content1`, |
500 | `content2`, | 618 | `content2`, |
... | @@ -521,6 +639,7 @@ if (! class_exists("AdminBoard")){ | ... | @@ -521,6 +639,7 @@ if (! class_exists("AdminBoard")){ |
521 | ) | 639 | ) |
522 | VALUES | 640 | VALUES |
523 | ( | 641 | ( |
642 | '{$productionType}', | ||
524 | '{$title}', | 643 | '{$title}', |
525 | '{$content1}', | 644 | '{$content1}', |
526 | '{$content2}', | 645 | '{$content2}', |
... | @@ -553,6 +672,7 @@ if (! class_exists("AdminBoard")){ | ... | @@ -553,6 +672,7 @@ if (! class_exists("AdminBoard")){ |
553 | $sql=" | 672 | $sql=" |
554 | UPDATE `tblProductionPortrait` | 673 | UPDATE `tblProductionPortrait` |
555 | SET | 674 | SET |
675 | `productionType` = '{$productionType}', | ||
556 | `title` = '{$title}', | 676 | `title` = '{$title}', |
557 | `content1` = '{$content1}', | 677 | `content1` = '{$content1}', |
558 | `content2` = '{$content2}', | 678 | `content2` = '{$content2}', | ... | ... |
... | @@ -389,8 +389,8 @@ if (! class_exists("Common")) | ... | @@ -389,8 +389,8 @@ if (! class_exists("Common")) |
389 | 389 | ||
390 | if($resPhone == "" && $resPhone == "") | 390 | if($resPhone == "" && $resPhone == "") |
391 | { | 391 | { |
392 | $logData = "Api : sendSMS // reqPhone : {$reqPhone} //resPhone : {$resPhone} // 발송실패"; | 392 | // $logData = "Api : sendSMS // reqPhone : {$reqPhone} //resPhone : {$resPhone} // 발송실패"; |
393 | LogUtil::writeFileLog($this->logPath, $logData); | 393 | // LogUtil::writeFileLog($this->logPath, $logData); |
394 | return false; | 394 | return false; |
395 | } | 395 | } |
396 | 396 | ||
... | @@ -413,8 +413,8 @@ if (! class_exists("Common")) | ... | @@ -413,8 +413,8 @@ if (! class_exists("Common")) |
413 | $returnMsg = $sms->errMsg; | 413 | $returnMsg = $sms->errMsg; |
414 | } | 414 | } |
415 | 415 | ||
416 | $logData = "Api : sendSMS // reqPhone : {$reqPhone} //resPhone : {$resPhone} // 메세지 : {$sendStr} // 발송여부 : {$returnMsg} // 잔여정보 : {$smsInfo}"; | 416 | // $logData = "Api : sendSMS // reqPhone : {$reqPhone} //resPhone : {$resPhone} // 메세지 : {$sendStr} // 발송여부 : {$returnMsg} // 잔여정보 : {$smsInfo}"; |
417 | LogUtil::writeFileLog($this->logPath, $logData); | 417 | // LogUtil::writeFileLog($this->logPath, $logData); |
418 | 418 | ||
419 | return $retunrVal; | 419 | return $retunrVal; |
420 | } | 420 | } | ... | ... |
... | @@ -27,7 +27,7 @@ if(! class_exists("Constants") ) | ... | @@ -27,7 +27,7 @@ if(! class_exists("Constants") ) |
27 | var $fileSaveUrl_480 = "/480/" ; | 27 | var $fileSaveUrl_480 = "/480/" ; |
28 | 28 | ||
29 | 29 | ||
30 | var $dbHost = "182.161.118.74" ; | 30 | var $dbHost = "1.201.142.86" ; |
31 | var $dbName = "kcSpecialVehicle" ; | 31 | var $dbName = "kcSpecialVehicle" ; |
32 | var $dbUser = "root" ; | 32 | var $dbUser = "root" ; |
33 | var $dbPass = "$#@!richware7" ; | 33 | var $dbPass = "$#@!richware7" ; | ... | ... |
... | @@ -9,7 +9,7 @@ if(! class_exists("Push") ) { | ... | @@ -9,7 +9,7 @@ if(! class_exists("Push") ) { |
9 | public $pushNo = "" ; | 9 | public $pushNo = "" ; |
10 | public $pushBadge = "0"; | 10 | public $pushBadge = "0"; |
11 | 11 | ||
12 | private $gcm_key = "AIzaSyB2dCs0PHflZYKnlrhF5bNZl_z7FYRYqfY" ; // 동네 | 12 | private $gcm_key = "AAAA9dR5CVk:APA91bHRB85BDeqQkl4hR5FU_9aYxQQGxoMFRrbEwdZrKbPidsFJbYhwzLuy6hYtrB4jR1JzagNhf00OIrJd00NdMH9QhSPAzAg9tkzk2AWQ6LISQKXor5aK-N9czVVxfuD3HDm6X4Cg" ; // 동네 |
13 | private $gcm_key2 = "AIzaSyBmoURv31T4FLmsf_SwoLRRZRijktAMzO0"; // 직장 | 13 | private $gcm_key2 = "AIzaSyBmoURv31T4FLmsf_SwoLRRZRijktAMzO0"; // 직장 |
14 | //private $gcm_key = "AIzaSyB2dCs0PHflZYKnlrhF5bNZl_z7FYRYqfY"; | 14 | //private $gcm_key = "AIzaSyB2dCs0PHflZYKnlrhF5bNZl_z7FYRYqfY"; |
15 | 15 | ... | ... |
... | @@ -136,7 +136,7 @@ if(! class_exists("LoginUtil")){ | ... | @@ -136,7 +136,7 @@ if(! class_exists("LoginUtil")){ |
136 | $map['name'] = $aUser[3] ; | 136 | $map['name'] = $aUser[3] ; |
137 | $map['userType'] = $aUser[4] ; | 137 | $map['userType'] = $aUser[4] ; |
138 | $map['userTel'] = $aUser[5] ; | 138 | $map['userTel'] = $aUser[5] ; |
139 | $map['deviceTypeID']= $aUeser[6]; | 139 | $map['deviceTypeID']= $aUser[6]; |
140 | } | 140 | } |
141 | $aUser = explode(chr(self::$spliter),$cookieStr); | 141 | $aUser = explode(chr(self::$spliter),$cookieStr); |
142 | 142 | ||
... | @@ -146,7 +146,7 @@ if(! class_exists("LoginUtil")){ | ... | @@ -146,7 +146,7 @@ if(! class_exists("LoginUtil")){ |
146 | $map['name'] = $aUser[3] ; | 146 | $map['name'] = $aUser[3] ; |
147 | $map['userType'] = $aUser[4] ; | 147 | $map['userType'] = $aUser[4] ; |
148 | $map['userTel'] = $aUser[5] ; | 148 | $map['userTel'] = $aUser[5] ; |
149 | $map['deviceTypeID']= $aUeser[6]; | 149 | $map['deviceTypeID']= $aUser[6]; |
150 | 150 | ||
151 | if( LoginUtil::isAppLogin() == false ) | 151 | if( LoginUtil::isAppLogin() == false ) |
152 | { | 152 | { | ... | ... |
2.61 MB
2.61 MB
-
Please register or sign in to post a comment