|
1 | | -<% total_criteria = 4 %> |
2 | | -<% partner_criteria_met = org_stats.partners_added > 0 %> |
3 | | -<% location_criteria_met = org_stats.storage_locations_added > 0 %> |
4 | | -<% donation_criteria_met = org_stats.donation_sites_added > 0 %> |
5 | | -<% inventory_criteria_met = org_stats.num_locations_with_inventory > 0 %> |
6 | | -<% criterias = [ location_criteria_met, partner_criteria_met, donation_criteria_met, inventory_criteria_met ] %> |
7 | | -<% current_step = criterias.find_index(false) %> |
8 | 1 |
|
9 | | -<% if current_step.present? %> |
| 2 | + |
| 3 | +<% unless org_is_set_up %> |
10 | 4 |
|
11 | 5 | <%= render( |
12 | 6 | "shared/card", |
13 | | - id: "summary", |
| 7 | + id: "getting-started-guide", |
14 | 8 | header: "Getting Started", |
15 | 9 | type: :plain, |
16 | 10 | ) do %> |
17 | 11 | <div class="row"> |
18 | 12 | <div class="col-md-12"> |
19 | 13 | <div class="box box-primary" id="getting-started-guide"> |
20 | 14 | <div class="box-header with-border"> |
21 | | - <h2 class="box-title"> |
22 | | - Just Starting? |
23 | | - <small>Here are some things you may need to set up:</small> |
24 | | - </h2> |
| 15 | + <h5> |
| 16 | + Here are a few steps to help you in getting started |
| 17 | + </h5> |
25 | 18 | </div> |
26 | 19 |
|
27 | | - <div class="box-body org-stats"> |
28 | | - <div class="col-md-12"> |
29 | | - <%= render partial: "getting_started_progress_stepper", locals: { |
30 | | - current_step: current_step, |
31 | | - criterias: criterias, |
32 | | - lines: ["line-right", "line-right line-left", "line-right line-left", "line-left"], |
33 | | - step_labels: ["Storage Locations", "Partner Agencies", "Donation Sites", "Inventory"] |
34 | | - } %> |
35 | | - </div> |
36 | | - |
37 | | - <div class="col-md-12 org-stats-box-container<%= current_step == 0 ? '' : ' d-none visible-xs' %>"> |
38 | | - <div class="org-stats-box"> |
39 | | - <div class="box-body text-center position-relative"> |
40 | | - <div class="org-stats-icon"> |
41 | | - <% if location_criteria_met %> |
42 | | - <i class="fa fa-check-circle-o fa-2x success" aria-hidden="true"></i> |
43 | | - <% else %> |
44 | | - <i class="fa fa-map-marker fa-2x" aria-hidden="true"></i> |
45 | | - <% end %> |
46 | | - <h4><%= pluralize(org_stats.storage_locations_added, 'Storage Location') %> Added</h4> |
47 | | - </div> |
48 | | - |
49 | | - <p class="org-stats-desc"> |
50 | | - Add details for all Storage Locations you use for your inventory. |
51 | | - </p> |
52 | | - |
53 | | - <div id="org-stats-call-to-action-storage-locations"> |
54 | | - <% location_link_text = location_criteria_met ? "Add More Storage Locations" : "Add a Storage Location" %> |
55 | | - <%= new_button_to new_storage_location_path, { text: location_link_text, size: "md" } %> |
56 | | - </div> |
57 | | - </div> |
58 | | - </div> |
59 | | - </div> |
60 | | - |
61 | | - <div class="col-md-12 org-stats-box-container<%= current_step == 1 ? '' : ' d-none visible-xs' %>"> |
62 | | - <div class="org-stats-box"> |
63 | | - <div class="box-body text-center position-relative"> |
64 | | - <div class="org-stats-icon"> |
65 | | - <% if partner_criteria_met %> |
66 | | - <i class="fa fa-check-circle-o fa-2x success" aria-hidden="true"></i> |
67 | | - <% else %> |
68 | | - <i class="fa fa-users fa-2x" aria-hidden="true"></i> |
69 | | - <% end %> |
70 | | - <h4><%= pluralize(org_stats.partners_added, 'Partner Agency') %> Added</h4> |
71 | | - </div> |
72 | | - |
73 | | - <p class="org-stats-desc"> |
74 | | - To start building your community in Human Essentials, import a list of your current partner agencies or add them individually. |
75 | | - </p> |
76 | | - |
77 | | - <div id="org-stats-call-to-action-partners"> |
78 | | - <%= modal_button_to("#csvImportModal", { text: "Import Partners", icon: "upload", size: "md" }) %> |
79 | | - <% partner_link_text = partner_criteria_met ? "Add More Partners" : "Add a Partner" %> |
80 | | - <%= new_button_to new_partner_path, { text: partner_link_text, size: "md" } %> |
81 | | - </div> |
82 | | - </div> |
83 | | - </div> |
84 | | - </div> |
85 | | - |
86 | | - <div class="col-md-12 org-stats-box-container<%= current_step == 2 ? '' : ' d-none visible-xs' %>"> |
87 | | - <div class="org-stats-box"> |
88 | | - <div class="box-body text-center position-relative"> |
89 | | - <div class="org-stats-icon"> |
90 | | - <% if donation_criteria_met %> |
91 | | - <i class="fa fa-check-circle-o fa-2x success" aria-hidden="true"></i> |
92 | | - <% else %> |
93 | | - <i class="fa fa-home fa-2x" aria-hidden="true"></i> |
94 | | - <% end %> |
95 | | - <h4><%= pluralize(org_stats.donation_sites_added, 'Donation Site') %> Added</h4> |
96 | | - </div> |
97 | | - |
98 | | - <p class="org-stats-desc"> |
99 | | - Add any community sites (including your primary storage facility) that accept donations on your behalf. |
100 | | - </p> |
101 | | - |
102 | | - <div id="org-stats-call-to-action-donation-sites"> |
103 | | - <% donation_link_text = donation_criteria_met ? "Add More Donation Sites" : "Add a Donation Site" %> |
104 | | - <%= new_button_to new_donation_site_path, { text: donation_link_text, size: "md" } %> |
105 | | - </div> |
106 | | - </div> |
107 | | - </div> |
108 | | - </div> |
109 | | - |
110 | | - <div class="col-md-12 org-stats-box-container<%= current_step == 3 ? '' : ' d-none visible-xs' %>"> |
111 | | - <div class="org-stats-box"> |
112 | | - <div class="box-body text-center position-relative"> |
113 | | - <div class="org-stats-icon"> |
114 | | - <% if inventory_criteria_met %> |
115 | | - <i class="fa fa-check-circle-o fa-2x success" aria-hidden="true"></i> |
116 | | - <% else %> |
117 | | - <i class="fa fa-pie-chart fa-2x" aria-hidden="true"></i> |
118 | | - <% end %> |
119 | | - <h4><%= pluralize(org_stats.num_locations_with_inventory, 'Storage Location') %> with Inventory</h4> |
120 | | - </div> |
121 | | - |
122 | | - <div class="org-stats-desc"> |
123 | | - <p> |
124 | | - As an essentials bank, you might already have inventory on hand. These items might have come from previous donations/purchases. If you have multiple sources or want to add inventory to multiple storage locations, you can create multiple donations or purchases while specifying the correct date, source, and location. |
125 | | - </p> |
126 | | - </div> |
127 | | - |
128 | | - <div id="org-stats-call-to-action-inventory"> |
129 | | - <%= new_button_to new_donation_path, { text: "Add past donation", size: "md" } %> |
130 | | - <%= new_button_to new_purchase_path, { text: "Add past purchase", size: "md" } %> |
131 | | - </div> |
132 | | - </div> |
133 | | - </div> |
134 | | - </div> |
| 20 | + <hr> |
| 21 | + |
| 22 | + <div> |
| 23 | + <ul> |
| 24 | + <li> |
| 25 | + <%= link_to "Set up storage locations", storage_locations_path, target: :_blank %> |
| 26 | + </li> |
| 27 | + <li> |
| 28 | + Set up your inventory |
| 29 | + <ul> |
| 30 | + <li> |
| 31 | + <%= link_to "Add any custom items", items_path, target: :_blank %> |
| 32 | + </li> |
| 33 | + <li> |
| 34 | + <%= link_to "Do an audit to set up your current inventory levels", audits_path, target: :_blank %> |
| 35 | + - |
| 36 | + <%= link_to "(User guide)", "https://rubyforgood.github.io/human-essentials/user_guide/bank/getting_started_inventory.html", target: :_blank %> |
| 37 | + </li> |
| 38 | + </ul> |
| 39 | + </li> |
| 40 | + <li> |
| 41 | + <%= link_to "Customize your organization", edit_organization_path, target: :_blank %> |
| 42 | + - |
| 43 | + <%= link_to "(User guide)", "https://rubyforgood.github.io/human-essentials/user_guide/bank/getting_started_customization.html", target: :_blank %> |
| 44 | + </li> |
| 45 | + <li> |
| 46 | + <%= link_to "Add other users at your bank", new_user_path, target: :_blank %> |
| 47 | + </li> |
| 48 | + <li> |
| 49 | + <%= link_to "Import Partners", partners_path, target: :_blank %> |
| 50 | + or |
| 51 | + <%= link_to "Add a single partner", new_partner_path, target: :_blank %> |
| 52 | + </li> |
| 53 | + </ul> |
135 | 54 | </div> |
136 | 55 | </div> |
137 | 56 | </div> |
| 57 | + |
| 58 | + <p>When you're done, click this box to hide this section</p> |
| 59 | + <%= button_to "Dismiss", "/manage", method: :patch, params: {organization: { bank_is_set_up: true }}, class: "btn btn-primary" %> |
138 | 60 | </div> |
139 | 61 |
|
140 | | - <%= render( |
141 | | - layout: "shared/csv_import_modal", |
142 | | - locals: { |
143 | | - import_type: "Partners", |
144 | | - csv_template_url: "/partners_template.csv", |
145 | | - csv_import_url: import_csv_partners_path, |
146 | | - }, |
147 | | - ) do %> |
148 | | - <li>Open the CSV file with Excel or your favourite spreadsheet program.</li> |
149 | | - <li>Delete the sample data and enter your partner agency names and addresses in the appropriate columns.</li> |
150 | | - <li>Save the file as a CSV file.</li> |
151 | | - <% end %> |
152 | 62 | <% end %> |
153 | 63 | <% end %> |
0 commit comments