[freeside-commits] freeside/httemplate/elements tr-pkg_svc.html, 1.5, 1.6
Erik Levinson
levinse at wavetail.420.am
Wed Dec 8 13:37:47 PST 2010
Update of /home/cvs/cvsroot/freeside/httemplate/elements
In directory wavetail.420.am:/tmp/cvs-serv9662/httemplate/elements
Modified Files:
tr-pkg_svc.html
Log Message:
-rename qual export sub to part_export, RT7111
-initial commit of part_pkg_vendor implementation, RT7111
Index: tr-pkg_svc.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/tr-pkg_svc.html,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -w -d -r1.5 -r1.6
--- tr-pkg_svc.html 13 Nov 2010 23:23:48 -0000 1.5
+++ tr-pkg_svc.html 8 Dec 2010 21:37:45 -0000 1.6
@@ -31,6 +31,11 @@
% } elsif ( $pkg_svc->quantity ) {
% $quan = $pkg_svc->quantity;
% }
+%
+% my @exports = $pkg_svc->part_svc->part_export;
+% foreach my $export ( @exports ) {
+% push @possible_exports, $export if $export->can('external_pkg_map');
+% }
<TR>
<TD>
@@ -62,6 +67,32 @@
</TR></TABLE></TD></TR></TABLE>
+% if ( scalar(@possible_exports) > 0 || scalar(@mapped_exports) > 0 ) {
+ <TABLE><TR>
+ <TH BGCOLOR="#dcdcdc">Export</TH>
+ <TH BGCOLOR="#dcdcdc">Vendor Package Id <FONT SIZE="-2">(blank to delete)</FONT></TH>
+ </TR>
+% foreach my $export ( @mapped_exports ) {
+ <TR>
+ <TD><% $export->exportname %></TD>
+ <TD><INPUT TYPE="text" NAME="export<% $export->exportnum %>"
+ SIZE="30" VALUE="<% $vendor_pkg_ids{$export->exportnum} %>">
+ </TD>
+ </TR>
+% }
+% foreach my $export ( @possible_exports ) {
+% unless ( defined $vendor_pkg_ids{$export->exportnum} ) {
+ <TR>
+ <TD><% $export->exportname %></TD>
+ <TD>
+ <INPUT TYPE="text" NAME="export<% $export->exportnum %>" SIZE="30">
+ </TD>
+ </TR>
+% }
+% }
+ </TABLE>
+% }
+
</TD>
</TR>
@@ -97,4 +128,12 @@
my $count = 0;
my $columns = 3;
+my @possible_exports = ();
+my @mapped_exports = ();
+my @part_pkg_vendor = $part_pkg->part_pkg_vendor;
+foreach my $part_pkg_vendor ( @part_pkg_vendor ) {
+ push @mapped_exports, $part_pkg_vendor->part_export;
+}
+my %vendor_pkg_ids = $part_pkg->vendor_pkg_ids;
+
</%init>
More information about the freeside-commits
mailing list