|
@@ -7,10 +7,11 @@ use think\facade\Db;
|
|
|
|
|
|
class Consult extends Base
|
|
|
{
|
|
|
-
|
|
|
+ public $noble=[];
|
|
|
public function __construct(App $app)
|
|
|
{
|
|
|
parent::__construct($app);
|
|
|
+ $this->noble =\think\facade\Config::get("noble");
|
|
|
}
|
|
|
// public function list(){
|
|
|
// $page = isset($this->post['page']) && $this->post['page'] !== "" ? intval($this->post['page']) :"1";
|
|
@@ -118,6 +119,7 @@ class Consult extends Base
|
|
|
$kh=Db::name("customer_info")->where(['companyNo'=>$value['khNo']])->find();
|
|
|
$value['khname']= isset($kh['companyName'])?$kh['companyName']:"";
|
|
|
}
|
|
|
+ $value['metal_name']=isset($value['metal_id'])&& $value['metal_id']!=0?$this->noble[$value['metal_id']]:"";
|
|
|
$data[]=$value;
|
|
|
}
|
|
|
return app_show(0,"获取成功",['count'=>$count,'list'=>$data]);
|
|
@@ -457,7 +459,9 @@ class Consult extends Base
|
|
|
$zxinfo['budget_total']="";
|
|
|
$zxinfo['departinfo']=[];
|
|
|
$zxinfo['unit_name']="";
|
|
|
+ $zxinfo['metal_name']=isset($zxinfo['metal_id'])&& $zxinfo['metal_id']!=0?$this->noble[$zxinfo['metal_id']]:"";
|
|
|
$zxinfo['specinfo']=json_decode($zxinfo['specinfo'],true);
|
|
|
+
|
|
|
if($zxorder['khNo']!==""){
|
|
|
$kh=Db::name("customer_info")->where(['companyNo'=>$zxorder['khNo']])->find();
|
|
|
$zxinfo['khname']= isset($kh['companyName'])?$kh['companyName']:"";
|
|
@@ -762,6 +766,7 @@ class Consult extends Base
|
|
|
$metal_id = isset($this->post['metal_id'])&&$this->post['metal_id']!=""? intval($this->post['metal_id']):"";
|
|
|
$is_gold_price = isset($this->post['is_gold_price'])&&$this->post['is_gold_price']!=""? intval($this->post['is_gold_price']):"";
|
|
|
$config = isset($this->post['config'])&&$this->post['config']!=""? $this->post['config']:"";
|
|
|
+ $other_config = isset($this->post['other_config'])&&$this->post['other_config']!=""? $this->post['other_config']:"";
|
|
|
$weight = isset($this->post['weight'])&&$this->post['weight']!=""? floatval($this->post['weight']):"";
|
|
|
$demo_fee = isset($this->post['demo_fee'])&&$this->post['demo_fee']!=""? floatval($this->post['demo_fee']):"";
|
|
|
$delivery_fee = isset($this->post['delivery_fee'])&&$this->post['delivery_fee']!=""? floatval($this->post['delivery_fee']):"";
|
|
@@ -813,6 +818,7 @@ class Consult extends Base
|
|
|
"metal_id"=>$metal_id,
|
|
|
"is_gold_price"=>$is_gold_price,
|
|
|
"config"=>$config,
|
|
|
+ "other_config"=>$other_config,
|
|
|
"weight"=>$weight,
|
|
|
"is_diff"=>$is_diff,
|
|
|
"demo_fee"=>$demo_fee,
|
|
@@ -923,6 +929,7 @@ class Consult extends Base
|
|
|
}
|
|
|
$info['specinfo'] = json_decode($info['specinfo'],true);
|
|
|
$info['sale_price'] =round($price,2);
|
|
|
+ $info['metal_name']=isset($info['metal_id'])&& $info['metal_id']!=0?$this->noble[$info['metal_id']]:"";
|
|
|
$bargain =Db::name("bargain_order")->where(['bidsNo'=>$bidNo,"is_del"=>0])->find();
|
|
|
$info['bargain'] =$bargain;
|
|
|
return app_show(0,"获取成功",$info);
|
|
@@ -985,6 +992,7 @@ class Consult extends Base
|
|
|
$metal_id = isset($this->post['metal_id'])&&$this->post['metal_id']!=""? intval($this->post['metal_id']):"";
|
|
|
$is_gold_price = isset($this->post['is_gold_price'])&&$this->post['is_gold_price']!=""? intval($this->post['is_gold_price']):"";
|
|
|
$config = isset($this->post['config'])&&$this->post['config']!=""? $this->post['config']:"";
|
|
|
+ $other_config = isset($this->post['other_config'])&&$this->post['other_config']!=""? $this->post['other_config']:"";
|
|
|
$weight = isset($this->post['weight'])&&$this->post['weight']!=""? floatval($this->post['weight']):"";
|
|
|
$demo_fee = isset($this->post['demo_fee'])&&$this->post['demo_fee']!=""? floatval($this->post['demo_fee']):"";
|
|
|
$delivery_fee = isset($this->post['delivery_fee'])&&$this->post['delivery_fee']!=""? floatval($this->post['delivery_fee']):"";
|
|
@@ -1018,6 +1026,7 @@ class Consult extends Base
|
|
|
"metal_id"=>$metal_id,
|
|
|
"is_gold_price"=>$is_gold_price,
|
|
|
"config"=>$config,
|
|
|
+ "other_config"=>$other_config,
|
|
|
"weight"=>$weight,
|
|
|
"is_diff"=>$is_diff,
|
|
|
"demo_fee"=>$demo_fee,
|
|
@@ -1201,7 +1210,6 @@ class Consult extends Base
|
|
|
$data=[];
|
|
|
foreach ($list as $value){
|
|
|
$catinfo = Db::name("cat")->where(["id"=>$value['cat_id']])->find();
|
|
|
-
|
|
|
$value['can']= isset($value['cat_id']) && $value['cat_id'] !=0 ? made($value['cat_id']):[];
|
|
|
$unit =Db::name("unit")->where(["id"=>$value['unit_id']])->find();
|
|
|
$value['unit'] = isset($unit['unit'])?$unit['unit']:'';
|
|
@@ -1235,7 +1243,7 @@ class Consult extends Base
|
|
|
$price = GoodPrice($god, $budget/100);
|
|
|
}
|
|
|
$value['specinfo'] = json_decode($value['specinfo'],true);
|
|
|
-
|
|
|
+ $value['metal_name']=isset($value['metal_id'])&& $value['metal_id']!=0?$this->noble[$value['metal_id']]:"";
|
|
|
$value['sale_price'] =round($price,2);
|
|
|
$value['bargain_status']=$bidinfo['bargain_status'];
|
|
|
$data[]=$value;
|
|
@@ -1311,6 +1319,7 @@ class Consult extends Base
|
|
|
}else{
|
|
|
$price = GoodPrice($god, $budget/100);
|
|
|
}
|
|
|
+ $value['metal_name']=isset($value['metal_id'])&& $value['metal_id']!=0?$this->noble[$value['metal_id']]:"";
|
|
|
$value['sale_price'] =round($price,2);
|
|
|
$value['specinfo'] = json_decode($value['specinfo'],true);
|
|
|
$value['bargain_status']=$bidinfo['bargain_status'];
|