mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-25 01:23:23 +00:00
Switching enterprise index to its own dedicated serializer, so we can spit out ownership
This commit is contained in:
@@ -61,23 +61,23 @@
|
||||
|
||||
.omega.eight.columns
|
||||
%div{ ng: { if: "!enterprise.is_primary_producer"} }
|
||||
%a.button.selector{ ng: { click: "enterprise.sells='none'", class: "{selected: enterprise.sells=='none'}" } }
|
||||
%a.button.selector{ ng: { click: "enterprise.owned && (enterprise.sells='none')", class: "{selected: enterprise.sells=='none', disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Profile Only
|
||||
%p Connect through OFN
|
||||
.bottom ALWAYS FREE
|
||||
%a.button.selector{ ng: { click: "enterprise.sells='any'", class: "{selected: enterprise.sells=='any'}" } }
|
||||
%a.button.selector{ ng: { click: "enterprise.owned && (enterprise.sells='any')", class: "{selected: enterprise.sells=='any', disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Hub Shop
|
||||
%p Sell produce from others
|
||||
.bottom ALWAYS FREE
|
||||
|
||||
%div{ ng: { if: "enterprise.is_primary_producer"} }
|
||||
%a.button.selector{ ng: { click: "enterprise.sells='none'", class: "{selected: enterprise.sells=='none'}" } }
|
||||
%a.button.selector{ ng: { click: "enterprise.owned && (enterprise.sells='none')", class: "{selected: enterprise.sells=='none', disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Profile Only
|
||||
.bottom ALWAYS FREE
|
||||
%a.button.selector{ ng: { click: "enterprise.sells='own'", class: "{selected: enterprise.sells=='own'}" } }
|
||||
%a.button.selector{ ng: { click: "enterprise.owned && (enterprise.sells='own')", class: "{selected: enterprise.sells=='own', disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Producer Shop
|
||||
%p Sell your own produce
|
||||
@@ -85,7 +85,7 @@
|
||||
\%2 OF SALES
|
||||
%br
|
||||
CAPPED AT $50 PER MONTH
|
||||
%a.button.selector{ ng: { click: "enterprise.sells='any';", class: "{selected: enterprise.sells=='any'}" } }
|
||||
%a.button.selector{ ng: { click: "enterprise.owned && (enterprise.sells='any')", class: "{selected: enterprise.sells=='any', disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Producer Hub
|
||||
%p Sell produce from self and others
|
||||
@@ -94,7 +94,7 @@
|
||||
%br
|
||||
CAPPED AT $50 PER MONTH
|
||||
|
||||
%a.button.update.fullwidth{ ng: { class: "{disabled: saved() && !saving, saving: saving}", click: "save()" } }
|
||||
%a.button.update.fullwidth{ ng: { show: "enterprise.owned", class: "{disabled: saved() && !saving, saving: saving}", click: "save()" } }
|
||||
%span{ ng: {hide: "saved() || saving" } }
|
||||
SAVE
|
||||
%i.icon-save
|
||||
|
||||
@@ -20,19 +20,19 @@
|
||||
%p Instead, non-producers specialise in linking producers to the end eater, whether it be by aggregating, grading, packing, selling or delivering food.
|
||||
|
||||
.omega.eight.columns
|
||||
%a.button.selector{ ng: { click: 'changeToProducer()', class: "{selected: enterprise.is_primary_producer==true}" } }
|
||||
%a.button.selector{ ng: { click: 'enterprise.owned && changeToProducer()', class: "{selected: enterprise.is_primary_producer==true, disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 PRODUCER
|
||||
%p Primary producers of food
|
||||
.bottom eg. GROWERS, BAKERS, BREWERS, MAKERS
|
||||
|
||||
%a.button.selector{ ng: { click: 'changeToNonProducer()', class: "{selected: enterprise.is_primary_producer==false}" } }
|
||||
%a.button.selector{ ng: { click: 'enterprise.owned && changeToNonProducer()', class: "{selected: enterprise.is_primary_producer==false, disabled: !enterprise.owned}" } }
|
||||
.top
|
||||
%h3 Non-Producer
|
||||
%p All other food enterprises
|
||||
.bottom eg. Grocery stores, Food co-ops, Buying groups
|
||||
|
||||
%a.button.update.fullwidth{ ng: { class: "{disabled: saved() && !saving, saving: saving}", click: "save()" } }
|
||||
%a.button.update.fullwidth{ ng: { show: "enterprise.owned", class: "{disabled: saved() && !saving, saving: saving}", click: "save()" } }
|
||||
%span{ ng: {hide: "saved() || saving" } }
|
||||
SAVE
|
||||
%i.icon-save
|
||||
|
||||
Reference in New Issue
Block a user