25 $sFields = $oOrderFile->getSelectFields();
26 $sShopId = $this->
getConfig()->getShopId();
28 $oOrderFile->addFieldName(
'oxorderfiles__oxarticletitle');
29 $oOrderFile->addFieldName(
'oxorderfiles__oxarticleartnum');
30 $oOrderFile->addFieldName(
'oxorderfiles__oxordernr');
31 $oOrderFile->addFieldName(
'oxorderfiles__oxorderdate');
33 $sSql =
"SELECT " . $sFields .
" ,
34 `oxorderarticles`.`oxtitle` AS `oxorderfiles__oxarticletitle`,
35 `oxorderarticles`.`oxartnum` AS `oxorderfiles__oxarticleartnum`,
36 `oxfiles`.`oxpurchasedonly` AS `oxorderfiles__oxpurchasedonly`,
37 `oxorder`.`oxordernr` AS `oxorderfiles__oxordernr`,
38 `oxorder`.`oxorderdate` AS `oxorderfiles__oxorderdate`,
39 IF( `oxorder`.`oxpaid` != '0000-00-00 00:00:00', 1, 0 ) AS `oxorderfiles__oxispaid`
41 LEFT JOIN `oxorderarticles` ON `oxorderarticles`.`oxid` = `oxorderfiles`.`oxorderarticleid`
42 LEFT JOIN `oxfiles` ON `oxfiles`.`oxid` = `oxorderfiles`.`oxfileid`
43 LEFT JOIN `oxorder` ON `oxorder`.`oxid` = `oxorderfiles`.`oxorderid`
44 WHERE `oxorder`.`oxuserid` = '" . $sUserId .
"'
45 AND `oxorderfiles`.`oxshopid` = '" . $sShopId .
"'
46 AND `oxorder`.`oxstorno` = 0
47 AND `oxorderarticles`.`oxstorno` = 0
48 ORDER BY `oxorder`.`oxordernr`";
61 $sFields = $oOrderFile->getSelectFields();
62 $sShopId = $this->
getConfig()->getShopId();
64 $oOrderFile->addFieldName(
'oxorderfiles__oxarticletitle');
65 $oOrderFile->addFieldName(
'oxorderfiles__oxarticleartnum');
67 $sSql =
"SELECT " . $sFields .
" ,
68 `oxorderarticles`.`oxtitle` AS `oxorderfiles__oxarticletitle`,
69 `oxorderarticles`.`oxartnum` AS `oxorderfiles__oxarticleartnum`,
70 `oxfiles`.`oxpurchasedonly` AS `oxorderfiles__oxpurchasedonly`
72 LEFT JOIN `oxorderarticles` ON `oxorderarticles`.`oxid` = `oxorderfiles`.`oxorderarticleid`
73 LEFT JOIN `oxfiles` ON `oxfiles`.`oxid` = `oxorderfiles`.`oxfileid`
74 WHERE `oxorderfiles`.`oxorderid` = '" . $sOrderId .
"' AND `oxorderfiles`.`oxshopid` = '" . $sShopId .
"'
75 AND `oxorderarticles`.`oxstorno` = 0";