hz-zhhq-web/node_modules/.cache/babel-loader/7b1eaea244fc92c450699efb68c...

1 line
24 KiB
JSON
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{"remainingRequest":"E:\\hz-zhhq-web\\node_modules\\babel-loader\\lib\\index.js!E:\\hz-zhhq-web\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!E:\\hz-zhhq-web\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!E:\\hz-zhhq-web\\src\\views\\resource\\officeEquipment\\index.vue?vue&type=script&lang=js","dependencies":[{"path":"E:\\hz-zhhq-web\\src\\views\\resource\\officeEquipment\\index.vue","mtime":1737610069446},{"path":"E:\\hz-zhhq-web\\babel.config.js","mtime":1737610069371},{"path":"E:\\hz-zhhq-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"E:\\hz-zhhq-web\\node_modules\\babel-loader\\lib\\index.js","mtime":456789000000},{"path":"E:\\hz-zhhq-web\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"E:\\hz-zhhq-web\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["\"use strict\";\n\nvar _interopRequireDefault = require(\"E:/hz-zhhq-web/node_modules/@babel/runtime/helpers/interopRequireDefault.js\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nrequire(\"core-js/modules/es6.function.name\");\nvar _defineProperty2 = _interopRequireDefault(require(\"E:/hz-zhhq-web/node_modules/@babel/runtime/helpers/defineProperty.js\"));\nrequire(\"core-js/modules/es6.regexp.constructor\");\nvar _paging = _interopRequireDefault(require(\"@/views/Public/paging.vue\"));\nvar _popup = _interopRequireDefault(require(\"@/views/estate/examine/dialog/popup.vue\"));\nvar _getdata = require(\"@/api/getdata\");\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//\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//\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//\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//\nvar _default = exports.default = {\n components: {\n Paging: _paging.default,\n Popup: _popup.default\n },\n data: function data() {\n var priceVa = function priceVa(rule, value, callback) {\n // var reg =/^[0-9\\\\.]*$/\n var reg = /^[0-9]*[1-9][0-9]*$/;\n if (reg.test(value)) {\n callback();\n } else {\n callback(new Error(\"请输入整数!\"));\n }\n };\n var devicenameV = function devicenameV(rule, value, callback) {\n var reg = /[`~!@#$%^&*()_\\-+=<>?:\"{}|,./;'\\\\[\\]·~@#¥%……&*()——\\-+={}|《》?:“”【】、;‘’,。、]/g;\n if (!reg.test(value)) {\n callback();\n } else {\n callback(new Error(\"请输入正确的格式 !\"));\n }\n };\n\n // modelV\n var modelV = function modelV(rule, value, callback) {\n var reg = /[`~!@#$%^&*()_\\-+=<>?:\"{}|,./;'\\\\[\\]·~@#¥%……&*()——\\-+={}|《》?:“”【】、;‘’,。、]/g;\n if (!reg.test(value)) {\n callback();\n } else {\n callback(new Error(\"请输入正确的格式 !\"));\n }\n };\n\n // unitV\n var unitV = function unitV(rule, value, callback) {\n var reg = /[`~!@#$%^&*()_\\-+=<>?:\"{}|,./;'\\\\[\\]·~@#¥%……&*()——\\-+={}|《》?:“”【】、;‘’,。、]/g;\n if (!reg.test(value)) {\n callback();\n } else {\n callback(new Error(\"请输入正确的格式 !\"));\n }\n };\n var propertyNameV = function propertyNameV(rule, value, callback) {\n var reg1 = new RegExp(/^[a-zA-Z]+$/);\n var reg2 = new RegExp(/^[\\u4e00-\\u9fa5]+$/);\n if (reg1.test(value) == false && reg2.test(value) == false && value != \"\") {\n callback(new Error(\"姓名格式只支持全中或全英文!\"));\n } else {\n callback();\n }\n };\n return (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({\n loading: false,\n //初始化loading\n loadingMsg: \"\",\n row: {},\n btn: 3,\n iscontinue: false,\n fileList: [],\n formDate: new FormData(),\n validation: false,\n completeTitle: \"\",\n nav: \"\",\n office: \"添加\",\n options: [] /**拜访部门 */,\n page: {\n limit: 0 /** 当前点击*/,\n sizePage: 10 /** 当前多少页*/,\n total: 0 /**总数 */\n }\n }, \"row\", {}), \"formInline\", {\n devicename: \"\",\n custodian: \"\",\n part: \"\",\n device_state: \"\",\n unit: \"\",\n grant_time: \"\",\n expires_time: \"\"\n }), \"ruleForm\", {\n devicename: \"\",\n model: \"\",\n custodian: \"\",\n part: \"\",\n device_state: \"\",\n unit: \"\",\n amount: \"\",\n grant_time: \"\",\n expires_time: \"\",\n desc: \"\"\n }), \"rules\", {\n devicename: [{\n required: true,\n message: \"请输入设备名称\",\n trigger: \"blur\"\n }, {\n validator: devicenameV,\n trigger: \"blur\"\n }],\n model: [{\n required: true,\n message: \"请输入规格型号\",\n trigger: \"blur\"\n }, {\n // validator: modelV,\n trigger: \"blur\"\n }],\n unit: [{\n required: true,\n message: \"请选择单位\",\n trigger: \"blur\"\n }, {\n validator: unitV,\n trigger: \"blur\"\n }],\n amount: [{\n required: true,\n message: \"请输入数量\",\n trigger: \"blur\"\n }, {\n validator: priceVa,\n trigger: \"blur\"\n }],\n grant_time: [{\n required: true,\n message: \"请选择发放时间\",\n trigger: \"blur\"\n }],\n expires_time: [{\n required: true,\n message: \"请选择到期时间\",\n trigger: \"blur\"\n }],\n device_state: [{\n required: true,\n message: \"请选择设备状态\",\n trigger: \"blur\"\n }],\n custodian: [{\n validator: propertyNameV,\n trigger: \"blur\"\n }]\n }), \"centerDialogVisible\", false), \"tableData\", []);\n },\n created: function created() {},\n mounted: function mounted() {\n this.createLoad();\n this.getDate();\n this.getbmlist();\n },\n methods: {\n createLoad: function createLoad() {\n this.loading = true;\n this.loadingMsg = \"加载中...\";\n },\n clearLoad: function clearLoad() {\n this.loading = false;\n this.loadingMsg = \"\";\n },\n bs64: function bs64(_bs) {\n var reader = new FileReader();\n reader.readAsDataURL(_bs);\n return new Promise(function (resolve) {\n reader.onload = function (e) {\n resolve(e.target.result);\n };\n });\n },\n //导入\n handlePreview: function handlePreview() {\n this.formDate = new FormData();\n this.$refs.upload.clearFiles();\n },\n onchange: function onchange(file) {\n var _this = this;\n this.fileList = [];\n // this.formDate = new FormData();\n // this.formDate.append(\"file\", file.raw);\n this.fileList.push(file);\n var flag = false;\n if (this.fileList.length > 0) {\n flag = false;\n var Lastindex = this.fileList[0].name.lastIndexOf(\".\");\n if (this.fileList[0].name.slice(Lastindex) != \".xls\" && this.fileList[0].name.slice(Lastindex) != \".xlsx\") {\n flag = false;\n this.$message({\n message: \"请选择正确的Excel格式\",\n type: \"warning\"\n });\n return false;\n } else {\n flag = true;\n }\n } else {\n flag = true;\n }\n this.bs64(file.raw).then(function (bs64) {\n _this.formDate = {\n file: bs64\n };\n if (flag) {\n _this.createLoad();\n (0, _getdata.BanimportByExcel)(_this.formDate).then(function (res) {\n if (res.returnCode == \"1\") {\n _this.$message({\n message: res.returnMsg,\n type: \"success\"\n });\n _this.clearLoad();\n _this.getDate();\n } else {\n _this.clearLoad();\n _this.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n }).catch(function (err) {\n _this.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n });\n }\n });\n },\n // 自定义上传 导入数据\n uploadFile: function uploadFile(item) {\n var _this2 = this;\n var form = new FormData();\n form.append(\"file\", item.file);\n (0, _getdata.BanimportByExcel)(form).then(function (res) {\n if (res.returnCode == \"1\") {\n _this2.$message({\n message: res.returnMsg,\n type: \"success\"\n });\n _this2.createLoad();\n _this2.getDate();\n } else {\n _this2.clearLoad();\n _this2.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n }).catch(function (err) {\n _this2.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n });\n },\n // 导出\n onOut: function onOut() {\n var _this3 = this;\n var Content = {\n department: this.formInline.part,\n deviceName: this.formInline.devicename,\n deviceState: this.formInline.device_state,\n issueTime: this.formInline.grant_time ? this.formInline.grant_time : \"\",\n maturityTime: this.formInline.expires_time ? this.formInline.expires_time : \"\",\n preserver: this.formInline.custodian,\n unit: this.formInline.unit\n };\n (0, _getdata.Own)().then(function (res) {\n if (res.returnCode === \"1\") {\n var str = \"department=\" + _this3.formInline.part + \"&deviceName=\" + _this3.formInline.devicename + \"&deviceState=\" + _this3.formInline.device_state + \"&issueTime=\" + _this3.formInline.grant_time + \"&maturityTime=\" + _this3.formInline.expires_time + \"&preserver=\" + _this3.formInline.custodian + \"&unit=\" + _this3.formInline.unit;\n var url = \"/greenH5/greenWebmodul/rest/greenOfficeDevice/exportByExcel?\" + str;\n window.location.href = url;\n }\n });\n\n // BanexportByExcel(Content).then(res=>{\n // let blob = new Blob([res],{ type: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document;charset=utf-8'});\n // let objectUrl = URL.createObjectURL(blob);\n // window.location.href = objectUrl;\n // let eleLink = document.createElement('a')\n // let blob = res;\n // let url = window.URL.createObjectURL(blob)\n // eleLink.href = url\n // eleLink.download = 'aaa'\n // document.body.appendChild(eleLink)\n // window.URL.revokeObjectURL(url)\n // }).catch(err=>{\n // console.log(err)\n // })\n },\n getbmlist: function getbmlist() {\n var _this4 = this;\n (0, _getdata.GetBmList)().then(function (res) {\n if (res.returnCode == \"1\") {\n // this.$message({\n // message: res.returnMsg,\n // type: \"success\"\n // });\n _this4.options = res.returnData;\n } else {\n _this4.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n\n // console.log(res, \"部门\");\n }).catch(function (err) {\n console.log(err);\n });\n },\n AddOffice: function AddOffice() {\n this.centerDialogVisible = true;\n this.office = \"添加\";\n if (this.office == \"添加\") {\n this.ruleForm = {\n devicename: \"\",\n model: \"\",\n custodian: \"\",\n part: \"\",\n device_state: \"\",\n unit: \"\",\n amount: \"\",\n grant_time: \"\",\n expires_time: \"\",\n desc: \"\"\n };\n }\n },\n // 弹框关闭的回调\n closeDialog: function closeDialog() {\n this.ruleForm = {};\n this.$refs.ruleForm.resetFields();\n },\n //保存\n submitForm: function submitForm(formName) {\n var _this5 = this;\n this.$refs.ruleForm.validate(function (valid) {\n if (valid) {\n _this5.validation = true;\n _this5.btn = 3;\n if (_this5.office == \"添加\") {\n _this5.completeTitle = \"添加\";\n _this5.nav = \"是否添加?\";\n } else {\n _this5.completeTitle = \"修改\";\n _this5.nav = \"是否修改?\";\n }\n // let Content;\n // if (this.office == \"添加\") {\n // Content = {\n // _number: this.ruleForm.amount,\n // department: this.ruleForm.part,\n // deviceName: this.ruleForm.device_state,\n // deviceState: this.ruleForm.device_state,\n // issueTime: this.ruleForm.grant_time,\n // maturityTime: this.ruleForm.expires_time,\n // preserver: this.ruleForm.custodian,\n // remark: this.ruleForm.desc,\n // ruleName: this.ruleForm.model,\n // unit: this.ruleForm.unit\n // };\n\n // AddList(Content)\n // .then(res => {\n // console.log(res);\n // if (res.returnCode == \"1\") {\n // this.$message({\n // message: res.returnMsg,\n // type: \"success\"\n // });\n // this.getDate();\n // } else {\n // this.$message({\n // message: res.returnMsg,\n // type: \"warning\"\n // });\n // }\n // })\n // .catch(err => {\n // console.log(err);\n // });\n // } else if (this.office == \"修改\") {\n // Content = {\n // id: this.row.id,\n // _number: this.ruleForm.amount,\n // department: this.ruleForm.part,\n // deviceName: this.ruleForm.devicename,\n // deviceState: this.ruleForm.device_state,\n // issueTime: this.ruleForm.grant_time,\n // maturityTime: this.ruleForm.expires_time,\n // preserver: this.ruleForm.custodian,\n // remark: this.ruleForm.desc,\n // ruleName: this.ruleForm.model,\n // unit: this.ruleForm.unit\n // };\n\n // DevList(Content)\n // .then(res => {\n // console.log(res);\n // if (res.returnCode == \"1\") {\n // this.$message({\n // message: res.returnMsg,\n // type: \"success\"\n // });\n // this.getDate();\n // } else {\n // this.$message({\n // message: res.returnMsg,\n // type: \"warning\"\n // });\n // }\n // })\n // .catch(err => {\n // console.log(err);\n // });\n // }\n } else {\n console.log(\"error submit!!\");\n return false;\n }\n });\n },\n //取消\n resetForm: function resetForm(formName) {\n this.centerDialogVisible = false;\n },\n onSubmit: function onSubmit() {\n var chinese = /^[\\u4e00-\\u9fa5]+$/;\n var englist = /^[a-zA-Z]+$/;\n this.iscontinue = false;\n if (chinese.test(this.formInline.custodian) || englist.test(this.formInline.custodian) || this.formInline.custodian == \"\") {\n this.iscontinue = true;\n }\n if (!this.iscontinue) {\n this.validation = true;\n this.completeTitle = \"警告\";\n this.btn = 2;\n this.nav = \"姓名格式只支持输入全中或全英文!\";\n } else {\n this.page.limit = 1;\n this.createLoad();\n this.getDate();\n }\n\n // this.page.limit = 1;\n // this.createLoad();\n // this.getDate();\n },\n //修改\n handleUpdate: function handleUpdate(row) {\n this.centerDialogVisible = true;\n this.office = \"修改\";\n this.row = row;\n // console.log(row,123)\n if (this.office == \"修改\") {\n this.ruleForm = {\n devicename: row.device_name,\n model: row.rule_name,\n custodian: row.preserver,\n part: row.department,\n device_state: row.device_state,\n unit: row.unit,\n amount: row.number,\n grant_time: row.issue_time,\n expires_time: row.maturity_time,\n desc: row.remark\n };\n }\n },\n closeDialogDel: function closeDialogDel(val) {\n var _this6 = this;\n var Contents = {\n id: this.row.id\n };\n var Content;\n if (val == 1) {\n (0, _getdata.DelList)(Contents).then(function (res) {\n // console.log(res);\n if (res.returnCode == \"1\") {\n _this6.$message({\n message: \"删除成功\",\n type: \"success\"\n });\n _this6.createLoad();\n _this6.getDate();\n } else {\n _this6.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n }).catch(function (err) {\n console.log(err);\n });\n } else if (val == 2) {\n var reg = /[\\u4e00-\\u9fa5]/g;\n var departments;\n this.options.map(function (item) {\n // console.log(item.name,682)\n if (item.name == _this6.ruleForm.part) {\n departments = item.id;\n }\n });\n // console.log(this.options.includes(this.ruleForm.part))\n // departments = reg.test(this.ruleForm.part)? departments:this.ruleForm.part\n //修改\n Content = {\n id: this.row.id,\n _number: this.ruleForm.amount,\n department: reg.test(this.ruleForm.part) ? departments : this.ruleForm.part,\n deviceName: this.ruleForm.devicename,\n deviceState: this.ruleForm.device_state,\n issueTime: this.ruleForm.grant_time ? this.ruleForm.grant_time : \"\",\n maturityTime: this.ruleForm.expires_time ? this.ruleForm.expires_time : \"\",\n preserver: this.ruleForm.custodian,\n remark: this.ruleForm.desc,\n ruleName: this.ruleForm.model,\n unit: this.ruleForm.unit\n };\n // console.log(Content)\n\n (0, _getdata.DevList)(Content).then(function (res) {\n if (res.returnCode == \"1\") {\n _this6.$message({\n message: res.returnMsg,\n type: \"success\"\n });\n _this6.page.limit = _this6.page.limit;\n _this6.createLoad();\n _this6.getDate();\n } else {\n _this6.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n _this6.centerDialogVisible = false;\n _this6.$refs.ruleForm.resetFields();\n }).catch(function (err) {\n console.log(err);\n });\n } else if (val == 3) {\n Content = {\n _number: this.ruleForm.amount,\n department: this.ruleForm.part,\n deviceName: this.ruleForm.devicename,\n deviceState: this.ruleForm.device_state,\n issueTime: this.ruleForm.grant_time ? this.ruleForm.grant_time : \"\",\n maturityTime: this.ruleForm.expires_time ? this.ruleForm.expires_time : \"\",\n preserver: this.ruleForm.custodian,\n remark: this.ruleForm.desc,\n ruleName: this.ruleForm.model,\n unit: this.ruleForm.unit\n };\n (0, _getdata.AddList)(Content).then(function (res) {\n // console.log(res);\n if (res.returnCode == \"1\") {\n _this6.$message({\n message: res.returnMsg,\n type: \"success\"\n });\n _this6.createLoad();\n _this6.getDate();\n } else {\n _this6.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n }\n _this6.centerDialogVisible = false;\n _this6.$refs.ruleForm.resetFields();\n }).catch(function (err) {\n console.log(err);\n });\n }\n this.validation = false;\n },\n /**删除 */handleModifyStatus: function handleModifyStatus(row) {\n this.completeTitle = \"删除\";\n this.nav = \"是否删除?\";\n this.row = row;\n this.btn = 3;\n this.validation = true;\n },\n handleDrag: function handleDrag() {\n this.$refs.select.blur();\n },\n formatJson: function formatJson(filterVal, jsonData) {\n return jsonData.map(function (v) {\n return filterVal.map(function (j) {\n if (j === \"timestamp\") {\n return parseTime(v[j]);\n } else {\n return v[j];\n }\n });\n });\n },\n // 分页\n currentChanges: function currentChanges(val) {\n this.createLoad();\n this.page.limit = val;\n this.getDate();\n },\n getDate: function getDate() {\n var _this7 = this;\n var Content = {\n currentPage: this.page.limit,\n queryObj: {\n department: this.formInline.part,\n //部门\n deviceName: this.formInline.devicename,\n //设备名称\n deviceState: this.formInline.device_state,\n issueTime: this.formInline.grant_time ? this.formInline.grant_time : \"\",\n //发放时间\n maturityTime: this.formInline.expires_time,\n //到期时间\n preserver: this.formInline.custodian,\n //保管人\n unit: this.formInline.unit //单位\n }\n };\n (0, _getdata.OfficeList)(Content).then(function (res) {\n if (res.returnCode == \"1\") {\n _this7.clearLoad();\n _this7.tableData = res.returnData.data;\n _this7.page.total = res.returnData.total;\n _this7.page.limit = res.returnData.currentPage;\n // console.log(res.returnData.data,100)\n if (_this7.page.total == 0) {\n _this7.$message({\n message: \"当前无数据\",\n type: \"success\"\n });\n } else {\n _this7.$message({\n message: res.returnMsg,\n type: \"success\"\n });\n }\n } else {\n _this7.$message({\n message: res.returnMsg,\n type: \"warning\"\n });\n setTimeout(function () {\n _this7.clearLoad();\n }, 300);\n }\n }).catch(function (err) {\n console.log(err);\n setTimeout(function () {\n _this7.clearLoad();\n }, 300);\n });\n }\n }\n};",null]}