mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-02 21:57:17 +00:00
Add affiliate sales data to form
This commit is contained in:
@@ -1,2 +1,4 @@
|
||||
= render partial: "/admin/enterprises/form/connected_apps/discover_regen",
|
||||
locals: { enterprise:, connected_app: enterprise.connected_apps.discover_regen.first }
|
||||
= render partial: "/admin/enterprises/form/connected_apps/affiliate_sales_data",
|
||||
locals: { enterprise:, connected_app: enterprise.connected_apps.affiliate_sales_data.first }
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
%section.connected_app
|
||||
.connected-app__head
|
||||
%div
|
||||
%h3= t ".title"
|
||||
%p= t ".tagline"
|
||||
%div
|
||||
- if connected_app.nil?
|
||||
= button_to t(".enable"), admin_enterprise_connected_apps_path(enterprise.id), method: :post, disabled: !managed_by_user?(enterprise)
|
||||
-# This is only seen by super-admins:
|
||||
%em= t(".need_to_be_manager") unless managed_by_user?(enterprise)
|
||||
- else
|
||||
= button_to t(".disable"), admin_enterprise_connected_app_path(0, enterprise_id: enterprise.id), method: :delete
|
||||
%hr
|
||||
.connected-app__description
|
||||
= t ".description_html"
|
||||
@@ -2,10 +2,18 @@
|
||||
max-width: 615px;
|
||||
}
|
||||
|
||||
.connected_app {
|
||||
margin-bottom: 2rem;
|
||||
|
||||
&:not(:first-of-type) {
|
||||
border-top: 1px solid $color-border;
|
||||
}
|
||||
}
|
||||
|
||||
.connected-app__head {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 1em;
|
||||
margin: 1em 0;
|
||||
|
||||
h3 {
|
||||
margin-bottom: 1em;
|
||||
|
||||
@@ -1358,6 +1358,22 @@ en:
|
||||
custom_tab_content: "Content for custom tab"
|
||||
connected_apps:
|
||||
legend: "Connected apps"
|
||||
affiliate_sales_data:
|
||||
title: "INRAE / UFC QUE CHOISIR Research"
|
||||
tagline: "Allow this research project to access your orders data anonymously"
|
||||
enable: "Allow data sharing"
|
||||
disable: "Stop sharing"
|
||||
loading: "Loading"
|
||||
need_to_be_manager: "Only managers can connect apps."
|
||||
description_html: |
|
||||
<p>
|
||||
INRAE and UFC QUE CHOISIR are teaming up to study food prices in short food systems and compare them with prices in the supermarket, for a given set of products. The data that is used by INRAE is mixed with data coming from other short food chain platforms in France. No individual product prices will be publicly disclosed through this project.
|
||||
</p>
|
||||
<p>
|
||||
<a href="https://apropos.coopcircuits.fr/"
|
||||
target="_blank"><b>Learn more about this research project</b>
|
||||
<i class="icon-external-link"></i></a>
|
||||
</p>
|
||||
discover_regen:
|
||||
title: "Discover Regenerative"
|
||||
tagline: "Allow Discover Regenerative to publish your enterprise information."
|
||||
|
||||
Reference in New Issue
Block a user