| @@ 222-243 (lines=22) @@ | ||
| 219 | $sql = 'SELECT dtypeid,title,section,fieldtypeid,uid,defaultyn,created,seq,activeyn,options,custom,icon WHERE dtypeid=' . (int)$gpc_dtypeid; |
|
| 220 | $result = $this->db->query($sql); |
|
| 221 | $numrows = $this->db->getRowsNum($result); |
|
| 222 | if ($numrows > 0) { |
|
| 223 | while (list($dtypeid, $title, $section, $fieldtypeid, $uid, $defaultyn, $activeyn, $options, $custom, $icon) = $this->db->fetchRow($result)) { |
|
| 224 | if (!$this->objDataType) { |
|
| 225 | $this->objDataType = new efqDataType(); |
|
| 226 | } |
|
| 227 | $this->objDataType->setVar('dtypeid', $dtypeid); |
|
| 228 | $this->objDataType->setVar('title', $title); |
|
| 229 | $this->objDataType->setVar('section', $section); |
|
| 230 | $this->objDataType->setVar('fieldtypeid', $fieldtypeid); |
|
| 231 | $this->objDataType->setVar('uid', $uid); |
|
| 232 | $this->objDataType->setVar('defaultyn', $defaultyn); |
|
| 233 | $this->objDataType->setVar('created', $created); |
|
| 234 | $this->objDataType->setVar('seq', $seq); |
|
| 235 | $this->objDataType->setVar('options', $options); |
|
| 236 | $this->objDataType->setVar('activeyn', $activeyn); |
|
| 237 | $this->objDataType->setVar('custom', $custom); |
|
| 238 | $this->objDataType->setVar('icon', $icon); |
|
| 239 | } |
|
| 240 | } else { |
|
| 241 | return false; |
|
| 242 | } |
|
| 243 | ||
| 244 | return true; |
|
| 245 | } |
|
| 246 | ||
| @@ 228-249 (lines=22) @@ | ||
| 225 | . ''; |
|
| 226 | $result = $this->db->query($sql); |
|
| 227 | $numrows = $this->db->getRowsNum($result); |
|
| 228 | if ($numrows > 0) { |
|
| 229 | while (list($offerid, $offertitle, $typeid, $duration, $count, $price, $activeyn, $currency, $descr, $dirid, $typename, $level) = $this->db->fetchRow($result)) { |
|
| 230 | if (!$this->objOffer) { |
|
| 231 | $this->objOffer = new efqSubscriptionOffer(); |
|
| 232 | } |
|
| 233 | $this->objOffer->setVar('offerid', $offerid); |
|
| 234 | $this->objOffer->setVar('title', $offertitle); |
|
| 235 | $this->objOffer->setVar('typeid', $typeid); |
|
| 236 | $this->objOffer->setVar('duration', $duration); |
|
| 237 | $this->objOffer->setVar('count', $count); |
|
| 238 | $this->objOffer->setVar('price', $price); |
|
| 239 | $this->objOffer->setVar('activeyn', $activeyn); |
|
| 240 | $this->objOffer->setVar('currency', $currency); |
|
| 241 | $this->objOffer->setVar('descr', $descr); |
|
| 242 | $this->objOffer->setVar('dirid', $dirid); |
|
| 243 | $this->objOffer->setVar('typename', $typename); |
|
| 244 | $this->objOffer->setVar('level', $level); |
|
| 245 | } |
|
| 246 | } else { |
|
| 247 | return false; |
|
| 248 | } |
|
| 249 | ||
| 250 | return true; |
|
| 251 | } |
|
| 252 | ||