1 line
16 KiB
JSON
1 line
16 KiB
JSON
{"remainingRequest":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\babel-loader\\lib\\index.js!C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!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\\registerManage\\staff-bind.vue?vue&type=script&lang=js&","dependencies":[{"path":"C:\\Users\\27446\\Desktop\\up\\front\\dkha-web-sz-main\\src\\views\\modules\\registerManage\\staff-bind.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":["import \"core-js/modules/es7.object.get-own-property-descriptors\";\nimport \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.object.keys\";\nimport \"core-js/modules/es6.regexp.search\";\nimport _defineProperty from \"C:\\\\Users\\\\27446\\\\Desktop\\\\up\\\\front\\\\dkha-web-sz-main\\\\node_modules\\\\@babel\\\\runtime-corejs2/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(source, true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(source).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\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 { getDictLabel } from '@/utils';\nimport debounce from 'lodash/debounce';\nexport default {\n filters: {\n filterLabel: function filterLabel(val, type) {\n return getDictLabel(type, val);\n }\n },\n data: function data() {\n var _this = this;\n\n var asyncValidate = function asyncValidate(rule, value, callback) {\n _this.$http({\n url: \"/system/globalValidation/checkUwb\",\n method: \"get\",\n params: {\n id: _this.dataForm.scWaid,\n uwb: value\n }\n }).then(function (_ref) {\n var res = _ref.data;\n\n if (res) {\n callback();\n } else {\n callback(new Error('UWB标签重复'));\n }\n }).catch(function (err) {\n callback(new Error(err.msg));\n });\n };\n\n var asyncValidateRf = function asyncValidateRf(rule, value, callback) {\n _this.$http({\n url: \"/system/globalValidation/checkRfid\",\n method: \"get\",\n params: {\n id: _this.dataForm.scWaid,\n uwb: value\n }\n }).then(function (_ref2) {\n var res = _ref2.data;\n\n if (res) {\n callback();\n } else {\n callback(new Error('RFID重复'));\n }\n }).catch(function (err) {\n callback(new Error(err.msg));\n });\n };\n\n return {\n dialogVisible: false,\n loading: false,\n type: 'post',\n dataForm: {},\n rules: {\n scRfcardid: [{\n required: true,\n message: '请输入',\n trigger: ['blur', 'change']\n }, {\n required: true,\n validator: asyncValidateRf,\n trigger: ['change']\n }],\n scUwbid: [{\n required: true,\n validator: function validator(rule, value, callback) {\n if (!/^[0-9]+$/.test(value)) {\n return callback(new Error(\"UWB标签只能是数字\"));\n }\n\n callback();\n },\n trigger: ['change']\n }, {\n required: true,\n validator: asyncValidate,\n trigger: ['change']\n }]\n }\n };\n },\n methods: {\n init: function init(data) {\n var _this2 = this;\n\n this.dialogVisible = true;\n this.dataForm = _objectSpread({}, data, {\n scSex: String(data.scSex),\n scStatus: String(data.scStatus),\n scEducation: String(data.scEducation)\n });\n this.$nextTick(function () {\n _this2.$refs['dataForm'].clearValidate();\n });\n },\n submitInfo: debounce(function () {\n var _this3 = this;\n\n this.$refs['dataForm'].validate(function (valid) {\n if (!valid) {\n return false;\n }\n\n _this3.loading = true;\n\n _this3.$http({\n url: \"/system/scworkersarchives\",\n method: 'put',\n data: _this3.dataForm\n }).then(function (_ref3) {\n var data = _ref3.data;\n\n if (data.code != 0) {\n return _this3.$message.error(data.msg);\n }\n\n _this3.dialogVisible = false;\n\n _this3.$parent.$parent.search();\n\n _this3.$message.success(data.msg);\n }).finally(function () {\n _this3.loading = false;\n });\n });\n }, 1000)\n }\n};",{"version":3,"sources":["staff-bind.vue"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4DA,SAAA,YAAA,QAAA,SAAA;AACA,OAAA,QAAA,MAAA,iBAAA;AACA,eAAA;AACA,EAAA,OAAA,EAAA;AACA,IAAA,WADA,uBACA,GADA,EACA,IADA,EACA;AACA,aAAA,YAAA,CAAA,IAAA,EAAA,GAAA,CAAA;AACA;AAHA,GADA;AAMA,EAAA,IANA,kBAMA;AAAA;;AACA,QAAA,aAAA,GAAA,SAAA,aAAA,CAAA,IAAA,EAAA,KAAA,EAAA,QAAA,EAAA;AACA,MAAA,KAAA,CAAA,KAAA,CAAA;AACA,QAAA,GAAA,EAAA,mCADA;AAEA,QAAA,MAAA,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A,YAAA,CAAA,KAAA,EAAA;AACA,iBAAA,KAAA;AACA;;AACA,QAAA,MAAA,CAAA,OAAA,GAAA,IAAA;;AACA,QAAA,MAAA,CAAA,KAAA,CAAA;AACA,UAAA,GAAA,EAAA,2BADA;AAEA,UAAA,MAAA,EAAA,KAFA;AAGA,UAAA,IAAA,EAAA,MAAA,CAAA;AAHA,SAAA,EAIA,IAJA,CAIA,iBAAA;AAAA,cAAA,IAAA,SAAA,IAAA;;AACA,cAAA,IAAA,CAAA,IAAA,IAAA,CAAA,EAAA;AACA,mBAAA,MAAA,CAAA,QAAA,CAAA,KAAA,CAAA,IAAA,CAAA,GAAA,CAAA;AACA;;AACA,UAAA,MAAA,CAAA,aAAA,GAAA,KAAA;;AACA,UAAA,MAAA,CAAA,OAAA,CAAA,OAAA,CAAA,MAAA;;AACA,UAAA,MAAA,CAAA,QAAA,CAAA,OAAA,CAAA,IAAA,CAAA,GAAA;AACA,SAXA,EAWA,OAXA,CAWA,YAAA;AACA,UAAA,MAAA,CAAA,OAAA,GAAA,KAAA;AACA,SAbA;AAcA,OAnBA;AAqBA,KAtBA,EAsBA,IAtBA;AAbA;AA7EA,CAAA","sourcesContent":["<template>\n <el-dialog title=\"绑卡\" :visible.sync=\"dialogVisible\" :close-on-click-modal=\"false\">\n <div>\n <el-form ref=\"dataForm\" :model=\"dataForm\" :rules=\"rules\" label-width=\"100px\">\n <el-row>\n <el-col>\n <el-form-item class=\"block-item\" label=\"照片\" prop=\"scPhotoimg\">\n <el-image :src=\"$ImgServerUrl+dataForm.scPhotoimg\" class=\"avatar\">\n <div slot=\"error\" class=\"image-slot\">\n <img class=\"student-img\" src=\"../../../assets/img/person.jpg\" />\n </div>\n </el-image>\n </el-form-item>\n </el-col>\n </el-row>\n <el-row>\n <el-col :span=\"12\">\n <el-form-item label=\"姓名\" prop=\"scWaname\">\n <p>{{dataForm.scWaname}}</p>\n </el-form-item>\n </el-col>\n <el-col :span=\"11\" :offset=\"1\">\n <el-form-item label=\"身份证号\" prop=\"scIdno\">\n <p>{{dataForm.scIdno}}</p>\n </el-form-item>\n </el-col>\n </el-row>\n <el-row>\n <el-col :span=\"12\">\n <el-form-item label=\"职工编号\" prop=\"scEmpno\">\n <p>{{dataForm.scEmpno}}</p>\n </el-form-item>\n </el-col>\n <el-col :span=\"11\" :offset=\"1\">\n <el-form-item label=\"联系电话\" prop=\"scPhonenum\">\n <p>{{dataForm.scPhonenum}}</p>\n </el-form-item>\n </el-col>\n </el-row>\n <el-row>\n <el-col :span=\"12\">\n <el-form-item label=\"UWB标签\" prop=\"scUwbid\">\n <el-input v-model=\"dataForm.scUwbid\" placeholder=\"请输入\"></el-input>\n </el-form-item>\n </el-col>\n <el-col :span=\"11\" :offset=\"1\">\n <el-form-item label=\"RFID\" prop=\"scRfcardid\">\n <el-input v-model=\"dataForm.scRfcardid\" placeholder=\"请输入\"></el-input>\n </el-form-item>\n </el-col>\n </el-row>\n </el-form>\n </div>\n <div slot=\"footer\">\n <el-button @click=\"dialogVisible = false\">取 消</el-button>\n <el-button type=\"primary\" v-loading=\"loading\" @click=\"submitInfo\">确 定</el-button>\n </div>\n </el-dialog>\n</template>\n<script>\nimport {getDictLabel} from '@/utils'\nimport debounce from 'lodash/debounce'\nexport default {\n filters:{\n filterLabel(val,type){\n return getDictLabel(type,val)\n },\n },\n data(){\n const asyncValidate=(rule, value, callback) => {\n this.$http({\n url: \"/system/globalValidation/checkUwb\",\n method: \"get\",\n params: {\n id: this.dataForm.scWaid,\n uwb: value\n }\n }).then(({ data: res }) => {\n if (res) {\n callback()\n } else {\n callback(new Error('UWB标签重复'))\n }\n }).catch(err => {\n callback(new Error(err.msg))\n })\n };\n const asyncValidateRf=(rule, value, callback) => {\n this.$http({\n url: \"/system/globalValidation/checkRfid\",\n method: \"get\",\n params: {\n id: this.dataForm.scWaid,\n uwb: value\n }\n }).then(({ data: res }) => {\n if (res) {\n callback()\n } else {\n callback(new Error('RFID重复'))\n }\n }).catch(err => {\n callback(new Error(err.msg))\n })\n };\n return {\n dialogVisible:false,\n loading:false,\n type:'post',\n dataForm:{},\n rules:{\n scRfcardid:[\n {required: true, message:'请输入', trigger: ['blur','change']},\n {\n required: true,\n validator: asyncValidateRf,\n trigger: ['change']\n }\n ],\n scUwbid:[\n {\n required: true,\n validator: (rule, value, callback)=>{\n if (!/^[0-9]+$/.test(value)) {\n return callback(new Error(\"UWB标签只能是数字\"));\n }\n callback()\n },\n trigger: ['change']\n },\n {\n required: true,\n validator: asyncValidate,\n trigger: ['change']\n }\n ]\n },\n }\n },\n methods:{\n init(data){\n this.dialogVisible=true;\n this.dataForm={\n ...data,\n scSex:String(data.scSex),\n scStatus:String(data.scStatus),\n scEducation:String(data.scEducation),\n }\n this.$nextTick(()=>{\n this.$refs['dataForm'].clearValidate();\n })\n },\n submitInfo:debounce(function(){\n this.$refs['dataForm'].validate((valid)=>{\n if(!valid){\n return false\n }\n this.loading=true;\n this.$http({\n url:\"/system/scworkersarchives\",\n method:'put',\n data:this.dataForm\n }).then(({data})=>{\n if(data.code!=0){\n return this.$message.error(data.msg)\n }\n this.dialogVisible=false;\n this.$parent.$parent.search();\n this.$message.success(data.msg)\n }).finally(()=>{\n this.loading=false\n })\n })\n \n },1000)\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.el-dialog {\n .el-form {\n .el-form-item {\n .el-date-editor--date,\n .el-select {\n width: 100%;\n }\n .avatar {\n height: 150px;\n width: 106px;\n margin-left: 20px;\n display: block;\n }\n .student-img {\n width: 106px;\n height: 150px;\n }\n p {\n margin: 0;\n padding: 0 10px;\n }\n }\n }\n}\n</style>"],"sourceRoot":"src/views/modules/registerManage"}]} |