- diff --git a/app/Helpers/helpers.php b/app/Helpers/helpers.php index 572988b1..9f0c4123 100644 --- a/app/Helpers/helpers.php +++ b/app/Helpers/helpers.php @@ -11,7 +11,7 @@ if (!function_exists('money')) { function money($amount, \App\Models\Currency $currency = null) { if(!$currency){ - return number_format($amount,0,'.',','); + return number_format($amount,0,'.',',').' manat'; } return $currency->symbol_left . number_format($amount, $currency->decimal_place, $currency->decimal_point, $currency->thousand_point) . $currency->symbol_right; @@ -28,6 +28,18 @@ if(!function_exists('main_categories')){ } } +if(!function_exists('category_menu')){ + /** + * make menu from categories + */ + function category_menu(){ + $categories = main_categories(); + if(count($categories)>6){ + + } + } +} + if(! function_exists('sub_categories')){ /** * return sub categoreies diff --git a/app/Helpers/macros.php b/app/Helpers/macros.php index 0463f7ec..9db0503d 100644 --- a/app/Helpers/macros.php +++ b/app/Helpers/macros.php @@ -78,6 +78,15 @@ HTML::macro('sortable_link', return $html; }); +HTML::macro('cat_menu', function ($categories = array(), $class = '',$item_class = '',$options = array()){ + $html = "