From 85a1982129dfbe614de4058974f3f162bb4b6023 Mon Sep 17 00:00:00 2001 From: nineven Date: Sun, 3 May 2020 23:03:24 +0800 Subject: [PATCH] add new functions --- .../src/components/FirAppInfossecurity.vue | 6 +- fir_client/src/components/FirApps.vue | 36 +-- fir_client/src/components/FirDownload.vue | 14 +- .../src/components/FirSuperSignBase.vue | 139 +++++++++++- fir_ser/api/admin.py | 1 + fir_ser/api/migrations/0001_initial.py | 157 ++++++++++--- .../api/migrations/0002_auto_20200303_1940.py | 19 -- .../api/migrations/0002_auto_20200503_1120.py | 26 +++ fir_ser/api/migrations/0003_apptodeveloper.py | 28 +++ .../api/migrations/0003_auto_20200306_1734.py | 27 --- .../api/migrations/0004_auto_20200306_2331.py | 27 --- .../api/migrations/0005_auto_20200307_0800.py | 22 -- .../api/migrations/0006_auto_20200307_0810.py | 22 -- .../0007_appreleaseinfo_changelog.py | 18 -- .../api/migrations/0008_auto_20200307_1249.py | 23 -- .../api/migrations/0009_auto_20200309_1424.py | 26 --- .../api/migrations/0010_auto_20200309_1918.py | 27 --- .../api/migrations/0011_auto_20200310_1019.py | 23 -- .../api/migrations/0012_userinfo_head_img.py | 18 -- .../api/migrations/0013_auto_20200323_2020.py | 44 ---- .../api/migrations/0014_userinfo_storage.py | 19 -- .../api/migrations/0015_auto_20200326_1454.py | 28 --- .../api/migrations/0016_auto_20200327_1121.py | 35 --- .../api/migrations/0017_auto_20200331_1543.py | 28 --- .../api/migrations/0018_auto_20200407_1134.py | 28 --- .../api/migrations/0019_auto_20200407_1135.py | 18 -- .../api/migrations/0020_auto_20200407_1157.py | 21 -- .../api/migrations/0021_auto_20200410_1141.py | 28 --- fir_ser/api/migrations/0022_apps_isshow.py | 18 -- .../migrations/0023_appreleaseinfo_udid.py | 18 -- .../api/migrations/0024_auto_20200413_1557.py | 28 --- .../0025_appstorage_updated_time.py | 18 -- .../api/migrations/0026_auto_20200414_1505.py | 18 -- .../api/migrations/0027_apps_issupersign.py | 18 -- fir_ser/api/migrations/0028_appudid.py | 31 --- .../api/migrations/0029_auto_20200416_0915.py | 38 ---- .../migrations/0030_appudid_updated_time.py | 18 -- .../api/migrations/0031_appudid_is_signed.py | 18 -- ...ppiosdeveloperinfo_appsupersignusedinfo.py | 49 ---- .../api/migrations/0033_auto_20200425_1601.py | 23 -- .../0034_appiosdeveloperinfo_certid.py | 18 -- fir_ser/api/models.py | 21 +- fir_ser/api/utils/app/iossignapi.py | 24 +- fir_ser/api/utils/app/shellcmds.py | 15 +- fir_ser/api/utils/app/supersignutils.py | 212 ++++++++++++++++-- fir_ser/api/utils/crontab/runWin.py | 53 +++++ fir_ser/api/utils/serializer.py | 4 +- fir_ser/api/utils/storage/caches.py | 30 ++- fir_ser/api/views/apps.py | 25 ++- fir_ser/api/views/download.py | 13 +- fir_ser/api/views/login.py | 1 + fir_ser/api/views/supersign.py | 63 +++++- fir_ser/fir_ser/urls.py | 3 + fir_ser/requirements.txt | 6 + fir_ser/supersign/scripts/apple_api.rb | 11 +- 55 files changed, 774 insertions(+), 928 deletions(-) delete mode 100644 fir_ser/api/migrations/0002_auto_20200303_1940.py create mode 100644 fir_ser/api/migrations/0002_auto_20200503_1120.py create mode 100644 fir_ser/api/migrations/0003_apptodeveloper.py delete mode 100644 fir_ser/api/migrations/0003_auto_20200306_1734.py delete mode 100644 fir_ser/api/migrations/0004_auto_20200306_2331.py delete mode 100644 fir_ser/api/migrations/0005_auto_20200307_0800.py delete mode 100644 fir_ser/api/migrations/0006_auto_20200307_0810.py delete mode 100644 fir_ser/api/migrations/0007_appreleaseinfo_changelog.py delete mode 100644 fir_ser/api/migrations/0008_auto_20200307_1249.py delete mode 100644 fir_ser/api/migrations/0009_auto_20200309_1424.py delete mode 100644 fir_ser/api/migrations/0010_auto_20200309_1918.py delete mode 100644 fir_ser/api/migrations/0011_auto_20200310_1019.py delete mode 100644 fir_ser/api/migrations/0012_userinfo_head_img.py delete mode 100644 fir_ser/api/migrations/0013_auto_20200323_2020.py delete mode 100644 fir_ser/api/migrations/0014_userinfo_storage.py delete mode 100644 fir_ser/api/migrations/0015_auto_20200326_1454.py delete mode 100644 fir_ser/api/migrations/0016_auto_20200327_1121.py delete mode 100644 fir_ser/api/migrations/0017_auto_20200331_1543.py delete mode 100644 fir_ser/api/migrations/0018_auto_20200407_1134.py delete mode 100644 fir_ser/api/migrations/0019_auto_20200407_1135.py delete mode 100644 fir_ser/api/migrations/0020_auto_20200407_1157.py delete mode 100644 fir_ser/api/migrations/0021_auto_20200410_1141.py delete mode 100644 fir_ser/api/migrations/0022_apps_isshow.py delete mode 100644 fir_ser/api/migrations/0023_appreleaseinfo_udid.py delete mode 100644 fir_ser/api/migrations/0024_auto_20200413_1557.py delete mode 100644 fir_ser/api/migrations/0025_appstorage_updated_time.py delete mode 100644 fir_ser/api/migrations/0026_auto_20200414_1505.py delete mode 100644 fir_ser/api/migrations/0027_apps_issupersign.py delete mode 100644 fir_ser/api/migrations/0028_appudid.py delete mode 100644 fir_ser/api/migrations/0029_auto_20200416_0915.py delete mode 100644 fir_ser/api/migrations/0030_appudid_updated_time.py delete mode 100644 fir_ser/api/migrations/0031_appudid_is_signed.py delete mode 100644 fir_ser/api/migrations/0032_appiosdeveloperinfo_appsupersignusedinfo.py delete mode 100644 fir_ser/api/migrations/0033_auto_20200425_1601.py delete mode 100644 fir_ser/api/migrations/0034_appiosdeveloperinfo_certid.py create mode 100644 fir_ser/api/utils/crontab/runWin.py diff --git a/fir_client/src/components/FirAppInfossecurity.vue b/fir_client/src/components/FirAppInfossecurity.vue index c78d1bf..0984e3f 100644 --- a/fir_client/src/components/FirAppInfossecurity.vue +++ b/fir_client/src/components/FirAppInfossecurity.vue @@ -54,7 +54,7 @@ inactive-value="off"> - + 清理开发者账户脏数据 @@ -79,9 +79,13 @@ passwordflag:false, showdownloadflag:false, showsupersignflag:false, + clecount:0 } }, methods: { + clean_app(){ + this.saveappinfo({"clean":true}) + }, saveappinfo(data) { updateapp(data => { if (data.code === 1000) { diff --git a/fir_client/src/components/FirApps.vue b/fir_client/src/components/FirApps.vue index 29159b9..d3a89aa 100644 --- a/fir_client/src/components/FirApps.vue +++ b/fir_client/src/components/FirApps.vue @@ -8,11 +8,15 @@ :title="getDelappTitle" :visible.sync="willDeleteApp" width="50%"> - 删除后不可恢复,请谨慎操作 + + 请先在权限管理页面关闭超级签名 + 删除后不可恢复,请谨慎操作 + 取 消 - 确 定 - + 确 定 + 确 定 + @@ -337,18 +341,21 @@ 打包类型: - - {{ r.master_release.release_type|getiOStype }} - + + + {{ r.master_release.release_type|getiOStype }} + 超级签名 + + 第三方平台下载: - - - {{ r.master_release.binary_url| autoformat}} - - + + + {{ r.master_release.binary_url| autoformat}} + + @@ -364,8 +371,10 @@ 预览 + - @@ -739,7 +748,8 @@ return size / 1000; }, autoformat: function (packname) { - if ((packname.length) > 20) { + + if (packname && (packname.length) > 20) { return packname.split('').slice(0, 20).join('') + '...'; } else { return packname diff --git a/fir_client/src/components/FirDownload.vue b/fir_client/src/components/FirDownload.vue index 1444c04..6e4b77c 100644 --- a/fir_client/src/components/FirDownload.vue +++ b/fir_client/src/components/FirDownload.vue @@ -31,7 +31,8 @@ -

{{ mcurrentappinfo.release_type|getiOStype }}

+

超级签

+

{{ mcurrentappinfo.release_type|getiOStype }}

@@ -175,7 +176,10 @@ this.isdownload = true; getdownloadurl(res=>{ if(res.code === 1000){ - + if(res.data.download_url === ""){ + window.location.href=this.full_url; + return + } if(this.currentappinfo.type === 1){ if(this.currentappinfo.issupersign && this.udid !== this.$route.query.udid){ if(this.agent !== ''){ @@ -209,7 +213,7 @@ 'short': this.currentappinfo.short, 'release_id': this.mcurrentappinfo.release_id, 'password':this.password, - 'udid':this.udid + 'udid':this.udid, }, 'app_id': this.currentappinfo.app_id }) @@ -223,7 +227,7 @@ }) }, getDownloadTokenFun() { - let params={ "short": this.$route.params.short }; + let params={ "short": this.$route.params.short ,"time":new Date().getTime()}; if(this.$route.query.release_id){ params["release_id"]=this.$route.query.release_id } @@ -363,7 +367,7 @@ this.getAgent(); }, mounted() { this.getDownloadTokenFun(); - this.full_url = location.href; + this.full_url = location.href.split("?")[0]; this.qrcode(); },filters:{ getiOStype: function (type) { diff --git a/fir_client/src/components/FirSuperSignBase.vue b/fir_client/src/components/FirSuperSignBase.vue index b95a57b..b15638a 100644 --- a/fir_client/src/components/FirSuperSignBase.vue +++ b/fir_client/src/components/FirSuperSignBase.vue @@ -1,5 +1,48 @@