Files
OMS/app/ome/model/tbgift/goods.php
2025-12-28 23:13:25 +08:00

24 lines
712 B
PHP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?php
/**
* Copyright © ShopeX http://www.shopex.cn. All rights reserved.
* See LICENSE file for license details.
*/
class ome_mdl_tbgift_goods extends dbeav_model{
var $has_many = array(
'product' => 'tbgift_product:replace'
);
function getGiftById($id){
return $this->db->select("SELECT * FROM sdb_ome_tbgift_goods where goods_id = '".$id."'");
}
function checkGiftByBn($bn){
return $this->db->select("SELECT goods_id FROM sdb_ome_tbgift_goods where gift_bn = '".addslashes($bn)."'");
}
function getGiftByBn($bn){
return $this->db->selectrow("SELECT goods_id FROM sdb_ome_tbgift_goods where gift_bn = '".addslashes($bn)."'");
}
}
?>