support zip5 tax lookups, correct errors with fixed format cch import, inital import...
[freeside.git] / httemplate / misc / tax-import.cgi
1 <% include("/elements/header.html",'Batch Tax Rate Import') %>
2
3 Import a CSV file set containing tax rate records.
4 <BR><BR>
5
6 <% include( '/elements/form-file_upload.html',
7               'name'      => 'TaxRateUpload',
8               'action'    => 'process/tax-import.cgi', 
9               'num_files' => 4,
10               'fields'    => [ 'format', ],
11               'message'   => 'Tax rates imported',
12           )
13 %>
14
15 <% &ntable("#cccccc", 2) %>
16
17   <TR>
18     <TH ALIGN="right">Format</TH>
19     <TD>
20       <SELECT NAME="format">
21         <OPTION VALUE="cch-update" SELECTED>CCH update (CSV)
22         <OPTION VALUE="cch">CCH initial import (CSV)
23         <OPTION VALUE="cch-fixed-update">CCH update (fixed length)
24         <OPTION VALUE="cch-fixed">CCH initial import (fixed length)
25       </SELECT>
26     </TD>
27   </TR>
28
29   <% include( '/elements/file-upload.html',
30                 'field'    => [ 'codefile',
31                                 'plus4file',
32                                 'zipfile',
33                                 'txmatrix',
34                                 'detail',
35                               ],
36                 'label'    => [ 'code filename',
37                                 'plus4 filename',
38                                 'zip filename',
39                                 'txmatrix filename',
40                                 'detail filename',
41                               ],
42                 'debug'    => 0,
43             )
44   %>
45
46   <TR>
47     <TD COLSPAN=2 ALIGN="center" STYLE="padding-top:6px">
48       <INPUT TYPE    = "submit"
49              VALUE   = "Import CSV files"
50              onClick = "document.TaxRateUpload.submit.disabled=true;"
51       >
52     </TD>
53   </TR>
54
55 </TABLE>
56
57 </FORM>
58
59 <% include('/elements/footer.html') %>
60 <%init>
61
62 die "access denied"
63   unless $FS::CurrentUser::CurrentUser->access_right('Import');
64
65 </%init>