Browse Source

除门类管理以外不需要自动生成项

master
xuhuajiao 1 year ago
parent
commit
5f0aa5ff8b
  1. 8
      src/views/components/category/SettingForm.vue
  2. 4
      src/views/system/archivesCategory/baseInfo/index.vue
  3. 4
      src/views/system/archivesCategory/descriptionPreview/index.vue
  4. 2
      src/views/system/archivesCategory/fieldManage/module/form.vue
  5. 2
      src/views/system/archivesCategory/form.vue
  6. 4
      src/views/system/fileLibraryManage/descriptionPreview/index.vue
  7. 2
      src/views/system/fileLibraryManage/fieldManage/module/form.vue
  8. 1
      src/views/system/fileLibraryManage/index.vue

8
src/views/components/category/SettingForm.vue

@ -64,7 +64,7 @@
<span>必填字段</span> <span>必填字段</span>
<el-checkbox v-model="form.isRequired" name="isRequired" :disabled="isDisabled" /> <el-checkbox v-model="form.isRequired" name="isRequired" :disabled="isDisabled" />
</el-form-item> </el-form-item>
<el-form-item class="checkbox-item">
<el-form-item v-if="isCategory" class="checkbox-item">
<span>自动生成</span> <span>自动生成</span>
<el-checkbox v-model="form.isAutomatic" name="isAutomatic" :disabled="isDisabled" @change="changeAuto" /> <el-checkbox v-model="form.isAutomatic" name="isAutomatic" :disabled="isDisabled" @change="changeAuto" />
</el-form-item> </el-form-item>
@ -96,6 +96,10 @@ export default {
name: 'SettingForm', name: 'SettingForm',
components: {}, components: {},
props: { props: {
isCategory: {
type: Boolean,
required: true
},
isDisabled: { isDisabled: {
type: Boolean, type: Boolean,
required: true required: true
@ -229,7 +233,6 @@ export default {
} }
}, },
created() { created() {
console.log(this.form)
}, },
mounted() { mounted() {
this.form = this.thisFields this.form = this.thisFields
@ -381,7 +384,6 @@ export default {
this.form.isAutomatic = false this.form.isAutomatic = false
this.$message.error('著录形式必须为文本框才可操作!') this.$message.error('著录形式必须为文本框才可操作!')
} else if (value) { } else if (value) {
console.log(this.form)
getNoFormatField({ categoryId: this.form.categoryId }).then((res) => { getNoFormatField({ categoryId: this.form.categoryId }).then((res) => {
const repeatIndex = res.findIndex((item) => { const repeatIndex = res.findIndex((item) => {
return item.dictionaryId === this.form.id return item.dictionaryId === this.form.id

4
src/views/system/archivesCategory/baseInfo/index.vue

@ -67,13 +67,9 @@ export default {
}, },
watch: { watch: {
selectedCategory: function(newValue, oldValue) { selectedCategory: function(newValue, oldValue) {
// if (newValue && newValue.id) {
// }
} }
}, },
created() { created() {
// if (this.selectedCategory && this.selectedCategory.id) {
// }
}, },
methods: { methods: {
} }

4
src/views/system/archivesCategory/descriptionPreview/index.vue

@ -28,7 +28,7 @@
<el-button type="primary" icon="iconfont icon-bianji" @click="settingForm">编辑</el-button> <el-button type="primary" icon="iconfont icon-bianji" @click="settingForm">编辑</el-button>
<el-button class="des-set-sort" type="primary" icon="iconfont icon-paixu" @click="previewFormVisible = true">排序</el-button> <el-button class="des-set-sort" type="primary" icon="iconfont icon-paixu" @click="previewFormVisible = true">排序</el-button>
</div> </div>
<SettingForm :is-disabled="true" :is-add="false" :this-fields="thisFields" />
<SettingForm :is-category="true" :is-disabled="true" :is-add="false" :this-fields="thisFields" />
</div> </div>
<div class="des-preview-right"> <div class="des-preview-right">
<div class="des-title"> <div class="des-title">
@ -40,7 +40,7 @@
<!-- 修改字段 --> <!-- 修改字段 -->
<el-dialog class="edit-form-dialog" :visible="settingFormVisible" :before-close="handleClose" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body title="修改字段"> <el-dialog class="edit-form-dialog" :visible="settingFormVisible" :before-close="handleClose" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body title="修改字段">
<div class="setting-dialog"> <div class="setting-dialog">
<SettingForm ref="editForm" :is-disabled="false" :is-add="false" :this-fields="editField" />
<SettingForm ref="editForm" :is-category="true" :is-disabled="false" :is-add="false" :this-fields="editField" />
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" :loading="loading" @click="editSubmit">保存</el-button> <el-button type="primary" :loading="loading" @click="editSubmit">保存</el-button>
</div> </div>

2
src/views/system/archivesCategory/fieldManage/module/form.vue

@ -1,7 +1,7 @@
<template> <template>
<el-dialog class="field-setting-dialog" :modal-append-to-body="false" append-to-body :close-on-click-modal="false" :before-close="crud.cancelCU" :visible="crud.status.cu > 0" :title="crud.status.title"> <el-dialog class="field-setting-dialog" :modal-append-to-body="false" append-to-body :close-on-click-modal="false" :before-close="crud.cancelCU" :visible="crud.status.cu > 0" :title="crud.status.title">
<div class="setting-dialog"> <div class="setting-dialog">
<SettingForm ref="editForm" :is-disabled="false" :is-add="crud.status.add === 1" :this-fields="form" />
<SettingForm ref="editForm" :is-category="true" :is-disabled="false" :is-add="crud.status.add === 1" :this-fields="form" />
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="crud.cancelCU"> <el-button @click="crud.cancelCU">
取消 取消

2
src/views/system/archivesCategory/form.vue

@ -110,7 +110,7 @@ export default {
}, },
watch: { watch: {
selectedCategory: function(newValue, oldValue) { selectedCategory: function(newValue, oldValue) {
console.log('newValue', newValue)
// console.log('newValue', newValue)
} }
}, },
created() { created() {

4
src/views/system/fileLibraryManage/descriptionPreview/index.vue

@ -28,7 +28,7 @@
<el-button type="primary" icon="iconfont icon-bianji" @click="settingForm">编辑</el-button> <el-button type="primary" icon="iconfont icon-bianji" @click="settingForm">编辑</el-button>
<el-button class="des-set-sort" type="primary" icon="iconfont icon-paixu" @click="previewFormVisible = true">排序</el-button> <el-button class="des-set-sort" type="primary" icon="iconfont icon-paixu" @click="previewFormVisible = true">排序</el-button>
</div> </div>
<SettingForm :is-disabled="true" :is-add="false" :this-fields="thisFields" />
<SettingForm :is-category="false" :is-disabled="true" :is-add="false" :this-fields="thisFields" />
</div> </div>
<div class="des-preview-right"> <div class="des-preview-right">
<div class="des-title"> <div class="des-title">
@ -40,7 +40,7 @@
<!-- 修改字段 --> <!-- 修改字段 -->
<el-dialog class="edit-form-dialog" :visible="settingFormVisible" :before-close="handleClose" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body title="修改字段"> <el-dialog class="edit-form-dialog" :visible="settingFormVisible" :before-close="handleClose" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body title="修改字段">
<div class="setting-dialog"> <div class="setting-dialog">
<SettingForm ref="editForm" :is-disabled="false" :is-add="false" :this-fields="editField" />
<SettingForm ref="editForm" :is-category="false" :is-disabled="false" :is-add="false" :this-fields="editField" />
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" :loading="loading" @click="editSubmit">保存</el-button> <el-button type="primary" :loading="loading" @click="editSubmit">保存</el-button>
</div> </div>

2
src/views/system/fileLibraryManage/fieldManage/module/form.vue

@ -1,7 +1,7 @@
<template> <template>
<el-dialog class="field-setting-dialog" :modal-append-to-body="false" append-to-body :close-on-click-modal="false" :before-close="crud.cancelCU" :visible="crud.status.cu > 0" :title="crud.status.title"> <el-dialog class="field-setting-dialog" :modal-append-to-body="false" append-to-body :close-on-click-modal="false" :before-close="crud.cancelCU" :visible="crud.status.cu > 0" :title="crud.status.title">
<div class="setting-dialog"> <div class="setting-dialog">
<SettingForm ref="editForm" :is-disabled="false" :is-add="crud.status.add === 1" :this-fields="form" />
<SettingForm ref="editForm" :is-category="false" :is-disabled="false" :is-add="crud.status.add === 1" :this-fields="form" />
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="crud.cancelCU"> <el-button @click="crud.cancelCU">
取消 取消

1
src/views/system/fileLibraryManage/index.vue

@ -214,7 +214,6 @@ export default {
this.crud.selectionChangeHandler([val]) this.crud.selectionChangeHandler([val])
this.$refs.eform.pid = val.id this.$refs.eform.pid = val.id
this.selectedCategory = val this.selectedCategory = val
console.log(this.selectedCategory)
if (val.pid !== '0') { if (val.pid !== '0') {
Vue.set(this.selectedCategory, 'parentName', this.$refs.tree.getNode(val.pid).data.cnName) Vue.set(this.selectedCategory, 'parentName', this.$refs.tree.getNode(val.pid).data.cnName)
} }

Loading…
Cancel
Save