summaryrefslogtreecommitdiff
path: root/httemplate
diff options
context:
space:
mode:
authormark <mark>2011-12-30 22:10:58 +0000
committermark <mark>2011-12-30 22:10:58 +0000
commit399b04d522b22e593a9fa7463851be6d121ae4cf (patch)
treea3952811cf74a5f9e6590886b6e1cb214aec7aab /httemplate
parent5b73387992a96f7b80e40b5ecb2fedabd8a78d6b (diff)
track/update census codes by year, #15381
Diffstat (limited to 'httemplate')
-rw-r--r--httemplate/edit/cust_main/bottomfixup.js17
-rw-r--r--httemplate/view/cust_main/misc.html4
2 files changed, 12 insertions, 9 deletions
diff --git a/httemplate/edit/cust_main/bottomfixup.js b/httemplate/edit/cust_main/bottomfixup.js
index a031f46..9d1f1e1 100644
--- a/httemplate/edit/cust_main/bottomfixup.js
+++ b/httemplate/edit/cust_main/bottomfixup.js
@@ -37,11 +37,11 @@ function post_geocode() {
var cf = document.CustomerForm;
var state_el = cf.elements['ship_state'];
var census_data = new Array(
- 'year', <% $conf->config('census_year') || '2011' %>,
- 'address', cf.elements['ship_address1'].value,
- 'city', cf.elements['ship_city'].value,
- 'state', state_el.options[ state_el.selectedIndex ].value,
- 'zip', cf.elements['ship_zip'].value
+ 'year', <% $conf->config('census_year') || '2011' %>,
+ 'address1', cf.elements['ship_address1'].value,
+ 'city', cf.elements['ship_city'].value,
+ 'state', state_el.options[ state_el.selectedIndex ].value,
+ 'zip', cf.elements['ship_zip'].value
);
censustract( census_data, update_censustract );
@@ -62,16 +62,17 @@ function update_censustract(arg) {
var cf = document.CustomerForm;
- var msacode = argsHash['msacode'];
+/* var msacode = argsHash['msacode'];
var statecode = argsHash['statecode'];
var countycode = argsHash['countycode'];
var tractcode = argsHash['tractcode'];
- var error = argsHash['error'];
var newcensus =
new String(statecode) +
new String(countycode) +
- new String(tractcode).replace(/\s$/, ''); // JSON 1 workaround
+ new String(tractcode).replace(/\s$/, ''); // JSON 1 workaround */
+ var error = argsHash['error'];
+ var newcensus = argsHash['censustract'];
set_censustract = function () {
diff --git a/httemplate/view/cust_main/misc.html b/httemplate/view/cust_main/misc.html
index c59f6af..f664ae2 100644
--- a/httemplate/view/cust_main/misc.html
+++ b/httemplate/view/cust_main/misc.html
@@ -119,7 +119,9 @@
% if ( $conf->exists('cust_main-require_censustract') ) {
<TR>
- <TD ALIGN="right"><% mt('Census tract') |h %></TD>
+ <TD ALIGN="right">
+ <% mt('Census tract ([_1])', $cust_main->censusyear) |h %>
+ </TD>
<TD BGCOLOR="#ffffff"><% $cust_main->censustract %></TD>
</TR>