minor psr12 fix
[openemr.git] / templates / pharmacies / general_edit.html
blob933af0571b21d40d99a07e7d678d5e0a955410d6
1 {**
2 * Pharmacy edit
4 * @package OpenEMR
5 * @link http://www.open-emr.org
6 * @author Brady Miller <brady.g.miller@gmail.com>
7 * @copyright Copyright (c) 2017 Brady Miller <brady.g.miller@gmail.com>
8 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
9 *}
10 <form name="pharmacy" method="post" action="{$FORM_ACTION}" class='form-horizontal' onsubmit="return top.restoreSession()">
11 <!-- it is important that the hidden form_id field be listed first, when it is called is populates any old information attached with the id, this allows for partial edits
12 if it were called last, the settings from the form would be overwritten with the old information-->
13 <input type="hidden" name="form_id" value="{$pharmacy->id|attr}" />
14 <div class="form-row py-sm-2">
15 <label for="name" class="col-form-label col-sm-2">{xlt t='Name'}</label>
16 <div class="col-sm-8">
17 <input type="text" id="name" name="name" class="form-control" aria-describedby="nameHelpBox" value="{$pharmacy->name|attr}" onKeyDown="PreventIt(event)" />
18 <span id="nameHelpBox" class="help-block">({xlt t='Required'})</span>
19 </div>
20 </div>
21 <div class="form-row py-sm-2">
22 <label for="address_line1" class="col-form-label col-sm-2">{xlt t='Address'}</label>
23 <div class="col-sm-8">
24 <input type="text" id="address_line1" name="address_line1" class="form-control" value="{$pharmacy->address->line1|attr}" onKeyDown="PreventIt(event)">
25 </div>
26 </div>
27 <div class="form-row py-sm-2">
28 <label for="address_line2" class="col-form-label col-sm-2">{xlt t='Address'}</label>
29 <div class="col-sm-8">
30 <input type="text" id="address_line2" name="address_line2" class="form-control" value="{$pharmacy->address->line2|attr}" onKeyDown="PreventIt(event)" />
31 </div>
32 </div>
33 <div class="form-row py-sm-2">
34 <label for="city" class="col-form-label col-sm-2">{xlt t='City'}</label>
35 <div class="col-sm-8">
36 <input type="text" id="city" name="city" class="form-control" value="{$pharmacy->address->city|attr}" onKeyDown="PreventIt(event)" />
37 </div>
38 </div>
39 <div class="form-row py-sm-2">
40 <label for="state" class="col-form-label col-sm-2">{xlt t='State'}</label>
41 <div class="col-sm-8">
42 <input type="text" maxlength="2" id="state" name="state" class="form-control" value="{$pharmacy->address->state|attr}" onKeyDown="PreventIt(event)" />
43 </div>
44 </div>
45 <div class="form-row py-sm-2">
46 <label for="city" class="col-form-label col-sm-2">{xlt t='Zip Code'}</label>
47 <div class="col-sm-8">
48 <input type="text" id="zip" name="zip" class="form-control" value="{$pharmacy->address->zip|attr}" onKeyDown="PreventIt(event)" />
49 </div>
50 </div>
51 <div class="form-row py-sm-2">
52 <label for="email" class="col-form-label col-sm-2">{xlt t='Email'}</label>
53 <div class="col-sm-8">
54 <input type="text" id="email" name="email" class="form-control" value="{$pharmacy->email|attr}" onKeyDown="PreventIt(event)">
55 </div>
56 </div>
57 <div class="form-row py-sm-2">
58 <label for="phone" class="col-form-label col-sm-2">{xlt t='Phone'}</label>
59 <div class="col-sm-8">
60 <input type="text" id="phone" name="phone" class="form-control" value="{$pharmacy->get_phone()|attr}" onKeyDown="PreventIt(event)" />
61 </div>
62 </div>
63 <div class="form-row py-sm-2">
64 <label for="fax" class="col-form-label col-sm-2">{xlt t='Fax'}</label>
65 <div class="col-sm-8">
66 <input type="text" id="fax" name="fax" class="form-control" value="{$pharmacy->get_fax()|attr}" onKeyDown="PreventIt(event)" />
67 </div>
68 </div>
69 <div class="form-row py-sm-2">
70 <label for="npi" class="col-form-label col-sm-2">{xlt t='NPI'}</label>
71 <div class="col-sm-8">
72 <input type="text" id="npi" name="npi" class="form-control" value="{$pharmacy->get_npi()|attr}" onKeyDown="PreventIt(event)" />
73 </div>
74 </div>
75 <div class="form-row py-sm-2">
76 <label for="ncpdp" class="col-form-label col-sm-2">{xlt t='NCPDP'}</label>
77 <div class="col-sm-8">
78 <input type="text" id="ncpdp" name="ncpdp" class="form-control" value="{$pharmacy->get_ncpdp()|attr}" onKeyDown="PreventIt(event)" />
79 </div>
80 </div>
81 <div class="form-row py-sm-2">
82 <label for="transmit_method" class="col-form-label col-sm-2">{xlt t='Default Method'}</label>
83 <div class="col-sm-8">
84 <select id="transmit_method" name="transmit_method" class="form-control">
85 {html_options options=$pharmacy->transmit_method_array selected=$pharmacy->transmit_method}
86 </select>
87 </div>
88 </div>
89 <div class="btn-group offset-sm-2">
90 <a href="javascript:submit_pharmacy();" class="btn btn-secondary btn-save" onclick="top.restoreSession()">
91 {xlt t='Save'}
92 </a>
93 <a href="controller.php?practice_settings&pharmacy&action=list" class="btn btn-link btn-cancel" onclick="top.restoreSession()">
94 {xlt t='Cancel'}
95 </a>
96 </div>
97 <input type="hidden" name="id" value="{$pharmacy->id|attr}" />
98 <input type="hidden" name="process" value="{$PROCESS|attr}" />
99 </form>
101 {literal}
102 <script>
103 function submit_pharmacy()
105 if(document.pharmacy.name.value.length>0)
107 top.restoreSession();
108 document.pharmacy.submit();
109 //Z&H Removed redirection
111 else
113 document.pharmacy.name.style.backgroundColor="red";
114 document.pharmacy.name.focus();
118 function Waittoredirect(delaymsec) {
119 var st = new Date();
120 var et = null;
121 do {
122 et = new Date();
123 } while ((et - st) < delaymsec);
125 </script>
126 {/literal}