forked from zhurui/management
1 line
16 KiB
JSON
1 line
16 KiB
JSON
|
{"remainingRequest":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\src\\views\\modules\\sys\\notice-add-or-update.vue?vue&type=script&lang=js&","dependencies":[{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\src\\views\\modules\\sys\\notice-add-or-update.vue","mtime":1614735254000},{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\babel-loader\\lib\\index.js","mtime":499162500000},{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\nimport Cookies from 'js-cookie'\nimport debounce from 'lodash/debounce'\nimport 'quill/dist/quill.snow.css'\nimport Quill from 'quill'\nexport default {\n data () {\n return {\n visible: false,\n quillEditor: null,\n quillEditorToolbarOptions: [\n ['bold', 'italic', 'underline', 'strike'],\n ['image'],\n [{ 'list': 'ordered' }, { 'list': 'bullet' }],\n [{ 'size': ['small', false, 'large', 'huge'] }],\n [{ 'color': [] }, { 'background': [] }],\n ['clean']\n ],\n uploadUrl: '',\n deptList: [],\n dataForm: {\n id: '',\n type: 0,\n title: '',\n content: '',\n receiverType: 0,\n receiverTypeIds: '',\n receiverTypeList: [],\n status: '',\n senderName: '',\n senderDate: '',\n creator: '',\n createDate: ''\n }\n }\n },\n computed: {\n dataRule () {\n var validateContent = (rule, value, callback) => {\n if (this.quillEditor.getLength() <= 1) {\n return callback(new Error(this.$t('validate.required')))\n }\n callback()\n }\n return {\n type: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ],\n title: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ],\n content: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' },\n { validator: validateContent, trigger: 'blur' }\n ],\n receiverType: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ],\n receiverTypeIds: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ],\n status: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ],\n senderName: [\n { required: true, message: this.$t('validate.required'), trigger: 'blur' }\n ]\n }\n }\n },\n methods: {\n init () {\n this.visible = true\n this.$nextTick(() => {\n if (this.quillEditor) {\n this.quillEditor.deleteText(0, this.quillEditor.getLength())\n } else {\n this.quillEditorHandle()\n }\n this.$refs['dataForm'].resetFields()\n Promise.all([\n this.getDeptList()\n ]).then(() => {\n if (this.dataForm.id) {\n this.getInfo()\n }\n })\n })\n },\n // 富文本编辑器\n quillEditorHandle () {\n this.quillEditor = new Quill('#J_quillEditor', {\n modules: {\n toolbar: this.quillEditorToolbarOptions\n },\n theme: 'snow'\n })\n // 自定义上传图片功能 (使用element upload组件)\n this.uploadUrl = `${window.SITE_CONFIG['apiURL']}/sys/oss/upl
|