projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
6493931
)
list disabled packages on agent type edit if they are still associated with the type
author
ivan
<ivan>
Thu, 1 Dec 2005 19:17:05 +0000
(19:17 +0000)
committer
ivan
<ivan>
Thu, 1 Dec 2005 19:17:05 +0000
(19:17 +0000)
httemplate/edit/agent_type.cgi
patch
|
blob
|
history
diff --git
a/httemplate/edit/agent_type.cgi
b/httemplate/edit/agent_type.cgi
index
6842163
..
84f4b65
100755
(executable)
--- a/
httemplate/edit/agent_type.cgi
+++ b/
httemplate/edit/agent_type.cgi
@@
-37,7
+37,15
@@
Agent Type
Select which packages agents of this type may sell to customers<BR>
Select which packages agents of this type may sell to customers<BR>
-<% foreach my $part_pkg ( qsearch('part_pkg',{ 'disabled' => '' }) ) { %>
+<% foreach my $part_pkg (
+ qsearch({ 'table' => 'part_pkg',
+ 'hashref' => { 'disabled' => '' },
+ 'select' => 'part_pkg.*',
+ 'addl_from' => 'LEFT JOIN type_pkgs USING ( pkgpart )',
+ 'extra_sql' => 'OR typenum = '. $agent_type->typenum,
+ })
+ ) {
+%>
<BR>
<INPUT TYPE="checkbox" NAME="pkgpart<%= $part_pkg->pkgpart %>" <%=
<BR>
<INPUT TYPE="checkbox" NAME="pkgpart<%= $part_pkg->pkgpart %>" <%=
@@
-50,7
+58,8
@@
Select which packages agents of this type may sell to customers<BR>
%> VALUE="ON">
<A HREF="<%= $p %>edit/part_pkg.cgi?<%= $part_pkg->pkgpart %>"><%= $part_pkg->pkgpart %>:
%> VALUE="ON">
<A HREF="<%= $p %>edit/part_pkg.cgi?<%= $part_pkg->pkgpart %>"><%= $part_pkg->pkgpart %>:
- <%= $part_pkg->pkg %> (<%= $part_pkg->comment %>)</A>
+ <%= $part_pkg->pkg %> - <%= $part_pkg->comment %></A>
+ <%= $part_pkg->disabled =~ /^Y/i ? ' (DISABLED)' : '' %>
<% } %>
<% } %>