diff --git a/src/components/generator/config.js b/src/components/generator/config.js index 1d1898a..d28f7e8 100644 --- a/src/components/generator/config.js +++ b/src/components/generator/config.js @@ -514,7 +514,7 @@ export const selectComponents = [ __slot__: { 'list-type': true }, - action: process.env.VUE_APP_API_ROOT + '/project/file/upload/', + action: process.env.VUE_APP_API_ROOT +process.env.VUE_APP_API_ROOT_TDUCK+ '/project/file/upload/', disabled: false, accept: '', name: 'file', @@ -665,7 +665,7 @@ export const assistComponents = [ }, color: '#000000', style: {width: '100%'}, - action: '/project/file/upload/' + action:`${process.env.VUE_APP_API_ROOT_TDUCK}/project/file/upload/` }, { typeId: 'SIGN_PAD', @@ -689,7 +689,7 @@ export const assistComponents = [ }, color: '#000000', style: {width: '100%'}, - action: '/project/file/upload/' + action: `${process.env.VUE_APP_API_ROOT_TDUCK}/project/file/upload/` }, { typeId: 'PAGINATION', diff --git a/src/components/parser/Parser.vue b/src/components/parser/Parser.vue index c68bee2..c0163b7 100644 --- a/src/components/parser/Parser.vue +++ b/src/components/parser/Parser.vue @@ -183,7 +183,7 @@ function setValue (event, config, scheme) { if (flag) { // 防止表单重新渲染 display被刷新 this.logicTriggerItemList.push(r.triggerFormItemId) - console.log(this.logicTriggerItemList) + document.querySelector(`div[cid="${r.triggerFormItemId}"]`).style.display = '' } else { _.remove(this.logicTriggerItemList, function (n) { @@ -240,7 +240,6 @@ function setOtherValueLabel (event, config) { // 临时保存其他的选项值 this.$nextTick(() => { this.$set(this[this.formConf.labelFormModel], `${config.__vModel__}other`, event) - console.log(this[this.formConf.labelFormModel]) setValueLabel.call(this, value, config.__config__, config) }) @@ -255,23 +254,21 @@ function setOtherValueLabel (event, config) { * @param scheme */ function setValueLabel (event, config, scheme) { - console.log(event) - console.log(config) - console.log(scheme) + // 需要处理的类型 如果是input等则不需要处理 let tagOptionKey = processType[config.tag] - debugger + if (tagOptionKey) { if (event instanceof Array) { // 多选 其他自定义输入 - if (!event.includes(0) && config.tag != 'el-cascader') { - // 如果多选里没有选择其他,就清掉other - this.$set(this[this.formConf.labelFormModel], `${scheme.__vModel__}other`, '') - // 同时把输入框清空 - document.querySelector('.' + config.tag).querySelector('.item-other-input').value = '' - } + // if (!event.includes(0) && config.tag != 'el-cascader') { + // // 如果多选里没有选择其他,就清掉other + // this.$set(this[this.formConf.labelFormModel], `${scheme.__vModel__}other`, '') + // // 同时把输入框清空 + // document.querySelector('.' + config.tag).querySelector('.item-other-input').value = '' + // } // debugger if (config.tag === 'el-cascader') { @@ -301,13 +298,13 @@ function setValueLabel (event, config, scheme) { } - console.log('最终结果') - console.log(this[this.formConf.labelFormModel]) + } else { + // 单选 其他自定义输入 if (event == 0) { - console.log(this[this.formConf.labelFormModel][`${scheme.__vModel__}other`]) + // 如果选择了其他,把label存在field字段,把输入框内容存在fieldother字段 let item = _.find(_.get(scheme, tagOptionKey), { 'value': event }) this.$set(this[this.formConf.labelFormModel], scheme.__vModel__, item.label) @@ -315,10 +312,10 @@ function setValueLabel (event, config, scheme) { } else { let item = _.find(_.get(scheme, tagOptionKey), { 'value': event }) this.$set(this[this.formConf.labelFormModel], scheme.__vModel__, item.label) - // 如果没有选择其他,就清掉other - this.$set(this[this.formConf.labelFormModel], `${scheme.__vModel__}other`, '') - // 同时把输入框清空 - document.querySelector('.' + config.tag).querySelector('.item-other-input').value = '""' + // // 如果没有选择其他,就清掉other + // this.$set(this[this.formConf.labelFormModel], `${scheme.__vModel__}other`, '') + // // 同时把输入框清空 + // document.querySelector('.' + config.tag).querySelector('.item-other-input').value = '""' } } } else if (config.tag === 'el-upload') { @@ -326,6 +323,9 @@ function setValueLabel (event, config, scheme) { } else { this.$set(this[this.formConf.labelFormModel], scheme.__vModel__, event) } + + console.log('最终结果') + console.log(this[this.formConf.labelFormModel]) } function getCascaderData (array, tagOptionKey, scheme) { diff --git a/src/utils/constants.js b/src/utils/constants.js index 1788c79..9d04e5f 100644 --- a/src/utils/constants.js +++ b/src/utils/constants.js @@ -4,7 +4,7 @@ export default { // 密码正则 passwordReg: /^.{6,}$/, passwordRegDesc: '密码最少为6位字符', - userUploadUrl: `${process.env.VUE_APP_API_ROOT}/user/file/upload`, + userUploadUrl: `${process.env.VUE_APP_API_ROOT}${process.env.VUE_APP_API_ROOT_TDUCK}/user/file/upload`, // 启用微信功能 // enableWx: process.env.VUE_APP_WX == 'OFF' enableWx: false diff --git a/src/views/account/member.vue b/src/views/account/member.vue index ffeb915..25dd471 100644 --- a/src/views/account/member.vue +++ b/src/views/account/member.vue @@ -1,469 +1,493 @@ diff --git a/src/views/form/editor/RightPanel.vue b/src/views/form/editor/RightPanel.vue index 5914c7b..0f13b38 100644 --- a/src/views/form/editor/RightPanel.vue +++ b/src/views/form/editor/RightPanel.vue @@ -1112,7 +1112,7 @@ export default { }; }, getUploadUrl () { - return `${process.env.VUE_APP_API_ROOT}/user/file/upload`; + return `${process.env.VUE_APP_API_ROOT}${process.env.VUE_APP_API_ROOT_TDUCK}/user/file/upload`; }, }, watch: { diff --git a/src/views/form/index.vue b/src/views/form/index.vue index 3b00105..b78de8f 100644 --- a/src/views/form/index.vue +++ b/src/views/form/index.vue @@ -18,7 +18,7 @@ - @@ -57,7 +57,7 @@ export default { components: { PreView }, data () { return { - publishStatus: false, + publishStatus: true, previewKey: +new Date(), previewDialogVisible: false, defaultActiveMenu: '', diff --git a/src/views/form/publish/index.vue b/src/views/form/publish/index.vue index aa3442b..cbaa1d3 100644 --- a/src/views/form/publish/index.vue +++ b/src/views/form/publish/index.vue @@ -83,18 +83,18 @@ 复制链接 --> - + 停止发布 - + @@ -233,6 +233,7 @@ export default { this.$api.post(`${process.env.VUE_APP_API_ROOT_TDUCK}/user/project/stop`, { 'key': this.projectKey }).then(res => { if (res.data) { this.msgSuccess('停止成功') + this.getProjectStatus() } }) diff --git a/src/views/form/setting/index.vue b/src/views/form/setting/index.vue index d715fbb..d649871 100644 --- a/src/views/form/setting/index.vue +++ b/src/views/form/setting/index.vue @@ -666,7 +666,7 @@ export default { } }, getUploadUrl () { - return `${process.env.VUE_APP_API_ROOT}/user/file/upload` + return `${process.env.VUE_APP_API_ROOT}${process.env.VUE_APP_API_ROOT_TDUCK}/user/file/upload` }, getUserInfo () { return JSON.parse(this.$store.getters['user/userInfo']) diff --git a/src/views/form/theme/index.vue b/src/views/form/theme/index.vue index 5e27980..db1a4fa 100644 --- a/src/views/form/theme/index.vue +++ b/src/views/form/theme/index.vue @@ -1,517 +1,521 @@