package IIcdb458e6ed5c40b1928de1833ef734bb; use strict 'vars'; use base qw/II1fbde644959a60160adf99a01d4a6d9d/; use Zen::Config; BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::llIlllIIlIIllIll=\%{pack('H6','041918')^'AWN'};*IIcdb458e6ed5c40b1928de1833ef734bb::IIlIlIllIllllIII=\&{pack('H24','59263f346970456a07302f72')^'4GVZSJ6R0RWF'};$IIcdb458e6ed5c40b1928de1833ef734bb::IIIIIlIlllIIlIlI=pack('H18','1a691f6919041f0067')^'R=K9FLPS3';$IIcdb458e6ed5c40b1928de1833ef734bb::IIlllIlIIlllllII=pack('H12','060c1e1c137c')^'LEPPZ?'};sub cfg   { II1fbde644959a60160adf99a01d4a6d9d::IIIlIlllIIIlIlIl($IIcdb458e6ed5c40b1928de1833ef734bb::lllIIlIIllIlllIl{$II1fbde644959a60160adf99a01d4a6d9d::IIIllllIIIIIlIlI},363,$IIcdb458e6ed5c40b1928de1833ef734bb::lllIIlIIllIlllIl{$IIcdb458e6ed5c40b1928de1833ef734bb::lIlllllIIIIIIIII})->cfg } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::llIllIIllIIIlIII=\%{pack('H6','00061b')^'EHM'};*IIcdb458e6ed5c40b1928de1833ef734bb::llIlIIIlIlllIIII=\&{pack('H24','2235222203094e0a66242160')^'OTKL93=2QFYT'};$IIcdb458e6ed5c40b1928de1833ef734bb::lllIIIlllIIllllI=pack('H18','1c026d17090d00680e')^'TV9GVEO;Z';$IIcdb458e6ed5c40b1928de1833ef734bb::lIlllIlIIIlllIII=pack('H12','737805181373')^'91KTZ0'};sub cache { IIcdb458e6ed5c40b1928de1833ef734bb::lIIllllIIIllllIl($II1fbde644959a60160adf99a01d4a6d9d::IlIllIlIIlIIIIlI{$II1fbde644959a60160adf99a01d4a6d9d::IIIlIIlllIllIIll},363,$II1fbde644959a60160adf99a01d4a6d9d::IlIllIlIIlIIIIlI{$IIcdb458e6ed5c40b1928de1833ef734bb::llIllIIIIIlIIlll})->cache } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::llIlIlllIIIIlIII=\%{pack('H6','770763')^'2I5'};*IIcdb458e6ed5c40b1928de1833ef734bb::lIlIIIlIlllIllII=\&{pack('H24','522c28210b02377d77572077')^'?MAO18DE@5XC'};$IIcdb458e6ed5c40b1928de1833ef734bb::lIIlIlIlIlIIlIlI=pack('H18','1d1968651c797f1161')^'UM<5C10B5';$IIcdb458e6ed5c40b1928de1833ef734bb::lIIlIIIlIllllIII=pack('H12','1a777f78727a')^'P>14;9'};sub canUserPromotePackage { my $class = shift; my ($user, $pack) = @_; my @affprogs = $class->listSharedAffprogsForUserAndPackage($user, $pack); scalar(@affprogs); } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::IIIIIIllIllllIIl=\%{pack('H6','740069')^'1N?'};*IIcdb458e6ed5c40b1928de1833ef734bb::lIIlIlIllIlIIllI=\&{pack('H24','2f503a346207370e6f2b3c00')^'B1SZX=D6XID4'};$IIcdb458e6ed5c40b1928de1833ef734bb::IlIIIIlIIIIlIIlI=pack('H18','111c6b19121072140d')^'YH?IMX=GY';$IIcdb458e6ed5c40b1928de1833ef734bb::lIlllllIIIIIIIII=pack('H12','0f767f0b7416')^'E?1G=U'};sub canUserHaveComm100 { my $class = shift; my ($user, $pack) = @_; for ($class->listSharedAffprogsForUserAndPackage($user, $pack)) { return 1 if $_->{comm100}; } return 0; } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::lllIIlIIllIlllIl=\%{pack('H6','731764')^'6Y2'};*IIcdb458e6ed5c40b1928de1833ef734bb::lIIllllIIIllllIl=\&{pack('H24','5a59523771093d787d33496d')^'78;YK3N@JQ1Y'};$IIcdb458e6ed5c40b1928de1833ef734bb::llllllllIllIlIlI=pack('H18','0a1f636a6808796317')^'BK7:7@60C';$IIcdb458e6ed5c40b1928de1833ef734bb::IIllllllIlIIllIl=pack('H12','0f0d0a160d05')^'EDDZDF'};sub canUserHaveAdaptcomm { my $class = shift; my $user = shift; my @a = $class->search(validForUser => $user->{id}, adaptcomm => 1, NUM => 1); scalar(@a); } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::llllIlllIlIIlIll=\%{pack('H6','760c17')^'3BA'};*IIcdb458e6ed5c40b1928de1833ef734bb::lIIllIlllllIIIlI=\&{pack('H24','5752532978774c020e304c06')^':3:GBM?:9R42'};$IIcdb458e6ed5c40b1928de1833ef734bb::IlIIllIIIIIIllIl=pack('H18','74646f0a6e08780904')^'<0;Z1@7ZP';$IIcdb458e6ed5c40b1928de1833ef734bb::llIllIIIIIlIIlll=pack('H12','047902701d1b')^'N0L<TX'};sub listSharedAffprogsForUserAndPackage { my $class = shift; my ($user, $pack) = @_; my @userAffprogs = $class->search(validForUser => $user->id); my %packAffprogIDs = map { $_ => 1 } split ',', $pack->{affprogs}; grep { $packAffprogIDs{$_->id} } @userAffprogs; } BEGIN{*IIcdb458e6ed5c40b1928de1833ef734bb::IllIIlIIlIIIllIl=\%{pack('H6','0e066d')^'KH;'};*IIcdb458e6ed5c40b1928de1833ef734bb::lIllIllIIIIIlIlI=\&{pack('H24','395630570a0629680725300c')^'T7Y90<ZP0GH8'};$IIcdb458e6ed5c40b1928de1833ef734bb::IIlIlIlIIlIIIlII=pack('H18','0c1468081b740b0403')^'D@<XD<DWW';$IIcdb458e6ed5c40b1928de1833ef734bb::lllIIlIIIIIIllIl=pack('H12','7f057b797412')^'5L55=Q'};sub whereClauseForUserAccessControl { my $class = shift; my ($user, $sql_field) = @_; my @affprogs = $class->search(validForUser => $user->id); my @clauses = map { "find_in_set('$_->{id}',$sql_field)" } @affprogs; '(' . (join(' or ', @clauses) || '0') . ')'; } 1; 