SProductAlikeIspTopic.php 608 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. class SProductAlikeIspTopic extends MyActiveRecord {
  3. public static function model($className = __CLASS__)
  4. {
  5. return parent::model($className);
  6. }
  7. public function tableName()
  8. {
  9. return 'product_alike_isp_topic';
  10. }
  11. /**
  12. * 相同变式题数据
  13. * @param $examId
  14. * @param $select
  15. * @return array|null
  16. */
  17. public function getCommonTopic($examId, $select){
  18. $criteria = new CDbCriteria();
  19. $criteria->select = $select;
  20. $criteria->addCondition('exam_id='.$examId);
  21. return $this->findAll($criteria);
  22. }
  23. }