Skip to content

Commit

Permalink
Add option for coupons dropdown menu
Browse files Browse the repository at this point in the history
  • Loading branch information
sampoyigi committed Aug 30, 2023
1 parent 8b8a592 commit c0e0bdf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
6 changes: 3 additions & 3 deletions language/en/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@

'label_code' => 'Code',
'label_discount' => 'Discount',
'label_min_total' => 'Minimum Total',
'label_min_total' => 'Minimum Order Total Amount',
'label_redemption' => 'Redemptions',
'label_customer_redemption' => 'Customer Redemptions',
'label_validity' => 'Validity',
'label_order_restriction' => 'Order Restriction',
'label_cart_restriction' => 'Do not apply to the whole cart',
'label_categories' => 'Apply to menu items from these categories',
'label_menus' => 'Apply to these menu items',
'label_categories' => 'Apply discount to menu items from these categories',
'label_menus' => 'Apply discount to these menu items',
'label_date' => 'Date',
'label_fixed_date' => 'Fixed date',
'label_fixed_from_time' => 'Fixed from time',
Expand Down
5 changes: 5 additions & 0 deletions models/Coupons_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,11 @@ public function getRecurringEveryOptions()
return ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'];
}

public static function getDropdownOptions()
{
return static::isEnabled()->dropdown('name');
}

//
// Accessors & Mutators
//
Expand Down

0 comments on commit c0e0bdf

Please sign in to comment.