Model_bh.php 473 B

12345678910111213141516171819
  1. <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
  2. class Model_bh extends Lin_Model
  3. {
  4. function __construct(){
  5. parent::__construct();
  6. $this->load->database();
  7. $this->table = 'bh';
  8. $this->load_table('bh');
  9. }
  10. /** 通过名称查找 */
  11. public function get_sku($sku)
  12. {
  13. return $this->find("sku = '$sku'");
  14. }
  15. public function get_features($features)
  16. {
  17. return $this->find("features = '$features'");
  18. }
  19. } //end class