Merge branch 'dev'

master
ELF 5 years ago
commit 1d129c0648

@ -204,6 +204,7 @@ class SourceEvent extends Controller
$newFileName = $temp[count($temp)-1];
$to = $file_url;
$originalUrl = '';
if ($file_type == 1) {
$new_file_url = $real_file_url;
$zip = new \ZipArchive;
@ -213,6 +214,7 @@ class SourceEvent extends Controller
} elseif ($file_type == 2) {
if (preg_match("/.ipa/", $file_url)) {
if($flag == 0 || ($flag ==1 && $newFileName != $file_name)) {
$originalUrl = $file_url;
$new_file_url = str_replace('Uploads/SourcePack', 'Uploads/Ios/original', $real_file_url);
$to = str_replace('Uploads/SourcePack', 'Uploads/Ios/original', $file_url);
$zip_open_game_source = zip_open($real_file_url);
@ -231,7 +233,7 @@ class SourceEvent extends Controller
$res = $zip -> open($new_file_url, \ZipArchive::CREATE);
$zip -> addFromString($url_ver, json_encode($data));
$zip -> close();
unlink($real_file_url);
// unlink($real_file_url);
}
}
}
@ -256,7 +258,7 @@ class SourceEvent extends Controller
}
$model = D('Game_source');
$model->where(['game_id'=>$game_id])->save(['file_url'=>$to]);
$model->where(['game_id'=>$game_id])->save(['file_url'=>$to, 'original_url' => $originalUrl]);
$plist = A("Plist");

@ -58,3 +58,6 @@ INSERT INTO `tab_promote_quick_menu` VALUES ('14', '1', '8', '1569719866');
INSERT INTO `tab_promote_quick_menu` VALUES ('15', '1', '9', '1569719870');
INSERT INTO `tab_promote_quick_menu` VALUES ('16', '1', '10', '1569719877');
INSERT INTO `tab_promote_quick_menu` VALUES ('18', '1', '1', '1569720739');
-- 2019-10-01
alter table tab_game_source add column `original_url` varchar(255) NOT NULL default '' COMMENT '原包路径';
Loading…
Cancel
Save