Adding properties tab to admin enterprise edit form

This commit is contained in:
Rob Harrington
2015-04-02 11:30:32 +11:00
parent 8926e3765e
commit 3aa5f6e023
6 changed files with 46 additions and 14 deletions

View File

@@ -13,6 +13,7 @@ angular.module("admin.enterprises")
{ name: 'About', icon_class: "icon-pencil" }
{ name: 'Business Details', icon_class: "icon-briefcase" }
{ name: 'Images', icon_class: "icon-picture" }
{ name: "Properties", icon_class: "icon-tags", show: "showProperties()" }
{ name: "Shipping Methods", icon_class: "icon-truck", show: "showShippingMethods()" }
{ name: "Payment Methods", icon_class: "icon-money", show: "showPaymentMethods()" }
{ name: "Enterprise Fees", icon_class: "icon-tasks", show: "showEnterpriseFees()" }
@@ -28,6 +29,9 @@ angular.module("admin.enterprises")
else
true
$scope.showProperties = ->
!!$scope.Enterprise.is_primary_producer
$scope.showShippingMethods = ->
enterprisePermissions.can_manage_shipping_methods && $scope.Enterprise.sells != "none"