diff --git a/sf-ui/src/views/FDS/publishList/components/addPack.vue b/sf-ui/src/views/FDS/publishList/components/addPack.vue index 891f169..e612f5d 100644 --- a/sf-ui/src/views/FDS/publishList/components/addPack.vue +++ b/sf-ui/src/views/FDS/publishList/components/addPack.vue @@ -10,11 +10,11 @@ > @@ -35,7 +35,7 @@ @@ -49,6 +49,12 @@ import { listINFO } from '@/api/FDS/installList' export default { name: 'AddPack', dicts: ['sys_yes_no'], + props: { + systemType: { + type: String, + default: '' + } + }, data() { return { // 遮罩层 @@ -66,8 +72,7 @@ export default { pageNum: 1, pageSize: 10, sysApkName: null, - appCode: '000000', - sysType: '' + appCode: '000000' } } }, @@ -79,7 +84,12 @@ export default { /** 查询参数列表 */ getList() { this.loading = true - listINFO(this.queryParams).then(response => { + console.log(this.systemType) + listINFO( + { + ...this.queryParams, + sysType: this.systemType + }).then(response => { this.moduleList = response.rows this.total = response.total this.loading = false @@ -99,11 +109,13 @@ export default { }, /** 新增当前包的按钮 */ - addPack(id, version, sysType) { + addPack(row) { this.$emit('addPack', { - apkId: id, - version: version, - sysType: sysType + apkId: row.id, + version: row.version, + sysType: row.sysType, + sysApkName: row.sysApkName, + sysApk: row.sysApk }) }, diff --git a/sf-ui/src/views/deployment/module/index.vue b/sf-ui/src/views/deployment/module/index.vue index 189a854..6117843 100644 --- a/sf-ui/src/views/deployment/module/index.vue +++ b/sf-ui/src/views/deployment/module/index.vue @@ -164,7 +164,7 @@ @getSize="getSize" /> - system/oss/upload + diff --git a/sf-ui/src/views/deployment/publish/component/detail.vue b/sf-ui/src/views/deployment/publish/component/detail.vue index 1b609cf..a1ed8af 100644 --- a/sf-ui/src/views/deployment/publish/component/detail.vue +++ b/sf-ui/src/views/deployment/publish/component/detail.vue @@ -9,18 +9,20 @@ > - + {{ form.applyId }} + - + {{ form.appName }} + - - - android - IOS - HarmonyOS - + {{ form.systemType }} + + + + + @@ -28,10 +30,8 @@ - - - {{ form.apkId }} - + + {{ form.sysApkName }} @@ -148,6 +148,7 @@ import { getPublish } from '@/api/deployment/publish' import { listEnvironment } from '@/api/deployment/environment' +import { getINFO } from '@/api/FDS/installList' export default { name: 'AddPack', @@ -168,7 +169,9 @@ export default { title: '添加安装包', loading: true, configName: undefined, - form: {}, + form: { + sysApkName: null + }, moduleList: [], // 显示搜索条件 showSearch: true, @@ -210,10 +213,17 @@ export default { getPublish(id).then(response => { this.form = response.data this.open = true - this.title = '详情' + this.title = '发布详情' + this.getPackList(this.form.apkId) + }) + }, + /** 查询参数列表 */ + getPackList(id) { + getINFO(id).then(response => { + this.form.sysApkName = response.data.sysApkName + console.log(this.form) }) }, - /** 搜索按钮操作 */ handleQuery() { this.queryParams.pageNum = 1 diff --git a/sf-ui/src/views/deployment/publish/index.vue b/sf-ui/src/views/deployment/publish/index.vue index d3d2cb4..3228054 100644 --- a/sf-ui/src/views/deployment/publish/index.vue +++ b/sf-ui/src/views/deployment/publish/index.vue @@ -199,7 +199,7 @@ icon="el-icon-top" size="mini" type="text" - @click="handlePublish(scope.row)" + @click="handlePublish(scope.row.id)" >发布 @@ -260,19 +260,32 @@ - - android - IOS - HarmonyOS - + + + + + + + + + - - + + + + + + - + @@ -369,14 +382,13 @@ - + @@ -397,10 +409,11 @@ import AddPack from '@/views/FDS/publishList/components/addPack.vue' import DetailModal from './component/detail.vue' import { listEnvironment } from '@/api/deployment/environment' import { getApplicationName } from '@/utils/application' +import { getINFO } from '@/api/FDS/installList' export default { name: 'Publish', - dicts: ['release_environment', 'sys_yes_no', 'release_strategy', 'release_user_type', 'release_status'], + dicts: ['release_environment', 'sys_yes_no', 'release_strategy', 'release_user_type', 'release_status', 'sys_apk_type'], components: { AddPack, DetailModal @@ -444,6 +457,12 @@ export default { }, // 表单参数 form: {}, + queryParamsPack: { + pageNum: 1, + pageSize: 10, + sysApkName: null, + appCode: '000000' + }, // 表单校验 rules: { appName: [ @@ -568,8 +587,18 @@ export default { this.form = response.data this.open = true this.title = '修改发布列表' + this.getPackList(this.form.apkId) }) }, + + /** 查询参数列表 */ + getPackList(id) { + this.loading = true + getINFO(id).then(response => { + this.form.sysApkName = response.data.sysApkName + }) + }, + /** 提交按钮 */ submitForm() { this.$refs['form'].validate(valid => { @@ -578,6 +607,7 @@ export default { let data = Object.assign({}, this.form) delete data.explain updatePublish(data).then(response => { + console.log(data) this.$modal.msgSuccess('修改成功') this.loading = false this.open = false @@ -604,18 +634,18 @@ export default { let data = Object.assign({}, this.form) delete data.explain updatePublish(data).then(response => { - this.$modal.msgSuccess('修改成功') + this.handlePublish(data.id) this.loading = false this.open = false - this.handlePublish(data.id) + // this.getList() }) } else { addPublish(this.form).then((res) => { - this.$modal.msgSuccess('新增成功') + this.loading = false this.open = false - this.handlePublish(res.id) + // this.handlePublish(res.id) // this.getList() }) } @@ -646,9 +676,12 @@ export default { }, addPack(e) { + this.form.apkId = e.apkId this.form.version = e.version this.form.systemType = e.sysType + this.form.sysApkName = e.sysApkName + this.form.sysApk = e.sysApk this.packOpen = false }, @@ -667,8 +700,13 @@ export default { }, // 选择系统做一些逻辑判断 - changeSys(sysType) { - this.form.systemType = sysType + changeSys() { + // this.form.systemType = sysType + this.form.apkId = null + this.form.version = null + this.form.sysApkName = null + this.form.appStoreAddress = null + console.log(this.form, 99999999) }, /**下载安装包*/ handleDownload() { @@ -677,12 +715,14 @@ export default { /**下架*/ handleDown(row) { soldPublish(row.id).then(response => { + this.$modal.msgSuccess('下架成功') this.getList() }) }, /**发布*/ - handlePublish(row) { - publish(row.id).then(response => { + handlePublish(id) { + publish(id).then(response => { + this.$modal.msgSuccess('发布成功') this.getList() }) },