1
This commit is contained in:
parent
c120d56759
commit
bcff501224
@ -393,7 +393,7 @@ class BaseAuthedController extends BaseController {
|
|||||||
$headsDb = emptyReplace(json_decode($userInfo['head_list'], true), array());
|
$headsDb = emptyReplace(json_decode($userInfo['head_list'], true), array());
|
||||||
$headFramesDb = emptyReplace(json_decode($userInfo['head_frame_list'], true), array());
|
$headFramesDb = emptyReplace(json_decode($userInfo['head_frame_list'], true), array());
|
||||||
$heads = array_unique(array_merge($heads, $headsDb));
|
$heads = array_unique(array_merge($heads, $headsDb));
|
||||||
$headFrames = array_unique(array_merge($headFrames, $headFramesDb));
|
$headFrames = array_values(array_unique(array_merge($headFrames, $headFramesDb)));
|
||||||
$this->_updateUserInfo(array(
|
$this->_updateUserInfo(array(
|
||||||
'head_list' => json_encode($heads),
|
'head_list' => json_encode($heads),
|
||||||
'head_frame_list' => json_encode($headFrames),
|
'head_frame_list' => json_encode($headFrames),
|
||||||
|
@ -20,9 +20,14 @@ class Parachute extends BaseModel
|
|||||||
public static function addParachute($itemMeta){
|
public static function addParachute($itemMeta){
|
||||||
if ($itemMeta){
|
if ($itemMeta){
|
||||||
if ($itemMeta['type'] == mt\Item::PARACHUTE_TYPE){
|
if ($itemMeta['type'] == mt\Item::PARACHUTE_TYPE){
|
||||||
SqlHelper::insert(
|
SqlHelper::upsert(
|
||||||
myself()->_getSelfMysql(),
|
myself()->_getSelfMysql(),
|
||||||
't_parachute',
|
't_parachute',
|
||||||
|
array(
|
||||||
|
'account_id' => myself()->_getAccountId(),
|
||||||
|
'item_id' => $itemMeta['id'],
|
||||||
|
),
|
||||||
|
array(),
|
||||||
array(
|
array(
|
||||||
'account_id' => myself()->_getAccountId(),
|
'account_id' => myself()->_getAccountId(),
|
||||||
'item_id' => $itemMeta['id'],
|
'item_id' => $itemMeta['id'],
|
||||||
|
@ -46,17 +46,20 @@ class UserSeasonRing extends BaseModel
|
|||||||
|
|
||||||
public static function internalAddHero($conn, $itemMeta, $accountId)
|
public static function internalAddHero($conn, $itemMeta, $accountId)
|
||||||
{
|
{
|
||||||
$fieldsKv = array(
|
SqlHelper::upsert(
|
||||||
'account_id' => $accountId,
|
|
||||||
'item_id' => $itemMeta['id'],
|
|
||||||
'createtime' => myself()->_getNowTime(),
|
|
||||||
'modifytime' => myself()->_getNowTime()
|
|
||||||
);
|
|
||||||
|
|
||||||
SqlHelper::insert(
|
|
||||||
$conn,
|
$conn,
|
||||||
't_user_season_ring',
|
't_user_season_ring',
|
||||||
$fieldsKv
|
array(
|
||||||
|
'account_id' => $accountId,
|
||||||
|
'item_id' => $itemMeta['id'],
|
||||||
|
),
|
||||||
|
array(),
|
||||||
|
array(
|
||||||
|
'account_id' => $accountId,
|
||||||
|
'item_id' => $itemMeta['id'],
|
||||||
|
'createtime' => myself()->_getNowTime(),
|
||||||
|
'modifytime' => myself()->_getNowTime()
|
||||||
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user