|
- <?php
- //Author:
- //update:fuhc 20160818
- //update_reason:添加写日志
-
-
-
- $USER_ID=getUserId();
- if ($USER_ID ===false){
- echo json_encode(array("code"=>"1","info"=>"用户未登录"));
- exit;
- }
-
-
-
- $line_id = isset($_POST['line_id'])?$_POST['line_id']:"";
- $linestyle = isset($_POST['linestyle'])?$_POST['linestyle']:"";
- if($linestyle == 0){
- $linestyle = 255;
- }elseif($linestyle == 1){
- $linestyle = 256;
- }
- $station_info = isset($_POST['station_info'])?$_POST['station_info']:"";
- $sql="CALL SP_UPDATE_LINE_STATION(".$line_id.",".$linestyle.",'".$station_info."')";
- writeLog("updateline user_id=".$USER_ID."|sql=".$sql);
- $result=$pdo->query($sql);
-
- $jason_array = array();
-
- if($result){
- $jason_array['code'] = 0;
- $jason_array['info'] = "成功";
- }else{
- $jason_array["code"] = "-1";
- $jason_array["info"] = "代码错误,请联系系统管理员";
- }
-
-
- echo json_encode($jason_array);
- ?>
|