Merge pull request #15421 from artfulrobot/queue-safety
[civicrm-core.git] / templates / CRM / Contribute / Form / ContributionPage / Settings.tpl
1
2 {*
3 +--------------------------------------------------------------------+
4 | CiviCRM version 5 |
5 +--------------------------------------------------------------------+
6 | Copyright CiviCRM LLC (c) 2004-2019 |
7 +--------------------------------------------------------------------+
8 | This file is a part of CiviCRM. |
9 | |
10 | CiviCRM is free software; you can copy, modify, and distribute it |
11 | under the terms of the GNU Affero General Public License |
12 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
13 | |
14 | CiviCRM is distributed in the hope that it will be useful, but |
15 | WITHOUT ANY WARRANTY; without even the implied warranty of |
16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
17 | See the GNU Affero General Public License for more details. |
18 | |
19 | You should have received a copy of the GNU Affero General Public |
20 | License and the CiviCRM Licensing Exception along |
21 | with this program; if not, contact CiviCRM LLC |
22 | at info[AT]civicrm[DOT]org. If you have questions about the |
23 | GNU Affero General Public License or the licensing of CiviCRM, |
24 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
25 +--------------------------------------------------------------------+
26 *}
27 {crmRegion name="contribute-form-contributionpage-settings-main"}
28 <div class="help">
29 {if $action eq 0}
30 <p>{ts}This is the first step in creating a new online Contribution Page. You can create one or more different Contribution Pages for different purposes, audiences, campaigns, etc. Each page can have it's own introductory message, pre-configured contribution amounts, custom data collection fields, etc.{/ts}</p>
31 <p>{ts}In this step, you will configure the page title, financial type (donation, campaign contribution, etc.), goal amount, and introductory message. You will be able to go back and modify all aspects of this page at any time after completing the setup wizard.{/ts}</p>
32 {else}
33 {ts}Use this form to edit the page title, financial type (e.g. donation, campaign contribution, etc.), goal amount, introduction, and status (active/inactive) for this online contribution page.{/ts}
34 {/if}
35 </div>
36 <div class="crm-block crm-form-block crm-contribution-contributionpage-settings-form-block">
37
38 <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
39 <table class="form-layout-compressed">
40 <tr class="crm-contribution-contributionpage-settings-form-block-title"><td class="label">{$form.title.label} {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_contribution_page' field='title' id=$contributionPageID}{/if}</td><td>{$form.title.html}<br/>
41 <span class="description">{ts}This title will be displayed at the top of the page unless the frontend title field is filled out.<br />Please use only alphanumeric, spaces, hyphens and dashes for Title.{/ts}</td>
42 </tr>
43 <tr class="crm-contribution-contributionpage-settings-form-block-frontend-title"><td class="label">{$form.contribution_page_frontend_title.label} {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_contribution_page' field='frontend_title' id=$contributionPageID}{/if}</td><td>{$form.contribution_page_frontend_title.html}<br/>
44 <span class="description">{ts}This title will be displayed at the top of the page.<br />Please use only alphanumeric, spaces, hyphens and dashes for Title.{/ts}</td>
45 </tr>
46 <tr class="crm-contribution-contributionpage-settings-form-block-financial_type_id"><td class="label">{$form.financial_type_id.label}</td><td>{$form.financial_type_id.html}<br />
47 <span class="description">{ts}Select the corresponding financial type for contributions made using this page.{/ts}</span> {help id="id-financial_type"}</td>
48 </tr>
49
50 {* CRM-7362 --add campaign to contribution page *}
51 {include file="CRM/Campaign/Form/addCampaignToComponent.tpl"
52 campaignTrClass="crm-contribution-contributionpage-settings-form-block-campaign_id"}
53
54 <tr class="crm-contribution-contributionpage-settings-form-block-is_organization"><td>&nbsp;</td><td>{$form.is_organization.html} {$form.is_organization.label} {help id="id-is_organization"}</td></tr>
55 <tr id="for_org_option" class="crm-contribution-form-block-is_organization">
56 <td>&nbsp;</td>
57 <td>
58 <table class="form-layout-compressed">
59 <tr class="crm-contribution-for_organization_help">
60 <td class="description" colspan="2">
61 {capture assign="profileURL"}{crmURL p='civicrm/admin/uf/group' q='reset=1'}{/capture}
62 {if $invalidProfiles}
63 {ts 1=$profileURL}You must <a href="%1">configure a valid organization profile</a> in order to allow individuals to contribute on behalf of an organization. Valid profiles include Contact and / or Organization fields, and may include Contribution and Membership fields.{/ts}
64 {else}
65 {ts 1=$profileURL}To change the organization data collected use the "On Behalf Of Organization" profile (<a href="%1">Administer > Customize Data and Screens > Profiles</a>).{/ts}
66 {/if}
67 </td>
68 </tr>
69 {if !$invalidProfiles}
70 <tr class="crm-contribution-onbehalf_profile_id">
71 <td class="label">{$form.onbehalf_profile_id.label}</td>
72 <td>{$form.onbehalf_profile_id.html}</td>
73 </tr>
74 {/if}
75 <tr id="for_org_text" class="crm-contribution-contributionpage-settings-form-block-for_organization">
76 <td class="label">{$form.for_organization.label}</td>
77 <td>{$form.for_organization.html}<br />
78 <span class="description">{ts}Text displayed next to the checkbox on the contribution form.{/ts}</span>
79 </td>
80 </tr>
81 <tr class="crm-contribution-contributionpage-settings-form-block-is_for_organization">
82 <td>&nbsp;</td>
83 <td>{$form.is_for_organization.html}<br />
84 <span class="description">{ts}Check 'Required' to force ALL users to contribute/signup on behalf of an organization.{/ts}</span>
85 </td>
86 </tr>
87 </table>
88 </td>
89 </tr>
90 <tr class="crm-contribution-contributionpage-settings-form-block-intro_text">
91 <td class ="label">{$form.intro_text.label}<br /> {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_contribution_page' field='intro_text' id=$contributionPageID}{/if} {help id="id-intro_msg"}</td><td>{$form.intro_text.html}</td>
92 </tr>
93 <tr class="crm-contribution-contributionpage-settings-form-block-footer_text">
94 <td class ="label">{$form.footer_text.label}<br /> {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_contribution_page' field='footer_text' id=$contributionPageID}{/if} {help id="id-footer_msg"}</td><td>{$form.footer_text.html}</td>
95 </tr>
96 <tr class="crm-contribution-contributionpage-settings-form-block-goal_amount">
97 <td class ="label">{$form.goal_amount.label}</td><td>{$form.goal_amount.html} {help id="id-goal_amount"}</td>
98 </tr>
99 <tr class="crm-contribution-contributionpage-settings-form-block-start_date">
100 <td class ="label">{$form.start_date.label} {help id="id-start_date"}</td>
101 <td>{$form.start_date.html}</td>
102 </tr>
103 <tr class="crm-contribution-contributionpage-settings-form-block-end_date">
104 <td class ="label">{$form.end_date.label}</td>
105 <td>{$form.end_date.html}</td>
106 </tr>
107 <tr class="crm-contribution-contributionpage-settings-form-block-honor_block_is_active">
108 <td>&nbsp;</td><td>{$form.honor_block_is_active.html}{$form.honor_block_is_active.label} {help id="id-honoree_section"}</td>
109 </tr>
110 </table>
111 <table class="form-layout-compressed" id="honor">
112 <tr class="crm-contribution-contributionpage-settings-form-block-honor_block_title">
113 <td class="label">
114 {$form.honor_block_title.label}
115 </td>
116 <td>
117 {$form.honor_block_title.html}<br />
118 <span class="description">{ts}Title for the Honoree section (e.g. &quot;Honoree Information&quot;).{/ts}</span>
119 </td>
120 </tr>
121 <tr class="crm-contribution-contributionpage-settings-form-block-honor_block_text">
122 <td class="label">
123 {crmAPI var='result' entity='OptionGroup' action='get' sequential=1 name='soft_credit_type'}
124 {$form.honor_block_text.label}
125 </td>
126 <td>
127 {$form.honor_block_text.html}<br />
128 <span class="description">{ts}Optional explanatory text for the Honoree section (displayed above the Honoree fields).{/ts}</span>
129 </td>
130 </tr>
131 <tr class="crm-contribution-contributionpage-settings-form-block-honor_soft_credit_types">
132 <td class="label">
133 {$form.soft_credit_types.label}
134 </td>
135 <td>
136 {$form.soft_credit_types.html}
137 </td>
138 </tr>
139 <tr class="crm-contribution-contributionpage-custom-form-block-custom_pre_id">
140 <td class="label">
141 {$form.honoree_profile.label}
142 </td>
143 <td class="html-adjust">
144 {$form.honoree_profile.html}
145 <span class="description">{ts}Profile to be included in the honoree section{/ts}</span>
146 </td>
147 </tr>
148 </table>
149 <table class="form-layout-compressed">
150 <tr class="crm-contribution-contributionpage-settings-form-block-is_confirm_enabled">
151 <td>&nbsp;</td>
152 <td>{$form.is_confirm_enabled.html} {$form.is_confirm_enabled.label}<br />
153 <span class="description">{ts}If you disable this contributions will be processed immediately after submitting the contribution form.{/ts}</span></td>
154 </tr>
155 <tr class="crm-contribution-contributionpage-settings-form-block-is_share">
156 <td>&nbsp;</td>
157 <td>{$form.is_share.html} {$form.is_share.label} {help id="id-is_share"}</td>
158 </tr>
159 <tr class="crm-contribution-contributionpage-settings-form-block-is_active">
160 <td>&nbsp;</td>
161 <td>{$form.is_active.html} {$form.is_active.label}</td>
162 </tr>
163 {if $contributionPageID}
164 <tr class="crm-contribution-contributionpage-settings-form-block-info_link">
165 <td>&nbsp;</td>
166 <td class="description">
167 {if $config->userSystem->is_drupal || $config->userFramework EQ 'WordPress'}
168 {ts}When your page is active, you can link people to the page by copying and pasting the following URL:{/ts}<br />
169 <strong>{crmURL a=1 fe=1 p='civicrm/contribute/transact' q="reset=1&id=`$contributionPageID`"}</strong>
170 {elseif $config->userFramework EQ 'Joomla'}
171 {ts 1=$title}When your page is active, create front-end links to the contribution page using the Menu Manager. Select <strong>Administer CiviCRM &raquo; CiviContribute &raquo; Manage Contribution Pages</strong> and select <strong>%1</strong> for the contribution page.{/ts}
172 {/if}
173 {/if}
174 </td>
175 </tr>
176 </table>
177 <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="bottom"}</div>
178 </div>
179
180 {include file="CRM/common/showHideByFieldValue.tpl"
181 trigger_field_id ="is_organization"
182 trigger_value = 1
183 target_element_id ="for_org_text"
184 target_element_type ="table-row"
185 field_type ="radio"
186 invert = 0
187 }
188
189 {include file="CRM/common/showHideByFieldValue.tpl"
190 trigger_field_id ="is_organization"
191 trigger_value = 1
192 target_element_id ="for_org_option"
193 target_element_type ="table-row"
194 field_type ="radio"
195 invert = 0
196 }
197 <script type="text/javascript">
198 showHonor();
199 {literal}
200 function showHonor() {
201 var checkbox = document.getElementsByName("honor_block_is_active");
202 if (checkbox[0].checked) {
203 document.getElementById("honor").style.display = "block";
204 } else {
205 document.getElementById("honor").style.display = "none";
206 }
207 }
208 {/literal}
209 </script>
210 {/crmRegion}
211 {crmRegion name="contribute-form-contributionpage-settings-post"}
212 {/crmRegion}