X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Fchange_history_common.html;h=63337cb6ab3e587ec4619b3cd3041021ff5e73aa;hb=016ff1020b1c0f1c4258c17209a9a7e48402dd5c;hp=9e19539d096258f82b3b5ec5e2c61dfc668caa68;hpb=fb4ab1073f0d15d660c6cdc4e07afebf68ef3924;p=freeside.git
diff --git a/httemplate/elements/change_history_common.html b/httemplate/elements/change_history_common.html
index 9e19539d0..63337cb6a 100644
--- a/httemplate/elements/change_history_common.html
+++ b/httemplate/elements/change_history_common.html
@@ -15,16 +15,10 @@
+
-% my $otaker = $item->history_user;
+% my $otaker = '';
+% if ( $item->history_usernum ) {
+% $access_user{ $item->history_usernum } ||=
+% FS::access_user->by_key( $item->history_usernum );
+% $otaker = $access_user{ $item->history_usernum }->username
+% if $access_user{ $item->history_usernum };
+% }
+% $otaker ||= $item->history_user;
% $otaker = 'auto billing' if $otaker eq 'fs_daily';
% $otaker = 'customer self-service' if $otaker eq 'fs_selfservice';
% $otaker = 'job queue' if $otaker eq 'fs_queue';
+% $otaker = 'system bootstrap user' if $otaker eq 'fs_bootstrap';
<% $otaker %>
|
+
% my $d = time2str('%b %o, %Y', $item->history_date );
% $d =~ s/ / /g;
<% $d %>
|
+
% my $t = time2str('%r', $item->history_date );
% $t =~ s/ / /g;
@@ -78,41 +117,26 @@
|
% my $label = '';
-% $label = $item->table;
-% $label =~ s/^h_//;
-% $label = $tables{$label};
-% if ( $single_cust ) {
-% $label = &{ $h_table_labelsub{$item->table} }( $item, $label )
-% if $h_table_labelsub{$item->table};
-% }
+% if ( $item->table eq 'legacy_cust_history' ) {
+% $label = $item->item;
+% } else {
+% $label = $item->table;
+% $label =~ s/^h_//;
+% $label = $tables{$label};
+% $label = &{ $h_table_labelsub{$item->table} }( $item, $label )
+% if $single_cust && $h_table_labelsub{$item->table};
+% }
<% $label %>
|
+
- <% $action{$item->history_action} %>
+ <% $action{$item->history_action} || ucfirst($item->history_action) |h %>
|
+
- <% join(', ',
- map { my $value = ( $_ =~ /(^pay(info|cvv)|^ss|_password)$/ )
- ? 'N/A'
- : $item->get($_);
- $value = time2str($cust_pkg_date_format, $value)
- if $item->table eq 'h_cust_pkg'
- && $cust_pkg_date_fields{$_}
- && $value;
-
- $value = substr($value, 0, 77).'...' if length($value) > 80;
- $value = encode_entities($value);
- "$_:$value";
- }
- grep { $history_other
- ? ( $item->get($_) ne $history_other->get($_) )
- : ( $item->get($_) =~ /\S/ )
- }
- grep { ! /^(history|custnum$)/i }
- $item->fields
- )
- %>
+ <% $description %>
|
+
% }
@@ -131,14 +155,14 @@ die "access deined"
my %action = (
'insert' => 'Insert', #'Create',
- 'replace_old' => 'Change from',
- 'replace_new' => 'Change to',
+ 'replace_old' => "Change\xA0from",
+ 'replace_new' => "Change\xA0to",
'delete' => 'Remove',
);
my %cust_pkg_date_fields = map { $_=>1 } qw(
start_date setup bill last_bill susp adjourn cancel expire contract_end
- change_date
+ resume change_date
);
# finding the other replace row
@@ -178,6 +202,12 @@ my $svc_labelsub = sub {
$label. ':