${r}Contact name (last, first) |
-END
-
-print < ,
-
-END
-
-print <SS# | |
-Company | |
-${r}Address | |
- | |
-${r}City | | ${r}State/Country | | ${r}Zip | | !;
-
-($daytime,$night,$fax)=(
- $cust_main->daytime,
- $cust_main->night,
- $cust_main->fax,
-);
+%>
-print <Day Phone | |
-Night Phone | |
-Fax | |
-END
+
-print "$r required fields ";
+
+Billing address
+<%= include('cust_main/contact.html', $cust_main, '', 'bill_changed(this)', '' ) %>
-# service address
+
-if ( defined $cust_main->dbdef_table->column('ship_last') ) {
+<% if ( defined $cust_main->dbdef_table->column('ship_last') ) { %>
- print "\n", <
- function changed(what) {
- what.form.same.checked = false;
+
-END
+}
+
- print ' Service address ',
- '(ship_last ) {
- print ' CHECKED';
+<%
+ my $checked = '';
+ my $disabled = '';
+ my $disabledselect = '';
+ unless ( $cust_main->ship_last && $cgi->param('same') ne 'Y' ) {
+ $checked = 'CHECKED';
+ $disabled = 'DISABLED style="background-color: #dddddd"';
foreach (
- qw( last first company address1 address2 city state zip daytime night fax)
+ qw( last first company address1 address2 city county state zip country
+ daytime night fax )
) {
$cust_main->set("ship_$_", $cust_main->get($_) );
}
}
- print '>same as billing address) ';
-
- my($ship_last,$ship_first,$ship_company,$ship_address1,$ship_address2,$ship_city,$ship_zip)=(
- $cust_main->ship_last,
- $cust_main->ship_first,
- $cust_main->ship_company,
- $cust_main->ship_address1,
- $cust_main->ship_address2,
- $cust_main->ship_city,
- $cust_main->ship_zip,
- );
-
- print &itable("#cccccc"), <${r}Contact name (last, first) |
-END
-
- print < ,
-
-END
-
- print <
- Company | |
- ${r}Address | |
- | |
- ${r}City | | ${r}State/Country | | ${r}Zip | | !;
-
- my($ship_daytime,$ship_night,$ship_fax)=(
- $cust_main->ship_daytime,
- $cust_main->ship_night,
- $cust_main->ship_fax,
- );
-
- print <Day Phone | |
- Night Phone | |
- Fax | |
-END
+%>
- print "$r required fields ";
+
+Service address
+(>same as billing address)
+<%= include('cust_main/contact.html', $cust_main, 'ship_', '', $disabled ) %>
-}
+<% } %>
+<%
# billing info
sub expselect {
@@ -323,7 +242,9 @@ sub expselect {
$return .= ">$_";
}
$return .= qq!/ | !;
+ }
+ }
+
+ print "$r required fields for each billing type";
+
+}
if ( defined $cust_main->dbdef_table->column('comments') ) {
print "
Comments", &itable("#cccccc"),
@@ -404,11 +416,13 @@ unless ( $custnum ) {
#eslaf
my @part_pkg = grep { $_->svcpart('svc_acct') && $pkgpart->{ $_->pkgpart } }
- qsearch( 'part_pkg', {} );
+ qsearch( 'part_pkg', { 'disabled' => '' } );
if ( @part_pkg ) {
- print "
First package", &itable("#cccccc", "0 ALIGN=LEFT"), #apiabuse
+# print "
First package", &itable("#cccccc", "0 ALIGN=LEFT"),
+#apiabuse & undesirable wrapping
+ print "
First package", &itable("#cccccc"),
qq! |
Password |
-
+ |
(blank to generate) |
END
@@ -442,9 +458,9 @@ END
}
}
-$otaker = $cust_main->otaker;
+my $otaker = $cust_main->otaker;
print qq!!,
- qq!
!,
" |