|
1234567891011121314151617181920212223242526272829 |
- <?php
- require_once "../Common/Config.php";
- $openid=$_COOKIE['wxopenid'];
- $id=$_GET["id"];
- $name=$_GET["name"];
- $mobile=$_GET["mobile"];
- $idno=$_GET["idno"];
- $sql="APP_MEMBER_LINKER_EDIT '{$openid}',{$id},'{$name}','{$mobile}',0,'{$idno}'";
- $pdo = new PDO("sqlsrv:Server=".HOST.";Database=".DB, USER, PASSWORD);//5.6版本pdo连接sqlsrv
- $result=$pdo->query($sql);
- $rowset = $result->fetchAll(PDO::FETCH_ASSOC);
- $linker_count=isset($rowset[0]["LINKER_COUNT"])?$rowset[0]["LINKER_COUNT"]:0;
- $data=array(
- "code"=>$rowset[0]["ERRCODE"],
- "info"=>$rowset[0]["ERRINFO"]
- );
- if ($linker_count >0){
- foreach ($rowset as $v){
- $val=array();
- $val["customer_id"]=$v["ID"];
- $val["customer_name"]=$v["CUSTOMER_NAME"];
- $val["customer_mobile"]=$v["CUSTOMER_MOBILE"];
- $val["customer_idtype"]=$v["CUSTOMER_ID_TYPE"];
- $val["customer_idno"]=$v["CUSTOMER_ID_NO"];
-
- $data["order_list"][]=$val;
- }
- }
- echo json_encode($data);
|