snow 2 سال پیش
والد
کامیت
de76604de3

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/0.js


+ 14 - 13
dist/static/js/1.js

@@ -1,5 +1,17 @@
 (window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],{
 
+/***/ "./node_modules/@babel/runtime/helpers/esm/objectDestructuringEmpty.js":
+/*!*****************************************************************************!*\
+  !*** ./node_modules/@babel/runtime/helpers/esm/objectDestructuringEmpty.js ***!
+  \*****************************************************************************/
+/*! exports provided: default */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
+
+"use strict";
+eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"default\", function() { return _objectDestructuringEmpty; });\nfunction _objectDestructuringEmpty(obj) {\n  if (obj == null) throw new TypeError(\"Cannot destructure \" + obj);\n}\n\n//# sourceURL=webpack:///./node_modules/@babel/runtime/helpers/esm/objectDestructuringEmpty.js?");
+
+/***/ }),
+
 /***/ "./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js":
 /*!****************************************************************************!*\
   !*** ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js ***!
@@ -8,7 +20,7 @@
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
-eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"default\", function() { return _objectWithoutProperties; });\n/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ \"./node_modules/core-js/modules/es.symbol.js\");\n/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _objectWithoutPropertiesLoose_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./objectWithoutPropertiesLoose.js */ \"./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js\");\n\n\nfunction _objectWithoutProperties(source, excluded) {\n  if (source == null) return {};\n  var target = Object(_objectWithoutPropertiesLoose_js__WEBPACK_IMPORTED_MODULE_1__[\"default\"])(source, excluded);\n  var key, i;\n\n  if (Object.getOwnPropertySymbols) {\n    var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n    for (i = 0; i < sourceSymbolKeys.length; i++) {\n      key = sourceSymbolKeys[i];\n      if (excluded.indexOf(key) >= 0) continue;\n      if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n      target[key] = source[key];\n    }\n  }\n\n  return target;\n}\n\n//# sourceURL=webpack:///./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js?");
+eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"default\", function() { return _objectWithoutProperties; });\n/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ \"./node_modules/core-js/modules/es.symbol.js\");\n/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _objectWithoutPropertiesLoose_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./objectWithoutPropertiesLoose.js */ \"./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js\");\n\n\nfunction _objectWithoutProperties(source, excluded) {\n  if (source == null) return {};\n  var target = Object(_objectWithoutPropertiesLoose_js__WEBPACK_IMPORTED_MODULE_1__[\"default\"])(source, excluded);\n  var key, i;\n  if (Object.getOwnPropertySymbols) {\n    var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n    for (i = 0; i < sourceSymbolKeys.length; i++) {\n      key = sourceSymbolKeys[i];\n      if (excluded.indexOf(key) >= 0) continue;\n      if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n      target[key] = source[key];\n    }\n  }\n  return target;\n}\n\n//# sourceURL=webpack:///./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js?");
 
 /***/ }),
 
@@ -20,7 +32,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) *
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
-eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"default\", function() { return _objectWithoutPropertiesLoose; });\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ \"./node_modules/core-js/modules/es.object.keys.js\");\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0__);\n\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n  if (source == null) return {};\n  var target = {};\n  var sourceKeys = Object.keys(source);\n  var key, i;\n\n  for (i = 0; i < sourceKeys.length; i++) {\n    key = sourceKeys[i];\n    if (excluded.indexOf(key) >= 0) continue;\n    target[key] = source[key];\n  }\n\n  return target;\n}\n\n//# sourceURL=webpack:///./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js?");
+eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"default\", function() { return _objectWithoutPropertiesLoose; });\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ \"./node_modules/core-js/modules/es.object.keys.js\");\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_0__);\n\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n  if (source == null) return {};\n  var target = {};\n  var sourceKeys = Object.keys(source);\n  var key, i;\n  for (i = 0; i < sourceKeys.length; i++) {\n    key = sourceKeys[i];\n    if (excluded.indexOf(key) >= 0) continue;\n    target[key] = source[key];\n  }\n  return target;\n}\n\n//# sourceURL=webpack:///./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js?");
 
 /***/ }),
 
@@ -83,17 +95,6 @@ eval("\nvar toIndexedObject = __webpack_require__(/*! ../internals/to-indexed-ob
 
 /***/ }),
 
-/***/ "./node_modules/core-js/internals/array-reduce.js":
-/*!********************************************************!*\
-  !*** ./node_modules/core-js/internals/array-reduce.js ***!
-  \********************************************************/
-/*! no static exports found */
-/***/ (function(module, exports, __webpack_require__) {
-
-eval("var aFunction = __webpack_require__(/*! ../internals/a-function */ \"./node_modules/core-js/internals/a-function.js\");\nvar toObject = __webpack_require__(/*! ../internals/to-object */ \"./node_modules/core-js/internals/to-object.js\");\nvar IndexedObject = __webpack_require__(/*! ../internals/indexed-object */ \"./node_modules/core-js/internals/indexed-object.js\");\nvar toLength = __webpack_require__(/*! ../internals/to-length */ \"./node_modules/core-js/internals/to-length.js\");\n\n// `Array.prototype.{ reduce, reduceRight }` methods implementation\nvar createMethod = function (IS_RIGHT) {\n  return function (that, callbackfn, argumentsLength, memo) {\n    aFunction(callbackfn);\n    var O = toObject(that);\n    var self = IndexedObject(O);\n    var length = toLength(O.length);\n    var index = IS_RIGHT ? length - 1 : 0;\n    var i = IS_RIGHT ? -1 : 1;\n    if (argumentsLength < 2) while (true) {\n      if (index in self) {\n        memo = self[index];\n        index += i;\n        break;\n      }\n      index += i;\n      if (IS_RIGHT ? index < 0 : length <= index) {\n        throw TypeError('Reduce of empty array with no initial value');\n      }\n    }\n    for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {\n      memo = callbackfn(memo, self[index], index, O);\n    }\n    return memo;\n  };\n};\n\nmodule.exports = {\n  // `Array.prototype.reduce` method\n  // https://tc39.github.io/ecma262/#sec-array.prototype.reduce\n  left: createMethod(false),\n  // `Array.prototype.reduceRight` method\n  // https://tc39.github.io/ecma262/#sec-array.prototype.reduceright\n  right: createMethod(true)\n};\n\n\n//# sourceURL=webpack:///./node_modules/core-js/internals/array-reduce.js?");
-
-/***/ }),
-
 /***/ "./node_modules/core-js/internals/ieee754.js":
 /*!***************************************************!*\
   !*** ./node_modules/core-js/internals/ieee754.js ***!

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/app.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/chunk-elementUI.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 11 - 11
dist/static/js/chunk-libs.js


+ 15 - 15
src/apis/service/serviceParam/supplier/index.js

@@ -1,32 +1,32 @@
 // 物业管理员
-import http from "@/apis/axios";
-const api = "admin/";
+import http from '@/apis/axios'
+const api = 'admin/'
 export default {
   // 添加
-  add: (data, params) => http(api + "supplercreate", data, "post", params),
+  add: (data, params) => http(api + 'supplercreate', data, 'post', params),
   // 删除
-  delete: (data, params) => http(api + "supplerdelete", data, "post", params),
+  delete: (data, params) => http(api + 'supplerdelete', data, 'post', params),
   // 分页查询
-  list: (data, params) => http(api + "supplerlist", data, "post", params),
+  list: (data, params) => http(api + 'supplerlist', data, 'post', params),
   // 更新
-  update: (data, params) => http(api + "suppleredit", data, "post", params),
+  update: (data, params) => http(api + 'suppleredit', data, 'post', params),
   // 修改状态
   status: (data, params) => http(api + 'supplerstatus', data, 'post', params),
   // 详情
-  detail: (data, params) => http(api + "supplerinfo", data, "post", params),
-  //升级为业务公司
-  inv_update: (data, params) => http(api + "supplerUpgrade", data, "post", params),
+  detail: (data, params) => http(api + 'supplerinfo', data, 'post', params),
+  // 升级为业务公司
+  inv_update: (data, params) => http(api + 'supplerUpgrade', data, 'post', params),
 
   // 添加
-  kadd: (data, params) => http(api + "keepbcreate", data, "post", params),
+  kadd: (data, params) => http(api + 'keepbcreate', data, 'post', params),
   // 删除
-  kdelete: (data, params) => http(api + "keepbdelete", data, "post", params),
+  kdelete: (data, params) => http(api + 'keepbdelete', data, 'post', params),
   // 分页查询
-  klist: (data, params) => http(api + "keepblist", data, "post", params),
+  klist: (data, params) => http(api + 'keepblist', data, 'post', params),
   // 修改状态
   kstatus: (data, params) => http(api + 'keepbstatus', data, 'post', params),
   // 详情
-  kdetail: (data, params) => http(api + "keepbinfo", data, "post", params),
+  kdetail: (data, params) => http(api + 'keepbinfo', data, 'post', params),
   // 更新
-  kupdate: (data, params) => http(api + "keepbedit", data, "post", params),
-};
+  kupdate: (data, params) => http(api + 'keepbedit', data, 'post', params)
+}

+ 4 - 0
src/store/modules/user.js

@@ -331,11 +331,13 @@ const actions = {
           commit('setCurrentLevel', level)
           //获取公司列表(区分超管和普通账户api)
           const api = isSupertube ? requsetSupertubeCompany : requsetUserBindingCompany
+
           //获取缓存里的业务公司 => 公司名称搜索 => 存在设置为默认公司
           const { data: companyData, code: companyCode } = await api({
             ...(!isSupertube ? ({size: 10000}) : {type: '1'}),
             ...({token: getToken()}),
           })
+          
            //保存公司列表 普通用户和超管使用两个列表需要转换
            let _companylist = []
            if(companyCode === 0) {
@@ -363,6 +365,7 @@ const actions = {
           //保存默认公司
           commit('setCurrentCompany', defaultCompany ? defaultCompany.code : '')
           const { mcode, mdata, mmsg } = await getRoleMenuList();
+
           //拦截账号异常: 禁用
           if(mcode === 10001) {
             dispatch('disabledCompany');
@@ -464,6 +467,7 @@ function isHasRoute(routes){
   let isHas = false
   const chunks = location.hash.split('/')
   const currentPath = chunks[chunks.length - 1]
+
   const dfs = (routes) => {
     routes.forEach(route => {
       if(route.path === currentPath) isHas = true;

+ 2 - 3
src/views/interest/handover/components/addEditForm.vue

@@ -212,22 +212,21 @@ export default {
         if (this.$refs.ruleForm) {
           this.$refs.ruleForm.resetFields();
           this.$refs.ruleForm.clearValidate();
-          console.log(this.sitem);
+
           const {
             status,
+            remark,
             resign_name,
             hand_name,
             hand_uid,
             resign_uid,
             expire_date,
             resign_date,
-            remark,
           } = this.sitem;
           this.resign_name = resign_name || "";
           this.hand_name = hand_name || "";
           this.status = status || "";
 
-          console.log('line229',this.sitem)
           this.ruleForm = {
             hand_uid: hand_uid ? String(hand_uid).split(",") : [],
             resign_uid: resign_uid ? String(resign_uid).split(",") : [],

+ 159 - 150
src/views/serviceParam/supplier/components/addEdit.vue

@@ -1,17 +1,17 @@
 <template>
   <el-dialog
+    v-loading="loading"
     :title="title"
     :center="true"
     align="left"
     top="8vh"
     width="1040px"
-    @close="showModelThis = false"
     :close-on-click-modal="false"
     :visible.sync="showModelThis"
-    v-loading="loading"
     element-loading-text="拼命加载中"
     element-loading-spinner="el-icon-loading"
     element-loading-background="rgba(0, 0, 0, 0.8)"
+    @close="showModelThis = false"
   >
     <el-card style="margin-top: -20px">
       <el-row>
@@ -37,9 +37,7 @@
                 <el-row>
                   <el-col :span="4">
                     <el-form-item label="法人" required>
-                      {{ ruleForm.inv_legaler }}</el-form-item
-                    ></el-col
-                  >
+                      {{ ruleForm.inv_legaler }}</el-form-item></el-col>
                   <el-col :span="4">
                     <el-form-item
                       label="营业执照"
@@ -52,10 +50,10 @@
                       >
                         <img
                           v-if="ruleForm.license_img"
-                          :src="ruleForm.license_img"
                           v-viewer
+                          :src="ruleForm.license_img"
                           class="avatar"
-                        />
+                        >
                       </div>
                     </el-form-item>
                   </el-col>
@@ -67,15 +65,16 @@
 
                   <el-col :span="24">
                     <el-row>
-                      <el-col :span="8"
-                        ><el-form-item
-                          label="纳税识别号"
-                          required
-                          label-width="100px"
-                          style="width: 100%"
-                        >
-                          {{ ruleForm.inv_code }}
-                        </el-form-item>
+                      <el-col
+                        :span="8"
+                      ><el-form-item
+                        label="纳税识别号"
+                        required
+                        label-width="100px"
+                        style="width: 100%"
+                      >
+                        {{ ruleForm.inv_code }}
+                      </el-form-item>
                       </el-col>
                       <el-col :span="7">
                         <el-form-item label="成立日期" required>
@@ -85,9 +84,7 @@
 
                       <el-col :span="9">
                         <el-form-item label="公司类型" required>
-                          {{ ruleForm.type }}</el-form-item
-                        ></el-col
-                      >
+                          {{ ruleForm.type }}</el-form-item></el-col>
                     </el-row>
                   </el-col>
 
@@ -99,8 +96,7 @@
                   <el-col :span="6">
                     <el-form-item label="联系人" required>
                       {{ ruleForm.contactor }}
-                    </el-form-item></el-col
-                  >
+                    </el-form-item></el-col>
 
                   <el-col :span="24">
                     <el-form-item label="营业范围" required>
@@ -126,6 +122,15 @@
               >
                 <el-row>
                   <el-col :span="13">
+                    <el-form-item size="medium" label="公司抬头" prop="invoice_title">
+                      <el-input
+                        v-model="ruleForm.invoice_title"
+                        placeholder="公司抬头"
+                        :disabled="isDetail == '007'"
+                        maxlength="100"
+                      />
+                    </el-form-item>
+
                     <el-form-item size="medium" label="银行名称" prop="inv_bank">
                       <el-input
                         v-model="ruleForm.inv_bank"
@@ -135,6 +140,7 @@
                       />
                     </el-form-item>
                   </el-col>
+
                   <el-col :span="11">
                     <el-form-item size="medium" label="银行卡号" prop="inv_bankNo">
                       <el-input
@@ -144,9 +150,7 @@
                         :disabled="isDetail == '007'"
                       />
                     </el-form-item>
-                  </el-col>
 
-                  <el-col :span="13">
                     <el-form-item size="medium" label="联系地址" prop="inv_addr">
                       <el-input
                         v-model="ruleForm.inv_addr"
@@ -156,7 +160,8 @@
                       />
                     </el-form-item>
                   </el-col>
-                  <el-col :span="11">
+
+                  <el-col :span="13">
                     <el-form-item size="medium" label="联系电话" prop="mobile">
                       <el-input
                         v-model="ruleForm.mobile"
@@ -165,19 +170,20 @@
                         :disabled="isDetail == '007'"
                       />
                     </el-form-item>
-                    <div style="width: 100%; text-align: right">
-                      <el-button
-                        type="primary"
-                        :size="'small'"
-                        @click="submitForm"
-                        v-if="isDetail !== '007'"
-                        >保 存
-                      </el-button>
-                      <el-button :size="'small'" @click="showModelThis = false">{{
-                        isDetail == "007" ? "关 闭" : "取 消"
-                      }}</el-button>
-                    </div>
                   </el-col>
+
+                  <div style="width: 100%; text-align: right">
+                    <el-button
+                      v-if="isDetail !== '007'"
+                      type="primary"
+                      :size="'small'"
+                      @click="submitForm"
+                    >保 存
+                    </el-button>
+                    <el-button :size="'small'" @click="showModelThis = false">{{
+                      isDetail == "007" ? "关 闭" : "取 消"
+                    }}</el-button>
+                  </div>
                 </el-row>
               </el-col>
             </el-row>
@@ -188,179 +194,181 @@
   </el-dialog>
 </template>
 <script>
-import asyncRequest from "@/apis/service/serviceParam/supplier";
-import resToken from "@/mixins/resToken";
-import { isMobile, isPhone, invTime } from "@/utils/validate";
+import asyncRequest from '@/apis/service/serviceParam/supplier'
+import resToken from '@/mixins/resToken'
+import { isMobile, isPhone, invTime } from '@/utils/validate'
 export default {
-  name: "workCompany",
-  props: ["showModel", "id", "sitem", "isDetail"],
+  name: 'WorkCompany',
   mixins: [resToken],
+  props: ['showModel', 'id', 'sitem', 'isDetail'],
   data() {
     const validatemobile = (rule, value, callback) => {
-      if (value !== "") {
+      if (value !== '') {
         if (isPhone(value) || isMobile(value)) {
-          callback();
+          callback()
         } else {
-          callback(new Error("联系电话格式不正确!"));
+          callback(new Error('联系电话格式不正确!'))
         }
       } else {
-        callback(new Error("联系电话不能为空!"));
+        callback(new Error('联系电话不能为空!'))
       }
-    };
+    }
 
     return {
       pickerOptions: {
         disabledDate(time) {
-          return time.getTime() >= Date.now();
-        },
+          return time.getTime() >= Date.now()
+        }
       },
-      supplier_name: "",
-      accountNames: "",
+      supplier_name: '',
+      accountNames: '',
       loading: false,
-      title: "供应商升级业务企业",
+      title: '供应商升级业务企业',
       showModelThis: this.showModel,
       ruleForm: {
-        id: "",
-        code: "",
-        company: "", //公司名称
-        type: "", //	公司类型
-        inv_code: "", //	纳税识别号
-        inv_legaler: "", //	法人
-        inv_time: "", //注册日期
-        inv_addr: "", //注册地址
-        inv_bank: "", //	银行
-        inv_bankNo: "", //	银行账户
-        contactor: "", //		联系人
-        mobile: "", //	联系人电话
-        addr: "", //		联系地址
-        inv_scope: "", //	经营范围
-        license_img: "", //	营业执照
+        id: '',
+        code: '',
+        company: '', // 公司名称
+        type: '', //	公司类型
+        inv_code: '', //	纳税识别号
+        inv_legaler: '', //	法人
+        inv_time: '', // 注册日期
+        inv_addr: '', // 注册地址
+        inv_bank: '', //	银行
+        inv_bankNo: '', //	银行账户
+        contactor: '', //		联系人
+        mobile: '', //	联系人电话
+        addr: '', //		联系地址
+        inv_scope: '', //	经营范围
+        license_img: '', //	营业执照
+        invoice_title: ''
       },
       rulesThis: this.rules,
       rules: {
         inv_bank: [
           {
             required: true,
-            message: "银行名称不能为空!",
-            trigger: "blur",
-          },
+            message: '银行名称不能为空!',
+            trigger: 'blur'
+          }
         ],
         inv_bankNo: [
           {
             required: true,
-            message: "银行卡号不能为空!",
-            trigger: "blur",
-          },
+            message: '银行卡号不能为空!',
+            trigger: 'blur'
+          }
         ],
 
         mobile: [
           {
             required: true,
             validator: validatemobile,
-            trigger: "blur",
-          },
+            trigger: 'blur'
+          }
         ],
-        inv_addr: [{ required: true, message: "联系地址不能为空!", trigger: "blur" }],
-      },
-    };
+        inv_addr: [{ required: true, message: '联系地址不能为空!', trigger: 'blur' }],
+        invoice_title: [{ required: true, message: '公司抬头不能为空', trigger: 'blur' }]
+      }
+    }
   },
   watch: {
-    showModel: function (val) {
-      this.showModelThis = val;
+    showModel: function(val) {
+      this.showModelThis = val
       if (val) {
-        this.initForm();
+        this.initForm()
       }
     },
     showModelThis(val) {
       if (!val) {
-        this.$emit("cancel");
+        this.$emit('cancel')
       }
-    },
+    }
   },
   methods: {
     async initForm() {
-      this.supplier_name = "";
-      this.loading = true;
-      this.rulesThis = this.rules;
-      await this.resetForm();
-      await this.initData();
-      this.loading = false;
+      this.supplier_name = ''
+      this.loading = true
+      this.rulesThis = this.rules
+      await this.resetForm()
+      await this.initData()
+      this.loading = false
     },
 
     async initData() {
-      const { code } = this.sitem;
-      const res = await asyncRequest.detail({ code });
+      const { code } = this.sitem
+      const res = await asyncRequest.detail({ code })
       if (res && res.code === 0 && res.data) {
         const {
           id,
-          name, //公司名称
+          name, // 公司名称
           nature, //	公司类型
           registercode, //	纳税识别号
           legaler, //	法人
-          registertime, //注册日期
+          registertime, // 注册日期
           contactor, //		联系人
           addr, //		联系地址
           scope, //	经营范围
-          license_img, //	营业执照
-        } = res.data;
+          license_img //	营业执照
+        } = res.data
         // console.log(invTime(registertime));
         this.ruleForm = {
-          id: id || "",
+          id: id || '',
           code,
-          company: name || "", //公司名称
-          type: nature || "", //	公司类型
-          inv_code: registercode || "", //	纳税识别号
-          inv_legaler: legaler || "", //	法人
-          inv_time: invTime(registertime) || "", //注册日期
-          inv_addr: "", //注册地址
-          inv_bank: "", //	银行
-          inv_bankNo: "", //	银行账户
-          contactor: contactor || "", //		联系人
-          mobile: "", //	联系人电话
-          addr: addr || "", //		联系地址
-          inv_scope: scope || "", //	经营范围
-          license_img: license_img || "", //	营业执照
-        };
+          company: name || '', // 公司名称
+          type: nature || '', //	公司类型
+          inv_code: registercode || '', //	纳税识别号
+          inv_legaler: legaler || '', //	法人
+          inv_time: invTime(registertime) || '', // 注册日期
+          inv_addr: '', // 注册地址
+          inv_bank: '', //	银行
+          inv_bankNo: '', //	银行账户
+          contactor: contactor || '', //		联系人
+          mobile: '', //	联系人电话
+          addr: addr || '', //		联系地址
+          inv_scope: scope || '', //	经营范围
+          license_img: license_img || '' //	营业执照
+        }
       } else if (res && res.code >= 100 && res.code <= 104) {
-        await this.logout();
+        await this.logout()
       } else {
-        this.$message.warning(res.message);
+        this.$message.warning(res.message)
       }
     },
     async resetForm() {
       // 重置
       await this.$nextTick(() => {
         if (this.$refs.ruleForm) {
-          this.$refs.ruleForm.resetFields();
-          this.$refs.ruleForm.clearValidate();
+          this.$refs.ruleForm.resetFields()
+          this.$refs.ruleForm.clearValidate()
           this.ruleForm = {
-            id: "",
-            code: "",
-            company: "", //公司名称
-            type: "", //	公司类型
-            inv_code: "", //	纳税识别号
-            inv_legaler: "", //	法人
-            inv_time: "", //注册日期
-            inv_addr: "", //注册地址
-            inv_bank: "", //	银行
-            inv_bankNo: "", //	银行账户
-            contactor: "", //		联系人
-            mobile: "", //	联系人电话
-            addr: "", //		联系地址
-            inv_scope: "", //	经营范围
-            license_img: "", //	营业执照
-          };
+            id: '',
+            code: '',
+            company: '', // 公司名称
+            type: '', //	公司类型
+            inv_code: '', //	纳税识别号
+            inv_legaler: '', //	法人
+            inv_time: '', // 注册日期
+            inv_addr: '', // 注册地址
+            inv_bank: '', //	银行
+            inv_bankNo: '', //	银行账户
+            contactor: '', //		联系人
+            mobile: '', //	联系人电话
+            addr: '', //		联系地址
+            inv_scope: '', //	经营范围
+            license_img: '' //	营业执照
+          }
         }
-      });
+      })
     },
     async submitForm() {
-      await this.$refs.ruleForm.validate(async (valid) => {
+      await this.$refs.ruleForm.validate(async(valid) => {
         if (valid) {
           if (this.loading) {
-            return;
+            return
           }
-          this.loading = true;
-          const { code, inv_bank, inv_bankNo, inv_addr, mobile } = this.ruleForm;
+          this.loading = true
+          const { code, inv_bank, inv_bankNo, inv_addr, mobile, invoice_title } = this.ruleForm
 
           const model = {
             code,
@@ -368,31 +376,32 @@ export default {
             inv_bankNo,
             inv_addr,
             mobile,
-          };
+            invoice_title
+          }
 
-          const res = await asyncRequest.inv_update(model);
-          this.loading = false;
+          const res = await asyncRequest.inv_update(model)
+          this.loading = false
           if (res && res.code === 0) {
             this.$notify.success({
-              title: "升级成功",
-              message: "",
-            });
-            this.showModelThis = false;
+              title: '升级成功',
+              message: ''
+            })
+            this.showModelThis = false
             // 刷新
-            this.$emit("refresh");
+            this.$emit('refresh')
           } else if (res && res.code >= 100 && res.code <= 104) {
-            await this.logout();
+            await this.logout()
           } else {
-            this.$message.warning(res.message);
+            this.$message.warning(res.message)
           }
         } else {
-          console.log("error submit!!");
-          return false;
+          console.log('error submit!!')
+          return false
         }
-      });
-    },
-  },
-};
+      })
+    }
+  }
+}
 </script>
 
 <style lang="scss" scoped>

+ 196 - 182
src/views/serviceParam/workCompany/addEdit.vue

@@ -1,17 +1,17 @@
 <template>
   <el-dialog
+    v-loading="loading"
     :title="title"
     :center="true"
     align="left"
     top="8vh"
     width="1040px"
-    @close="showModelThis = false"
     :close-on-click-modal="false"
     :visible.sync="showModelThis"
-    v-loading="loading"
     element-loading-text="拼命加载中"
     element-loading-spinner="el-icon-loading"
     element-loading-background="rgba(0, 0, 0, 0.8)"
+    @close="showModelThis = false"
   >
     <el-card style="margin-top: -20px">
       <el-row>
@@ -38,9 +38,7 @@
                 <el-row>
                   <el-col :span="4">
                     <el-form-item label="法人" required>
-                      {{ ruleForm.inv_legaler }}</el-form-item
-                    ></el-col
-                  >
+                      {{ ruleForm.inv_legaler }}</el-form-item></el-col>
                   <el-col :span="4">
                     <el-form-item
                       label="营业执照"
@@ -53,10 +51,10 @@
                       >
                         <img
                           v-if="ruleForm.license_img"
-                          :src="ruleForm.license_img"
                           v-viewer
+                          :src="ruleForm.license_img"
                           class="avatar"
-                        />
+                        >
                       </div>
                     </el-form-item>
                   </el-col>
@@ -68,15 +66,16 @@
 
                   <el-col :span="24">
                     <el-row>
-                      <el-col :span="8"
-                        ><el-form-item
-                          label="纳税识别号"
-                          required
-                          label-width="100px"
-                          style="width: 100%"
-                        >
-                          {{ ruleForm.inv_code }}
-                        </el-form-item>
+                      <el-col
+                        :span="8"
+                      ><el-form-item
+                        label="纳税识别号"
+                        required
+                        label-width="100px"
+                        style="width: 100%"
+                      >
+                        {{ ruleForm.inv_code }}
+                      </el-form-item>
                       </el-col>
                       <el-col :span="7">
                         <el-form-item label="成立日期" required>
@@ -86,9 +85,7 @@
 
                       <el-col :span="9">
                         <el-form-item label="公司类型" required>
-                          {{ ruleForm.type }}</el-form-item
-                        ></el-col
-                      >
+                          {{ ruleForm.type }}</el-form-item></el-col>
                     </el-row>
                   </el-col>
 
@@ -100,8 +97,7 @@
                   <el-col :span="6">
                     <el-form-item label="联系人" required>
                       {{ ruleForm.contactor }}
-                    </el-form-item></el-col
-                  >
+                    </el-form-item></el-col>
 
                   <el-col :span="24">
                     <el-form-item label="营业范围" required>
@@ -131,6 +127,17 @@
               <el-col :span="23" style="padding: 20px 0 0 0">
                 <el-row>
                   <el-col :span="13">
+                    <el-form-item label="公司抬头" prop="invoice_title">
+                      <el-input
+                        v-model="ruleForm.invoice_title"
+                        placeholder="公司抬头"
+                        :disabled="isDetail == '007'"
+                        maxlength="100"
+                      />
+                    </el-form-item>
+                  </el-col>
+
+                  <el-col :span="11">
                     <el-form-item label="银行名称" prop="inv_bank">
                       <el-input
                         v-model="ruleForm.inv_bank"
@@ -140,7 +147,8 @@
                       />
                     </el-form-item>
                   </el-col>
-                  <el-col :span="11">
+
+                  <el-col :span="13">
                     <el-form-item label="银行卡号" prop="inv_bankNo">
                       <el-input
                         v-model="ruleForm.inv_bankNo"
@@ -151,7 +159,7 @@
                     </el-form-item>
                   </el-col>
 
-                  <el-col :span="13">
+                  <el-col :span="11">
                     <el-form-item label="联系地址" prop="addr">
                       <el-input
                         v-model="ruleForm.inv_addr"
@@ -161,7 +169,8 @@
                       />
                     </el-form-item>
                   </el-col>
-                  <el-col :span="11">
+
+                  <el-col :span="13">
                     <el-form-item label="联系电话" prop="mobile">
                       <el-input
                         v-model="ruleForm.mobile"
@@ -170,19 +179,20 @@
                         :disabled="isDetail == '007'"
                       />
                     </el-form-item>
-                    <div style="width: 100%; text-align: right">
-                      <el-button
-                        type="primary"
-                        :size="'small'"
-                        @click="submitForm"
-                        v-if="isDetail !== '007'"
-                        >保 存
-                      </el-button>
-                      <el-button :size="'small'" @click="showModelThis = false">{{
-                        isDetail == "007" ? "关 闭" : "取 消"
-                      }}</el-button>
-                    </div>
                   </el-col>
+
+                  <div style="width: 100%; text-align: right">
+                    <el-button
+                      v-if="isDetail !== '007'"
+                      type="primary"
+                      :size="'small'"
+                      @click="submitForm"
+                    >保 存
+                    </el-button>
+                    <el-button :size="'small'" @click="showModelThis = false">{{
+                      isDetail == "007" ? "关 闭" : "取 消"
+                    }}</el-button>
+                  </div>
                 </el-row>
               </el-col>
             </el-row>
@@ -193,133 +203,135 @@
   </el-dialog>
 </template>
 <script>
-import asyncRequest from "@/apis/service/serviceParam/workCompany";
-import resToken from "@/mixins/resToken";
-import { isMobile, isPhone, invTime } from "@/utils/validate";
+import asyncRequest from '@/apis/service/serviceParam/workCompany'
+import resToken from '@/mixins/resToken'
+import { isMobile, isPhone, invTime } from '@/utils/validate'
 export default {
-  name: "workCompany",
-  props: ["showModel", "id", "isDetail"],
+  name: 'WorkCompany',
   mixins: [resToken],
+  props: ['showModel', 'id', 'isDetail'],
   data() {
     const validatemobile = (rule, value, callback) => {
-      if (value !== "") {
+      if (value !== '') {
         if (isPhone(value) || isMobile(value)) {
-          callback();
+          callback()
         } else {
-          callback(new Error("联系电话格式不正确!"));
+          callback(new Error('联系电话格式不正确!'))
         }
       } else {
-        callback(new Error("联系电话不能为空!"));
+        callback(new Error('联系电话不能为空!'))
       }
-    };
+    }
 
     return {
       pickerOptions: {
         disabledDate(time) {
-          return time.getTime() >= Date.now();
-        },
+          return time.getTime() >= Date.now()
+        }
       },
-      supplier_name: "",
-      accountNames: "",
+      supplier_name: '',
+      accountNames: '',
       loading: false,
-      title: "添加业务企业",
+      title: '添加业务企业',
       showModelThis: this.showModel,
       ruleForm: {
-        id: "",
-        company: "", //公司名称
-        type: "", //	公司类型
-        inv_code: "", //	纳税识别号
-        inv_legaler: "", //	法人
-        inv_time: "", //注册日期
-        inv_addr: "", //注册地址
-        inv_bank: "", //	银行
-        inv_bankNo: "", //	银行账户
-        contactor: "", //		联系人
-        mobile: "", //	联系人电话
-        addr: "", //		联系地址
-        inv_scope: "", //	经营范围
-        license_img: "", //	营业执照
+        id: '',
+        company: '', // 公司名称
+        type: '', //	公司类型
+        inv_code: '', //	纳税识别号
+        inv_legaler: '', //	法人
+        inv_time: '', // 注册日期
+        inv_addr: '', // 注册地址
+        inv_bank: '', //	银行
+        inv_bankNo: '', //	银行账户
+        contactor: '', //		联系人
+        mobile: '', //	联系人电话
+        addr: '', //		联系地址
+        inv_scope: '', //	经营范围
+        license_img: '', //	营业执照
+        invoice_title: ''
       },
       rulesThis: this.rules,
       rules: {
         inv_bank: [
           {
             required: true,
-            message: "银行名称不能为空!",
-            trigger: "blur",
-          },
+            message: '银行名称不能为空!',
+            trigger: 'blur'
+          }
         ],
         inv_bankNo: [
           {
             required: true,
-            message: "银行卡号不能为空!",
-            trigger: "blur",
-          },
+            message: '银行卡号不能为空!',
+            trigger: 'blur'
+          }
         ],
 
         mobile: [
           {
             required: true,
             validator: validatemobile,
-            trigger: "blur",
-          },
+            trigger: 'blur'
+          }
         ],
-        inv_addr: [{ required: true, message: "联系地址不能为空!", trigger: "blur" }],
-      },
-    };
+        invoice_title: [{ required: true, message: '公司抬头不能为空!', trigger: 'blur' }],
+        addr: [{ required: true, message: '联系地址不能为空!', trigger: 'blur' }]
+      }
+    }
   },
   watch: {
-    showModel: function (val) {
-      this.showModelThis = val;
+    showModel: function(val) {
+      this.showModelThis = val
       if (val) {
-        this.initForm();
+        this.initForm()
       }
     },
     showModelThis(val) {
       if (!val) {
-        this.$emit("cancel");
+        this.$emit('cancel')
       }
-    },
+    }
   },
   methods: {
     async initForm() {
-      this.supplier_name = "";
-      this.loading = true;
-      if (this.isDetail == "007") {
-        this.title = "业务企业详情";
-        this.rulesThis = {};
-        await this.resetForm();
-        await this.initData();
+      this.supplier_name = ''
+      this.loading = true
+      if (this.isDetail == '007') {
+        this.title = '业务企业详情'
+        this.rulesThis = {}
+        await this.resetForm()
+        await this.initData()
       } else {
-        this.title = "修改业务企业";
-        this.rulesThis = this.rules;
-        await this.resetForm();
-        await this.initData();
+        this.title = '修改业务企业'
+        this.rulesThis = this.rules
+        await this.resetForm()
+        await this.initData()
       }
-      this.loading = false;
+      this.loading = false
     },
     type_search_change(e) {
-      console.log(e);
-      const { id, code, label } = e;
+      console.log(e)
+      const { id, code, label } = e
       if (id) {
-        this.ruleForm.type = id;
+        this.ruleForm.type = id
       } else {
-        this.ruleForm.type = "";
+        this.ruleForm.type = ''
       }
-      this.$refs.ruleForm.validateField("type");
+      this.$refs.ruleForm.validateField('type')
     },
 
     async initData() {
-      const res = await asyncRequest.detail({ companyNo: this.id });
+      const res = await asyncRequest.detail({ companyNo: this.id })
       if (res && res.code === 0 && res.data) {
         const {
           id,
-          company, //公司名称
+          company, // 公司名称
           company_type, //	公司类型
           inv_code, //	纳税识别号
           inv_legaler, //	法人
-          inv_time, //注册日期
-          inv_addr, //注册地址
+          inv_time, // 注册日期
+          inv_addr, // 注册地址
           inv_bank, //	银行
           inv_bankNo, //	银行账户
           contactor, //		联系人
@@ -327,64 +339,65 @@ export default {
           addr, //		联系地址
           inv_scope, //	经营范围
           license_img, //	营业执照
-        } = res.data;
+          invoice_title
+        } = res.data
 
         this.ruleForm = {
-          id: id || "",
-          company: company || "", //公司名称
-          type: company_type || "", //	公司类型
-          inv_code: inv_code || "", //	纳税识别号
-          inv_legaler: inv_legaler || "", //	法人
-          inv_time: invTime(inv_time) || "", //注册日期
-          inv_addr: inv_addr || "", //注册地址
-          inv_bank: inv_bank || "", //	银行
-          inv_bankNo: inv_bankNo || "", //	银行账户
-          contactor: contactor || "", //		联系人
-          mobile: mobile || "", //	联系人电话
-          addr: addr || "", //		联系地址
-          inv_scope: inv_scope || "", //	经营范围
-          license_img: license_img || "", //	营业执照
-        };
-        console.log(this.ruleForm);
+          id: id || '',
+          company: company || '', // 公司名称
+          type: company_type || '', //	公司类型
+          inv_code: inv_code || '', //	纳税识别号
+          inv_legaler: inv_legaler || '', //	法人
+          inv_time: invTime(inv_time) || '', // 注册日期
+          inv_addr: inv_addr || '', // 注册地址
+          inv_bank: inv_bank || '', //	银行
+          inv_bankNo: inv_bankNo || '', //	银行账户
+          contactor: contactor || '', //		联系人
+          mobile: mobile || '', //	联系人电话
+          addr: addr || '', //		联系地址
+          inv_scope: inv_scope || '', //	经营范围
+          license_img: license_img || '', //	营业执照
+          invoice_title: invoice_title || ''
+        }
       } else if (res && res.code >= 100 && res.code <= 104) {
-        await this.logout();
+        await this.logout()
       } else {
-        this.$message.warning(res.message);
+        this.$message.warning(res.message)
       }
     },
     async resetForm() {
       // 重置
       await this.$nextTick(() => {
         if (this.$refs.ruleForm) {
-          this.$refs.ruleForm.resetFields();
-          this.$refs.ruleForm.clearValidate();
+          this.$refs.ruleForm.resetFields()
+          this.$refs.ruleForm.clearValidate()
           this.ruleForm = {
-            id: "",
-            company: "", //公司名称
-            type: "", //	公司类型
-            inv_code: "", //	纳税识别号
-            inv_legaler: "", //	法人
-            inv_time: "", //注册日期
-            inv_addr: "", //注册地址
-            inv_bank: "", //	银行
-            inv_bankNo: "", //	银行账户
-            contactor: "", //		联系人
-            mobile: "", //	联系人电话
-            addr: "", //		联系地址
-            inv_scope: "", //	经营范围
-            license_img: "", //	营业执照
-          };
+            id: '',
+            company: '', // 公司名称
+            type: '', //	公司类型
+            inv_code: '', //	纳税识别号
+            inv_legaler: '', //	法人
+            inv_time: '', // 注册日期
+            inv_addr: '', // 注册地址
+            inv_bank: '', //	银行
+            inv_bankNo: '', //	银行账户
+            contactor: '', //		联系人
+            mobile: '', //	联系人电话
+            addr: '', //		联系地址
+            inv_scope: '', //	经营范围
+            license_img: '' //	营业执照
+          }
         }
-      });
+      })
     },
     async submitForm() {
-      await this.$refs.ruleForm.validate(async (valid) => {
+      await this.$refs.ruleForm.validate(async(valid) => {
         if (valid) {
           if (this.loading) {
-            return;
+            return
           }
-          this.loading = true;
-          const { code, inv_bank, inv_bankNo, inv_addr, mobile, id } = this.ruleForm;
+          this.loading = true
+          const { code, inv_bank, inv_bankNo, inv_addr, mobile, id, invoice_title } = this.ruleForm
 
           const model = {
             id,
@@ -393,73 +406,74 @@ export default {
             inv_bankNo,
             inv_addr,
             mobile,
-          };
-          const res = await asyncRequest.update(model);
+            invoice_title
+          }
+          const res = await asyncRequest.update(model)
 
-          this.loading = false;
+          this.loading = false
           if (res && res.code === 0) {
             this.$notify.success({
-              title: "修改成功",
-              message: "",
-            });
-            this.showModelThis = false;
+              title: '修改成功',
+              message: ''
+            })
+            this.showModelThis = false
             // 刷新
-            this.$emit("refresh");
+            this.$emit('refresh')
           } else if (res && res.code >= 100 && res.code <= 104) {
-            await this.logout();
+            await this.logout()
           } else {
-            this.$message.warning(res.message);
+            this.$message.warning(res.message)
           }
         } else {
-          console.log("error submit!!");
-          return false;
+          console.log('error submit!!')
+          return false
         }
-      });
+      })
     },
-    //判断图片规格
+    // 判断图片规格
     beforeAvatarUpload(file) {
-      let isJPG = false,
-        isLt2M = false;
+      let isJPG = false
+      let isLt2M = false
       if (file) {
         if (
-          file.type === "image/jpg" ||
-          file.type === "image/png" ||
-          file.type === "image/jpeg"
+          file.type === 'image/jpg' ||
+          file.type === 'image/png' ||
+          file.type === 'image/jpeg'
         ) {
-          isJPG = true;
+          isJPG = true
         }
-        isLt2M = file.size / 1024 / 1024 < 1;
+        isLt2M = file.size / 1024 / 1024 < 1
         if (!isJPG) {
-          this.$message.error("图片格式不正确!");
+          this.$message.error('图片格式不正确!')
         }
         if (!isLt2M) {
-          this.$message.error("图片大小不能超过 1MB!");
+          this.$message.error('图片大小不能超过 1MB!')
         }
       }
 
-      return isJPG && isLt2M;
+      return isJPG && isLt2M
     },
-    //图片上传失败
+    // 图片上传失败
     UploadErrorEvent(res) {
-      if (res !== "break") {
-        this.$message.error("图片上传失败!");
-        this.ruleForm.license_img = "";
-        this.$refs.ruleForm.validateField("license_img");
+      if (res !== 'break') {
+        this.$message.error('图片上传失败!')
+        this.ruleForm.license_img = ''
+        this.$refs.ruleForm.validateField('license_img')
       }
     },
-    //图片上传成功
+    // 图片上传成功
     async UploadSuccessEvent(data) {
-      const { url } = data;
-      if (url === "noToken") {
-        await this.logout();
+      const { url } = data
+      if (url === 'noToken') {
+        await this.logout()
       } else {
-        this.ruleForm.license_img = url;
-        this.$message.success("图片上传成功!");
-        this.$refs.ruleForm.validateField("license_img");
+        this.ruleForm.license_img = url
+        this.$message.success('图片上传成功!')
+        this.$refs.ruleForm.validateField('license_img')
       }
-    },
-  },
-};
+    }
+  }
+}
 </script>
 
 <style lang="scss" scoped>

+ 6 - 0
src/views/serviceParam/workCompany/index.vue

@@ -271,6 +271,12 @@ export default {
         {
           prop: "company",
           label: "公司名称",
+          minWidth:'200px'
+        },
+        {
+          prop:'invoice_title',
+          label:'公司抬头',
+          minWidth:'200px'
         },
         {
           prop: "status",

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است