Commit 812d38e1 authored by YIyiyi's avatar YIyiyi

pref:修改新增事项默认编码和部门

parent ee074c32
......@@ -35,6 +35,7 @@
"js-cookie": "^2.2.1",
"mockjs": "^1.1.0",
"moment": "^2.24.0",
"nanoid": "^4.0.0",
"nprogress": "^0.2.0",
"quill-image-resize-module": "^3.0.0",
"v-viewer": "^1.6.4",
......
......@@ -45,7 +45,9 @@ Vue.use(Viewer);
// moment 时间处理
import moment from "moment";
Vue.prototype.$moment = moment;
// nanoid
import { nanoid } from "nanoid";
Vue.prototype.$nanoid = nanoid;
// echats
import * as echarts from "echarts";
Vue.prototype.$echarts = echarts;
......
......@@ -391,6 +391,10 @@ export default {
},
},
created() {
if (!this.baseform.matterNo) {
this.baseform.matterNo = this.$nanoid();
// this.baseform.matterNo = new Date().getTime();
}
if (this.$route.query.edit == 1) {
let matterId = this.$route.query.matterId;
this.getMatterInfo(matterId);
......@@ -404,6 +408,7 @@ export default {
let { code, data } = res.data;
if (code === 1) {
this.deptData = data.data;
this.baseform.deptCode = this.deptData[0].deptNumber;
}
},
// 编辑时获取信息
......
......@@ -7656,6 +7656,11 @@ nan@^2.12.1:
resolved "https://registry.npmmirror.com/nan/-/nan-2.17.0.tgz#c0150a2368a182f033e9aa5195ec76ea41a199cb"
integrity sha512-2ZTgtl0nJsO0KQCjEpxcIr5D+Yv90plTitZt9JBfQvVJDS5seMl3FOvsh3+9CoYWXf/1l5OaZzzF6nDm4cagaQ==
nanoid@^4.0.0:
version "4.0.0"
resolved "https://registry.npmmirror.com/nanoid/-/nanoid-4.0.0.tgz#6e144dee117609232c3f415c34b0e550e64999a5"
integrity sha512-IgBP8piMxe/gf73RTQx7hmnhwz0aaEXYakvqZyE302IXW3HyVNhdNGC+O2MwMAVhLEnvXlvKtGbtJf6wvHihCg==
nanomatch@^1.2.9:
version "1.2.13"
resolved "https://registry.npm.taobao.org/nanomatch/download/nanomatch-1.2.13.tgz"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment