Commit 941e78fe authored by hujun's avatar hujun

vip 盘

parent de134f7a
...@@ -768,4 +768,39 @@ class Houses extends Basic ...@@ -768,4 +768,39 @@ class Houses extends Basic
return $this->response($code, $msg, []); return $this->response($code, $msg, []);
} }
/**
* 是否对C端显示
*
* @return \think\Response
*/
public function vipHouse() {
$code = 200;
$msg = '';
$house_check = new HouseValidate();
$check = $house_check->scene('vip')->check($this->params);
if (true !== $check) {
return $this->response(101, $house_check->getError());
}
try {
$house = new GHouses();
$house_data = $house->getHouseDetail('id,vip', ['id'=>$this->params['id']]);
if (empty($house_data['id'])) {
$code = 101;
$msg = '没有该商铺';
} else {
if ($house_data['vip'] != $this->params['vip']) {
$house->editData(['vip'=> $this->params['vip']], $this->params['id']);
}
}
} catch (\Exception $e) {
$code = 101;
$msg = $e->getMessage();
}
return $this->response($code, $msg, []);
}
} }
\ No newline at end of file
...@@ -87,6 +87,7 @@ class HouseValidate extends Validate ...@@ -87,6 +87,7 @@ class HouseValidate extends Validate
'add' => ['internal_title', 'internal_address', 'province', 'city', 'disc', 'market_area', 'shop_area_start', 'rent_type', 'add' => ['internal_title', 'internal_address', 'province', 'city', 'disc', 'market_area', 'shop_area_start', 'rent_type',
'rent_price', 'industry_type', 'shop_type', 'shop_sign', 'management_fee', 'slotting_fee', 'residue_num', 'rent_price', 'industry_type', 'shop_type', 'shop_sign', 'management_fee', 'slotting_fee', 'residue_num',
'total', 'longitude', 'latitude', 'fee_rule', 'fee_rule', 'business_district_id'], 'total', 'longitude', 'latitude', 'fee_rule', 'fee_rule', 'business_district_id'],
'show' => 'id,is_show' 'show' => 'id,is_show',
'vip' => 'id,vip'
]; ];
} }
\ No newline at end of file
...@@ -114,7 +114,8 @@ Route::group('index', [ ...@@ -114,7 +114,8 @@ Route::group('index', [
'transformLandlord' => [ 'index/houses/transformLandlord', [ 'method' => 'post' ] ],//转换房东手机号 'transformLandlord' => [ 'index/houses/transformLandlord', [ 'method' => 'post' ] ],//转换房东手机号
'lockHouse' => [ 'index/houses/lockHouse', [ 'method' => 'post' ] ],//锁盘 'lockHouse' => [ 'index/houses/lockHouse', [ 'method' => 'post' ] ],//锁盘
'getEditLog' => [ 'index/houses/getEditLog', [ 'method' => 'get' ] ],//商铺修改日志 'getEditLog' => [ 'index/houses/getEditLog', [ 'method' => 'get' ] ],//商铺修改日志
'isShow' => [ 'index/houses/isShow', [ 'method' => 'POST' ] ],//是否对C端显示 'isShow' => [ 'index/houses/isShow', [ 'method' => 'POST' ] ],//是否对C端显示
'vipHouse' => [ 'index/houses/vipHouse', [ 'method' => 'POST' ] ],//vip盘
//版本管理 //版本管理
'version' => [ 'index/version/index', [ 'method' => 'get' ] ], 'version' => [ 'index/version/index', [ 'method' => 'get' ] ],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment