PreOrder fixes
This commit is contained in:
parent
7fd8122251
commit
a7d1c5e518
|
|
@ -13,8 +13,12 @@ class EventServiceProvider extends ServiceProvider
|
|||
* @var array
|
||||
*/
|
||||
protected $listen = [
|
||||
// 'Illuminate\Auth\Events\Attempting' => [
|
||||
// 'Webkul\AdminAuthCheck\Listeners\LoginAuthenticationAttempt'
|
||||
// ], // make use of this to stop admins logging into other sites
|
||||
|
||||
'Illuminate\Auth\Events\Authenticated' => [
|
||||
'Webkul\AdminAuthCheck\Listeners\LoginAuthenticationAttempt'
|
||||
], // make use of this to stop admins logging into other sites
|
||||
]
|
||||
];
|
||||
}
|
||||
|
|
@ -108,4 +108,4 @@ class CategoryRepository extends BaseCategoryRepository
|
|||
|
||||
return $parentCategories;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ class CustomerObserver
|
|||
public function creating(Customer $model)
|
||||
{
|
||||
if (! auth()->guard('super-admin')->check()) {
|
||||
$model->status = 1;
|
||||
$model->company_id = Company::getCurrent()->id;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,8 @@ class PreOrder extends DataGrid
|
|||
->addSelect('pre_order_items.id', 'pre_order_items.order_id', 'order_items.name as product_name', 'orders.customer_email', 'order_item_id', 'preorder_type', 'pre_order_items.status', 'base_paid_amount', 'pre_order_items.email_sent', 'base_remaining_amount', 'payment_order_items.order_id as payment_order_id')
|
||||
->addSelect(DB::raw('CONCAT(orders.customer_first_name, " ", orders.customer_last_name) as customer_name'));
|
||||
|
||||
$this->addFilter('order_id', 'pre_order_items.order_id');
|
||||
$this->addFilter('id', 'pre_order_items.id');
|
||||
$this->addFilter('status', 'pre_order_items.status');
|
||||
$this->addFilter('payment_order_id', 'payment_order_items.order_id');
|
||||
$this->addFilter('product_name', 'order_items.name');
|
||||
$this->addFilter('customer_name', DB::raw('CONCAT(orders.customer_first_name, " ", orders.customer_last_name)'));
|
||||
|
|
|
|||
Loading…
Reference in New Issue