This commit is contained in:
hujiabin 2022-11-03 16:57:08 +08:00
parent a8230c99d9
commit 94919e7ee4

View File

@ -30,25 +30,25 @@ class Chip extends BaseModel
public static function getChipList($cb)
{
SqlHelper::ormSelect(
myself()->_getSelfMysql(),
't_chip',
array(
'account_id' => myself()->_getAccountId()
),
function ($row) use($cb) {
$cb($row);
}
);
foreach (NftService::getChips(myself()->_getOpenId()) as $nftDb) {
if (! $nftDb['deleted']){
$row = SqlHelper::ormSelectOne(
myself()->_getSelfMysql(),
't_chip',
array(
'token_id' => $nftDb['token_id'],
)
);
// SqlHelper::ormSelect(
// myself()->_getSelfMysql(),
// 't_chip',
// array(
// 'account_id' => myself()->_getAccountId()
// ),
// function ($row) use($cb) {
// $cb($row);
// }
// );
// foreach (NftService::getChips(myself()->_getOpenId()) as $nftDb) {
// if (! $nftDb['deleted']){
// $row = SqlHelper::ormSelectOne(
// myself()->_getSelfMysql(),
// 't_chip',
// array(
// 'token_id' => $nftDb['token_id'],
// )
// );
// if (!$row) {
// $itemMeta = mt\Item::get($nftDb['item_id']);
// if ($itemMeta) {
@ -62,11 +62,11 @@ class Chip extends BaseModel
// );
// }
// }
if ($row) {
$cb($row);
}
}
}
// if ($row) {
// $cb($row);
// }
// }
// }
}
public static function toDto($row)