This commit is contained in:
aozhiwei 2024-10-10 16:17:34 +08:00
parent 9b2b25c591
commit 8db0c59e82

View File

@ -2,18 +2,22 @@
namespace services; namespace services;
require_once('models/HashRateShopBuyRecord.php');
require_once('mt/HashRateShop.php'); require_once('mt/HashRateShop.php');
require_once('mt/Item.php'); require_once('mt/Item.php');
use mt; use mt;
use phpcommon; use phpcommon;
use models\HashRateShopBuyRecord;
class HashRateShopService { class HashRateShopService {
public static function getGoodsList() public static function getGoodsList()
{ {
$goodsMetaList = mt\HashRateShop::all(); $goodsMetaList = mt\HashRateShop::all();
$buyRecordHash = ShopBuyRecord::allToHash(); $buyRecordHash = HashRateShopBuyRecord::allToHash();
$goodsList = array(); $goodsList = array();
foreach ($goodsMetaList as $goodsMeta) { foreach ($goodsMetaList as $goodsMeta) {
@ -65,7 +69,7 @@ class HashRateShopService {
} }
$errCode = 0; $errCode = 0;
$errMsg = ''; $errMsg = '';
$buyRecordHash = ShopBuyRecord::allToHash(); $buyRecordHash = HashRateShopBuyRecord::allToHash();
$boughtTimes = 1; $boughtTimes = 1;
$goodsId = $goodsMeta['goods_id']; $goodsId = $goodsMeta['goods_id'];
{ {