订单详情不加诊所限制(给互联网医院转的在线复诊留口子)
This commit is contained in:
@@ -123,7 +123,7 @@ class SystemNoticeController extends BaseAppController
|
|||||||
'scene_type' => 1,
|
'scene_type' => 1,
|
||||||
'user_id' => \Yii::$app->user->identity->id,
|
'user_id' => \Yii::$app->user->identity->id,
|
||||||
'base_type' => 6
|
'base_type' => 6
|
||||||
])->groupBy('notice_at')->orderBy('notice_at DESC');
|
])->orderBy('notice_at DESC');
|
||||||
|
|
||||||
|
|
||||||
$this->field = [
|
$this->field = [
|
||||||
@@ -171,18 +171,18 @@ class SystemNoticeController extends BaseAppController
|
|||||||
$type = $post['type'];
|
$type = $post['type'];
|
||||||
switch ($type) {
|
switch ($type) {
|
||||||
case 'all':
|
case 'all':
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND user_id='.\Yii::$app->user->identity->id.' AND store_id='.$post['store_id'])->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND user_id='.\Yii::$app->user->identity->id/*.' AND store_id='.$post['store_id']*/)->execute();
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=99 AND user_id='.\Yii::$app->user->identity->id)->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=99 AND user_id='.\Yii::$app->user->identity->id)->execute();
|
||||||
break;
|
break;
|
||||||
case 'system':
|
case 'system':
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND (base_type=3 or base_type=4 or base_type=5 or base_type=7) AND user_id='.\Yii::$app->user->identity->id.' AND store_id='.$post['store_id'])->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND (base_type=3 or base_type=4 or base_type=5 or base_type=7) AND user_id='.\Yii::$app->user->identity->id/*.' AND store_id='.$post['store_id']*/)->execute();
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=99 AND user_id='.\Yii::$app->user->identity->id)->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=99 AND user_id='.\Yii::$app->user->identity->id)->execute();
|
||||||
break;
|
break;
|
||||||
case 'order':
|
case 'order':
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=1 AND user_id='.\Yii::$app->user->identity->id.' AND store_id='.$post['store_id'])->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=1 AND user_id='.\Yii::$app->user->identity->id/*.' AND store_id='.$post['store_id']*/)->execute();
|
||||||
break;
|
break;
|
||||||
case 'doctor_news':
|
case 'doctor_news':
|
||||||
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=6 AND user_id='.\Yii::$app->user->identity->id.' AND store_id='.$post['store_id'])->execute();
|
\Yii::$app->db->createCommand()->update(SystemNotice::tableName(), ['read_status' => '1'], 'read_status=0 AND scene_type=1 AND base_type=6 AND user_id='.\Yii::$app->user->identity->id/*.' AND store_id='.$post['store_id']*/)->execute();
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Exception('错误的type');
|
throw new Exception('错误的type');
|
||||||
|
|||||||
Reference in New Issue
Block a user