Commit | Line | Data |
---|---|---|
6a488035 TO |
1 | {* |
2 | +--------------------------------------------------------------------+ | |
1188c7a8 | 3 | | Copyright CiviCRM LLC. All rights reserved. | |
6a488035 | 4 | | | |
1188c7a8 TO |
5 | | This work is published under the GNU AGPLv3 license with some | |
6 | | permitted exceptions and without any warranty. For full license | | |
7 | | and copyright information, see https://civicrm.org/licensing | | |
6a488035 TO |
8 | +--------------------------------------------------------------------+ |
9 | *} | |
10 | {* This template is used for adding/configuring SMS Providers *} | |
6a488035 TO |
11 | <div class="crm-block crm-form-block crm-job-form-block"> |
12 | <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div> | |
13 | ||
14 | {if $action eq 8} | |
7f7fa13a | 15 | <div class="messages status no-popup"> |
34d6cec4 | 16 | {icon icon="fa-info-circle"}{/icon} |
6a488035 TO |
17 | {ts}Do you want to continue?{/ts} |
18 | </div> | |
19 | {elseif $action eq 128} | |
7f7fa13a | 20 | <div class="messages status no-popup"> |
34d6cec4 | 21 | {icon icon="fa-info-circle"}{/icon} |
6a488035 TO |
22 | {ts}Are you sure you would like to execute this job?{/ts} |
23 | </div> | |
24 | {else} | |
25 | <table class="form-layout-compressed"> | |
26 | <tr class="crm-job-form-block-name"> | |
27 | <td class="label">{$form.name.label}</td><td>{$form.name.html}</td> | |
28 | </tr> | |
29 | <tr class="crm-job-form-block-title"> | |
30 | <td class="label">{$form.title.label}</td><td>{$form.title.html}</td> | |
31 | </tr> | |
32 | <tr class="crm-job-form-block-username"> | |
33 | <td class="label">{$form.username.label}</td><td>{$form.username.html}</td> | |
34 | </tr> | |
35 | <tr class="crm-job-form-block-password"> | |
36 | <td class="label">{$form.password.label}</td><td>{$form.password.html}</td> | |
37 | </tr> | |
38 | <tr class="crm-job-form-block-api_type"> | |
39 | <td class="label">{$form.api_type.label}</td><td>{$form.api_type.html}</td> | |
40 | </tr> | |
41 | <tr class="crm-job-form-block-api_url"> | |
42 | <td class="label">{$form.api_url.label}</td><td>{$form.api_url.html}</td> | |
43 | </tr> | |
44 | <tr class="crm-job-form-block-api_params"> | |
45 | <td class="label">{$form.api_params.label}</td><td>{$form.api_params.html}</td> | |
46 | </tr> | |
47 | <tr class="crm-job-form-block-is_active"> | |
48 | <td></td><td>{$form.is_active.html} {$form.is_active.label}</td> | |
49 | </tr> | |
50 | <tr class="crm-job-form-block-is_active"> | |
51 | <td></td><td>{$form.is_default.html} {$form.is_default.label}</td> | |
52 | </tr> | |
53 | </table> | |
7f7fa13a | 54 | {/if} |
6a488035 TO |
55 | </table> |
56 | <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="bottom"}</div> | |
57 | </fieldset> | |
58 | </div> | |
59 | ||
60 | {if $action eq 1 or $action eq 2} | |
61 | <script type="text/javascript" > | |
62 | {literal} | |
185eb0fc | 63 | CRM.$(function($) { |
b50fdacc | 64 | var $form = $("form.{/literal}{$form.formClass}{literal}"); |
185eb0fc CW |
65 | $('select[name=name]', $form).change(function() { |
66 | var url = {/literal}"{$refreshURL}"{literal} + "&key=" + this.value; | |
67 | $(this).closest('.crm-ajax-container, #crm-main-content-wrapper').crmSnippet({url: url}).crmSnippet('refresh'); | |
68 | }); | |
69 | }); | |
6a488035 TO |
70 | {/literal} |
71 | </script> | |
72 | {/if} |