summaryrefslogtreecommitdiff
path: root/httemplate/edit/process
diff options
context:
space:
mode:
Diffstat (limited to 'httemplate/edit/process')
-rwxr-xr-xhttemplate/edit/process/REAL_cust_pkg.cgi5
-rw-r--r--httemplate/edit/process/mailinglistmember.html6
-rw-r--r--httemplate/edit/process/part_device.html4
-rwxr-xr-xhttemplate/edit/process/rate_region.cgi2
-rw-r--r--httemplate/edit/process/svc_mailinglist.html11
-rw-r--r--httemplate/edit/process/svc_phone.html19
6 files changed, 40 insertions, 7 deletions
diff --git a/httemplate/edit/process/REAL_cust_pkg.cgi b/httemplate/edit/process/REAL_cust_pkg.cgi
index 22aab44e8..b5796ebf5 100755
--- a/httemplate/edit/process/REAL_cust_pkg.cgi
+++ b/httemplate/edit/process/REAL_cust_pkg.cgi
@@ -39,14 +39,15 @@ push @errors, '_setup_areyousure'
&& ! $cgi->param('setup_areyousure'); # and it wasn't confirmed
push @errors, '_start'
- if $hash{'start_date'} && $old->start_date # if a start date was added
- && $hash{'setup'}; # but there's a setup date
+ if $hash{'start_date'} && !$old->start_date # if a start date was added
+ && $hash{'setup'}; # but there's a setup date
my $new;
my $error;
if ( @errors ) {
$error = join(',', @errors);
} else {
+ warn join(',',%hash);
$new = new FS::cust_pkg \%hash;
$error = $new->replace($old);
}
diff --git a/httemplate/edit/process/mailinglistmember.html b/httemplate/edit/process/mailinglistmember.html
new file mode 100644
index 000000000..f1842b8ef
--- /dev/null
+++ b/httemplate/edit/process/mailinglistmember.html
@@ -0,0 +1,6 @@
+<% include( 'elements/process.html',
+ 'table' => 'mailinglistmember',
+ 'popup_reload' => 'Member added',
+ )
+%>
+%#XXX ACL
diff --git a/httemplate/edit/process/part_device.html b/httemplate/edit/process/part_device.html
index 399991fc8..2b7e1da49 100644
--- a/httemplate/edit/process/part_device.html
+++ b/httemplate/edit/process/part_device.html
@@ -1,10 +1,6 @@
<% include( 'elements/process.html',
'table' => 'part_device',
'viewall_dir' => 'browse',
- 'process_m2m' => {
- 'link_table' => 'export_device',
- 'target_table' => 'part_export',
- },
)
%>
<%init>
diff --git a/httemplate/edit/process/rate_region.cgi b/httemplate/edit/process/rate_region.cgi
index 882991e9d..8036f7388 100755
--- a/httemplate/edit/process/rate_region.cgi
+++ b/httemplate/edit/process/rate_region.cgi
@@ -39,7 +39,7 @@ my @dest_detail = map {
new FS::rate_detail {
'ratenum' => $ratenum,
map { $_ => $cgi->param("$_$ratenum") }
- qw( min_included min_charge sec_granularity classnum )
+ qw( min_included conn_charge conn_sec min_charge sec_granularity classnum )
};
} qsearch('rate', {} );
diff --git a/httemplate/edit/process/svc_mailinglist.html b/httemplate/edit/process/svc_mailinglist.html
new file mode 100644
index 000000000..580f6ccbd
--- /dev/null
+++ b/httemplate/edit/process/svc_mailinglist.html
@@ -0,0 +1,11 @@
+<% include( 'elements/svc_Common.html',
+ 'table' => 'svc_mailinglist',
+ 'fields' => [ fields('svc_mailinglist'), 'listname' ],
+ )
+%>
+<%init>
+
+die "access denied"
+ unless $FS::CurrentUser::CurrentUser->access_right('Provision customer service'); #something else more specific?
+
+</%init>
diff --git a/httemplate/edit/process/svc_phone.html b/httemplate/edit/process/svc_phone.html
index 27a703cdf..e02ec5ccc 100644
--- a/httemplate/edit/process/svc_phone.html
+++ b/httemplate/edit/process/svc_phone.html
@@ -1,5 +1,6 @@
<% include( 'elements/svc_Common.html',
'table' => 'svc_phone',
+ 'args_callback' => $args_callback,
)
%>
<%init>
@@ -7,4 +8,22 @@
die "access denied"
unless $FS::CurrentUser::CurrentUser->access_right('Provision customer service'); #something else more specific?
+my $args_callback = sub {
+ my( $cgi, $object ) = @_;
+
+ my %opt = ();
+ if ( $cgi->param('locationnum') == -1 ) {
+ my $cust_location = new FS::cust_location {
+ map { $_ => scalar($cgi->param($_)) }
+ qw( custnum address1 address2 city county state zip country )
+ };
+ $opt{'cust_location'} = $cust_location;
+ }
+
+ %opt;
+
+};
+
+
+
</%init>