PATH:
home
/
letacommog
/
letaweb
/
scripts
/
editor
/
popup
angular.module('ui.popup') .service('popup_product_bulk_price', ['$file_manager','communication','popup_form','$templateCache','$filter',function($file_manager,communication,popup_form,$templateCache,$filter) { this.open = function(opt) { opt = opt || {}; return popup_form.open({ name:'product_bulk_price', data:opt.data, controller: function($scope) { $scope.bulk_prices = []; var product_id = opt.product_id || 0; if(product_id != 0) { communication.moduleExecute('getBulk_Prices',{id:product_id},'ecommerce.catalog.product').then(function(json) { $scope.bulk_prices = json; }); } $scope.curr_symbol_left=''; $scope.curr_symbol_right=''; communication.getDefaultCurrency().then(function(default_currency) { $scope.curr_symbol_left = default_currency['symbol_left']; $scope.curr_symbol_right = default_currency['symbol_right']; }); $scope.add = function() { $scope.bulk_prices.push({curr_symbol_right:$scope.curr_symbol_right,curr_symbol_left:$scope.curr_symbol_left}); } $scope.delete = function(index) { $scope.bulk_prices.splice(index, 1); } $scope.changeAmountType = function(index) { var amount_type = $scope.bulk_prices[index].amount_type; switch(amount_type) { case 1: case 3: case '1': case '3': $scope.bulk_prices[index].curr_symbol_right = $scope.curr_symbol_right; $scope.bulk_prices[index].curr_symbol_left = $scope.curr_symbol_left; break; case 2: case '2': default: $scope.bulk_prices[index].curr_symbol_right = '%'; $scope.bulk_prices[index].curr_symbol_left = ''; break; } } }, size:'lg', execute_path:'ecommerce.catalog.product', form_name:'ProductForm' }); } }]);
[+]
..
[-] profile.js
[edit]
[-] pagelist.js
[edit]
[-] order.js
[edit]
[-] customer_group.js
[edit]
[-] module_list.js
[edit]
[-] backgroundeditor.js
[edit]
[-] product.js
[edit]
[-] visualcsseditor.js
[edit]
[-] shipping_rule.js
[edit]
[-] profile_change_password.js
[edit]
[-] review.js
[edit]
[-] contributor_invite.js
[edit]
[-] dbfilter.js
[edit]
[-] tax_class.js
[edit]
[-] special_module_style_editor.js
[edit]
[-] idletimeout.js
[edit]
[-] address.js
[edit]
[-] contributor.js
[edit]
[-] login.js
[edit]
[-] skin.js
[edit]
[-] mail.js
[edit]
[-] discount.js
[edit]
[-] customer.js
[edit]
[-] productgrid.js
[edit]
[-] socialsharebuttonconfig.js
[edit]
[-] news.js
[edit]
[-] color.js
[edit]
[-] palette.js
[edit]
[-] newsgrid.js
[edit]
[-] product_option_combination_grid.js
[edit]
[-] page.js
[edit]
[-] product_option.js
[edit]
[-] tax_rate.js
[edit]
[-] coupons.js
[edit]
[-] zone.js
[edit]
[-] product_bulk_price.js
[edit]
[-] option_set.js
[edit]
[-] product_option_combination.js
[edit]