|
@@ -28,6 +28,11 @@ class NurseServiceController extends AdminController
|
|
$grid = new Grid(new Organization());
|
|
$grid = new Grid(new Organization());
|
|
$grid->column('name', __('社区医院'));
|
|
$grid->column('name', __('社区医院'));
|
|
$type = request('product_type',5);
|
|
$type = request('product_type',5);
|
|
|
|
+
|
|
|
|
+ $org_id = \Admin::user()->org_id;
|
|
|
|
+ if(!empty($org_id)){
|
|
|
|
+ $grid->model()->where(['id'=>$org_id]);
|
|
|
|
+ }
|
|
$grid->column('orders', __('总订单数'))->display(function () use ($type) {
|
|
$grid->column('orders', __('总订单数'))->display(function () use ($type) {
|
|
return Order::where('organization_id',$this->id)->where('product_type',$type)->count();
|
|
return Order::where('organization_id',$this->id)->where('product_type',$type)->count();
|
|
});
|
|
});
|