admin web done
Showing
13 changed files
with
120 additions
and
24 deletions
100/20170223/201702231126191901520.jpg
0 → 100644
2.68 KB
320/20170223/201702231126191901520.jpg
0 → 100644
12.3 KB
480/20170223/201702231126191901520.jpg
0 → 100644
12.3 KB
640/20170223/201702231126191901520.jpg
0 → 100644
12.3 KB
720/20170223/201702231126191901520.jpg
0 → 100644
12.3 KB
... | @@ -65,6 +65,33 @@ | ... | @@ -65,6 +65,33 @@ |
65 | 65 | ||
66 | </script> | 66 | </script> |
67 | 67 | ||
68 | <script type="text/javascript"> | ||
69 | function doImgPop(img){ | ||
70 | img1= new Image(); | ||
71 | img1.src=(img); | ||
72 | imgControll(img); | ||
73 | } | ||
74 | |||
75 | function imgControll(img){ | ||
76 | if((img1.width!=0)&&(img1.height!=0)){ | ||
77 | viewImage(img); | ||
78 | } | ||
79 | else{ | ||
80 | controller="imgControll('"+img+"')"; | ||
81 | intervalID=setTimeout(controller,20); | ||
82 | } | ||
83 | } | ||
84 | function viewImage(img){ | ||
85 | W=img1.width; | ||
86 | H=img1.height; | ||
87 | O="width="+W+",height="+H+",scrollbars=yes"; | ||
88 | imgWin=window.open("","",O); | ||
89 | imgWin.document.write("<html><head><title>이미지상세보기</title></head>"); | ||
90 | imgWin.document.write("<body topmargin=0 leftmargin=0>"); | ||
91 | imgWin.document.write("<img src="+img+" onclick='self.close()' style='cursor:pointer;' title ='클릭하시면 창이 닫힙니다.'>"); | ||
92 | imgWin.document.close(); | ||
93 | } | ||
94 | </script> | ||
68 | 95 | ||
69 | <div id="Contents" class="notice"> | 96 | <div id="Contents" class="notice"> |
70 | 97 | ||
... | @@ -131,19 +158,19 @@ | ... | @@ -131,19 +158,19 @@ |
131 | <center> | 158 | <center> |
132 | <div class="data"> | 159 | <div class="data"> |
133 | <?if($info["imgPathCS1"] != ""){?> | 160 | <?if($info["imgPathCS1"] != ""){?> |
134 | <img alt="" src="/720/<?=$info["imgPathCS1"]?>" style="width:15%; height:600%;"> | 161 | <img alt="" src="/720/<?=$info["imgPathCS1"]?>" onclick="doImgPop('/720/<?=$info["imgPathCS1"]?>')" style="width:15%; height:600%; cursor: pointer;"> |
135 | <?}?> | 162 | <?}?> |
136 | <?if($info["imgPathCS2"] != ""){?> | 163 | <?if($info["imgPathCS2"] != ""){?> |
137 | <img alt="" src="/720/<?=$info["imgPathCS2"]?>" style="width:15%; height:600%;"> | 164 | <img alt="" src="/720/<?=$info["imgPathCS2"]?>" onclick="doImgPop('/720/<?=$info["imgPathCS1"]?>')" style="width:15%; height:600%; cursor: pointer;"> |
138 | <?}?> | 165 | <?}?> |
139 | <?if($info["imgPathCS3"] != ""){?> | 166 | <?if($info["imgPathCS3"] != ""){?> |
140 | <img alt="" src="/720/<?=$info["imgPathCS3"]?>" style="width:15%; height:600%;"> | 167 | <img alt="" src="/720/<?=$info["imgPathCS3"]?>"onclick="doImgPop('/720/<?=$info["imgPathCS1"]?>')" style="width:15%; height:600%; cursor: pointer;"> |
141 | <?}?> | 168 | <?}?> |
142 | <?if($info["imgPathCS4"] != ""){?> | 169 | <?if($info["imgPathCS4"] != ""){?> |
143 | <img alt="" src="/720/<?=$info["imgPathCS4"]?>" style="width:15%; height:600%;"> | 170 | <img alt="" src="/720/<?=$info["imgPathCS4"]?>" onclick="doImgPop('/720/<?=$info["imgPathCS1"]?>')" style="width:15%; height:600%; cursor: pointer;"> |
144 | <?}?> | 171 | <?}?> |
145 | <?if($info["imgPathCS5"] != ""){?> | 172 | <?if($info["imgPathCS5"] != ""){?> |
146 | <img alt="" src="/720/<?=$info["imgPathCS5"]?>" style="width:15%; height:600%;"> | 173 | <img alt="" src="/720/<?=$info["imgPathCS5"]?>" onclick="doImgPop('/720/<?=$info["imgPathCS1"]?>')" style="width:15%; height:600%; cursor: pointer;"> |
147 | <?}?> | 174 | <?}?> |
148 | </div> | 175 | </div> |
149 | </center> | 176 | </center> | ... | ... |
... | @@ -89,7 +89,8 @@ | ... | @@ -89,7 +89,8 @@ |
89 | 89 | ||
90 | $.ajax({ | 90 | $.ajax({ |
91 | url : "/action_front.php?cmd=AdminProductionSpec.saveProductionSpec", | 91 | url : "/action_front.php?cmd=AdminProductionSpec.saveProductionSpec", |
92 | async : false, | 92 | async : false,\ |
93 | |||
93 | cache : false, | 94 | cache : false, |
94 | dataType : "json", | 95 | dataType : "json", |
95 | data : data, | 96 | data : data, |
... | @@ -196,7 +197,6 @@ | ... | @@ -196,7 +197,6 @@ |
196 | <td class="center" colspan='7'> | 197 | <td class="center" colspan='7'> |
197 | <input type="text" name="vehicleTON" style="width:5%;" value="<?=$info["vehicleTON"]?>" /> TON | 198 | <input type="text" name="vehicleTON" style="width:5%;" value="<?=$info["vehicleTON"]?>" /> TON |
198 | <input type="text" name="vehicleText" style="margin-right:50px;" value="<?=$info["vehicleText"]?>"/> | 199 | <input type="text" name="vehicleText" style="margin-right:50px;" value="<?=$info["vehicleText"]?>"/> |
199 | |||
200 | <input type="radio" name="vehicleType" value="HY" <?=$info["vehicleType"] == "HY" ? "CHECKED" : "" ?>>현대 | 200 | <input type="radio" name="vehicleType" value="HY" <?=$info["vehicleType"] == "HY" ? "CHECKED" : "" ?>>현대 |
201 | <input type="radio" name="vehicleType" value="DW" <?=$info["vehicleType"] == "DW" ? "CHECKED" : "" ?>>대우 | 201 | <input type="radio" name="vehicleType" value="DW" <?=$info["vehicleType"] == "DW" ? "CHECKED" : "" ?>>대우 |
202 | <input type="radio" name="vehicleType" value="VV" <?=$info["vehicleType"] == "VV" ? "CHECKED" : "" ?>>볼보 | 202 | <input type="radio" name="vehicleType" value="VV" <?=$info["vehicleType"] == "VV" ? "CHECKED" : "" ?>>볼보 |
... | @@ -275,7 +275,7 @@ | ... | @@ -275,7 +275,7 @@ |
275 | <input type="radio" name="floor" value="C" <?=$info["floor"] == "C" ? "CHECKED" : "" ?>>체크 | 275 | <input type="radio" name="floor" value="C" <?=$info["floor"] == "C" ? "CHECKED" : "" ?>>체크 |
276 | <input type="radio" name="floor" value="P" <?=$info["floor"] == "P" ? "CHECKED" : "" ?>>민판 | 276 | <input type="radio" name="floor" value="P" <?=$info["floor"] == "P" ? "CHECKED" : "" ?>>민판 |
277 | <input type="text" name="floorValueT" style='width:5%;' value="<?=$info["floorValueT"]?>"/> T | 277 | <input type="text" name="floorValueT" style='width:5%;' value="<?=$info["floorValueT"]?>"/> T |
278 | <input type="text" name="floorValue" style='margin-left:45px;' value="<?=$info["floorValueText"]?>" /> | 278 | <input type="text" name="floorValueText" style='margin-left:45px;' value="<?=$info["floorValueText"]?>" /> |
279 | </td> | 279 | </td> |
280 | </tr> | 280 | </tr> |
281 | <tr> | 281 | <tr> | ... | ... |
... | @@ -252,12 +252,14 @@ if(! class_exists("ApiBase") ) { | ... | @@ -252,12 +252,14 @@ if(! class_exists("ApiBase") ) { |
252 | $loginInfo["isLogin"] = $result[0][0]["po_returnCode"]; | 252 | $loginInfo["isLogin"] = $result[0][0]["po_returnCode"]; |
253 | $loginInfo["loginMessage"] = $result[0][0]["po_returnMsg"]; | 253 | $loginInfo["loginMessage"] = $result[0][0]["po_returnMsg"]; |
254 | $loginInfo["loginInfo"] = $this->inFn_ApiBase_getInfoOfUser($loginParams[0]); | 254 | $loginInfo["loginInfo"] = $this->inFn_ApiBase_getInfoOfUser($loginParams[0]); |
255 | /* | ||
255 | if($loginParams[5]!=$loginInfo["loginInfo"]["userPwd"]){ | 256 | if($loginParams[5]!=$loginInfo["loginInfo"]["userPwd"]){ |
256 | $loginInfo["loginInfo"]=""; | 257 | $loginInfo["loginInfo"]=""; |
257 | $loginInfo["isLogin"]="-1000"; | 258 | $loginInfo["isLogin"]="-1000"; |
258 | $loginInfo["loginMessage"]="비밀번호를 확인하세요"; | 259 | $loginInfo["loginMessage"]="비밀번호를 확인하세요"; |
259 | return $loginInfo; | 260 | return $loginInfo; |
260 | } | 261 | } |
262 | */ | ||
261 | 263 | ||
262 | LoginUtil::doAppLogin($loginInfo["loginInfo"]); | 264 | LoginUtil::doAppLogin($loginInfo["loginInfo"]); |
263 | } | 265 | } | ... | ... |
... | @@ -27,7 +27,7 @@ if (! class_exists("ApiBoard")) | ... | @@ -27,7 +27,7 @@ if (! class_exists("ApiBoard")) |
27 | $this->setPageForDevice($this->rownum); | 27 | $this->setPageForDevice($this->rownum); |
28 | 28 | ||
29 | $sql=" | 29 | $sql=" |
30 | SELECT * | 30 | SELECT noticeNo, title |
31 | FROM tblNotice | 31 | FROM tblNotice |
32 | WHERE status=1 | 32 | WHERE status=1 |
33 | ORDER BY noticeNo DESC | 33 | ORDER BY noticeNo DESC |
... | @@ -64,7 +64,7 @@ if (! class_exists("ApiBoard")) | ... | @@ -64,7 +64,7 @@ if (! class_exists("ApiBoard")) |
64 | $this->setPageForDevice($this->rownum); | 64 | $this->setPageForDevice($this->rownum); |
65 | 65 | ||
66 | $sql=" | 66 | $sql=" |
67 | SELECT * | 67 | SELECT eventNo, title |
68 | FROM tblEvent | 68 | FROM tblEvent |
69 | WHERE status=1 | 69 | WHERE status=1 |
70 | ORDER BY eventNo DESC | 70 | ORDER BY eventNo DESC |
... | @@ -121,8 +121,8 @@ if (! class_exists("ApiBoard")) | ... | @@ -121,8 +121,8 @@ if (! class_exists("ApiBoard")) |
121 | $imgResult = $this->inFn_Common_fileSave($_FILES); | 121 | $imgResult = $this->inFn_Common_fileSave($_FILES); |
122 | 122 | ||
123 | $title=$this->req["title"]; | 123 | $title=$this->req["title"]; |
124 | //$userFk = $this->appUser["no"]; | 124 | $userFk = $this->appUser["no"]; |
125 | $userFk=$this->req["userFk"]; | 125 | //$userFk=$this->req["userFk"]; |
126 | 126 | ||
127 | $imgPathBoard1 = $imgResult["imgPathBoard1"]["saveURL"] != null ? $imgResult["imgPathBoard1"]["saveURL"] : $this->req["imgPathBoard1"]; | 127 | $imgPathBoard1 = $imgResult["imgPathBoard1"]["saveURL"] != null ? $imgResult["imgPathBoard1"]["saveURL"] : $this->req["imgPathBoard1"]; |
128 | $imgPathBoard2 = $imgResult["imgPathBoard2"]["saveURL"] != null ? $imgResult["imgPathBoard2"]["saveURL"] : $this->req["imgPathBoard2"]; | 128 | $imgPathBoard2 = $imgResult["imgPathBoard2"]["saveURL"] != null ? $imgResult["imgPathBoard2"]["saveURL"] : $this->req["imgPathBoard2"]; |
... | @@ -186,7 +186,7 @@ if (! class_exists("ApiBoard")) | ... | @@ -186,7 +186,7 @@ if (! class_exists("ApiBoard")) |
186 | $this->setPageForDevice($this->rownum); | 186 | $this->setPageForDevice($this->rownum); |
187 | 187 | ||
188 | $sql=" | 188 | $sql=" |
189 | SELECT B.*, U.userID, U.userNo | 189 | SELECT B.boardNo, B.title, U.userID, U.userNo |
190 | FROM tblBoard B | 190 | FROM tblBoard B |
191 | JOIN tblUser U ON B.userFk=U.userNo | 191 | JOIN tblUser U ON B.userFk=U.userNo |
192 | {$where} | 192 | {$where} | ... | ... |
... | @@ -46,6 +46,9 @@ if (! class_exists("ApiUser")) | ... | @@ -46,6 +46,9 @@ if (! class_exists("ApiUser")) |
46 | function checkIDRedundancy(){ | 46 | function checkIDRedundancy(){ |
47 | $userID=$this->req["userID"]; | 47 | $userID=$this->req["userID"]; |
48 | 48 | ||
49 | if($userID == "") | ||
50 | return $this->makeResultJson(-1, "아이디 입력 후 시도해 주세요"); | ||
51 | |||
49 | $sql=" | 52 | $sql=" |
50 | SELECT * | 53 | SELECT * |
51 | FROM tblUser | 54 | FROM tblUser |
... | @@ -63,6 +66,9 @@ if (! class_exists("ApiUser")) | ... | @@ -63,6 +66,9 @@ if (! class_exists("ApiUser")) |
63 | function checkNickRedundancy(){ | 66 | function checkNickRedundancy(){ |
64 | $nickName=$this->req["nickName"]; | 67 | $nickName=$this->req["nickName"]; |
65 | 68 | ||
69 | if($nickName == "") | ||
70 | return $this->makeResultJson(-1, "닉네임 입력 후 시도해 주세요"); | ||
71 | |||
66 | $sql=" | 72 | $sql=" |
67 | SELECT * | 73 | SELECT * |
68 | FROM tblUser | 74 | FROM tblUser |
... | @@ -77,6 +83,8 @@ if (! class_exists("ApiUser")) | ... | @@ -77,6 +83,8 @@ if (! class_exists("ApiUser")) |
77 | return $this->makeResultJson(1, "사용할 수 있는 닉네임 입니다"); | 83 | return $this->makeResultJson(1, "사용할 수 있는 닉네임 입니다"); |
78 | } | 84 | } |
79 | 85 | ||
86 | |||
87 | |||
80 | // 회원 가입 (http://106.240.232.36:8004/action_front.php?cmd=ApiUser.memberJoin) | 88 | // 회원 가입 (http://106.240.232.36:8004/action_front.php?cmd=ApiUser.memberJoin) |
81 | function memberJoin() | 89 | function memberJoin() |
82 | { | 90 | { |
... | @@ -107,12 +115,21 @@ if (! class_exists("ApiUser")) | ... | @@ -107,12 +115,21 @@ if (! class_exists("ApiUser")) |
107 | "; | 115 | "; |
108 | $regInfo = $this->getRow($sql); | 116 | $regInfo = $this->getRow($sql); |
109 | 117 | ||
118 | |||
119 | |||
110 | if(strlen($userID) < 6) | 120 | if(strlen($userID) < 6) |
111 | return $this->makeResultJson(-106, "아이디는 여섯 자리 이상이어야 합니다."); | 121 | return $this->makeResultJson(-106, "아이디는 여섯 자리 이상이어야 합니다."); |
112 | 122 | ||
123 | if(strlen($userID) != strlen($this->removeSpecials($userID))) { | ||
124 | return $this->makeResultJson(-108, "아이디에는 특수문자가 포함될 수 없습니다."); | ||
125 | } | ||
126 | |||
113 | if($regInfo != null) | 127 | if($regInfo != null) |
114 | return $this->makeResultJson(-100, "아이디 중복을 확인해 주세요."); | 128 | return $this->makeResultJson(-100, "아이디 중복을 확인해 주세요."); |
115 | 129 | ||
130 | if($nickName == "") | ||
131 | return $this->makeResultJson(-107, "닉네임을 입력해 주세요"); | ||
132 | |||
116 | $sql="SELECT * FROM tblUser WHERE nickName='{$nickName} AND status=1'"; | 133 | $sql="SELECT * FROM tblUser WHERE nickName='{$nickName} AND status=1'"; |
117 | $regInfo=$this->getRow($sql); | 134 | $regInfo=$this->getRow($sql); |
118 | 135 | ||
... | @@ -127,6 +144,9 @@ if (! class_exists("ApiUser")) | ... | @@ -127,6 +144,9 @@ if (! class_exists("ApiUser")) |
127 | 144 | ||
128 | if($userPwd != $userPwdConfirm) | 145 | if($userPwd != $userPwdConfirm) |
129 | return $this->makeResultJson(-105, "비밀번호가 일치하지 않습니다."); | 146 | return $this->makeResultJson(-105, "비밀번호가 일치하지 않습니다."); |
147 | |||
148 | if($userName == "") | ||
149 | return $this->makeResultJson(-102, "이름을 입력해 주세요."); | ||
130 | /* | 150 | /* |
131 | if($userTel == "") | 151 | if($userTel == "") |
132 | return $this->makeResultJson(-105, "전화번호는 필수 입력사항입니다."); | 152 | return $this->makeResultJson(-105, "전화번호는 필수 입력사항입니다."); |
... | @@ -157,6 +177,8 @@ if (! class_exists("ApiUser")) | ... | @@ -157,6 +177,8 @@ if (! class_exists("ApiUser")) |
157 | $result = $this->techOfInsertForUpdate("tblUser", $insAssoc); | 177 | $result = $this->techOfInsertForUpdate("tblUser", $insAssoc); |
158 | 178 | ||
159 | $no = $this->mysql_insert_id(); | 179 | $no = $this->mysql_insert_id(); |
180 | |||
181 | $userInfo = $this->inFn_ApiBase_getInfoOfUser($no); | ||
160 | /* | 182 | /* |
161 | $file_vir_name = ""; | 183 | $file_vir_name = ""; |
162 | $file_org_name = ""; | 184 | $file_org_name = ""; |
... | @@ -197,6 +219,18 @@ if (! class_exists("ApiUser")) | ... | @@ -197,6 +219,18 @@ if (! class_exists("ApiUser")) |
197 | return $this->makeResultJson($returnCode, $returnMessage, $userInfo); | 219 | return $this->makeResultJson($returnCode, $returnMessage, $userInfo); |
198 | } | 220 | } |
199 | 221 | ||
222 | function checkExpire($userNo, $expireDate){ | ||
223 | |||
224 | if(date('Y-m-d', $expireDate) <= date('Y-m-d')){ | ||
225 | $sql=" | ||
226 | UPDATE tblUser | ||
227 | SET status=0 | ||
228 | WHERE userNo='{$userNo}' | ||
229 | "; | ||
230 | $this->update($sql); | ||
231 | return 1; | ||
232 | } | ||
233 | } | ||
200 | 234 | ||
201 | // 회원 로그인 (http://106.240.232.36:8004/action_front.php?cmd=ApiUser.userLogin) | 235 | // 회원 로그인 (http://106.240.232.36:8004/action_front.php?cmd=ApiUser.userLogin) |
202 | function userLogin() | 236 | function userLogin() |
... | @@ -225,6 +259,9 @@ if (! class_exists("ApiUser")) | ... | @@ -225,6 +259,9 @@ if (! class_exists("ApiUser")) |
225 | $userInfo = $this->inFn_ApiBase_getInfoOfUser($result[0][0]["v_userNumber"]); | 259 | $userInfo = $this->inFn_ApiBase_getInfoOfUser($result[0][0]["v_userNumber"]); |
226 | //echo $userPwd; | 260 | //echo $userPwd; |
227 | //echo $userInfo["userID"]; | 261 | //echo $userInfo["userID"]; |
262 | $res=$this->checkExpire($userInfo["userNo"], $userInfo["expireDate"]); | ||
263 | if($res=1) | ||
264 | return $this->makeResultJson(-999, "탈퇴된 회원입니다"); | ||
228 | if($userInfo["userPwd"] != $userPwd) | 265 | if($userInfo["userPwd"] != $userPwd) |
229 | return $this->makeResultJson("-1000", "비밀번호를 확인하세요"); | 266 | return $this->makeResultJson("-1000", "비밀번호를 확인하세요"); |
230 | 267 | ||
... | @@ -239,7 +276,7 @@ if (! class_exists("ApiUser")) | ... | @@ -239,7 +276,7 @@ if (! class_exists("ApiUser")) |
239 | } | 276 | } |
240 | 277 | ||
241 | function userAutoLogin(){ | 278 | function userAutoLogin(){ |
242 | $userNumber=$this->req["userNumber"]; | 279 | $userNo=$this->req["userNo"]; |
243 | $userID = $this->req["userID"]; | 280 | $userID = $this->req["userID"]; |
244 | $deviceID = $this->req["deviceID"]; | 281 | $deviceID = $this->req["deviceID"]; |
245 | $deviceTypeID = $this->req["deviceTypeID"]; | 282 | $deviceTypeID = $this->req["deviceTypeID"]; |
... | @@ -247,8 +284,15 @@ if (! class_exists("ApiUser")) | ... | @@ -247,8 +284,15 @@ if (! class_exists("ApiUser")) |
247 | $appVersion = $this->req["appVersion"]; | 284 | $appVersion = $this->req["appVersion"]; |
248 | $userPwd=md5($this->req["userPwd"]); | 285 | $userPwd=md5($this->req["userPwd"]); |
249 | 286 | ||
287 | |||
288 | $sql="SELECT expireDate FROM tblUser WHERE userNo='{$userNo}' AND status=1 LIMIT 1"; | ||
289 | $expireDate=$this->getValue($sql, "expireDate"); | ||
290 | $res=$this->checkExpire($userNo, $expireDate); | ||
291 | if($res=1) | ||
292 | return $this->makeResultJson(-999, "탈퇴된 회원입니다"); | ||
293 | |||
250 | $param = Array( | 294 | $param = Array( |
251 | $userNumber, | 295 | $userNo, |
252 | $deviceID, | 296 | $deviceID, |
253 | $deviceTypeID, | 297 | $deviceTypeID, |
254 | $registrationKey, | 298 | $registrationKey, |
... | @@ -262,6 +306,7 @@ if (! class_exists("ApiUser")) | ... | @@ -262,6 +306,7 @@ if (! class_exists("ApiUser")) |
262 | 306 | ||
263 | } | 307 | } |
264 | 308 | ||
309 | |||
265 | // 비동기 푸시키 갱신 API | 310 | // 비동기 푸시키 갱신 API |
266 | function setUserRegistrationKey() | 311 | function setUserRegistrationKey() |
267 | { | 312 | { |
... | @@ -316,7 +361,7 @@ if (! class_exists("ApiUser")) | ... | @@ -316,7 +361,7 @@ if (! class_exists("ApiUser")) |
316 | { | 361 | { |
317 | $userNo = $this->appUser["no"]; | 362 | $userNo = $this->appUser["no"]; |
318 | //$is_file_change = $this->req["is_file_change"]; // NEW / DEL / NON | 363 | //$is_file_change = $this->req["is_file_change"]; // NEW / DEL / NON |
319 | 364 | //$userNo=$this->req["userNo"]; | |
320 | $userPwd = $this->req["userPwd"]; | 365 | $userPwd = $this->req["userPwd"]; |
321 | $userPwdConfirm = $this->req["userPwdConfirm"]; | 366 | $userPwdConfirm = $this->req["userPwdConfirm"]; |
322 | $nickName = $this->req["nickName"]; | 367 | $nickName = $this->req["nickName"]; |
... | @@ -362,8 +407,25 @@ if (! class_exists("ApiUser")) | ... | @@ -362,8 +407,25 @@ if (! class_exists("ApiUser")) |
362 | if($userPwd != $userPwdConfirm) | 407 | if($userPwd != $userPwdConfirm) |
363 | return $this->makeResultJson(-101, "비밀번호 가 일치하지 않습니다"); | 408 | return $this->makeResultJson(-101, "비밀번호 가 일치하지 않습니다"); |
364 | 409 | ||
410 | $userPwd=md5($userPwd); | ||
411 | |||
412 | if($userPwd==""){ | ||
365 | $sql = " | 413 | $sql = " |
366 | UPDATE tbl_user | 414 | UPDATE tblUser |
415 | SET | ||
416 | nickName='{$nickName}', | ||
417 | userTel='{$userTel}', | ||
418 | userVehicleTON='{$userVehicleTON}', | ||
419 | userVehicleName='{$userVehicleName}', | ||
420 | userVehicleType='{$userVehicleType}', | ||
421 | userVehicleWish='{$userVehicleWish}' | ||
422 | WHERE `userNo` = '{$userNo}' | ||
423 | "; | ||
424 | $this->update($sql); | ||
425 | } | ||
426 | else{ | ||
427 | $sql = " | ||
428 | UPDATE tblUser | ||
367 | SET | 429 | SET |
368 | userPwd='{$userPwd}', | 430 | userPwd='{$userPwd}', |
369 | nickName='{$nickName}', | 431 | nickName='{$nickName}', |
... | @@ -375,7 +437,7 @@ if (! class_exists("ApiUser")) | ... | @@ -375,7 +437,7 @@ if (! class_exists("ApiUser")) |
375 | WHERE `userNo` = '{$userNo}' | 437 | WHERE `userNo` = '{$userNo}' |
376 | "; | 438 | "; |
377 | $this->update($sql); | 439 | $this->update($sql); |
378 | 440 | } | |
379 | return $this->makeResultJson("1", "저장되었습니다.", $this->inFn_ApiBase_getInfoOfUser($userNo)); | 441 | return $this->makeResultJson("1", "저장되었습니다.", $this->inFn_ApiBase_getInfoOfUser($userNo)); |
380 | } | 442 | } |
381 | 443 | ||
... | @@ -393,22 +455,26 @@ if (! class_exists("ApiUser")) | ... | @@ -393,22 +455,26 @@ if (! class_exists("ApiUser")) |
393 | 455 | ||
394 | function delUser(){ | 456 | function delUser(){ |
395 | $userNo=$this->appUser["no"]; | 457 | $userNo=$this->appUser["no"]; |
396 | 458 | $userNo=$this->req["no"]; | |
397 | $sql=" | 459 | $sql=" |
398 | UPDATE tblUser | 460 | UPDATE tblUser |
399 | SET expireDate=DATE_FORMAT(NOW() + interval 3 DAY, '%Y%m%d') | 461 | SET expireDate=DATE_FORMAT(NOW() + interval 3 DAY, '%Y%m%d') |
400 | WHERE userNo='{$userNo}' AND status=1 | 462 | WHERE userNo='{$userNo}' AND status=1 |
401 | "; | 463 | "; |
464 | $this->update($sql); | ||
465 | return $this->makeResultJson("1", "탈퇴 신청이 완료되었습니다"); | ||
402 | } | 466 | } |
403 | 467 | ||
404 | function delCancel(){ | 468 | function delCancel(){ |
405 | $userNo=$this->appUser["no"]; | 469 | $userNo=$this->appUser["no"]; |
406 | 470 | $userNo=$this->req["no"]; | |
407 | $sql=" | 471 | $sql=" |
408 | UPDATE tblUser | 472 | UPDATE tblUser |
409 | SET expireDate=NULL | 473 | SET expireDate=NULL |
410 | WHERE userNo='{$userNo}' AND status=1 | 474 | WHERE userNo='{$userNo}' AND status=1 |
411 | "; | 475 | "; |
476 | $this->update($sql); | ||
477 | return $this->makeResultJson("1", "취소되었습니다"); | ||
412 | } | 478 | } |
413 | 479 | ||
414 | 480 | ... | ... |
... | @@ -143,7 +143,7 @@ $(document).ready(function(){ | ... | @@ -143,7 +143,7 @@ $(document).ready(function(){ |
143 | async : false, | 143 | async : false, |
144 | cache : false, | 144 | cache : false, |
145 | data:{ | 145 | data:{ |
146 | "userID" : "fishcreek1", | 146 | "userID" : "test111", |
147 | "userPwd": "alclsekf1", | 147 | "userPwd": "alclsekf1", |
148 | "deviceID" : "device", | 148 | "deviceID" : "device", |
149 | "deviceTypeID" : 2, | 149 | "deviceTypeID" : 2, |
... | @@ -190,11 +190,11 @@ $(document).ready(function(){ | ... | @@ -190,11 +190,11 @@ $(document).ready(function(){ |
190 | async : false, | 190 | async : false, |
191 | cache : false, | 191 | cache : false, |
192 | data:{ | 192 | data:{ |
193 | "userID" : "fishcreek1", | 193 | "userID" : "test111", |
194 | "userPwd" : "alclsekf1", | 194 | "userPwd" : "alclsekf1", |
195 | "userPwdConfirm" : "alclsekf1", | 195 | "userPwdConfirm" : "alclsekf1", |
196 | "userName" : "세호", | 196 | "userName" : "세호", |
197 | "nickName" : "fishcreek1", | 197 | "nickName" : "test1", |
198 | "userTel" : "01026264848", | 198 | "userTel" : "01026264848", |
199 | "userVehicleTON" : 21, | 199 | "userVehicleTON" : 21, |
200 | "userVehicleName" : "내장탑차", | 200 | "userVehicleName" : "내장탑차", |
... | @@ -323,6 +323,7 @@ $(document).ready(function(){ | ... | @@ -323,6 +323,7 @@ $(document).ready(function(){ |
323 | </head> | 323 | </head> |
324 | <body> | 324 | <body> |
325 | <div id="Contents" class="notice" style="width:1000px;" > | 325 | <div id="Contents" class="notice" style="width:1000px;" > |
326 | <?echo date('Y-m-d', $expireDate);?> | ||
326 | <form name=test1 method=POST> | 327 | <form name=test1 method=POST> |
327 | <span class="button bigrounded blue saveComment btnleft_y">댓글 저장 </span> | 328 | <span class="button bigrounded blue saveComment btnleft_y">댓글 저장 </span> |
328 | <span class="button bigrounded blue saveBoard btnleft_y">게시물 저장 </span> | 329 | <span class="button bigrounded blue saveBoard btnleft_y">게시물 저장 </span> | ... | ... |
9.56 KB
-
Please register or sign in to post a comment