[freeside-commits] freeside/FS/FS part_pkg.pm,1.97.2.1,1.97.2.2
Ivan,,,
ivan at wavetail.420.am
Sat Dec 19 11:10:48 PST 2009
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv30046
Modified Files:
Tag: FREESIDE_1_9_BRANCH
part_pkg.pm
Log Message:
fix package order to really display only those pacakges available
Index: part_pkg.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_pkg.pm,v
retrieving revision 1.97.2.1
retrieving revision 1.97.2.2
diff -u -d -r1.97.2.1 -r1.97.2.2
--- part_pkg.pm 4 Nov 2009 00:59:52 -0000 1.97.2.1
+++ part_pkg.pm 19 Dec 2009 19:10:45 -0000 1.97.2.2
@@ -1352,15 +1352,16 @@
"
(
- agentnum IS NOT NULL
- OR
- 0 < ( SELECT COUNT(*)
- FROM type_pkgs
- LEFT JOIN agent_type USING ( typenum )
- LEFT JOIN agent AS typeagent USING ( typenum )
- WHERE type_pkgs.pkgpart = part_pkg.pkgpart
- AND typeagent.agentnum IN ($agentnums)
- )
+ ( agentnum IS NOT NULL AND agentnum IN ($agentnums) )
+ OR ( agentnum IS NULL
+ AND EXISTS ( SELECT 1
+ FROM type_pkgs
+ LEFT JOIN agent_type USING ( typenum )
+ LEFT JOIN agent AS typeagent USING ( typenum )
+ WHERE type_pkgs.pkgpart = part_pkg.pkgpart
+ AND typeagent.agentnum IN ($agentnums)
+ )
+ )
)
";
More information about the freeside-commits
mailing list