|
|
|
@ -51,18 +51,7 @@ class SourceEvent extends Controller
|
|
|
|
|
$data['bao_name'] = $packageName;
|
|
|
|
|
$game = M('game', 'tab_')->where(['id' => $data['game_id']])->find();
|
|
|
|
|
$gameSourceService = new GameSourceService();
|
|
|
|
|
|
|
|
|
|
$gameSourceData = array_merge(
|
|
|
|
|
$data,
|
|
|
|
|
[
|
|
|
|
|
'plist_url' => '',
|
|
|
|
|
'org_plist_url' => '',
|
|
|
|
|
'file_url' => '',
|
|
|
|
|
'original_url' => '',
|
|
|
|
|
]
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
$result = $gameSourceService->sourcePack($gameSourceData, $game);
|
|
|
|
|
$result = $gameSourceService->sourcePack($data, $game);
|
|
|
|
|
if (!$result['status']) {
|
|
|
|
|
$this->error('添加失败' , U('GameSource/lists', ['type' => $data['type']]));
|
|
|
|
|
}
|
|
|
|
@ -127,17 +116,7 @@ class SourceEvent extends Controller
|
|
|
|
|
$game = M('game', 'tab_')->where(['id' => $data['game_id']])->find();
|
|
|
|
|
|
|
|
|
|
$gameSourceService = new GameSourceService();
|
|
|
|
|
|
|
|
|
|
$gameSourceData = array_merge(
|
|
|
|
|
$data,
|
|
|
|
|
[
|
|
|
|
|
'plist_url' => $game_source['plist_url'],
|
|
|
|
|
'org_plist_url' => $game_source['org_plist_url'],
|
|
|
|
|
'file_url' => $game_source['file_url'],
|
|
|
|
|
'original_url' => $game_source['original_url'],
|
|
|
|
|
]
|
|
|
|
|
);
|
|
|
|
|
$result = $gameSourceService->sourcePack($gameSourceData, $game);
|
|
|
|
|
$result = $gameSourceService->sourcePack($data, $game, $game_source);
|
|
|
|
|
if (!$result['status']) {
|
|
|
|
|
if ($from == "dev") {
|
|
|
|
|
$this->error('修改失败', U('Developers/source'));
|
|
|
|
|