game2006api/webapp/models/UserWalletRecord.php
aozhiwei 38c7acc215 1
2022-03-28 16:20:28 +08:00

39 lines
860 B
PHP

<?php
namespace models;
use mt;
use phpcommon\SqlHelper;
class UserWalletRecord extends BaseModel {
public static function find($conn, $txHash)
{
$row = SqlHelper::ormSelectOne(
$conn,
't_user_wallet_record',
array(
'txHash' => $txHash,
)
);
return $row;
}
public static function add($txHash, $dir, $accountId, $type, $value)
{
SqlHelper::insert(
$conn,
't_user_wallet_record',
array(
'txhash' => $txHash,
'dir' => $dir,
'account_id' => $accountId,
'type' => $type,
'value' => $value,
'createtime' => myself()->_getNowTime(),
'modifytime' => myself()->_getNowTime()
));
}
}