{"remainingRequest":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\components\\personForm-dialog.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\components\\personForm-dialog.vue","mtime":1684458239215},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es6.regexp.split\";\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//\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//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport { mapState } from 'vuex';\nimport perSon from '@/api/perSon.js';\nimport req from '@/request.js'; // import { addCodeInfo,getCodeInfoById,editCodeInfo } from \"@/api/cold-chain-info\";\n\nexport default {\n name: 'FormDialog',\n props: {\n showFormDia: {\n type: Boolean,\n default: false\n },\n title: {\n type: String,\n default: ''\n },\n pId: {\n type: String,\n default: ''\n },\n addId: {\n type: String,\n default: ''\n }\n },\n data: function data() {\n return {\n params: {\n orgId: '',\n dept: '',\n dutyMemo: '',\n memo: '',\n mobilePhone: '',\n name: '',\n position: '',\n projectType: null //工程类型\n\n },\n parentIds: [],\n //组织树数组\n projectTypes: [],\n //工程类型下拉\n rules: {\n orgId: [{\n required: true,\n message: '请选择责任人组织',\n trigger: 'blur'\n }],\n name: [{\n required: true,\n message: '请输入姓名',\n trigger: 'blur'\n }]\n }\n };\n },\n created: function created() {\n var _this = this;\n\n this.getSysDict();\n this.getDetailInfo(); // 组织树查询\n\n perSon.getPerson({}, function (res) {\n _this.parentIds = res.value;\n });\n },\n methods: {\n changetype: function changetype(val) {\n if (val) {\n this.params.projectType = val;\n } else {\n this.params.projectType = null;\n }\n },\n // 根据ID查询\n getDetailInfo: function getDetailInfo() {\n var _this2 = this;\n\n if (this.title === '修改') {\n perSon.getPerson({}, function (res) {\n _this2.parentIds = res.value;\n });\n perSon.detailId(this.pId, function (res) {\n _this2.params = res.value;\n _this2.params.projectType = res.value.projectType.split(\",\");\n });\n }\n\n if (this.title === '新增') {\n this.params.orgId = this.addId;\n }\n },\n onparentIds: function onparentIds(val) {\n if (val) {\n this.params.orgId = val.pop();\n }\n },\n handleClose: function handleClose() {\n this.params = {\n orgId: '',\n dept: '',\n dutyMemo: '',\n memo: '',\n mobilePhone: '',\n name: '',\n position: '',\n projectType: null //工程类型\n\n };\n this.$emit('closeFormDiao');\n },\n goInfo: function goInfo(e) {\n var _this3 = this;\n\n this.$refs.formInfo.validate(function (valid) {\n if (valid) {\n if (_this3.title === '新增') {\n _this3.params.projectType = String(_this3.params.projectType);\n perSon.addSave(_this3.params, function (response) {\n if (response.state) {\n _this3.$notify({\n type: 'success',\n message: '新增成功',\n duration: 2000 // offset: 80\n\n });\n\n _this3.$emit('closeFormDiao');\n\n _this3.$emit('refList');\n } else {\n _this3.$message.success(response.message);\n }\n });\n }\n\n if (_this3.title === '修改') {\n _this3.params.projectType = String(_this3.params.projectType);\n perSon.upData(_this3.params, function (response) {\n if (response.state) {\n _this3.$notify({\n type: 'success',\n message: '修改成功',\n duration: 2000 // offset: 80\n\n });\n\n _this3.$emit('closeFormDiao');\n\n _this3.$emit('refList');\n } else {}\n });\n }\n } else {\n return false;\n }\n });\n },\n //获取字典数据\n getSysDict: function getSysDict() {\n var _this4 = this;\n\n var portal = window.context.portal;\n return new Promise(function (resolve, reject) {\n req.post(portal + '/sys/sysDictionary/v1/queryAllDictItems').then(function (response) {\n resolve(response.data);\n _this4.projectTypes = response.data.gclx;\n console.log(_this4.projectTypes);\n }, function (error) {\n reject(error);\n });\n });\n },\n getRowKey: function getRowKey(row) {\n return row.id;\n }\n }\n};",null]}