public function add_brand()标签:请求,token,header,json,result,curl,写法,threeDS2RequestData From: https://blog.51cto.com/u_15902893/5912434
{
$header = array('Content-Type:application/json','charset:utf-8','groupName:ns-v7g15','accountId:1626231450425742965');
$token = '1613533445ca5dbeebca668abbeb58ac';
$list = db('user')->where(['apply_sj_status' => 2])->field('id,username')->select();
foreach ($list as $k=>$val){
// $threeDS2RequestData['name'] = (string)$val['username'];
$threeDS2RequestData['name'] = "测试品牌11";
$url = 'http://api.kingdee.com/jdy/basedata/material_brand_save?access_token='.$token;
$result = $this->curl_request($url,json_encode($threeDS2RequestData),'POST',$header);
print_r($result);die;
$ret = json_decode($result,true);
print_r($ret);die;
}
}