Browse Source

暂停
Signed-off-by: lijunqing <lijunqing@dashoo.cn>

lijunqing 6 years ago
parent
commit
4520602140

+ 64 - 22
src/dashoo.cn/backend/api/controllers/oilsupplier/supplier.go

@@ -1456,29 +1456,50 @@ func (this *OilSupplierController) GetEntityByName() {
 	typecode := this.GetString("typecode")
 	svc := supplier.GetOilSupplierService(utils.DBE)
 	var model supplier.OilSupplierApply
+	var datainfo ErrorDataInfo
 
-	var sql string
-	sql = `select a.*,b.InStyle,b.Status from ` + OilSupplierName + ` a `
-	sql += ` left join ` + OilSupplierCertName + ` b on b.SupplierId = a.Id and b.SupplierTypeCode='`+typecode+`'`
-	sql += ` where a.SupplierName ='` + name + `'`
-
-	utils.DBE.SQL(sql).Get(&model)
-
-	if model.SupplierName==""{
-		var model2 register.OilCorporateInfo
-		svc.GetEntityByWhere(OilCorporateInfoName, "SupplierName='" + name + "'", &model2)
-		model2.Remark=""
-		model2.Id=0
+	var sqlsus string
+	sqlsus = `select 1 from ` + OilSupplierName + ` a `
+	sqlsus += ` left join ` + OilSupplierCertName + ` b on b.SupplierId = a.Id`
+	sqlsus += ` where a.SupplierName ='` + name + `' and b.InFlag='2'`
+	var tempMap []map[string]string
+	tempMap,_=svc.DBE.QueryString(sqlsus)
 
-		if model2.SupplierName==""{
-			this.ServeJSON()
+	if tempMap!=nil && tempMap[0]["1"] !=""{
+		datainfo.Code = -1
+		this.Data["json"] = &datainfo
+		this.ServeJSON()
+	}else {
+		var sql string
+		sql = `select a.*,b.InStyle,b.Status from ` + OilSupplierName + ` a `
+		sql += ` left join ` + OilSupplierCertName + ` b on b.SupplierId = a.Id and b.SupplierTypeCode='` + typecode + `'`
+		sql += ` where a.SupplierName ='` + name + `'`
+
+		utils.DBE.SQL(sql).Get(&model)
+
+		if model.SupplierName == "" {
+			var model2 register.OilCorporateInfo
+			svc.GetEntityByWhere(OilCorporateInfoName, "SupplierName='"+name+"'", &model2)
+			model2.Remark = ""
+			model2.Id = 0
+
+			if model2.SupplierName == "" {
+				datainfo.Code = -2
+				this.Data["json"] = &datainfo
+				this.ServeJSON()
+			} else {
+				datainfo.Code = 0
+				datainfo.Item = model2
+				this.Data["json"] = &datainfo
+				this.ServeJSON()
+			}
 		}else{
-			this.Data["json"] = &model2
+			datainfo.Code = 0
+			datainfo.Item = model
+			this.Data["json"] = &datainfo
 			this.ServeJSON()
 		}
 	}
-	this.Data["json"] = &model
-	this.ServeJSON()
 }
 
 // @Title 添加
@@ -1494,7 +1515,10 @@ func (this *OilSupplierController) AddEntity() {
 	json.Unmarshal(jsonBlob, &model)
 	json.Unmarshal(jsonBlob, &modelCertVM)
 	serviceCert := suppliercert.GetOilSupplierCertService(utils.DBE)
-	canApply := serviceCert.IsCanApplyByExtOrganizeUser(modelCertVM.SupplierTypeCode, this.User.DepartmentId, this.User.Id, this.User.IsCompanyUser)
+	var registerUser register.OilCorporateInfo
+	sql := " UserName='" + this.User.Username + "'"
+	serviceCert.GetEntity(&registerUser,sql)
+	canApply := serviceCert.IsCanApplyByExtOrganizeUser(modelCertVM.SupplierTypeCode, registerUser.CommercialNo, this.User.Id, this.User.IsCompanyUser)
 	var errinfo ErrorDataInfo
 	if !canApply {
 		errinfo.Message = "添加失败!供方用户只能申请一次"
@@ -1806,10 +1830,28 @@ func (this *OilSupplierController) IsCanApply() {
 	canApply := svc.IsCanApplyByExtOrganizeUser(Type, registerUser.CommercialNo, this.User.Id, this.User.IsCompanyUser)
 
 	if canApply {
-		errinfo.Message = "无申请记录,可以申请"
-		errinfo.Code = 0
-		this.Data["json"] = &errinfo
-		this.ServeJSON()
+		//判断是否是暂停
+		if this.User.IsCompanyUser==1{
+			var tempMap []map[string]string
+			sql:= "select 1 from OilSupplier a left join OilSupplierCert b on a.Id=b.SupplierId where (b.CreateUserId = '" + this.User.Id + "' or a.CommercialNo='"+ registerUser.CommercialNo+"') and b.InFlag='2'"
+			tempMap,_=svc.DBE.QueryString(sql)
+			if tempMap!=nil && tempMap[0]["1"] !="" {
+				errinfo.Message = "已暂停,不可申请"
+				errinfo.Code = -2
+				this.Data["json"] = &errinfo
+				this.ServeJSON()
+			}else{
+				errinfo.Message = "无申请记录,可以申请"
+				errinfo.Code = 0
+				this.Data["json"] = &errinfo
+				this.ServeJSON()
+			}
+		}else{
+			errinfo.Message = "无申请记录,可以申请"
+			errinfo.Code = 0
+			this.Data["json"] = &errinfo
+			this.ServeJSON()
+		}
 	} else {
 		errinfo.Message = "供方用户只能申请一次"
 		errinfo.Code = -1

File diff suppressed because it is too large
+ 1247 - 1029
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/basisedit.vue


+ 1352 - 1179
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/goodsedit.vue

@@ -31,7 +31,10 @@
             @click="nextTab"
           >下一步</el-button>-->
           <el-popover>
-            <el-steps :active="formData.Step" direction="vertical" align-center finish-status="success">
+            <el-steps :active="formData.Step"
+                      direction="vertical"
+                      align-center
+                      finish-status="success">
               <el-step title="填信息"></el-step>
               <el-step title="待审批"></el-step>
               <el-step title="已审批"></el-step>
@@ -39,20 +42,29 @@
               <el-step title="待入库"></el-step>
               <el-step title="完成"></el-step>
             </el-steps>
-            <el-button slot="reference" plain size="mini" style="margin-right: 5px">查看进度</el-button>
+            <el-button slot="reference"
+                       plain
+                       size="mini"
+                       style="margin-right: 5px">查看进度</el-button>
           </el-popover>
           <!--<el-button type="primary" plain size="mini" style="margin-right:3px" v-if="formDataCert.Status == 8"
             @click="annaudit">
             年审申请</el-button>
           <el-button type="primary" plain size="mini" v-if="formDataCert.Status == 8" @click="qppend">增项申请
           </el-button>-->
-          <el-button type="primary" @click="toWord" size="mini" :disabled="formData.Status == 0">表单下载</el-button>
-          <el-button type="primary" size="mini" @click="nextStep()" v-if="add_flat && IsCompanyUser == 1 && parseInt(activeName)==3">
-          提交
-        </el-button>
+          <el-button type="primary"
+                     @click="toWord"
+                     size="mini"
+                     :disabled="formData.Status == 0">表单下载</el-button>
+          <el-button type="primary"
+                     size="mini"
+                     @click="nextStep()"
+                     v-if="add_flat && IsCompanyUser == 1 && parseInt(activeName)==3">
+            提交
+          </el-button>
           <!--<el-button type="primary" @click="toPdf" size="mini" :disabled="formData.Status == 0">准入范围</el-button>-->
           <!--<router-link :to="'/oilsupplier/supplier/goodslist'">-->
-            <!--<el-button type="primary" size="mini" style="margin-left: 8px" v-if="showReturn">返回</el-button>-->
+          <!--<el-button type="primary" size="mini" style="margin-left: 8px" v-if="showReturn">返回</el-button>-->
           <!--</router-link>-->
         </span>
       </div>
@@ -66,164 +78,255 @@
         <el-step title="完成"></el-step>
       </el-steps>-->
 
-      <el-tabs tab-position="top" v-model="activeName" style="margin-top: -10px">
+      <el-tabs tab-position="top"
+               v-model="activeName"
+               style="margin-top: -10px">
         <el-tab-pane label="企业信息">
           <el-card class="box-card">
-            <div slot="header" class="clearfix">
+            <div slot="header"
+                 class="clearfix">
               <span>供方基本信息表</span>
               <span style="float: right;">
-                <el-button type="primary" size="mini" @click="saveEntity" v-if="formDataCert.Status <= 0">保存基本信息
+                <el-button type="primary"
+                           size="mini"
+                           @click="saveEntity"
+                           v-if="formDataCert.Status <= 0">保存基本信息
                 </el-button>
               </span>
             </div>
-            <goods-info ref="GoodsInfo" :formData.sync="formData" :dictData.sync="dictData" :authUser="authUser"
-              :canUpdateSupplier="canUpdateSupplier" @selectcompany="changeFormData" @inputcompany="inputCompany">
+            <goods-info ref="GoodsInfo"
+                        :formData.sync="formData"
+                        :dictData.sync="dictData"
+                        :authUser="authUser"
+                        :canUpdateSupplier="canUpdateSupplier"
+                        @selectcompany="changeFormData"
+                        @inputcompany="inputCompany">
             </goods-info>
           </el-card>
         </el-tab-pane>
 
-        <el-tab-pane label="企业情况" :disabled="!certId" ref="tabPaneRef">
+        <el-tab-pane label="企业情况"
+                     :disabled="!certId"
+                     ref="tabPaneRef">
           <el-card class="box-card mycard">
-            <div slot="header" class="clearfix">
+            <div slot="header"
+                 class="clearfix">
               <span>企业人员结构情况</span>
               <span style="float: right;">
-                <el-button type="primary" size="mini" @click="updateNumberEntity()" v-if="formDataCert.Status <= 0">
+                <el-button type="primary"
+                           size="mini"
+                           @click="updateNumberEntity()"
+                           v-if="formDataCert.Status <= 0">
                   保存人员结构情况</el-button>
               </span>
             </div>
 
-            <el-form label-width="220px" ref="EntityFormNumber" size="mini" :model="formDataCert" :rules="rules">
+            <el-form label-width="220px"
+                     ref="EntityFormNumber"
+                     size="mini"
+                     :model="formDataCert"
+                     :rules="rules">
               <el-row>
                 <el-col :span="8">
 
                   <!--修改为必填-->
-                  <el-form-item label="企业员工总数" prop="WorkerTotal">
-                    <el-input-number v-model="formDataCert.WorkerTotal" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                  <el-form-item label="企业员工总数"
+                                prop="WorkerTotal">
+                    <el-input-number v-model="formDataCert.WorkerTotal"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="合同化用工数量">
-                    <el-input-number v-model="formDataCert.ContractNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.ContractNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="大学及以上学历人员数量">
-                    <el-input-number v-model="formDataCert.UniversityNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.UniversityNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
 
                   <!--修改为必填-->
-                  <el-form-item label="技术、管理人员数量" prop="TechnicalNum">
-                    <el-input-number v-model="formDataCert.TechnicalNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                  <el-form-item label="技术、管理人员数量"
+                                prop="TechnicalNum">
+                    <el-input-number v-model="formDataCert.TechnicalNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="高级及以上职称人员数量">
-                    <el-input-number v-model="formDataCert.AboveProfNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.AboveProfNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="中级职称人员数量">
-                    <el-input-number v-model="formDataCert.MiddleProfNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.MiddleProfNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="具有国家注册执业资格人员数量">
-                    <el-input-number v-model="formDataCert.NationalRegNum" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.NationalRegNum"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="具有国家注册执业资格证书总数">
-                    <el-input-number v-model="formDataCert.NationalCertTotal" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.NationalCertTotal"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
                   <el-form-item label="设计人员总数">
-                    <el-input-number v-model="formDataCert.DesignerTotal" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                    <el-input-number v-model="formDataCert.DesignerTotal"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
 
                 <el-col :span="8">
-                  <el-form-item label="技术工人总数" prop="SkillerTotal">
-                    <el-input-number v-model="formDataCert.SkillerTotal" controls-position="right" :min="0"
-                      style="width: 100%"></el-input-number>
+                  <el-form-item label="技术工人总数"
+                                prop="SkillerTotal">
+                    <el-input-number v-model="formDataCert.SkillerTotal"
+                                     controls-position="right"
+                                     :min="0"
+                                     style="width: 100%"></el-input-number>
                   </el-form-item>
                 </el-col>
               </el-row>
             </el-form>
           </el-card>
 
-          <el-card class="box-card mycard" style="margin-top: 10px;">
-            <div slot="header" class="clearfix">
+          <el-card class="box-card mycard"
+                   style="margin-top: 10px;">
+            <div slot="header"
+                 class="clearfix">
               <span>企业主要设备</span>
-              <el-button style="float: right; padding: 3px 0" type="text" @click="equipmentdialog"
-                v-if="formDataCert.Status <= 0">添加</el-button>
+              <el-button style="float: right; padding: 3px 0"
+                         type="text"
+                         @click="equipmentdialog"
+                         v-if="formDataCert.Status <= 0">添加</el-button>
             </div>
-            <equipment-list ref="equipmentList" :data.sync="equipmentList" :SupplierCertId="certId+''"
-              :SupplierTypeCode="classId" :canadd="add_flat" height="360px" style="margin-top: 20px"></equipment-list>
+            <equipment-list ref="equipmentList"
+                            :data.sync="equipmentList"
+                            :SupplierCertId="certId+''"
+                            :SupplierTypeCode="classId"
+                            :canadd="add_flat"
+                            height="360px"
+                            style="margin-top: 20px"></equipment-list>
           </el-card>
 
-          <el-card class="box-card mycard" style="margin-top: 10px;">
-            <div slot="header" class="clearfix">
+          <el-card class="box-card mycard"
+                   style="margin-top: 10px;">
+            <div slot="header"
+                 class="clearfix">
               <span>近三年主要业绩</span>
-              <el-button style="float: right; padding: 3px 0" type="text" @click="performancedialog"
-                v-if="formDataCert.Status <= 0">添加</el-button>
+              <el-button style="float: right; padding: 3px 0"
+                         type="text"
+                         @click="performancedialog"
+                         v-if="formDataCert.Status <= 0">添加</el-button>
             </div>
-            <performance-list ref="performanceList" :data.sync="performanceList" :SupplierCertId="certId+''"
-              :SupplierTypeCode="classId" :canadd="add_flat" style="margin-top: 20px"></performance-list>
+            <performance-list ref="performanceList"
+                              :data.sync="performanceList"
+                              :SupplierCertId="certId+''"
+                              :SupplierTypeCode="classId"
+                              :canadd="add_flat"
+                              style="margin-top: 20px"></performance-list>
           </el-card>
 
-          <el-card class="box-card mycard" style="margin-top: 10px;">
-            <div slot="header" class="clearfix">
+          <el-card class="box-card mycard"
+                   style="margin-top: 10px;">
+            <div slot="header"
+                 class="clearfix">
               <span>专利及专有技术</span>
-              <el-button style="float: right; padding: 3px 0" type="text" @click="patentdialog"
-                v-if="formDataCert.Status <= 0">添加</el-button>
+              <el-button style="float: right; padding: 3px 0"
+                         type="text"
+                         @click="patentdialog"
+                         v-if="formDataCert.Status <= 0">添加</el-button>
             </div>
-            <patent-list ref="patentList" :data.sync="patentList" :SupplierCertId="certId+''"
-              :SupplierTypeCode="classId" :canadd="add_flat" height="360px" style="margin-top: 20px"></patent-list>
+            <patent-list ref="patentList"
+                         :data.sync="patentList"
+                         :SupplierCertId="certId+''"
+                         :SupplierTypeCode="classId"
+                         :canadd="add_flat"
+                         height="360px"
+                         style="margin-top: 20px"></patent-list>
           </el-card>
 
-          <el-card class="box-card mycard" style="margin-top: 10px;">
-            <div slot="header" class="clearfix">
+          <el-card class="box-card mycard"
+                   style="margin-top: 10px;">
+            <div slot="header"
+                 class="clearfix">
               <span>近三年省部级及以上获奖项目</span>
-              <el-button style="float: right; padding: 3px 0" type="text" @click="winningdialog"
-                v-if="formDataCert.Status <= 0">添加</el-button>
+              <el-button style="float: right; padding: 3px 0"
+                         type="text"
+                         @click="winningdialog"
+                         v-if="formDataCert.Status <= 0">添加</el-button>
             </div>
-            <winning-list ref="winningList" :data.sync="winningList" :SupplierCertId="certId+''"
-              :SupplierTypeCode="classId" :canadd="add_flat" height="360px" style="margin-top: 20px"></winning-list>
+            <winning-list ref="winningList"
+                          :data.sync="winningList"
+                          :SupplierCertId="certId+''"
+                          :SupplierTypeCode="classId"
+                          :canadd="add_flat"
+                          height="360px"
+                          style="margin-top: 20px"></winning-list>
           </el-card>
         </el-tab-pane>
 
-        <el-tab-pane label="准入范围" :disabled="!certId">
-          <goods-list ref="goodsList" :data.sync="goodsList" @close="getbuslist" :canadd="add_flat"
-            :candelete="delete_flat" height="360px" style="margin-top: 20px"></goods-list>
+        <el-tab-pane label="准入范围"
+                     :disabled="!certId">
+          <goods-list ref="goodsList"
+                      :data.sync="goodsList"
+                      @close="getbuslist"
+                      :canadd="add_flat"
+                      :candelete="delete_flat"
+                      height="360px"
+                      style="margin-top: 20px"></goods-list>
         </el-tab-pane>
-        <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="add_flat" :flag="flag"
-            @close="selectAuditOrg"></subfile-list>
+        <el-tab-pane label="企业资质"
+                     :disabled="!certId">
+          <subfile-list ref="subfileList"
+                        :data.sync="subfileList"
+                        :canadd="add_flat"
+                        :flag="flag"
+                        @close="selectAuditOrg"></subfile-list>
         </el-tab-pane>
 
-        <el-tab-pane label="审批流程" v-if="formDataCert.Status != 0">
+        <el-tab-pane label="审批流程"
+                     v-if="formDataCert.Status != 0">
           <el-card class="box-card mycard">
-            <div slot="header" class="clearfix">
+            <div slot="header"
+                 class="clearfix">
               <span>审批流程</span>
               <!-- <span style="float: right;">
                 <el-button type="primary" size="mini" :disabled="formDataCert.Status > 0" :loading="applyLoading"
@@ -231,7 +334,8 @@
                 </el-button>
               </span>-->
             </div>
-            <wf-multi-history ref="WfHistory" :entryinfo="entrydetail"></wf-multi-history>
+            <wf-multi-history ref="WfHistory"
+                              :entryinfo="entrydetail"></wf-multi-history>
           </el-card>
         </el-tab-pane>
 
@@ -244,112 +348,174 @@
         <!--</el-card>-->
         <!--</el-tab-pane>-->
 
-        <el-tab-pane label="供方缴费" v-if="formDataCert.Status == 5"></el-tab-pane>
+        <el-tab-pane label="供方缴费"
+                     v-if="formDataCert.Status == 5"></el-tab-pane>
       </el-tabs>
 
       <div style="float: right; margin: 20px;">
-        <el-button ref="floatNxtBtn" type="primary" plain size="mini" @click="backTab" v-if="parseInt(activeName) > 0">
+        <el-button ref="floatNxtBtn"
+                   type="primary"
+                   plain
+                   size="mini"
+                   @click="backTab"
+                   v-if="parseInt(activeName) > 0">
           上一步</el-button>
-        <el-button ref="floatBtn" type="primary" plain size="mini" @click="nextTab"
-          v-if="parseInt(activeName) < totalTab">下一步</el-button>
-        <el-button type="primary" size="mini" @click="nextStep()" v-if="add_flat && IsCompanyUser == 1 && parseInt(activeName)==3">
+        <el-button ref="floatBtn"
+                   type="primary"
+                   plain
+                   size="mini"
+                   @click="nextTab"
+                   v-if="parseInt(activeName) < totalTab">下一步</el-button>
+        <el-button type="primary"
+                   size="mini"
+                   @click="nextStep()"
+                   v-if="add_flat && IsCompanyUser == 1 && parseInt(activeName)==3">
           提交
         </el-button>
       </div>
 
     </el-card>
-    <el-dialog title="提交初审" :visible.sync="dialogVisible" width="520px">
-      <el-form ref="searchForm" label-width="100px">
+    <el-dialog title="提交初审"
+               :visible.sync="dialogVisible"
+               width="520px">
+      <el-form ref="searchForm"
+               label-width="100px">
         <el-row>
           <el-col :span="24">
             <el-form-item label="初审人员">
-              <el-input ref="selectAuditer" readonly v-model="auditerName" placeholder="请选择初审人">
-                <el-button slot="append" icon="el-icon-search" @click="chooseAuditorShow"></el-button>
+              <el-input ref="selectAuditer"
+                        readonly
+                        v-model="auditerName"
+                        placeholder="请选择初审人">
+                <el-button slot="append"
+                           icon="el-icon-search"
+                           @click="chooseAuditorShow"></el-button>
               </el-input>
             </el-form-item>
             <el-form-item label="复审人员">
-              <el-select ref="selectAuditer" v-model="fushenauditer" placeholder="请选择复审人" style="width: 100%" filterable
-                allow-create default-first-option>
-                <el-option v-for="item in secauditerOptions" :key="item.Id" :label="item.Realname" :value="item.Id">
+              <el-select ref="selectAuditer"
+                         v-model="fushenauditer"
+                         placeholder="请选择复审人"
+                         style="width: 100%"
+                         filterable
+                         allow-create
+                         default-first-option>
+                <el-option v-for="item in secauditerOptions"
+                           :key="item.Id"
+                           :label="item.Realname"
+                           :value="item.Id">
                 </el-option>
               </el-select>
             </el-form-item>
-            <el-form-item label="专业处室" v-if="allowpre">
+            <el-form-item label="专业处室"
+                          v-if="allowpre">
               <!--<el-cascader :options="orgtreelist" :props="orgtreeprops" :show-all-levels="false" filterable-->
-                <!--style="width: 100%" v-model="majorDept" placeholder="请选择专业处室" @change="orgtreeChange()">-->
+              <!--style="width: 100%" v-model="majorDept" placeholder="请选择专业处室" @change="orgtreeChange()">-->
               <!--</el-cascader>-->
-              <el-select  v-model="selectDept" filterable
-                          placeholder="请选择" style="width: 100%" @change="changeOrgUnit">
-                <el-option  v-for="item in allorgunitOptions" :key="item.Id" :label="item.Fullname"
-                            :value="item.Id">
+              <el-select v-model="selectDept"
+                         filterable
+                         placeholder="请选择"
+                         style="width: 100%"
+                         @change="changeOrgUnit">
+                <el-option v-for="item in allorgunitOptions"
+                           :key="item.Id"
+                           :label="item.Fullname"
+                           :value="item.Id">
                 </el-option>
               </el-select>
             </el-form-item>
           </el-col>
           <el-col :span="24">
             <el-form-item label="说明">
-              <el-input v-model="auditform.AuditRemark" type="textarea" placeholder="请输入说明内容"></el-input>
+              <el-input v-model="auditform.AuditRemark"
+                        type="textarea"
+                        placeholder="请输入说明内容"></el-input>
             </el-form-item>
           </el-col>
         </el-row>
       </el-form>
-      <span slot="footer" class="dialog-footer">
-        <el-button size="mini" @click="dialogVisible = false">取 消</el-button>
-        <el-button size="mini" type="primary" @click="AuditEntity">确定</el-button>
+      <span slot="footer"
+            class="dialog-footer">
+        <el-button size="mini"
+                   @click="dialogVisible = false">取 消</el-button>
+        <el-button size="mini"
+                   type="primary"
+                   @click="AuditEntity">确定</el-button>
       </span>
     </el-dialog>
-    <el-dialog title="提交" :visible.sync="dialogVisibleCom" width="520px">
-      <el-form ref="searchForm" label-width="100px">
+    <el-dialog title="提交"
+               :visible.sync="dialogVisibleCom"
+               width="520px">
+      <el-form ref="searchForm"
+               label-width="100px">
         <el-row>
           <el-col :span="24">
             <!--<el-form-item label="分办人员">-->
-              <!--<el-input ref="selectAuditerFen" readonly v-model="auditerName" placeholder="请选择分办人">-->
-                <!--<el-button slot="append" icon="el-icon-search" @click="chooseAuditorShowFen"></el-button>-->
-              <!--</el-input>-->
+            <!--<el-input ref="selectAuditerFen" readonly v-model="auditerName" placeholder="请选择分办人">-->
+            <!--<el-button slot="append" icon="el-icon-search" @click="chooseAuditorShowFen"></el-button>-->
+            <!--</el-input>-->
             <!--</el-form-item>-->
             <el-form-item label="分办单位">
-              <el-select filterable v-model="UnitOrg" maxlength="255"  clearable  placeholder="请选择分办单位" style="width: 100%" @change="orgunitChange">
-                <el-option  v-for="item in UnitOrgOptions" :key="item.Id" :label="item.Fullname"
-                            :value="item.Id">
+              <el-select filterable
+                         v-model="UnitOrg"
+                         maxlength="255"
+                         clearable
+                         placeholder="请选择分办单位"
+                         style="width: 100%"
+                         @change="orgunitChange">
+                <el-option v-for="item in UnitOrgOptions"
+                           :key="item.Id"
+                           :label="item.Fullname"
+                           :value="item.Id">
                 </el-option>
               </el-select>
             </el-form-item>
           </el-col>
           <el-col :span="24">
             <el-form-item label="说明">
-              <el-input v-model="auditform.AuditRemark" type="textarea" placeholder="请输入说明内容">
+              <el-input v-model="auditform.AuditRemark"
+                        type="textarea"
+                        placeholder="请输入说明内容">
               </el-input>
             </el-form-item>
           </el-col>
         </el-row>
       </el-form>
-      <span slot="footer" class="dialog-footer">
-        <el-button size="mini" @click="dialogVisibleCom = false">取 消</el-button>
-        <el-button size="mini" type="primary" @click="SubpEntity">确定</el-button>
+      <span slot="footer"
+            class="dialog-footer">
+        <el-button size="mini"
+                   @click="dialogVisibleCom = false">取 消</el-button>
+        <el-button size="mini"
+                   type="primary"
+                   @click="SubpEntity">确定</el-button>
       </span>
     </el-dialog>
 
-    <choose-auditor ref="chooseAuditor" @close="setAuditer" @hideChooseAuditer="chooseAuditorVisible=false"
-      :visible="chooseAuditorVisible"></choose-auditor>
-    <choose-auditor-fen ref="chooseAuditorFen" @close="setAuditerFen" @hideChooseAuditer="chooseAuditorVisibleFen=false"
-      :visible="chooseAuditorVisibleFen"></choose-auditor-fen>
+    <choose-auditor ref="chooseAuditor"
+                    @close="setAuditer"
+                    @hideChooseAuditer="chooseAuditorVisible=false"
+                    :visible="chooseAuditorVisible"></choose-auditor>
+    <choose-auditor-fen ref="chooseAuditorFen"
+                        @close="setAuditerFen"
+                        @hideChooseAuditer="chooseAuditorVisibleFen=false"
+                        :visible="chooseAuditorVisibleFen"></choose-auditor-fen>
   </div>
 </template>
 
 <script>
-  import {
-    mapGetters
-  } from 'vuex'
+import {
+  mapGetters
+} from 'vuex'
 import api from '@/api/oilsupplier/supplier'
 import apiCert from '@/api/oilsupplier/suppliercert'
 import annapi from '@/api/oilsupplier/annualaudit'
-  import SupplierFileTable from '@/pages/oilsupplier/supplierfile/table.vue'
+import SupplierFileTable from '@/pages/oilsupplier/supplierfile/table.vue'
 import WfMultiHistory from '@/components/workflow/wfmultihistory.vue'
 import WfBackHistory from '@/components/workflow/wfbackhistory.vue'
 import SupplierCertEdit from '@/components/oilsupplier/suppliercertedit.vue'
 import dataapi from '@/api/oilsupplier/dataentry'
 
-  import EquipmentList from '@/components/oilsupplier/equipmentlist'
+import EquipmentList from '@/components/oilsupplier/equipmentlist'
 import PerformanceList from '@/components/oilsupplier/performancelist'
 import PatentList from '@/components/oilsupplier/patentlist'
 import WinningList from '@/components/oilsupplier/winninglist'
@@ -357,1172 +523,1179 @@ import GoodsList from '@/components/oilsupplier/goodslist'
 import SubfileList from '@/components/oilsupplier/subfilelist'
 import GoodsInfo from '@/components/oilsupplier/goodsinfo'
 import ChooseAuditorFen from '@/components/oilsupplier/chooseauditorfenban'
-  import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
+import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
 import FloatImgBtn from '@/components/floatButton/index'
 
-  export default {
-    components: {
-      FloatImgBtn,
-      SupplierFileTable,
-      WfMultiHistory,
-      WfBackHistory,
-      SupplierCertEdit,
-      ChooseAuditorFen,
+export default {
+  components: {
+    FloatImgBtn,
+    SupplierFileTable,
+    WfMultiHistory,
+    WfBackHistory,
+    SupplierCertEdit,
+    ChooseAuditorFen,
 
-      EquipmentList, // 企业主要设备
-      PerformanceList, // 近三年主要业绩列表
-      PatentList, // 专利及专有技术列表
-      WinningList, // 近三年省部级及以上获奖项目列表
-      GoodsList, // 选择准入范围
-      SubfileList, // 选择企业资质
-      GoodsInfo,
+    EquipmentList, // 企业主要设备
+    PerformanceList, // 近三年主要业绩列表
+    PatentList, // 专利及专有技术列表
+    WinningList, // 近三年省部级及以上获奖项目列表
+    GoodsList, // 选择准入范围
+    SubfileList, // 选择企业资质
+    GoodsInfo,
 
-      ChooseAuditor
-    },
-    computed: {
-      ...mapGetters({
-        authUser: 'authUser'
-      })
-    },
-    name: 'goodsEdit',
+    ChooseAuditor
+  },
+  computed: {
+    ...mapGetters({
+      authUser: 'authUser'
+    })
+  },
+  name: 'goodsEdit',
 
-    data () {
-      var checkWorkerTotal = (rule, value, callback) => {
-        if (value <= 0) {
-          return callback(new Error('企业员工总数必须大于0'))
-        } else {
-          callback()
-        }
+  data () {
+    var checkWorkerTotal = (rule, value, callback) => {
+      if (value <= 0) {
+        return callback(new Error('企业员工总数必须大于0'))
+      } else {
+        callback()
       }
-      var checkTechnicalNum = (rule, value, callback) => {
-        if (value <= 0) {
-          return callback(new Error('技术、管理人员数量必须大于0'))
-        } else {
-          callback()
-        }
+    }
+    var checkTechnicalNum = (rule, value, callback) => {
+      if (value <= 0) {
+        return callback(new Error('技术、管理人员数量必须大于0'))
+      } else {
+        callback()
       }
-      var checkSkillerTotal = (rule, value, callback) => {
-        if (value <= 0) {
-          return callback(new Error('技术工人总数必须大于0'))
-        } else {
-          callback()
-        }
+    }
+    var checkSkillerTotal = (rule, value, callback) => {
+      if (value <= 0) {
+        return callback(new Error('技术工人总数必须大于0'))
+      } else {
+        callback()
       }
-      return {
-        allowpre: true,
-        totalTab: 3,
-        chooseAuditorVisible: false,
-        chooseAuditorVisibleFen: false,
-        createBtn: false,
-        activeName: '0',
-        fushenauditer: '', // 复审人员
-        majorDept: [100000000, 100000001, 100000071], // 专业可是
-        userOptions: [],
-        UnitOrgOptions: [],
-        orgauditOptions: [],
-        UnitOrg: '',
-        allorgunitOptions: [],
-        selectDept: 100000071,
-        dialogVisibleCom: false,
-        showReturn: 1,
-        IsCompanyUser: 0,
-        dialogVisible: false,
-        canUpdateSupplier: true,
-        dictData: null,
-        applyLoading: false,
-        equipmentList: [], // 企业主要设备
-        performanceList: [], // 近三年主要业绩
-        patentList: [], // 专利及专有技术
-        winningList: [], // 近三年省部级及以上获奖项目
-        goodsList: [], // 准入业务
-        subfileList: [], // 资质
-        organizeOption: [], // 审批部门
-        secauditerOptions: [],
-        orgtreelist: [],
-        secOrganize: [],
-        auditer: '',
-        auditerName: '',
-        serviceId: '',
+    }
+    return {
+      allowpre: true,
+      totalTab: 3,
+      chooseAuditorVisible: false,
+      chooseAuditorVisibleFen: false,
+      createBtn: false,
+      activeName: '0',
+      fushenauditer: '', // 复审人员
+      majorDept: [100000000, 100000001, 100000071], // 专业可是
+      userOptions: [],
+      UnitOrgOptions: [],
+      orgauditOptions: [],
+      UnitOrg: '',
+      allorgunitOptions: [],
+      selectDept: 100000071,
+      dialogVisibleCom: false,
+      showReturn: 1,
+      IsCompanyUser: 0,
+      dialogVisible: false,
+      canUpdateSupplier: true,
+      dictData: null,
+      applyLoading: false,
+      equipmentList: [], // 企业主要设备
+      performanceList: [], // 近三年主要业绩
+      patentList: [], // 专利及专有技术
+      winningList: [], // 近三年省部级及以上获奖项目
+      goodsList: [], // 准入业务
+      subfileList: [], // 资质
+      organizeOption: [], // 审批部门
+      secauditerOptions: [],
+      orgtreelist: [],
+      secOrganize: [],
+      auditer: '',
+      auditerName: '',
+      serviceId: '',
+      certId: '',
+      classId: '01',
+      FirstAudit: '',
+      auditform: {
+        FirstAuditName: '',
+        SecondAudit: '',
+        ThirdAudit: '',
+        CertId: '',
+        AuditRemark: '',
+        TypeCode: '01'
+      },
+      orgtreeprops: {
+        value: 'id',
+        label: 'name',
+        children: 'children'
+      },
+      formData: {
+        Id: '',
+        AllAddress: '',
+        LinkAllAddress: '',
+        SupplierName: '',
+        CredentialFlag: '1',
+        OilCertificateNo: '',
+        Grade: '',
+        MgrUnit: '',
+        OperType: '',
+        Country: '中国',
+        MaunAgent: '',
+        ConstructTeam: '',
+        CommercialNo: '',
+        OrganCode: '',
+        CountryTaxNo: '',
+        LocalTaxNo: '',
+        Address: '',
+        Province: '',
+        City: '',
+        Street: '',
+        HouseNo: '',
+        ZipCode: '',
+        LinkAddress: '',
+        LinkProvince: '',
+        LinkCity: '',
+        LinkStreet: '',
+        LinkHouseNo: '',
+        LinkZipCode: '',
+        QualitySystemCert: '',
+        ProductQualityCert: '',
+        MaunLicense: '',
+        QualifCert: '',
+        QualifCertLevel: '',
+        SafetyLicense: '',
+        TechServiceLic: '',
+        TJInNotify: '',
+        SpecIndustryCert: '',
+        BusinessScope: '',
+        LegalPerson: '',
+        CategoryCode: '',
+        CategoryName: '',
+        RegCapital: '',
+        Currency: 'CNY',
+        ContactName: '',
+        CompanyType: '',
+        SetupTime: new Date(),
+        DepositBank: '',
+        BankAccount: '',
+        EMail: '',
+        BankCreditRating: '',
+        Mobile: '',
+        Telphone: '',
+        Fax: '',
+        CompanyTel: '',
+        QQ: '',
+        CompanyUrl: '',
+        SpecSupplier: '',
+        SpecTypeCode: '1',
+        SpecTypeName: '',
+        InStyle: '1',
+        WorkerTotal: 0,
+        ContractNum: 0,
+        UniversityNum: 0,
+        TechnicalNum: 0,
+        AboveProfNum: 0,
+        MiddleProfNum: 0,
+        NationalRegNum: 0,
+        NationalCertTotal: 0,
+        DesignerTotal: 0,
+        SkillerTotal: 0,
+        Remark: '',
+        // IsDelete: 0,
+        // CreateOn: "",
+        // CreateUserId: "",
+        // CreateBy: "",
+        // ModifiedOn: "",
+        // ModifiedUserId: "",
+        // ModifiedBy: "",
+        CertId: 0,
+        SupplierTypeCode: '01',
+        SupplierTypeName: '物资类',
+        Step: 0,
+        HseTraining: '0',
+        AuditIndex: 0,
+        PACNumber: '',
+        SupplierCertificate: '',
+        ProcessKey: ''
+      },
+
+      formDataCert: {
+        InStyle: '1',
+        WorkerTotal: 0,
+        ContractNum: 0,
+        UniversityNum: 0,
+        TechnicalNum: 0,
+        AboveProfNum: 0,
+        MiddleProfNum: 0,
+        NationalRegNum: 0,
+        NationalCertTotal: 0,
+        DesignerTotal: 0,
+        SkillerTotal: 0,
+        Status: 0
+      },
+      add_flat: true,
+      delete_flat: true,
+      entrydetail: {
+        process: '',
+        business: '',
+        instance: ''
+      },
+      backhistroy: {
         certId: '',
-        classId: '01',
+        classId: '03',
+        workflowId: ''
+      },
+      flag: '01',
+      rules: {
+        WorkerTotal: [{
+          required: true,
+          validator: checkWorkerTotal,
+          trigger: 'change'
+        }],
+        TechnicalNum: [{
+          required: true,
+          validator: checkTechnicalNum,
+          trigger: 'change'
+        }],
+        SkillerTotal: [{
+          required: true,
+          validator: checkSkillerTotal,
+          trigger: 'change'
+        }]
+      },
+      appendformData: {
+        Id: '',
+        Step: 1,
+        Status: '',
+        SupplierName: '',
+        SupplierId: 0,
+        SupplierCertId: 0,
+        RecUnitFlag: '', // 推荐单位的级联Id标记
+        RecUnitId: '', // 推荐单位编码
+        RecUnitName: '', // 推荐单位名称
+        AppendType: '', // 增项类别(01 物资类,02 基建类,03 技术服务类)
+        Remark: '' // 备注
+      },
+      annentityForm: {
+        Id: '',
+        SupplierName: '',
+        SupplierId: '',
+        SupplierTypeName: '01',
         FirstAudit: '',
-        auditform: {
-          FirstAuditName: '',
-          SecondAudit: '',
-          ThirdAudit: '',
-          CertId: '',
-          AuditRemark: '',
-          TypeCode: '01'
-        },
-        orgtreeprops: {
-          value: 'id',
-          label: 'name',
-          children: 'children'
-        },
-        formData: {
-          Id: '',
-          AllAddress: '',
-          LinkAllAddress: '',
-          SupplierName: '',
-          CredentialFlag: '1',
-          OilCertificateNo: '',
-          Grade: '',
-          MgrUnit: '',
-          OperType: '',
-          Country: '中国',
-          MaunAgent: '',
-          ConstructTeam: '',
-          CommercialNo: '',
-          OrganCode: '',
-          CountryTaxNo: '',
-          LocalTaxNo: '',
-          Address: '',
-          Province: '',
-          City: '',
-          Street: '',
-          HouseNo: '',
-          ZipCode: '',
-          LinkAddress: '',
-          LinkProvince: '',
-          LinkCity: '',
-          LinkStreet: '',
-          LinkHouseNo: '',
-          LinkZipCode: '',
-          QualitySystemCert: '',
-          ProductQualityCert: '',
-          MaunLicense: '',
-          QualifCert: '',
-          QualifCertLevel: '',
-          SafetyLicense: '',
-          TechServiceLic: '',
-          TJInNotify: '',
-          SpecIndustryCert: '',
-          BusinessScope: '',
-          LegalPerson: '',
-          CategoryCode: '',
-          CategoryName: '',
-          RegCapital: '',
-          Currency: 'CNY',
-          ContactName: '',
-          CompanyType: '',
-          SetupTime: new Date(),
-          DepositBank: '',
-          BankAccount: '',
-          EMail: '',
-          BankCreditRating: '',
-          Mobile: '',
-          Telphone: '',
-          Fax: '',
-          CompanyTel: '',
-          QQ: '',
-          CompanyUrl: '',
-          SpecSupplier: '',
-          SpecTypeCode: '1',
-          SpecTypeName: '',
-          InStyle: '1',
-          WorkerTotal: 0,
-          ContractNum: 0,
-          UniversityNum: 0,
-          TechnicalNum: 0,
-          AboveProfNum: 0,
-          MiddleProfNum: 0,
-          NationalRegNum: 0,
-          NationalCertTotal: 0,
-          DesignerTotal: 0,
-          SkillerTotal: 0,
-          Remark: '',
-          // IsDelete: 0,
-          // CreateOn: "",
-          // CreateUserId: "",
-          // CreateBy: "",
-          // ModifiedOn: "",
-          // ModifiedUserId: "",
-          // ModifiedBy: "",
-          CertId: 0,
-          SupplierTypeCode: '01',
-          SupplierTypeName: '物资类',
-          Step: 0,
-          HseTraining: '0',
-          AuditIndex: 0,
-          PACNumber: '',
-          SupplierCertificate: '',
-          ProcessKey: ''
-        },
-
-        formDataCert: {
-          InStyle: '1',
-          WorkerTotal: 0,
-          ContractNum: 0,
-          UniversityNum: 0,
-          TechnicalNum: 0,
-          AboveProfNum: 0,
-          MiddleProfNum: 0,
-          NationalRegNum: 0,
-          NationalCertTotal: 0,
-          DesignerTotal: 0,
-          SkillerTotal: 0,
-          Status: 0
-        },
-        add_flat: true,
-        delete_flat: true,
-        entrydetail: {
-          process: '',
-          business: '',
-          instance: ''
-        },
-        backhistroy: {
-          certId: '',
-          classId: '03',
-          workflowId: ''
-        },
-        flag: '01',
-        rules: {
-          WorkerTotal: [{
-            required: true,
-            validator: checkWorkerTotal,
-            trigger: 'change'
-          }],
-          TechnicalNum: [{
-            required: true,
-            validator: checkTechnicalNum,
-            trigger: 'change'
-          }],
-          SkillerTotal: [{
-            required: true,
-            validator: checkSkillerTotal,
-            trigger: 'change'
-          }]
-        },
-        appendformData: {
-          Id: '',
-          Step: 1,
-          Status: '',
-          SupplierName: '',
-          SupplierId: 0,
-          SupplierCertId: 0,
-          RecUnitFlag: '', // 推荐单位的级联Id标记
-          RecUnitId: '', // 推荐单位编码
-          RecUnitName: '', // 推荐单位名称
-          AppendType: '', // 增项类别(01 物资类,02 基建类,03 技术服务类)
-          Remark: '' // 备注
-        },
-        annentityForm: {
-          Id: '',
-          SupplierName: '',
-          SupplierId: '',
-          SupplierTypeName: '01',
-          FirstAudit: '',
-          auditer: '',
-          Step: 0,
-          Remark: ''
-        }
+        auditer: '',
+        Step: 0,
+        Remark: ''
       }
+    }
   },
-    mounted () {
-      this.serviceId = this.$route.params.opera + ''
-      if (this.$route.query.rtn) {
-        this.showReturn = 0
-      }
-      if (this.$route.query.certid) {
-        this.certId = this.$route.query.certid + ''
-      }
-      if (this.serviceId !== 'add' && this.serviceId > 0) {
-        this.formData.Id = this.serviceId
-      } else {
-        this.formData.Id = 0
-      }
-      this.getDictOptions()
-      // this.getorgtreelist();
-      this.IsCompanyUser = this.authUser.Profile.IsCompanyUser
+  mounted () {
+    this.serviceId = this.$route.params.opera + ''
+    if (this.$route.query.rtn) {
+      this.showReturn = 0
+    }
+    if (this.$route.query.certid) {
+      this.certId = this.$route.query.certid + ''
+    }
+    if (this.serviceId !== 'add' && this.serviceId > 0) {
+      this.formData.Id = this.serviceId
+    } else {
+      this.formData.Id = 0
+    }
+    this.getDictOptions()
+    // this.getorgtreelist();
+    this.IsCompanyUser = this.authUser.Profile.IsCompanyUser
 
-      if (this.IsCompanyUser && this.serviceId === 'add') {
-        // apiCert
-        //   .getEntityByCreatorAndType("01", this.$axios)
-        //   .then(res => {
-        //     this.certId = res.data.Id;
-        //     this.serviceId = res.data.SupplierId;
-        //     this.formData.Id = res.data.SupplierId;
-        //     this.initDatas();
-        //   })
-        //   .catch(err => {
-        //     console.error(err);
-        //   });
-        this.inputCompany(this.authUser.Profile.Realname)
-      } else {
-        this.initDatas()
-      }
-      this.isAccess()
-      // this.orgtreeChange(this.majorDept)
-      this.changeOrgUnit(this.selectDept)
+    if (this.IsCompanyUser && this.serviceId === 'add') {
+      // apiCert
+      //   .getEntityByCreatorAndType("01", this.$axios)
+      //   .then(res => {
+      //     this.certId = res.data.Id;
+      //     this.serviceId = res.data.SupplierId;
+      //     this.formData.Id = res.data.SupplierId;
+      //     this.initDatas();
+      //   })
+      //   .catch(err => {
+      //     console.error(err);
+      //   });
+      this.inputCompany(this.authUser.Profile.Realname)
+    } else {
+      this.initDatas()
+    }
+    this.isAccess()
+    // this.orgtreeChange(this.majorDept)
+    this.changeOrgUnit(this.selectDept)
+  },
+  methods: {
+    nextStep () {
+      this.$refs['subfileList'].nextStep()
     },
-    methods: {
-      nextStep () {
-        this.$refs['subfileList'].nextStep()
-      },
-      annaudit () {
-        this.annentityForm.supplierId = parseInt(this.serviceId)
-        this.annentityForm.SupplierName = this.formData.SupplierName
-        console.log('----this.ann', this.annentityForm)
-        annapi.addEntity(this.annentityForm, this.annentityForm.auditer, this.$axios).then(res => {
+    annaudit () {
+      this.annentityForm.supplierId = parseInt(this.serviceId)
+      this.annentityForm.SupplierName = this.formData.SupplierName
+      console.log('----this.ann', this.annentityForm)
+      annapi.addEntity(this.annentityForm, this.annentityForm.auditer, this.$axios).then(res => {
+        if (res.data.code === 0) {
+          // 保存成功后,初始化数据,变成修改
+          let annId = res.data.item
+          this.$router.push({
+            path: '/oilsupplier/annualaudit/' + this.serviceId + '/goodsoperation',
+            query: {
+              certid: this.certId,
+              // WorkflowId: ,
+              Status: 0,
+              Step: 1,
+              annualId: annId
+            }
+          })
+          this.$message({
+            type: 'success',
+            message: res.data.message
+          })
+        } else {
+          this.$message({
+            type: 'warning',
+            message: res.data.message
+          })
+        }
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    qppend () {
+      let _this = this
+      _this.appendformData.SupplierName = this.formData.SupplierName
+      _this.appendformData.SupplierId = parseInt(this.serviceId)
+      _this.appendformData.SupplierCertId = parseInt(this.certId)
+      _this.appendformData.AppendType = '01'
+      _this.$axios.post('/suppliercertappend/addappend/', _this.appendformData)
+        .then(res => {
           if (res.data.code === 0) {
-            // 保存成功后,初始化数据,变成修改
-            let annId = res.data.item
+            // this.entityList = res.data.item
+            let AppendId = res.data.info
             this.$router.push({
-              path: '/oilsupplier/annualaudit/' + this.serviceId + '/goodsoperation',
+              path: `/oilsupplier/supplierappend/1/goodsdataopera`,
               query: {
-                certid: this.certId,
-                // WorkflowId: ,
-                Status: 0,
-                Step: 1,
-                annualId: annId
+                Id: AppendId,
+                editFlag: 1 // 编辑标记: 1 修改,0 不修改
               }
             })
-            this.$message({
+            _this.$message({
               type: 'success',
               message: res.data.message
             })
           } else {
-            this.$message({
+            _this.$message({
               type: 'warning',
               message: res.data.message
             })
           }
-        }).catch(err => {
+        })
+        .catch(err => {
           console.error(err)
         })
-      },
-      qppend () {
-        let _this = this
-        _this.appendformData.SupplierName = this.formData.SupplierName
-        _this.appendformData.SupplierId = parseInt(this.serviceId)
-        _this.appendformData.SupplierCertId = parseInt(this.certId)
-        _this.appendformData.AppendType = '01'
-        _this.$axios.post('/suppliercertappend/addappend/', _this.appendformData)
+    },
+    orgunitChange (val) {
+      let deptid = val
+      let auditstepcode = 'SUB_OFFICE_JS'
+      api.getAuditerByDept(deptid, auditstepcode, this.$axios).then(res => {
+        this.orgauditOptions = res.data.item
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    changeOrgUnit (val) {
+      let auditstepcode = 'PROF_RECE'
+      api.getAuditerByDept(val, auditstepcode, this.$axios).then(res => {
+        console.log(res.data.item, 'res.data.item==')
+        this.userOptions = res.data.item
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    orgtreeChange (val) {
+      this.userOptions = []
+      let deptid = val[val.length - 1]
+      let auditstepcode = 'PROF_RECE'
+      api.getAuditerByDept(deptid, auditstepcode, this.$axios).then(res => {
+        this.userOptions = res.data.item
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    isAccess () {
+      apiCert.isAccess('PROF_REGULATION', this.$axios).then(res => {
+        this.createBtn = res.data
+      }).catch(err => {
+        console.log(err)
+      })
+    },
+    inputCompany (val) {
+      if (!this.certId) {
+        api
+          .getEntityByName(val, '01', this.$axios)
           .then(res => {
             if (res.data.code === 0) {
-              // this.entityList = res.data.item
-              let AppendId = res.data.info
-              this.$router.push({
-                path: `/oilsupplier/supplierappend/1/goodsdataopera`,
-                query: {
-                  Id: AppendId,
-                  editFlag: 1 // 编辑标记: 1 修改,0 不修改
-                }
-              })
-              _this.$message({
-                type: 'success',
-                message: res.data.message
-              })
-            } else {
-              _this.$message({
+              this.SetFormData(res.data.item)
+            } else if (res.data.code === -1) {
+              this.$message({
                 type: 'warning',
-                message: res.data.message
+                message: '该企业已暂停'
               })
+            } else {
+
             }
           })
           .catch(err => {
             console.error(err)
           })
-      },
-      orgunitChange (val) {
-        let deptid = val
-        let auditstepcode = 'SUB_OFFICE_JS'
-        api.getAuditerByDept(deptid, auditstepcode, this.$axios).then(res => {
-          this.orgauditOptions = res.data.item
+      }
+    },
+
+    changeFormData (fdata) {
+      if (!this.certId) {
+        this.SetFormData(fdata)
+      }
+    },
+    SetFormData (fdata) {
+      console.log(fdata)
+      this.isCanUpdateSupplier(fdata.Id)
+      this.formData.Id = fdata.Id
+      this.formData.SupplierName = fdata.SupplierName
+      this.formData.OilCertificateNo = fdata.OilCertificateNo
+      this.formData.Grade = fdata.Grade
+      this.formData.MgrUnit = fdata.MgrUnit
+      if (fdata.InStyle != null && fdata.InStyle != '') {
+        this.formData.InStyle = fdata.InStyle
+      }
+      this.formData.OperType = fdata.OperType
+      if (fdata.Country != '') {
+        this.formData.Country = fdata.Country
+      }
+      this.formData.MaunAgent = fdata.MaunAgent
+      this.formData.ConstructTeam = fdata.ConstructTeam
+      if (fdata.CredentialFlag != null && fdata.CredentialFlag != '') {
+        this.formData.CredentialFlag = fdata.CredentialFlag
+      }
+      this.formData.CommercialNo = fdata.CommercialNo
+      if (fdata.CredentialFlag != null && fdata.CredentialFlag != '') {
+        this.$refs['GoodsInfo'].showorhid(this.formData.CredentialFlag)
+      }
+      this.formData.OrganCode = fdata.OrganCode
+      this.formData.CountryTaxNo = fdata.CountryTaxNo
+      this.formData.LocalTaxNo = fdata.LocalTaxNo
+      this.formData.Address = fdata.Address
+      this.formData.Province = fdata.Province
+      this.formData.City = fdata.City
+      this.formData.Street = fdata.Street
+      this.formData.HouseNo = fdata.HouseNo
+      this.formData.ZipCode = fdata.ZipCode
+      this.formData.LinkAddress = fdata.LinkAddress
+      this.formData.LinkProvince = fdata.LinkProvince
+      this.formData.LinkCity = fdata.LinkCity
+      this.formData.LinkStreet = fdata.LinkStreet
+      this.formData.LinkHouseNo = fdata.LinkHouseNo
+      this.formData.LinkZipCode = fdata.LinkZipCode
+      this.formData.LegalPerson = fdata.LegalPerson
+      this.formData.CategoryCode = fdata.CategoryCode
+      this.formData.CategoryName = fdata.CategoryName
+      this.formData.RegCapital = fdata.RegCapital
+      if (fdata.Currency != null && fdata.Currency != '') {
+        this.formData.Currency = fdata.Currency
+      }
+      this.formData.ContactName = fdata.ContactName
+      if (fdata.CompanyType != null && fdata.CompanyType != '') {
+        this.formData.CompanyType = fdata.CompanyType
+      }
+      this.formData.SetupTime = fdata.SetupTime
+      this.formData.DepositBank = fdata.DepositBank
+      this.formData.BankAccount = fdata.BankAccount
+      this.formData.EMail = fdata.EMail
+      this.formData.BankCreditRating = fdata.BankCreditRating
+      if (fdata.Mobile != null && fdata.Mobile != '') {
+        this.formData.Mobile = fdata.Mobile
+      } else {
+        this.formData.Mobile = fdata.UserTelephone
+      }
+      this.formData.Telphone = fdata.Telphone
+      this.formData.Fax = fdata.Fax
+      this.formData.CompanyTel = fdata.CompanyTel
+      this.formData.QQ = fdata.QQ
+      this.formData.CompanyUrl = fdata.CompanyUrl
+      if (fdata.HseTraining != null && fdata.HseTraining != '') {
+        this.formData.HseTraining = fdata.HseTraining
+      }
+      if (fdata.SpecTypeCode != null && fdata.SpecTypeCode != '') {
+        this.formData.SpecTypeCode = fdata.SpecTypeCode
+      }
+      this.formData.QualitySystemCert = fdata.QualitySystemCert
+      this.formData.SafetyLicense = fdata.SafetyLicense
+      this.formData.SpecIndustryCert = fdata.SpecIndustryCert
+      this.formData.BusinessScope = fdata.BusinessScope
+      this.formData.Remark = fdata.Remark
+      this.formData.TjinNotify = fdata.TjinNotify
+      this.formData.Status = fdata.Status
+      this.formData.ProductQualityCert = fdata.ProductQualityCert
+      this.formData.MaunLicense = fdata.MaunLicense
+      this.formData.PACNumber = fdata.PACNumber
+
+      this.$refs['GoodsInfo'].CityAry = []
+      this.$refs['GoodsInfo'].CityAry.push(this.formData.Province)
+      this.$refs['GoodsInfo'].CityAry.push(this.formData.City)
+      this.$refs['GoodsInfo'].CityAry.push(this.formData.Street)
+      this.$refs['GoodsInfo'].LinkCityAry = []
+      this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkProvince)
+      this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkCity)
+      this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkStreet)
+      /* this.$refs['GoodsInfo'].UnitRelationAry = []
+        if (this.formData.SpecTypeCode.length > 0) {
+          this.$refs['GoodsInfo'].UnitRelationAry = this.formData.SpecTypeCode.split(',')
+        } */
+    },
+    // 导出到Word文件
+    toWord () {
+      let id = this.formData.Id
+      let params = {
+        CertId: this.certId
+      }
+      dataapi.docexport(id, params, this.$axios)
+        .then(res => {
+          // response
+          if (res.data.code === 0) {
+            // this.$message({
+            //   type: 'success'
+            //   message: res.data.message
+            // })
+            let docurl = res.data.item
+            // 内网服务器专用
+            if (process.client && docurl.indexOf('upfile') === 0) {
+              const myDomain = window.location.host
+              location.href = 'http://' + myDomain + '/' + docurl
+            } else {
+              location.href = 'http://' + docurl
+            }
+          }
         }).catch(err => {
           console.error(err)
         })
-      },
-      changeOrgUnit (val) {
-        let auditstepcode = 'PROF_RECE'
-        api.getAuditerByDept(val, auditstepcode, this.$axios).then(res => {
-          console.log(res.data.item, 'res.data.item==')
-          this.userOptions = res.data.item
+    },
+    // 导出准入范围到pdf
+    toPdf () {
+      let id = this.formData.Id
+      dataapi.pdfexport(id, this.$axios)
+        .then(res => {
+          // response
+          if (res.data.code === 0) {
+            // this.$message({
+            //   type: 'success'
+            //   message: res.data.message
+            // })
+            let docurl = res.data.item
+            let pdfurl
+            // 内网服务器专用
+            if (process.client && docurl.indexOf('upfile') === 0) {
+              const myDomain = window.location.host
+              // location.href = 'http://' + myDomain + '/' + docurl
+              pdfurl = 'http://' + process.env.LOCAL_IP + '/' + docurl
+              let requestParams = {
+                pdfUrl: pdfurl,
+                watermark: this.formData.SupplierName
+              }
+              this.$axios.post('supplierdataentry/word-to-pdf-watermark', requestParams)
+                .then(function (res) {
+                  window.open('http://' + myDomain + '/' + res.data)
+                })
+            } else {
+              // location.href = 'http://' + docurl
+              pdfurl = 'http://' + docurl
+              let requestParams = {
+                pdfUrl: pdfurl,
+                watermark: this.formData.SupplierName
+              }
+              this.$axios.post('supplierdataentry/word-to-pdf-watermark', requestParams)
+                .then(function (res) {
+                  window.open('http://' + res.data)
+                })
+            }
+          }
         }).catch(err => {
           console.error(err)
         })
-      },
-      orgtreeChange (val) {
-        this.userOptions = []
-        let deptid = val[val.length - 1]
-        let auditstepcode = 'PROF_RECE'
-        api.getAuditerByDept(deptid, auditstepcode, this.$axios).then(res => {
-          this.userOptions = res.data.item
-        }).catch(err => {
-          console.error(err)
+    },
+    isCanUpdateSupplier (supplierId) {
+      api
+        .isCanUpdateSupplier(supplierId, this.$axios)
+        .then(res => {
+          this.canUpdateSupplier = res.data.code === 0
         })
-      },
-      isAccess () {
-        apiCert.isAccess('PROF_REGULATION', this.$axios).then(res => {
-          this.createBtn = res.data
-        }).catch(err => {
-          console.log(err)
+        .catch(err => {
+          console.error(err)
         })
-      },
-      inputCompany (val) {
-        if (!this.certId) {
-          api
-            .getEntityByName(val, '01', this.$axios)
-            .then(res => {
-              if (res.data) {
-                this.SetFormData(res.data)
-              }
-            })
-            .catch(err => {
-              console.error(err)
-            })
-        }
-      },
-
-      changeFormData (fdata) {
-        if (!this.certId) {
-          this.SetFormData(fdata)
-        }
-      },
-      SetFormData (fdata) {
-        console.log(fdata)
-        this.isCanUpdateSupplier(fdata.Id)
-        this.formData.Id = fdata.Id
-        this.formData.SupplierName = fdata.SupplierName
-        this.formData.OilCertificateNo = fdata.OilCertificateNo
-        this.formData.Grade = fdata.Grade
-        this.formData.MgrUnit = fdata.MgrUnit
-        if (fdata.InStyle != null && fdata.InStyle != '') {
-          this.formData.InStyle = fdata.InStyle
-        }
-        this.formData.OperType = fdata.OperType
-        if (fdata.Country != '') {
-          this.formData.Country = fdata.Country
-        }
-        this.formData.MaunAgent = fdata.MaunAgent
-        this.formData.ConstructTeam = fdata.ConstructTeam
-        if (fdata.CredentialFlag != null && fdata.CredentialFlag != '') {
-          this.formData.CredentialFlag = fdata.CredentialFlag
-        }
-        this.formData.CommercialNo = fdata.CommercialNo
-        if (fdata.CredentialFlag != null && fdata.CredentialFlag != '') {
-          this.$refs['GoodsInfo'].showorhid(this.formData.CredentialFlag)
-        }
-        this.formData.OrganCode = fdata.OrganCode
-        this.formData.CountryTaxNo = fdata.CountryTaxNo
-        this.formData.LocalTaxNo = fdata.LocalTaxNo
-        this.formData.Address = fdata.Address
-        this.formData.Province = fdata.Province
-        this.formData.City = fdata.City
-        this.formData.Street = fdata.Street
-        this.formData.HouseNo = fdata.HouseNo
-        this.formData.ZipCode = fdata.ZipCode
-        this.formData.LinkAddress = fdata.LinkAddress
-        this.formData.LinkProvince = fdata.LinkProvince
-        this.formData.LinkCity = fdata.LinkCity
-        this.formData.LinkStreet = fdata.LinkStreet
-        this.formData.LinkHouseNo = fdata.LinkHouseNo
-        this.formData.LinkZipCode = fdata.LinkZipCode
-        this.formData.LegalPerson = fdata.LegalPerson
-        this.formData.CategoryCode = fdata.CategoryCode
-        this.formData.CategoryName = fdata.CategoryName
-        this.formData.RegCapital = fdata.RegCapital
-        if (fdata.Currency != null && fdata.Currency != '') {
-          this.formData.Currency = fdata.Currency
-        }
-        this.formData.ContactName = fdata.ContactName
-        if (fdata.CompanyType != null && fdata.CompanyType != '') {
-          this.formData.CompanyType = fdata.CompanyType
-        }
-        this.formData.SetupTime = fdata.SetupTime
-        this.formData.DepositBank = fdata.DepositBank
-        this.formData.BankAccount = fdata.BankAccount
-        this.formData.EMail = fdata.EMail
-        this.formData.BankCreditRating = fdata.BankCreditRating
-        if (fdata.Mobile != null && fdata.Mobile != '') {
-          this.formData.Mobile = fdata.Mobile
-        } else {
-          this.formData.Mobile = fdata.UserTelephone
-        }
-        this.formData.Telphone = fdata.Telphone
-        this.formData.Fax = fdata.Fax
-        this.formData.CompanyTel = fdata.CompanyTel
-        this.formData.QQ = fdata.QQ
-        this.formData.CompanyUrl = fdata.CompanyUrl
-        if (fdata.HseTraining != null && fdata.HseTraining != '') {
-          this.formData.HseTraining = fdata.HseTraining
-        }
-        if (fdata.SpecTypeCode != null && fdata.SpecTypeCode != '') {
-          this.formData.SpecTypeCode = fdata.SpecTypeCode
-        }
-        this.formData.QualitySystemCert = fdata.QualitySystemCert
-        this.formData.SafetyLicense = fdata.SafetyLicense
-        this.formData.SpecIndustryCert = fdata.SpecIndustryCert
-        this.formData.BusinessScope = fdata.BusinessScope
-        this.formData.Remark = fdata.Remark
-        this.formData.TjinNotify = fdata.TjinNotify
-        this.formData.Status = fdata.Status
-        this.formData.ProductQualityCert = fdata.ProductQualityCert
-        this.formData.MaunLicense = fdata.MaunLicense
-        this.formData.PACNumber = fdata.PACNumber
+    },
+    equipmentdialog () {
+      this.$refs['equipmentList'].showDialog()
+    },
+    performancedialog () {
+      this.$refs['performanceList'].showDialog()
+    },
+    patentdialog () {
+      this.$refs['patentList'].showDialog()
+    },
+    winningdialog () {
+      this.$refs['winningList'].showDialog()
+    },
 
-        this.$refs['GoodsInfo'].CityAry = []
-        this.$refs['GoodsInfo'].CityAry.push(this.formData.Province)
-        this.$refs['GoodsInfo'].CityAry.push(this.formData.City)
-        this.$refs['GoodsInfo'].CityAry.push(this.formData.Street)
-        this.$refs['GoodsInfo'].LinkCityAry = []
-        this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkProvince)
-        this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkCity)
-        this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkStreet)
-      /* this.$refs['GoodsInfo'].UnitRelationAry = []
-        if (this.formData.SpecTypeCode.length > 0) {
-          this.$refs['GoodsInfo'].UnitRelationAry = this.formData.SpecTypeCode.split(',')
-        } */
-      },
-      // 导出到Word文件
-      toWord () {
-        let id = this.formData.Id
-        let params = {
-          CertId: this.certId
-        }
-        dataapi.docexport(id, params, this.$axios)
+    initDatas () {
+      if (this.formData.Id) {
+        this.isCanUpdateSupplier(this.formData.Id)
+        api
+          .getEntityAndCert(this.certId, this.$axios)
           .then(res => {
-            // response
-            if (res.data.code === 0) {
-              // this.$message({
-              //   type: 'success'
-              //   message: res.data.message
-              // })
-              let docurl = res.data.item
-              // 内网服务器专用
-              if (process.client && docurl.indexOf('upfile') === 0) {
-                const myDomain = window.location.host
-                location.href = 'http://' + myDomain + '/' + docurl
-              } else {
-                location.href = 'http://' + docurl
-              }
+            this.formData = res.data
+            this.formDataCert.WorkerTotal = this.formData.WorkerTotal
+            this.formDataCert.ContractNum = this.formData.ContractNum
+            this.formDataCert.UniversityNum = this.formData.UniversityNum
+            this.formDataCert.TechnicalNum = this.formData.TechnicalNum
+            this.formDataCert.AboveProfNum = this.formData.AboveProfNum
+            this.formDataCert.MiddleProfNum = this.formData.MiddleProfNum
+            this.formDataCert.NationalRegNum = this.formData.NationalRegNum
+            this.formDataCert.NationalCertTotal = this.formData.NationalCertTotal
+            this.formDataCert.DesignerTotal = this.formData.DesignerTotal
+            this.formDataCert.SkillerTotal = this.formData.SkillerTotal
+            this.formDataCert.Status = this.formData.Status
+            this.formDataCert.WorkflowId = this.formData.WorkflowId
+            this.formDataCert.InStyle = this.formData.InStyle
+            if (this.formData.Status > 0 || this.formData.Status == -5) {
+              this.add_flat = false
             }
-          }).catch(err => {
-            console.error(err)
-          })
-      },
-      // 导出准入范围到pdf
-      toPdf () {
-        let id = this.formData.Id
-        dataapi.pdfexport(id, this.$axios)
-          .then(res => {
-            // response
-            if (res.data.code === 0) {
-              // this.$message({
-              //   type: 'success'
-              //   message: res.data.message
-              // })
-              let docurl = res.data.item
-              let pdfurl
-              // 内网服务器专用
-              if (process.client && docurl.indexOf('upfile') === 0) {
-                const myDomain = window.location.host
-                // location.href = 'http://' + myDomain + '/' + docurl
-                pdfurl = 'http://' + process.env.LOCAL_IP + '/' + docurl
-                let requestParams = {
-                  pdfUrl: pdfurl,
-                  watermark: this.formData.SupplierName
-                }
-                this.$axios.post('supplierdataentry/word-to-pdf-watermark', requestParams)
-                  .then(function (res) {
-                    window.open('http://' + myDomain + '/' + res.data)
-                  })
-              } else {
-                // location.href = 'http://' + docurl
-                pdfurl = 'http://' + docurl
-                let requestParams = {
-                  pdfUrl: pdfurl,
-                  watermark: this.formData.SupplierName
-                }
-                this.$axios.post('supplierdataentry/word-to-pdf-watermark', requestParams)
-                  .then(function (res) {
-                    window.open('http://' + res.data)
-                  })
-              }
+            if ((this.formData.Status > 0) && (this.formData.Status != 4)) {
+              this.delete_flat = false
+            }
+            if ((this.formData.Status > 0) && (this.authUser.Profile.IsCompanyUser == 1)) {
+              this.delete_flat = false
+            }
+
+            if (this.formData.CredentialFlag != '') {
+              this.$refs['GoodsInfo'].showorhid(this.formData.CredentialFlag)
+            }
+            this.$refs['GoodsInfo'].CityAry = []
+            this.$refs['GoodsInfo'].CityAry.push(this.formData.Province)
+            this.$refs['GoodsInfo'].CityAry.push(this.formData.City)
+            this.$refs['GoodsInfo'].CityAry.push(this.formData.Street)
+            this.$refs['GoodsInfo'].LinkCityAry = []
+            this.$refs['GoodsInfo'].LinkCityAry.push(
+              this.formData.LinkProvince
+            )
+            this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkCity)
+            this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkStreet)
+            /* this.$refs['GoodsInfo'].UnitRelationAry = []
+          if (this.formData.SpecTypeCode.length > 0) {
+            this.$refs['GoodsInfo'].UnitRelationAry = this.formData.SpecTypeCode.split(',')
+          } */
+            this.entrydetail.business = this.certId
+            this.entrydetail.instance = this.formDataCert.WorkflowId
+            this.entrydetail.process = this.formData.ProcessKey
+            this.backhistroy.certId = this.certId
+            this.backhistroy.workflowId = this.formDataCert.WorkflowId
+            if (this.certId && this.formDataCert.WorkflowId) {
+              // this.$refs['WfHistory'].getHistoryTask() /* 刷新工作流 */
+            }
+            this.$refs['equipmentList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId
+            )
+            this.$refs['performanceList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId
+            )
+            this.$refs['patentList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId
+            )
+            this.$refs['winningList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId
+            )
+            this.$refs['goodsList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId
+            )
+            this.$refs['subfileList'].getvalue(
+              this.formData.Id,
+              this.formData.SupplierTypeCode,
+              this.certId,
+              this.formDataCert.InStyle
+            )
+            if (this.formData.InStyle == '2' || this.formData.InStyle == '6') {
+              this.allowpre = false
             }
-          }).catch(err => {
-            console.error(err)
-          })
-      },
-      isCanUpdateSupplier (supplierId) {
-        api
-          .isCanUpdateSupplier(supplierId, this.$axios)
-          .then(res => {
-            this.canUpdateSupplier = res.data.code === 0
           })
           .catch(err => {
             console.error(err)
           })
-      },
-      equipmentdialog () {
-        this.$refs['equipmentList'].showDialog()
-      },
-      performancedialog () {
-        this.$refs['performanceList'].showDialog()
-      },
-      patentdialog () {
-        this.$refs['patentList'].showDialog()
-      },
-      winningdialog () {
-        this.$refs['winningList'].showDialog()
-      },
-
-      initDatas () {
-        if (this.formData.Id) {
-          this.isCanUpdateSupplier(this.formData.Id)
-          api
-            .getEntityAndCert(this.certId, this.$axios)
-            .then(res => {
-              this.formData = res.data
-              this.formDataCert.WorkerTotal = this.formData.WorkerTotal
-              this.formDataCert.ContractNum = this.formData.ContractNum
-              this.formDataCert.UniversityNum = this.formData.UniversityNum
-              this.formDataCert.TechnicalNum = this.formData.TechnicalNum
-              this.formDataCert.AboveProfNum = this.formData.AboveProfNum
-              this.formDataCert.MiddleProfNum = this.formData.MiddleProfNum
-              this.formDataCert.NationalRegNum = this.formData.NationalRegNum
-              this.formDataCert.NationalCertTotal = this.formData.NationalCertTotal
-              this.formDataCert.DesignerTotal = this.formData.DesignerTotal
-              this.formDataCert.SkillerTotal = this.formData.SkillerTotal
-              this.formDataCert.Status = this.formData.Status
-              this.formDataCert.WorkflowId = this.formData.WorkflowId
-              this.formDataCert.InStyle = this.formData.InStyle
-              if (this.formData.Status > 0 || this.formData.Status == -5) {
-                this.add_flat = false
-              }
-              if ((this.formData.Status > 0) && (this.formData.Status != 4)) {
-                this.delete_flat = false
-              }
-              if ((this.formData.Status > 0) && (this.authUser.Profile.IsCompanyUser == 1)) {
-                this.delete_flat = false
-              }
+      }
+    },
+    getbuslist () {
+      this.$refs['subfileList'].getvalue(
+        this.formData.Id,
+        this.formData.SupplierTypeCode,
+        this.certId,
+        this.formDataCert.InStyle
+      )
+    },
+    nextTab () {
+      if (this.formData.AuditIndex > 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status > 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status < 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status >= 5) {
+        this.totalTab = 5
+      }
+      let valid = true
+      if (this.formDataCert.Status <= 0 && this.activeName === '0') {
+        valid = this.saveEntity()
+      } else if (this.formDataCert.Status <= 0 && this.activeName === '1') {
+        valid = this.updateNumberEntity()
+        valid = true// 没办法中的办法
+      }
+      if (!valid) {
+        return false
+      }
+      let activeIdx = parseInt(this.activeName)
+      if (activeIdx < this.totalTab) {
+        this.activeName = (activeIdx + 1) + ''
+      } else {
+        this.activeName = '0'
+      }
+      document.querySelector('.content').scrollTop = 0
+    },
 
-              if (this.formData.CredentialFlag != '') {
-                this.$refs['GoodsInfo'].showorhid(this.formData.CredentialFlag)
-              }
-              this.$refs['GoodsInfo'].CityAry = []
-              this.$refs['GoodsInfo'].CityAry.push(this.formData.Province)
-              this.$refs['GoodsInfo'].CityAry.push(this.formData.City)
-              this.$refs['GoodsInfo'].CityAry.push(this.formData.Street)
-              this.$refs['GoodsInfo'].LinkCityAry = []
-              this.$refs['GoodsInfo'].LinkCityAry.push(
-                this.formData.LinkProvince
-              )
-              this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkCity)
-              this.$refs['GoodsInfo'].LinkCityAry.push(this.formData.LinkStreet)
-              /* this.$refs['GoodsInfo'].UnitRelationAry = []
-            if (this.formData.SpecTypeCode.length > 0) {
-              this.$refs['GoodsInfo'].UnitRelationAry = this.formData.SpecTypeCode.split(',')
-            } */
-              this.entrydetail.business = this.certId
-              this.entrydetail.instance = this.formDataCert.WorkflowId
-              this.entrydetail.process = this.formData.ProcessKey
-              this.backhistroy.certId = this.certId
-              this.backhistroy.workflowId = this.formDataCert.WorkflowId
-              if (this.certId && this.formDataCert.WorkflowId) {
-                // this.$refs['WfHistory'].getHistoryTask() /* 刷新工作流 */
-              }
-              this.$refs['equipmentList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId
-              )
-              this.$refs['performanceList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId
-              )
-              this.$refs['patentList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId
-              )
-              this.$refs['winningList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId
-              )
-              this.$refs['goodsList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId
-              )
-              this.$refs['subfileList'].getvalue(
-                this.formData.Id,
-                this.formData.SupplierTypeCode,
-                this.certId,
-                this.formDataCert.InStyle
-              )
-              if (this.formData.InStyle == '2' || this.formData.InStyle == '6') {
-                this.allowpre = false
-              }
-            })
-            .catch(err => {
-              console.error(err)
-            })
-        }
-      },
-      getbuslist () {
-        this.$refs['subfileList'].getvalue(
-          this.formData.Id,
-          this.formData.SupplierTypeCode,
-          this.certId,
-          this.formDataCert.InStyle
-        )
-      },
-      nextTab () {
-        if (this.formData.AuditIndex > 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status > 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status < 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status >= 5) {
-          this.totalTab = 5
-        }
-        let valid = true
-        if (this.formDataCert.Status <= 0 && this.activeName === '0') {
-          valid = this.saveEntity()
-        } else if (this.formDataCert.Status <= 0 && this.activeName === '1') {
-          valid = this.updateNumberEntity()
-          valid = true// 没办法中的办法
-        }
-        if (!valid) {
-          return false
-        }
-        let activeIdx = parseInt(this.activeName)
-        if (activeIdx < this.totalTab) {
-          this.activeName = (activeIdx + 1) + ''
-        } else {
-          this.activeName = '0'
-        }
-        document.querySelector('.content').scrollTop = 0
-      },
+    backTab () {
+      if (this.formData.AuditIndex > 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status > 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status < 0) {
+        this.totalTab = 4
+      }
+      if (this.formDataCert.Status >= 5) {
+        this.totalTab = 5
+      }
 
-      backTab () {
-        if (this.formData.AuditIndex > 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status > 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status < 0) {
-          this.totalTab = 4
-        }
-        if (this.formDataCert.Status >= 5) {
-          this.totalTab = 5
-        }
+      let activeIdx = parseInt(this.activeName)
+      if (activeIdx > 0) {
+        this.activeName = (activeIdx - 1) + ''
+      } else {
+        this.activeName = this.totalTab + ''
+      }
+      document.querySelector('.content').scrollTop = 0
+    },
 
-        let activeIdx = parseInt(this.activeName)
-        if (activeIdx > 0) {
-          this.activeName = (activeIdx - 1) + ''
-        } else {
-          this.activeName = this.totalTab + ''
-        }
-        document.querySelector('.content').scrollTop = 0
-      },
+    getDictOptions () {
+      let params = {
+        status: this.formData.Status,
+        majorAduit: this.formData.ThirdAudit
+      }
+      api.getDictListByStatus(params, this.$axios).then(res => {
+        this.dictData = res.data.items
+        this.orgtreelist = window.toolfun_gettreejson(res.data.items['ProOrgList'], 'id', 'pId', 'id,name')
+        this.UnitOrgOptions = res.data.items['UnitOrgList']
+        this.UnitOrg = res.data.items['Register'].CheckUnitId
+        this.allorgunitOptions = res.data.items['Allunitorglist']
+        this.orgunitChange(this.UnitOrg)
+        // this.auditerOptions = res.data.items['Auditer']
+        // this.organizeOption = res.data.items['Organizes']
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    // getorgtreelist() {
+    //   let _this = this;
+    //   let params = {
+    //     IsInnerOrganize: 1
+    //   };
+    //   _this.$axios
+    //     .get("organizes/orgalllist", {
+    //       params
+    //     })
+    //     .then(res => {
+    //       _this.orgtreelist = window.toolfun_gettreejson(
+    //         res.data.items,
+    //         "Id",
+    //         "Parentid",
+    //         "Id,Fullname"
+    //       );
+    //       if (_this.authUser.Profile.IsCompanyUser === 0) {
+    //         this.secOrganize = _this.authUser.Profile.Superior.split(",").map(
+    //           val => {
+    //             return parseInt(val);
+    //           }
+    //         );
+    //         this.auditOrgChang(this.secOrganize);
+    //       }
+    //     })
+    //     .catch(err => {
+    //       console.error(err);
+    //     });
+    // },
 
-      getDictOptions () {
-        let params = {
-          status: this.formData.Status,
-          majorAduit: this.formData.ThirdAudit
-        }
-        api.getDictListByStatus(params, this.$axios).then(res => {
-          this.dictData = res.data.items
-          this.orgtreelist = window.toolfun_gettreejson(res.data.items['ProOrgList'], 'id', 'pId', 'id,name')
-          this.UnitOrgOptions = res.data.items['UnitOrgList']
-          this.UnitOrg = res.data.items['Register'].CheckUnitId
-          this.allorgunitOptions = res.data.items['Allunitorglist']
-          this.orgunitChange(this.UnitOrg)
-          // this.auditerOptions = res.data.items['Auditer']
-          // this.organizeOption = res.data.items['Organizes']
-        }).catch(err => {
+    auditOrgChang (val) {
+      console.log('------val', val)
+      let auditstepcode = 'SECOND_TRIAL'
+      api.getAuditerByFirst(val, auditstepcode, this.$axios)
+        .then(res => {
+          this.secauditerOptions = res.data.item
+        })
+        .catch(err => {
           console.error(err)
         })
-      },
-      // getorgtreelist() {
-      //   let _this = this;
-      //   let params = {
-      //     IsInnerOrganize: 1
-      //   };
-      //   _this.$axios
-      //     .get("organizes/orgalllist", {
-      //       params
-      //     })
-      //     .then(res => {
-      //       _this.orgtreelist = window.toolfun_gettreejson(
-      //         res.data.items,
-      //         "Id",
-      //         "Parentid",
-      //         "Id,Fullname"
-      //       );
-      //       if (_this.authUser.Profile.IsCompanyUser === 0) {
-      //         this.secOrganize = _this.authUser.Profile.Superior.split(",").map(
-      //           val => {
-      //             return parseInt(val);
-      //           }
-      //         );
-      //         this.auditOrgChang(this.secOrganize);
-      //       }
-      //     })
-      //     .catch(err => {
-      //       console.error(err);
-      //     });
-      // },
+    },
+    /* getCityList(val) {
+       let resultData = JSON.parse(val)
+       let countstr = JSON.stringify(resultData.districts[0].districts)
+       countstr = countstr.replace(/\,\"districts\"\:\[\]/g, '')
+       this.countryoptions = JSON.parse(countstr)
+       }, */
 
-      auditOrgChang (val) {
-        console.log('------val', val)
-        let auditstepcode = 'SECOND_TRIAL'
-        api.getAuditerByFirst(val, auditstepcode, this.$axios)
-          .then(res => {
-            this.secauditerOptions = res.data.item
+    // 保存信息
+    saveEntity () {
+      let valid1 = false
+      let valid2 = false
+      this.$refs['GoodsInfo'].$refs['EntityForm'].validate((valid) => {
+        valid1 = valid
+      })
+
+      this.$refs['GoodsInfo'].$refs['EntityFormCert'].validate((valid) => {
+        valid2 = valid
+      })
+      if (this.formData.OperType === '制造商') {
+        if (!this.formData.MaunLicense && !this.formData.SafetyLicense) {
+          valid1 = false
+          this.$message({
+            type: 'warning',
+            message: '【生产制造许可证获证情况及编号】或【安全生产许可证】 为必填项'
           })
-          .catch(err => {
-            console.error(err)
+          return
+        }
+      } else if (this.formData.OperType === '代理商') {
+        if (!this.formData.MaunAgent) {
+          valid1 = false
+          this.$message({
+            type: 'warning',
+            message: '【所代理制造商名称】不能为空'
           })
-      },
-      /* getCityList(val) {
-         let resultData = JSON.parse(val)
-         let countstr = JSON.stringify(resultData.districts[0].districts)
-         countstr = countstr.replace(/\,\"districts\"\:\[\]/g, '')
-         this.countryoptions = JSON.parse(countstr)
-         }, */
+          return
+        }
+      }
 
-      // 保存信息
-      saveEntity () {
-        let valid1 = false
-        let valid2 = false
-        this.$refs['GoodsInfo'].$refs['EntityForm'].validate((valid) => {
-          valid1 = valid
+      /** 2019.05.16 - 16 准入申请中,若选择了“管理单位”,“中石油准入证编号”应自动改为必填项 */
+      if (this.formData.MgrUnit.length > 0 && this.formData.PACNumber.length <= 0) {
+        valid1 = false
+        this.$message({
+          type: 'warning',
+          message: '【中石油准入证编号】不能为空'
         })
+        return
+      }
 
-        this.$refs['GoodsInfo'].$refs['EntityFormCert'].validate((valid) => {
-          valid2 = valid
-        })
-        if (this.formData.OperType === '制造商') {
-          if (!this.formData.MaunLicense && !this.formData.SafetyLicense) {
-            valid1 = false
+      if (valid1 && valid2) {
+        if (!this.formData.SetupTime) {
+          this.formData.SetupTime = null
+        } else {
+          this.formData.SetupTime = new Date(this.formData.SetupTime)
+        }
+        // this.formData.WellNo = this.$refs.selectWellNo.selectedLabel + '';
+        this.formData.RegCapital = parseFloat(this.formData.RegCapital)
+        if (!this.formData.Id || !this.certId) {
+          this.addEntity()
+        } else {
+          this.updateEntity()
+        }
+        return true
+      }
+    },
+
+    // 保存信息
+    saveCertEntity () {
+      this.$refs['SupplierCertEditCompoment'].saveEntity()
+    },
+
+    addEntity () {
+      this.formData.SupplierTypeCode = '01'
+      this.formData.SupplierTypeName = '物资类'
+      api
+        .addEntity(this.formData, this.$axios)
+        .then(res => {
+          if (res.data.code === 0) {
+            // 保存成功后,初始化数据,变成修改
+            this.formData.Id = res.data.item.split('_')[0]
+            this.certId = res.data.item.split('_')[1]
+            this.initDatas()
             this.$message({
-              type: 'warning',
-              message: '【生产制造许可证获证情况及编号】或【安全生产许可证】 为必填项'
+              type: 'success',
+              message: res.data.message
             })
-            return
-          }
-        } else if (this.formData.OperType === '代理商') {
-          if (!this.formData.MaunAgent) {
-            valid1 = false
+          } else {
             this.$message({
               type: 'warning',
-              message: '【所代理制造商名称】不能为空'
+              message: res.data.message
             })
-            return
           }
-        }
-
-        /** 2019.05.16 - 16 准入申请中,若选择了“管理单位”,“中石油准入证编号”应自动改为必填项 */
-        if (this.formData.MgrUnit.length > 0 && this.formData.PACNumber.length <= 0) {
-          valid1 = false
-          this.$message({
-            type: 'warning',
-            message: '【中石油准入证编号】不能为空'
-          })
-          return
-        }
+        })
+        .catch(err => {
+          console.error(err)
+        })
+    },
 
-        if (valid1 && valid2) {
-          if (!this.formData.SetupTime) {
-            this.formData.SetupTime = null
-          } else {
-            this.formData.SetupTime = new Date(this.formData.SetupTime)
-          }
-          // this.formData.WellNo = this.$refs.selectWellNo.selectedLabel + '';
-          this.formData.RegCapital = parseFloat(this.formData.RegCapital)
-          if (!this.formData.Id || !this.certId) {
-            this.addEntity()
+    updateEntity () {
+      api
+        .updateEntity(this.formData.Id, this.formData, this.$axios)
+        .then(res => {
+          if (res.data.code === 0) {
+            // 更新子表
+            // this.updateNumberEntity()
+            this.initDatas()
+            this.$message({
+              type: 'success',
+              message: res.data.message
+            })
           } else {
-            this.updateEntity()
+            this.$message({
+              type: 'warning',
+              message: res.data.message
+            })
           }
-          return true
-        }
-      },
-
-      // 保存信息
-      saveCertEntity () {
-        this.$refs['SupplierCertEditCompoment'].saveEntity()
-      },
-
-      addEntity () {
-        this.formData.SupplierTypeCode = '01'
-        this.formData.SupplierTypeName = '物资类'
-        api
-          .addEntity(this.formData, this.$axios)
-          .then(res => {
-            if (res.data.code === 0) {
-              // 保存成功后,初始化数据,变成修改
-              this.formData.Id = res.data.item.split('_')[0]
-              this.certId = res.data.item.split('_')[1]
-              this.initDatas()
-              this.$message({
-                type: 'success',
-                message: res.data.message
-              })
-            } else {
-              this.$message({
-                type: 'warning',
-                message: res.data.message
-              })
-            }
-          })
-          .catch(err => {
-            console.error(err)
-          })
-      },
-
-      updateEntity () {
-        api
-          .updateEntity(this.formData.Id, this.formData, this.$axios)
-          .then(res => {
-            if (res.data.code === 0) {
-              // 更新子表
-              // this.updateNumberEntity()
-              this.initDatas()
-              this.$message({
-                type: 'success',
-                message: res.data.message
-              })
-            } else {
-              this.$message({
-                type: 'warning',
-                message: res.data.message
-              })
-            }
-          })
-          .catch(err => {
-            console.error(err)
-          })
-      },
+        })
+        .catch(err => {
+          console.error(err)
+        })
+    },
 
-      CheckCompanyBase () {
-        if (!this.formData.Id) {
-          this.$message({
-            type: 'error',
-            message: '无法保存,请先填写企业基本信息'
-          })
-          return false
-        }
-        if (!this.certId) {
-          this.$message({
-            type: 'error',
-            message: '准入类别不清晰,无法保存!'
-          })
-          return false
-        }
-        return true
-      },
-      // 企业人员结构情况
-      updateNumberEntity () {
-        this.$refs['EntityFormNumber'].validate((valid) => {
-          if (valid) {
-            if (!this.CheckCompanyBase()) {
-              return false
-            }
-            this.formDataCert.InStyle = this.formData.InStyle
-            api
-              .updateNumberEntity(
-                this.formData.Id + '_' + this.certId,
-                this.formDataCert,
-                this.$axios
-              )
-              .then(res => {
-                if (res.data.code === 0) {
-                  // 保存成功后,初始化数据,变成修改
-                  this.initDatas()
-                  this.$message({
-                    type: 'success',
-                    message: res.data.message
-                  })
-                } else {
-                  this.$message({
-                    type: 'warning',
-                    message: res.data.message
-                  })
-                }
-              })
-              .catch(err => {
-                console.error(err)
-              })
-          } else {
+    CheckCompanyBase () {
+      if (!this.formData.Id) {
+        this.$message({
+          type: 'error',
+          message: '无法保存,请先填写企业基本信息'
+        })
+        return false
+      }
+      if (!this.certId) {
+        this.$message({
+          type: 'error',
+          message: '准入类别不清晰,无法保存!'
+        })
+        return false
+      }
+      return true
+    },
+    // 企业人员结构情况
+    updateNumberEntity () {
+      this.$refs['EntityFormNumber'].validate((valid) => {
+        if (valid) {
+          if (!this.CheckCompanyBase()) {
             return false
           }
-        })
-      },
-      selectAuditOrg () {
-        console.log('----this.IsCompanyUser', this.IsCompanyUser)
-        if (this.IsCompanyUser === 0) {
-          this.dialogVisible = true
-        } else if (this.IsCompanyUser === 1) {
-          this.dialogVisibleCom = true
+          this.formDataCert.InStyle = this.formData.InStyle
+          api
+            .updateNumberEntity(
+              this.formData.Id + '_' + this.certId,
+              this.formDataCert,
+              this.$axios
+            )
+            .then(res => {
+              if (res.data.code === 0) {
+                // 保存成功后,初始化数据,变成修改
+                this.initDatas()
+                this.$message({
+                  type: 'success',
+                  message: res.data.message
+                })
+              } else {
+                this.$message({
+                  type: 'warning',
+                  message: res.data.message
+                })
+              }
+            })
+            .catch(err => {
+              console.error(err)
+            })
+        } else {
+          return false
         }
-      },
-      chooseAuditorShow () {
-        this.$refs['chooseAuditor'].getorgtreelist(
-          this.formData.SupplierTypeCode
-        )
-        this.chooseAuditorVisible = true
-      },
-      setAuditer (val, name) {
-        this.auditer = val
-        this.auditerName = name
-        this.chooseAuditorVisible = false
-        this.auditOrgChang(this.auditer)
-      },
-      chooseAuditorShowFen () {
-        console.log('--this.formData.SupplierTypeCode----', this.formData.SupplierTypeCode)
-        this.$refs['chooseAuditorFen'].getorgtreelist(this.formData.SupplierTypeCode)
-        this.chooseAuditorVisibleFen = true
-      },
-      setAuditerFen (val, name) {
-        this.auditer = val
-        this.auditerName = name
-        this.chooseAuditorVisibleFen = false
-      },
-      AuditEntity (val) {
-        if (this.auditer === '') {
+      })
+    },
+    selectAuditOrg () {
+      console.log('----this.IsCompanyUser', this.IsCompanyUser)
+      if (this.IsCompanyUser === 0) {
+        this.dialogVisible = true
+      } else if (this.IsCompanyUser === 1) {
+        this.dialogVisibleCom = true
+      }
+    },
+    chooseAuditorShow () {
+      this.$refs['chooseAuditor'].getorgtreelist(
+        this.formData.SupplierTypeCode
+      )
+      this.chooseAuditorVisible = true
+    },
+    setAuditer (val, name) {
+      this.auditer = val
+      this.auditerName = name
+      this.chooseAuditorVisible = false
+      this.auditOrgChang(this.auditer)
+    },
+    chooseAuditorShowFen () {
+      console.log('--this.formData.SupplierTypeCode----', this.formData.SupplierTypeCode)
+      this.$refs['chooseAuditorFen'].getorgtreelist(this.formData.SupplierTypeCode)
+      this.chooseAuditorVisibleFen = true
+    },
+    setAuditerFen (val, name) {
+      this.auditer = val
+      this.auditerName = name
+      this.chooseAuditorVisibleFen = false
+    },
+    AuditEntity (val) {
+      if (this.auditer === '') {
+        this.$message({
+          type: 'warning',
+          message: '请选择初审人!'
+        })
+        return
+      }
+      if (this.fushenauditer === '') {
+        this.$message({
+          type: 'warning',
+          message: '请选择复审人!'
+        })
+        return
+      }
+      if (this.formData.InStyle != '2' && this.formData.InStyle != '6') {
+        if (this.selectDept === 0 || this.selectDept == '') {
           this.$message({
             type: 'warning',
-            message: '请选择初审人!'
+            message: '请选择专业处室!'
           })
           return
         }
-        if (this.fushenauditer === '') {
+      }
+      if (this.formData.InStyle != '2' && this.formData.InStyle != '6') {
+        if (this.userOptions == null || this.userOptions.length === 0) {
           this.$message({
             type: 'warning',
-            message: '请选择复审人!'
+            message: '该专业科室未配置接收人!'
           })
           return
         }
-        if (this.formData.InStyle != '2' && this.formData.InStyle != '6') {
-          if (this.selectDept === 0 || this.selectDept == '') {
+      }
+      this.applyLoading = true
+      this.auditform.FirstAuditName = this.auditer
+      this.auditform.CertId = this.certId
+      this.auditform.SecondAudit = this.fushenauditer
+      this.auditform.ThirdAudit = this.selectDept // this.majorDept[this.majorDept.length - 1]
+      console.log('--this.audiform--', this.auditform)
+      apiCert
+        .auditEntity(this.certId, this.auditform, this.$axios)
+        .then(res => {
+          if (res.data.code === 0) {
+            // 保存成功后,初始化数据,变成修改
+            this.initDatas()
+            this.dialogVisible = false
+            this.$message({
+              type: 'success',
+              message: res.data.message
+            })
+          } else {
             this.$message({
               type: 'warning',
-              message: '请选择专业处室!'
+              message: res.data.message
             })
-            return
           }
-        }
-        if (this.formData.InStyle != '2' && this.formData.InStyle != '6') {
-          if (this.userOptions == null || this.userOptions.length === 0) {
+          this.applyLoading = false
+        })
+        .catch(err => {
+          console.error(err)
+        })
+    },
+    SubpEntity () {
+      if (this.orgauditOptions == null || this.orgauditOptions.length === 0) {
+        this.$message({
+          type: 'warning',
+          message: '该单位没有分办人员!'
+        })
+        return
+      }
+      // if (this.auditer === "") {
+      //   this.$message({
+      //     type: "warning",
+      //     message: "请选择分办人!"
+      //   })
+      //   return
+      // }
+      this.applyLoading = true
+      this.auditform.FirstAuditName = this.UnitOrg
+      this.auditform.CertId = this.certId
+      console.log('--this.audiform--', this.auditform)
+      apiCert.auditEntity(this.certId, this.auditform, this.$axios)
+        .then(res => {
+          if (res.data.code === 0) {
+            // 保存成功后,初始化数据,变成修改
+            this.initDatas()
+            this.dialogVisibleCom = false
+            this.$message({
+              type: 'success',
+              message: res.data.message
+            })
+          } else {
             this.$message({
               type: 'warning',
-              message: '该专业科室未配置接收人!'
+              message: res.data.message
             })
-            return
           }
-        }
-        this.applyLoading = true
-        this.auditform.FirstAuditName = this.auditer
-        this.auditform.CertId = this.certId
-        this.auditform.SecondAudit = this.fushenauditer
-        this.auditform.ThirdAudit = this.selectDept // this.majorDept[this.majorDept.length - 1]
-        console.log('--this.audiform--', this.auditform)
-        apiCert
-          .auditEntity(this.certId, this.auditform, this.$axios)
-          .then(res => {
-            if (res.data.code === 0) {
-              // 保存成功后,初始化数据,变成修改
-              this.initDatas()
-              this.dialogVisible = false
-              this.$message({
-                type: 'success',
-                message: res.data.message
-              })
-            } else {
-              this.$message({
-                type: 'warning',
-                message: res.data.message
-              })
-            }
-            this.applyLoading = false
-          })
-          .catch(err => {
-            console.error(err)
-          })
-      },
-      SubpEntity () {
-        if (this.orgauditOptions == null || this.orgauditOptions.length === 0) {
-          this.$message({
-            type: 'warning',
-            message: '该单位没有分办人员!'
-          })
-          return
-        }
-        // if (this.auditer === "") {
-        //   this.$message({
-        //     type: "warning",
-        //     message: "请选择分办人!"
-        //   })
-        //   return
-        // }
-        this.applyLoading = true
-        this.auditform.FirstAuditName = this.UnitOrg
-        this.auditform.CertId = this.certId
-        console.log('--this.audiform--', this.auditform)
-        apiCert.auditEntity(this.certId, this.auditform, this.$axios)
-          .then(res => {
-            if (res.data.code === 0) {
-              // 保存成功后,初始化数据,变成修改
-              this.initDatas()
-              this.dialogVisibleCom = false
-              this.$message({
-                type: 'success',
-                message: res.data.message
-              })
-            } else {
-              this.$message({
-                type: 'warning',
-                message: res.data.message
-              })
-            }
-            this.applyLoading = false
-          })
-          .catch(err => {
-            console.error(err)
-          })
-      },
-
-      jstimehandle (val) {
-        if (val === '') {
-          return '----'
-        } else if (val === '0001-01-01T08:00:00+08:00') {
-          return '----'
-        } else if (val === '5000-01-01T23:59:59+08:00') {
-          return '永久'
-        } else {
-          val = val.replace('T', ' ')
-          return val.substring(0, 10)
-        }
-      },
+          this.applyLoading = false
+        })
+        .catch(err => {
+          console.error(err)
+        })
+    },
 
-      formatDateTime (date) {
-        var y = date.getFullYear()
-        var m = date.getMonth() + 1
-        m = m < 10 ? '0' + m : m
-        var d = date.getDate()
-        d = d < 10 ? '0' + d : d
-        var h = date.getHours()
-        var minute = date.getMinutes()
-        minute = minute < 10 ? '0' + minute : minute
-        return y + '-' + m + '-' + d + ' ' + h + ':' + minute
+    jstimehandle (val) {
+      if (val === '') {
+        return '----'
+      } else if (val === '0001-01-01T08:00:00+08:00') {
+        return '----'
+      } else if (val === '5000-01-01T23:59:59+08:00') {
+        return '永久'
+      } else {
+        val = val.replace('T', ' ')
+        return val.substring(0, 10)
       }
+    },
+
+    formatDateTime (date) {
+      var y = date.getFullYear()
+      var m = date.getMonth() + 1
+      m = m < 10 ? '0' + m : m
+      var d = date.getDate()
+      d = d < 10 ? '0' + d : d
+      var h = date.getHours()
+      var minute = date.getMinutes()
+      minute = minute < 10 ? '0' + minute : minute
+      return y + '-' + m + '-' + d + ' ' + h + ':' + minute
     }
   }
+}
 </script>
 
 <style>
-  .mycard .el-card__header {
-    padding : 8px;
-  }
+.mycard .el-card__header {
+  padding: 8px;
+}
 </style>

File diff suppressed because it is too large
+ 1245 - 1029
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/techedit.vue


+ 10 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/basislist.vue

@@ -17,6 +17,11 @@
                        style="margin-left:10px; margin-top: -4px;"
                        v-if="canApply">准入申请</el-button>
           </router-link>
+          <el-button type="primary"
+                     size="mini"
+                     style="margin-left:10px; margin-top: -4px;"
+                     disabled
+                     v-if="isSuspend">已暂停</el-button>
         </span>
         <el-form ref="form"
                  :inline="true"
@@ -431,6 +436,7 @@ export default {
   data () {
     return {
       canApply: false,
+      isSuspend: false,
       dialogVisible: false,
       // 列表数据
       countryoptions: [],
@@ -1011,8 +1017,12 @@ export default {
 
     isCanApply () {
       api.isCanApply('02', this.$axios).then(res => {
+        console.log(res)
         if (res.data.code === 0) {
           this.canApply = true
+        } else if (res.data.code === -2) {
+          this.canApply = false
+          this.isSuspend = true
         } else {
           this.canApply = false
         }

+ 919 - 789
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/goodslist.vue

@@ -4,24 +4,44 @@
       <el-breadcrumb-item :to="{ path: '/' }">平台首页</el-breadcrumb-item>
       <el-breadcrumb-item>物资类列表</el-breadcrumb-item>
     </el-breadcrumb>
-    <el-card class="box-card" style="height: calc(100vh - 115px);">
+    <el-card class="box-card"
+             style="height: calc(100vh - 115px);">
       <div slot="header">
         <span>
           <i class="icon icon-table2"></i> 物资类列表
         </span>
         <span style="float: right;">
           <router-link :to="'/oilsupplier/supplier/add/goodsedit'">
-            <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" v-if="canApply">准入申请</el-button>
+            <el-button type="primary"
+                       size="mini"
+                       style="margin-left:10px; margin-top: -4px;"
+                       v-if="canApply">准入申请</el-button>
           </router-link>
+          <el-button type="primary"
+                     size="mini"
+                     style="margin-left:10px; margin-top: -4px;"
+                     disabled
+                     v-if="isSuspend">已暂停</el-button>
         </span>
-        <el-form ref="form" :inline="true" style="float: right; margin-top: -10px">
+        <el-form ref="form"
+                 :inline="true"
+                 style="float: right; margin-top: -10px">
           <el-form-item label="上报时间">
-            <el-date-picker size="mini" style="width: 220px" v-model="CreateOn" type="daterange" range-separator="至"
-                            start-placeholder="生成日期" end-placeholder="结束日期"></el-date-picker>
+            <el-date-picker size="mini"
+                            style="width: 220px"
+                            v-model="CreateOn"
+                            type="daterange"
+                            range-separator="至"
+                            start-placeholder="生成日期"
+                            end-placeholder="结束日期"></el-date-picker>
           </el-form-item>
 
           <el-form-item>
-            <el-dropdown split-button type="primary" size="mini" @click="handleSearch" @command="searchCommand">
+            <el-dropdown split-button
+                         type="primary"
+                         size="mini"
+                         @click="handleSearch"
+                         @command="searchCommand">
               查询
               <el-dropdown-menu slot="dropdown">
                 <el-dropdown-item command="search">高级查询</el-dropdown-item>
@@ -31,48 +51,91 @@
           </el-form-item>
         </el-form>
       </div>
-      <el-table :data="entityList" border height="calc(100vh - 243px)" style="width: 100%" @sort-change="orderby" size="mini">
-        <el-table-column label="操作" min-width="200px" align="center" fixed="right">
+      <el-table :data="entityList"
+                border
+                height="calc(100vh - 243px)"
+                style="width: 100%"
+                @sort-change="orderby"
+                size="mini">
+        <el-table-column label="操作"
+                         min-width="200px"
+                         align="center"
+                         fixed="right">
           <template slot-scope="scope">
             <router-link :to="'/oilsupplier/supplier/' + scope.row.Id + '/goodsedit?certid=' + scope.row.CertId">
-              <el-button type="text" title="打开"  icon="el-icon-edit" size="mini">打开</el-button>
+              <el-button type="text"
+                         title="打开"
+                         icon="el-icon-edit"
+                         size="mini">打开</el-button>
             </router-link>
-            <el-popover placement="top" title="提示">
-              <el-alert
-                title=""
-                description="确认要删除吗?"
-                type="warning"
-                :closable="false">
+            <el-popover placement="top"
+                        title="提示">
+              <el-alert title=""
+                        description="确认要删除吗?"
+                        type="warning"
+                        :closable="false">
               </el-alert>
-              <br/>
+              <br />
               <div style="text-align: right; margin: 0">
-                <el-button type="primary" size="mini" @click="deleteEntity(scope.row)">删除</el-button>
+                <el-button type="primary"
+                           size="mini"
+                           @click="deleteEntity(scope.row)">删除</el-button>
               </div>
-              <el-button slot="reference" :disabled="checkStatus(scope.row.Status)"  type="text" title="删除" style="margin-left:10px" size="mini" icon="el-icon-delete">删除</el-button>
+              <el-button slot="reference"
+                         :disabled="checkStatus(scope.row.Status)"
+                         type="text"
+                         title="删除"
+                         style="margin-left:10px"
+                         size="mini"
+                         icon="el-icon-delete">删除</el-button>
             </el-popover>
           </template>
         </el-table-column>
-        <el-table-column width="160px" align="center" prop="Status" label="审核状态" show-overflow-tooltip>
+        <el-table-column width="160px"
+                         align="center"
+                         prop="Status"
+                         label="审核状态"
+                         show-overflow-tooltip>
           <template slot-scope="scope">
-            <span v-if="scope.row.Status=='0' || scope.row.Status==''" style="color:#E6A23C">待提交</span>
-            <span v-if="scope.row.Status=='10'" style="color:#E6A23C">待二级单位分办</span>
-            <span v-if="scope.row.Status=='1'" style="color:#E6A23C">待初审</span>
-            <span v-if="scope.row.Status=='-1'" style="color:#F56C6C">初审未通过</span>
-            <span v-if="scope.row.Status=='2'" style="color:#E6A23C">待复审</span>
-            <span v-if="scope.row.Status=='-2'" style="color:#F56C6C">复审未通过</span>
-            <span v-if="scope.row.Status=='3'" style="color:#E6A23C">待专业处室分办</span>
-            <span v-if="scope.row.Status=='4'" style="color:#E6A23C">待专业处室审批</span>
-            <span v-if="scope.row.Status=='-4'" style="color:#F56C6C">专业处室审批未通过</span>
-            <span v-if="scope.row.Status=='5'" style="color:#E6A23C">待集中评审</span>
-            <span v-if="scope.row.Status=='-5'" style="color:#F56C6C">集中评审未通过</span>
-            <span v-if="scope.row.Status=='6'" style="color:#E6A23C">待缴费</span>
-            <span v-if="scope.row.Status=='7'" style="color:#E6A23C">待入库</span>
-            <span v-if="scope.row.Status=='8'" style="color:#67C23A">已入库</span>
+            <span v-if="scope.row.Status=='0' || scope.row.Status==''"
+                  style="color:#E6A23C">待提交</span>
+            <span v-if="scope.row.Status=='10'"
+                  style="color:#E6A23C">待二级单位分办</span>
+            <span v-if="scope.row.Status=='1'"
+                  style="color:#E6A23C">待初审</span>
+            <span v-if="scope.row.Status=='-1'"
+                  style="color:#F56C6C">初审未通过</span>
+            <span v-if="scope.row.Status=='2'"
+                  style="color:#E6A23C">待复审</span>
+            <span v-if="scope.row.Status=='-2'"
+                  style="color:#F56C6C">复审未通过</span>
+            <span v-if="scope.row.Status=='3'"
+                  style="color:#E6A23C">待专业处室分办</span>
+            <span v-if="scope.row.Status=='4'"
+                  style="color:#E6A23C">待专业处室审批</span>
+            <span v-if="scope.row.Status=='-4'"
+                  style="color:#F56C6C">专业处室审批未通过</span>
+            <span v-if="scope.row.Status=='5'"
+                  style="color:#E6A23C">待集中评审</span>
+            <span v-if="scope.row.Status=='-5'"
+                  style="color:#F56C6C">集中评审未通过</span>
+            <span v-if="scope.row.Status=='6'"
+                  style="color:#E6A23C">待缴费</span>
+            <span v-if="scope.row.Status=='7'"
+                  style="color:#E6A23C">待入库</span>
+            <span v-if="scope.row.Status=='8'"
+                  style="color:#67C23A">已入库</span>
           </template>
         </el-table-column>
-        <el-table-column v-for="column in tableColumns" :key="column.Id"
-                         :prop="column.prop" sortable :width="column.width" :label="column.label" align="center" show-overflow-tooltip>
-          <template slot-scope="scope" >
+        <el-table-column v-for="column in tableColumns"
+                         :key="column.Id"
+                         :prop="column.prop"
+                         sortable
+                         :width="column.width"
+                         :label="column.label"
+                         align="center"
+                         show-overflow-tooltip>
+          <template slot-scope="scope">
             <span v-if="column.prop == 'SetupTime'">{{ jstimehandle(scope.row.SetupTime+'') }}</span>
             <span v-else>{{ scope.row[column.prop] }}</span>
           </template>
@@ -84,149 +147,190 @@
           </template>
         </el-table-column>-->
       </el-table>
-      <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
-                     :page-sizes="[10, 15, 20, 25]" :page-size="size" layout="total, sizes, prev, pager, next, jumper" :total="currentItemCount">
+      <el-pagination @size-change="handleSizeChange"
+                     @current-change="handleCurrentChange"
+                     :current-page="currentPage"
+                     :page-sizes="[10, 15, 20, 25]"
+                     :page-size="size"
+                     layout="total, sizes, prev, pager, next, jumper"
+                     :total="currentItemCount">
       </el-pagination>
     </el-card>
 
-    <el-dialog title="高级查询" :visible.sync="dialogVisible" width="750px">
-      <el-form ref="advancedsearchForm" label-width="130px">
+    <el-dialog title="高级查询"
+               :visible.sync="dialogVisible"
+               width="750px">
+      <el-form ref="advancedsearchForm"
+               label-width="130px">
         <el-row>
 
           <el-col :span="12">
             <el-form-item label="上报时间">
-              <el-date-picker size="mini" v-model="CreateOn" type="daterange" style="width:100%" range-separator="至"
-                              start-placeholder="生成日期" end-placeholder="结束日期"></el-date-picker>
+              <el-date-picker size="mini"
+                              v-model="CreateOn"
+                              type="daterange"
+                              style="width:100%"
+                              range-separator="至"
+                              start-placeholder="生成日期"
+                              end-placeholder="结束日期"></el-date-picker>
             </el-form-item>
           </el-col>
 
           <el-col :span="12">
             <el-form-item label="企业名称">
-              <el-input size="mini" v-model="searchForm.SupplierName" style="width:100%" placeholder="请输入"></el-input>
+              <el-input size="mini"
+                        v-model="searchForm.SupplierName"
+                        style="width:100%"
+                        placeholder="请输入"></el-input>
             </el-form-item>
           </el-col>
 
-         <el-col :span="12">
-          <el-form-item label="供应商类型">
-            <el-select  size="mini" v-model="searchForm.OperType" placeholder="请选择" style="width: 100%">
-              <el-option v-for="item in OperTypeOptions" :key="item.Id" :label="item.Key"
-                         :value="item.Key">
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
-
-        <el-col :span="12">
-          <el-form-item label="单位关系">
-            <el-select size="mini" v-model="searchForm.SpecTypeCode" placeholder="请选择" style="width: 100%">
-              <el-option v-for="item in UnitRelationOptions" :key="item.Id" :label="item.Key"
-                         :value="item.Value">
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
-
-       <el-col :span="12">
-          <el-form-item label="国家">
-            <el-select  size="mini" v-model="searchForm.Country" filterable placeholder="请选择" style="width: 100%">
-              <el-option
-                v-for="item in countryListOptions"
-                :key="item.key"
-                :label="item.value"
-                :value="item.value">
-                <span style="float: left">{{ item.value }}</span>
-                <span style="float: right; color: #8492a6; font-size: 13px">{{ item.label }}</span>
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
+          <el-col :span="12">
+            <el-form-item label="供应商类型">
+              <el-select size="mini"
+                         v-model="searchForm.OperType"
+                         placeholder="请选择"
+                         style="width: 100%">
+                <el-option v-for="item in OperTypeOptions"
+                           :key="item.Id"
+                           :label="item.Key"
+                           :value="item.Key">
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
 
           <el-col :span="12">
-          <el-form-item label="准入方式">
-            <el-select size="mini"  v-model="searchForm.InStyle" placeholder="请选择" style="width: 100%">
-              <el-option  v-for="item in InOptions" :key="item.Id" :label="item.Key"
-                         :value="item.Value">
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
-
-        <el-col :span="12">
-          <el-form-item label="管理单位" >
-            <el-select size="mini" filterable v-model="searchForm.MgrUnit" maxlength="255"  clearable placeholder="请输入" style="width: 100%">
-            <el-option  v-for="item in ManagementUnitOptions" :key="item.Value" :label="item.Key"
-                         :value="item.Key">
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
+            <el-form-item label="单位关系">
+              <el-select size="mini"
+                         v-model="searchForm.SpecTypeCode"
+                         placeholder="请选择"
+                         style="width: 100%">
+                <el-option v-for="item in UnitRelationOptions"
+                           :key="item.Id"
+                           :label="item.Key"
+                           :value="item.Value">
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
 
-        <el-col :span="12">
-          <el-form-item label="中石油准入证编号" >
-            <el-input size="mini" v-model="searchForm.PACNumber" maxlength="255" placeholder="请输入" style="width: 100%"></el-input>
-          </el-form-item>
-        </el-col>
+          <el-col :span="12">
+            <el-form-item label="国家">
+              <el-select size="mini"
+                         v-model="searchForm.Country"
+                         filterable
+                         placeholder="请选择"
+                         style="width: 100%">
+                <el-option v-for="item in countryListOptions"
+                           :key="item.key"
+                           :label="item.value"
+                           :value="item.value">
+                  <span style="float: left">{{ item.value }}</span>
+                  <span style="float: right; color: #8492a6; font-size: 13px">{{ item.label }}</span>
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
 
+          <el-col :span="12">
+            <el-form-item label="准入方式">
+              <el-select size="mini"
+                         v-model="searchForm.InStyle"
+                         placeholder="请选择"
+                         style="width: 100%">
+                <el-option v-for="item in InOptions"
+                           :key="item.Id"
+                           :label="item.Key"
+                           :value="item.Value">
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
 
-        <el-col :span="12">
-          <el-form-item label="统一社会信用代码">
-            <el-input size="mini" v-model="searchForm.CommercialNo" maxlength="50" placeholder="请输入" style="width: 100%"></el-input>
-          </el-form-item>
-        </el-col>
+          <el-col :span="12">
+            <el-form-item label="管理单位">
+              <el-select size="mini"
+                         filterable
+                         v-model="searchForm.MgrUnit"
+                         maxlength="255"
+                         clearable
+                         placeholder="请输入"
+                         style="width: 100%">
+                <el-option v-for="item in ManagementUnitOptions"
+                           :key="item.Value"
+                           :label="item.Key"
+                           :value="item.Key">
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+
+          <el-col :span="12">
+            <el-form-item label="中石油准入证编号">
+              <el-input size="mini"
+                        v-model="searchForm.PACNumber"
+                        maxlength="255"
+                        placeholder="请输入"
+                        style="width: 100%"></el-input>
+            </el-form-item>
+          </el-col>
+
+          <el-col :span="12">
+            <el-form-item label="统一社会信用代码">
+              <el-input size="mini"
+                        v-model="searchForm.CommercialNo"
+                        maxlength="50"
+                        placeholder="请输入"
+                        style="width: 100%"></el-input>
+            </el-form-item>
+          </el-col>
 
-        <el-col :span="24">
+          <el-col :span="24">
             <el-form-item label="注册地址">
               <el-row>
                 <el-col :span="10">
-                  <el-cascader
-                    :change-on-select="true"
-                    v-model="CityAry"
-                    size="mini"
-                    :options="countryoptions"
-                    :props="countryprops"
-                    maxlength="100"
-                    placeholder="省市区"
-                    style="width: 100%"
-                    @change="handleAreaChange"
-                  ></el-cascader>
+                  <el-cascader :change-on-select="true"
+                               v-model="CityAry"
+                               size="mini"
+                               :options="countryoptions"
+                               :props="countryprops"
+                               maxlength="100"
+                               placeholder="省市区"
+                               style="width: 100%"
+                               @change="handleAreaChange"></el-cascader>
                 </el-col>
                 <el-col :span="14">
-                  <el-input
-                    size="mini"
-                    v-model="searchForm.Address"
-                    maxlength="500"
-                    placeholder="详细地址"
-                    style="width: 100%"
-                  ></el-input>
+                  <el-input size="mini"
+                            v-model="searchForm.Address"
+                            maxlength="500"
+                            placeholder="详细地址"
+                            style="width: 100%"></el-input>
                 </el-col>
               </el-row>
             </el-form-item>
           </el-col>
 
-         <el-col :span="24">
+          <el-col :span="24">
             <el-form-item label="通信地址">
               <el-row>
                 <el-col :span="10">
-                  <el-cascader
-                    :change-on-select="true"
-                    v-model="LinkCityAry"
-                    size="mini"
-                    :options="countryoptions"
-                    :props="countryprops"
-                    maxlength="100"
-                    placeholder="省市区"
-                    style="width: 100%"
-                    @change="handleLinkAreaChange"
-                  ></el-cascader>
+                  <el-cascader :change-on-select="true"
+                               v-model="LinkCityAry"
+                               size="mini"
+                               :options="countryoptions"
+                               :props="countryprops"
+                               maxlength="100"
+                               placeholder="省市区"
+                               style="width: 100%"
+                               @change="handleLinkAreaChange"></el-cascader>
                 </el-col>
                 <el-col :span="14">
-                  <el-input
-                    size="mini"
-                    v-model="searchForm.LinkAddress"
-                    maxlength="500"
-                    placeholder="详细地址"
-                    style="width: 100%"
-                  ></el-input>
+                  <el-input size="mini"
+                            v-model="searchForm.LinkAddress"
+                            maxlength="500"
+                            placeholder="详细地址"
+                            style="width: 100%"></el-input>
                 </el-col>
               </el-row>
             </el-form-item>
@@ -234,19 +338,32 @@
 
           <el-col :span="12">
             <el-form-item label="法人">
-              <el-input size="mini" v-model="searchForm.LegalPerson" placeholder="请输入内容"></el-input>
+              <el-input size="mini"
+                        v-model="searchForm.LegalPerson"
+                        placeholder="请输入内容"></el-input>
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <el-form-item label="联系人">
-              <el-input size="mini" v-model="searchForm.ContactName" placeholder="请输入内容"></el-input>
+              <el-input size="mini"
+                        v-model="searchForm.ContactName"
+                        placeholder="请输入内容"></el-input>
             </el-form-item>
           </el-col>
 
           <el-col :span="12">
-            <el-form-item label="公司类型" prop="CompanyType" >
-              <el-select size="mini" v-model="searchForm.CompanyType" maxlength="50" filterable placeholder="请选择" style="width: 100%;">
-                <el-option v-for="item in CompanyTypeOptions" :key="item.Id" :label="item.Key" :value="item.Value"
+            <el-form-item label="公司类型"
+                          prop="CompanyType">
+              <el-select size="mini"
+                         v-model="searchForm.CompanyType"
+                         maxlength="50"
+                         filterable
+                         placeholder="请选择"
+                         style="width: 100%;">
+                <el-option v-for="item in CompanyTypeOptions"
+                           :key="item.Id"
+                           :label="item.Key"
+                           :value="item.Value"
                            style="width: 100%">
                 </el-option>
               </el-select>
@@ -255,682 +372,695 @@
 
           <el-col :span="12">
             <el-form-item label="成立时间">
-              <el-date-picker
-                v-model="searchForm.SetupTime"
-                size="mini"
-                type="date"
-                format="yyyy 年 MM 月 dd 日"
-                value-format="yyyy-MM-dd"
-                placeholder="选择日期"
-                style="width: 100%"
-              ></el-date-picker>
+              <el-date-picker v-model="searchForm.SetupTime"
+                              size="mini"
+                              type="date"
+                              format="yyyy 年 MM 月 dd 日"
+                              value-format="yyyy-MM-dd"
+                              placeholder="选择日期"
+                              style="width: 100%"></el-date-picker>
             </el-form-item>
           </el-col>
 
-        <el-col>
-          <el-form-item label="注册资本(万元)">
-            <el-col :span="5">
-              <el-input size="mini" v-model="searchForm.RegCapital1" placeholder="请输入内容"></el-input>
-            </el-col>
-            <el-col :span="1">
-              <span>&nbsp;~</span>
-            </el-col>
-            <el-col :span="5">
-              <el-input size="mini" v-model="searchForm.RegCapital2" placeholder="请输入内容"></el-input>
-            </el-col>
-          </el-form-item>
-        </el-col>
+          <el-col>
+            <el-form-item label="注册资本(万元)">
+              <el-col :span="5">
+                <el-input size="mini"
+                          v-model="searchForm.RegCapital1"
+                          placeholder="请输入内容"></el-input>
+              </el-col>
+              <el-col :span="1">
+                <span>&nbsp;~</span>
+              </el-col>
+              <el-col :span="5">
+                <el-input size="mini"
+                          v-model="searchForm.RegCapital2"
+                          placeholder="请输入内容"></el-input>
+              </el-col>
+            </el-form-item>
+          </el-col>
 
-        <el-col :span="24">
+          <el-col :span="24">
             <el-form-item label="营业范围">
-              <el-input size="mini" v-model="searchForm.BusinessScope" placeholder="请输入内容"></el-input>
+              <el-input size="mini"
+                        v-model="searchForm.BusinessScope"
+                        placeholder="请输入内容"></el-input>
             </el-form-item>
-        </el-col>
+          </el-col>
 
-       </el-row>
+        </el-row>
 
       </el-form>
-      <span slot="footer" class="dialog-footer">
-        <el-button size="mini" @click="dialogVisible = false">取 消</el-button>
-        <el-button size="mini" type="primary" @click="handleSearch">查 询</el-button>
+      <span slot="footer"
+            class="dialog-footer">
+        <el-button size="mini"
+                   @click="dialogVisible = false">取 消</el-button>
+        <el-button size="mini"
+                   type="primary"
+                   @click="handleSearch">查 询</el-button>
       </span>
     </el-dialog>
 
   </div>
 </template>
 <script>
-  import { mapGetters } from 'vuex'
+import { mapGetters } from 'vuex'
 import api from '@/api/oilsupplier/supplier'
 import certApi from '@/api/oilsupplier/suppliercert'
 
-  export default {
-    computed: {
-      ...mapGetters({
-        authUser: 'authUser'
-      })
-    },
-    name: 'oilsupplier',
-
-    data () {
-      return {
-        canApply: false,
-        dialogVisible: false,
-        countryoptions: [],
-        CityAry: [],
-        LinkCityAry: [],
-        countryprops: {
-          value: 'adcode',
-          label: 'name',
-          children: 'districts'
+export default {
+  computed: {
+    ...mapGetters({
+      authUser: 'authUser'
+    })
+  },
+  name: 'oilsupplier',
+
+  data () {
+    return {
+      canApply: false,
+      isSuspend: false,
+      dialogVisible: false,
+      countryoptions: [],
+      CityAry: [],
+      LinkCityAry: [],
+      countryprops: {
+        value: 'adcode',
+        label: 'name',
+        children: 'districts'
+      },
+      // 列表数据
+      entityList: [],
+      OperTypeOptions: [],
+      UnitRelationOptions: [],
+      countryListOptions: [],
+      CompanyTypeOptions: [],
+      InOptions: [],
+      ManagementUnitOptions: [],
+      dictData: null,
+      // 分页参数
+      size: 10,
+      currentPage: 1,
+      currentItemCount: 0,
+      // 列表排序
+      Column: {
+        Order: '',
+        Prop: ''
+      },
+      // 查询时间
+      CreateOn: null,
+      /* CreateOn: [new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000), new Date()], */
+      // 查询项
+      searchFormReset: {},
+      searchForm: {
+        Id: '',
+        SupplierName: '',
+        OperType: '',
+        SpecTypeCode: '',
+        Country: '',
+        InStyle: '',
+        MgrUnit: '',
+        PACNumber: '',
+        CommercialNo: '',
+        Province: '',
+        City: '',
+        Street: '',
+        Address: '',
+        LinkProvince: '',
+        LinkCity: '',
+        LinkStreet: '',
+        LinkAddress: '',
+        LegalPerson: '',
+        ContactName: '',
+        CompanyType: '',
+        SetupTime: '',
+        RegCapital1: '',
+        RegCapital2: '',
+        BusinessScope: ''
+      },
+      tableColumns: [
+
+        /* {
+         prop: "Id",
+         label: '',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'AccessCardNo',
+          label: '准入证编号',
+          width: 240,
+          sort: true
+        },
+
+        {
+          prop: 'SupplierTypeName',
+          label: '准入类别',
+          width: 150,
+          sort: true
+        },
+
+        {
+          prop: 'SupplierName',
+          label: '企业名称',
+          width: 240,
+          sort: true
+        },
+
+        /* {
+         prop: "OilCertificateNo",
+         label: '中石油供应商证书号',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "Grade",
+         label: '级别',
+         width: 100,
+         sort: true
+         }, */
+
+        /* {
+         prop: "MgrUnit",
+         label: '管理单位',
+         width: 100,
+         sort: true
+         }, */
+
+        /* {
+         prop: "OperType",
+         label: '经营方式',
+         width: 100,
+         sort: true
+         }, */
+
+        /* {
+         prop: "Country",
+         label: '国家',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "MaunAgent",
+         label: '所代理制造商名称',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "ConstructTeam",
+         label: '施工队伍名称',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'CommercialNo',
+          label: '工商注册号',
+          width: 240,
+          sort: true
         },
-        // 列表数据
-        entityList: [],
-        OperTypeOptions: [],
-        UnitRelationOptions: [],
-        countryListOptions: [],
-        CompanyTypeOptions: [],
-        InOptions: [],
-        ManagementUnitOptions: [],
-        dictData: null,
-        // 分页参数
-        size: 10,
-        currentPage: 1,
-        currentItemCount: 0,
-        // 列表排序
-        Column: {
-          Order: '',
-          Prop: ''
+
+        /* {
+         prop: "OrganCode",
+         label: '组织机构代码',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'CountryTaxNo',
+          label: '税务登记证编号',
+          width: 220,
+          sort: true
+        },
+
+        /* {
+         prop: "LocalTaxNo",
+         label: '税务登记证地税编号',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'Address',
+          label: '单位地址',
+          width: 280,
+          sort: true
+        },
+
+        /* {
+         prop: "Province",
+         label: '省直辖市',
+         width: 200,
+         sort: true
+         },
+
+         {
+         prop: "City",
+         label: '地市区县',
+         width: 200,
+         sort: true
+         },
+
+         {
+         prop: "Street",
+         label: '街道',
+         width: 200,
+         sort: true
+         },
+
+         {
+         prop: "HouseNo",
+         label: '门牌号',
+         width: 200,
+         sort: true
+         },
+
+         {
+         prop: "ZipCode",
+         label: '邮编',
+         width: 200,
+         sort: true
+         }, */
+
+        /* {
+         prop: "QualitySystemCert",
+         label: '质量管理体系认证情况及认证机构',
+         width: 300,
+         sort: true
+         },
+
+         {
+         prop: "ProductQualityCert",
+         label: '产品质量认证情况及认证机构',
+         width: 300,
+         sort: true
+         },
+
+         {
+         prop: "MaunLicense",
+         label: '生产制造许可证获证情况及编号',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "QualifCert",
+         label: '企业资质证书编号',
+         width: 300,
+         sort: true
+         },
+
+         {
+         prop: "QualifCertLevel",
+         label: '企业资质证书级别',
+         width: 300,
+         sort: true
+         },
+
+         {
+         prop: "SafetyLicense",
+         label: '安全生产许可证',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "TechServiceLic",
+         label: '技术服务类准入许可证',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "TJInNotify",
+         label: '外地企业进津备案通知书',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "SpecIndustryCert",
+         label: '行业特殊要求的认证证书',
+         width: 200,
+         sort: true
+         },
+
+         {
+         prop: "LegalPerson",
+         label: '法定代表人姓名',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "CategoryCode",
+         label: '行业类别代码',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "CategoryName",
+         label: '行业类别名称',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'RegCapital',
+          label: '注册资本',
+          width: 150,
+          sort: true
         },
-        // 查询时间
-        CreateOn: null,
-        /* CreateOn: [new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000), new Date()], */
-        // 查询项
-        searchFormReset: {},
-        searchForm: {
-          Id: '',
-          SupplierName: '',
-          OperType: '',
-          SpecTypeCode: '',
-          Country: '',
-          InStyle: '',
-          MgrUnit: '',
-          PACNumber: '',
-          CommercialNo: '',
-          Province: '',
-          City: '',
-          Street: '',
-          Address: '',
-          LinkProvince: '',
-          LinkCity: '',
-          LinkStreet: '',
-          LinkAddress: '',
-          LegalPerson: '',
-          ContactName: '',
-          CompanyType: '',
-          SetupTime: '',
-          RegCapital1: '',
-          RegCapital2: '',
-          BusinessScope: ''
+
+        {
+          prop: 'Currency',
+          label: '币种',
+          width: 100,
+          sort: true
+        },
+
+        {
+          prop: 'ContactName',
+          label: '联系人姓名',
+          width: 140,
+          sort: true
+        },
+
+        {
+          prop: 'CompanyType',
+          label: '公司类型',
+          width: 150,
+          sort: true
         },
-        tableColumns: [
-
-          /* {
-           prop: "Id",
-           label: '',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'AccessCardNo',
-            label: '准入证编号',
-            width: 240,
-            sort: true
-          },
-
-          {
-            prop: 'SupplierTypeName',
-            label: '准入类别',
-            width: 150,
-            sort: true
-          },
-
-          {
-            prop: 'SupplierName',
-            label: '企业名称',
-            width: 240,
-            sort: true
-          },
-
-          /* {
-           prop: "OilCertificateNo",
-           label: '中石油供应商证书号',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "Grade",
-           label: '级别',
-           width: 100,
-           sort: true
-           }, */
-
-          /* {
-           prop: "MgrUnit",
-           label: '管理单位',
-           width: 100,
-           sort: true
-           }, */
-
-          /* {
-           prop: "OperType",
-           label: '经营方式',
-           width: 100,
-           sort: true
-           }, */
-
-          /* {
-           prop: "Country",
-           label: '国家',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "MaunAgent",
-           label: '所代理制造商名称',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "ConstructTeam",
-           label: '施工队伍名称',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'CommercialNo',
-            label: '工商注册号',
-            width: 240,
-            sort: true
-          },
-
-          /* {
-           prop: "OrganCode",
-           label: '组织机构代码',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'CountryTaxNo',
-            label: '税务登记证编号',
-            width: 220,
-            sort: true
-          },
-
-          /* {
-           prop: "LocalTaxNo",
-           label: '税务登记证地税编号',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'Address',
-            label: '单位地址',
-            width: 280,
-            sort: true
-          },
-
-          /* {
-           prop: "Province",
-           label: '省直辖市',
-           width: 200,
-           sort: true
-           },
-
-           {
-           prop: "City",
-           label: '地市区县',
-           width: 200,
-           sort: true
-           },
-
-           {
-           prop: "Street",
-           label: '街道',
-           width: 200,
-           sort: true
-           },
-
-           {
-           prop: "HouseNo",
-           label: '门牌号',
-           width: 200,
-           sort: true
-           },
-
-           {
-           prop: "ZipCode",
-           label: '邮编',
-           width: 200,
-           sort: true
-           }, */
-
-          /* {
-           prop: "QualitySystemCert",
-           label: '质量管理体系认证情况及认证机构',
-           width: 300,
-           sort: true
-           },
-
-           {
-           prop: "ProductQualityCert",
-           label: '产品质量认证情况及认证机构',
-           width: 300,
-           sort: true
-           },
-
-           {
-           prop: "MaunLicense",
-           label: '生产制造许可证获证情况及编号',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "QualifCert",
-           label: '企业资质证书编号',
-           width: 300,
-           sort: true
-           },
-
-           {
-           prop: "QualifCertLevel",
-           label: '企业资质证书级别',
-           width: 300,
-           sort: true
-           },
-
-           {
-           prop: "SafetyLicense",
-           label: '安全生产许可证',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "TechServiceLic",
-           label: '技术服务类准入许可证',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "TJInNotify",
-           label: '外地企业进津备案通知书',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "SpecIndustryCert",
-           label: '行业特殊要求的认证证书',
-           width: 200,
-           sort: true
-           },
-
-           {
-           prop: "LegalPerson",
-           label: '法定代表人姓名',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "CategoryCode",
-           label: '行业类别代码',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "CategoryName",
-           label: '行业类别名称',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'RegCapital',
-            label: '注册资本',
-            width: 150,
-            sort: true
-          },
-
-          {
-            prop: 'Currency',
-            label: '币种',
-            width: 100,
-            sort: true
-          },
-
-          {
-            prop: 'ContactName',
-            label: '联系人姓名',
-            width: 140,
-            sort: true
-          },
-
-          {
-            prop: 'CompanyType',
-            label: '公司类型',
-            width: 150,
-            sort: true
-          },
-
-          {
-            prop: 'SetupTime',
-            label: '成立时间',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'DepositBank',
-            label: '开户银行',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'BankAccount',
-            label: '银行账号',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'EMail',
-            label: '电子邮箱',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'BankCreditRating',
-            label: '银行信用等级',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'Mobile',
-            label: '移动电话',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'Telphone',
-            label: '固定电话',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'Fax',
-            label: '传真',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'CompanyTel',
-            label: '公司电话',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'QQ',
-            label: 'QQ号码',
-            width: 220,
-            sort: true
-          },
-
-          {
-            prop: 'CompanyUrl',
-            label: '公司网址',
-            width: 220,
-            sort: true
-          },
-
-          /* {
-           prop: "SpecSupplier",
-           label: '是否特殊业务供应商(可不招标)',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "SpecTypeCode",
-           label: '业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)',
-           width: 100,
-           sort: true
-           },
-
-           {
-           prop: "SpecTypeName",
-           label: '业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)',
-           width: 100,
-           sort: true
-           }, */
-
-          {
-            prop: 'Remark',
-            label: '备注',
-            width: 220,
-            sort: true
-          }
-
-        ]
+
+        {
+          prop: 'SetupTime',
+          label: '成立时间',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'DepositBank',
+          label: '开户银行',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'BankAccount',
+          label: '银行账号',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'EMail',
+          label: '电子邮箱',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'BankCreditRating',
+          label: '银行信用等级',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'Mobile',
+          label: '移动电话',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'Telphone',
+          label: '固定电话',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'Fax',
+          label: '传真',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'CompanyTel',
+          label: '公司电话',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'QQ',
+          label: 'QQ号码',
+          width: 220,
+          sort: true
+        },
+
+        {
+          prop: 'CompanyUrl',
+          label: '公司网址',
+          width: 220,
+          sort: true
+        },
+
+        /* {
+         prop: "SpecSupplier",
+         label: '是否特殊业务供应商(可不招标)',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "SpecTypeCode",
+         label: '业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)',
+         width: 100,
+         sort: true
+         },
+
+         {
+         prop: "SpecTypeName",
+         label: '业务类型(1战略合作,2内部多经,3区域关键,4专业化实施)',
+         width: 100,
+         sort: true
+         }, */
+
+        {
+          prop: 'Remark',
+          label: '备注',
+          width: 220,
+          sort: true
+        }
+
+      ]
+    }
+  },
+  created () {
+    this.isCanApply()
+    // 查询条件初始值备份
+    Object.assign(this.searchFormReset, this.searchForm)
+    // 查询列表
+    this.initDatas()
+    this.getDictOptions()
+  },
+
+  methods: {
+    checkStatus (val) {
+      if (val === '0' || val === '' || val === '-1' || val === '-2' || val === '-4') {
+        return false
+      } else {
+        return true
+      }
+    },
+    handleLinkAreaChange (value) {
+      this.searchForm.LinkProvince = value[0]
+      this.searchForm.LinkCity = value[1]
+      this.searchForm.LinkStreet = value[2]
+    },
+    handleAreaChange (value) {
+      this.searchForm.Province = value[0]
+      this.searchForm.City = value[1]
+      this.searchForm.Street = value[2]
+    },
+    initDatas () {
+      // 分页及列表条件
+      let params = {
+        _currentPage: this.currentPage,
+        _size: this.size,
+        Order: this.Column.Order,
+        Prop: this.Column.Prop,
+        SupplierTypeCode: '01'
+      }
+      let myCreateOn = []
+      // 解析时间
+      if (this.CreateOn && this.CreateOn.length === 2) {
+        this.CreateOn[1].setHours(23)
+        this.CreateOn[1].setMinutes(59)
+        this.CreateOn[1].setSeconds(59)
+        myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
+        myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
+      }
+      // 查询条件
+      Object.assign(params, this.searchForm)
+      // 访问接口
+      api.getCertList(myCreateOn.join(','), params, this.$axios).then(res => {
+        this.entityList = res.data.items
+        this.currentItemCount = res.data.currentItemCount
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    getDictOptions () {
+      api.getDictList(this.$axios).then(res => {
+        this.dictData = res.data.items
+        console.log(this.dictData)
+        this.OperTypeOptions = this.dictData['OperType']
+        this.UnitRelationOptions = this.dictData['UnitRelation']
+        this.InOptions = this.dictData['InOptions']
+        this.CompanyTypeOptions = this.dictData['CompanyType']
+        this.getCountryList(this.dictData['CountryList'])
+        this.ManagementUnitOptions = this.dictData['ManagementUnit']
+        this.getCityList(this.dictData['GaodeMapChinaAreas'])
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    getCityList (val) {
+      let resultData = JSON.parse(val)
+      let countstr = JSON.stringify(resultData.districts[0].districts)
+      countstr = countstr.replace(/\,\"districts\"\:\[\]/g, '')
+      this.countryoptions = JSON.parse(countstr)
+    },
+    getCountryList (val) {
+      let tmpJson = JSON.parse(val)
+      this.countryListOptions = []
+      for (let idx in tmpJson) {
+        this.countryListOptions.push({
+          label: tmpJson[idx].split('-')[0],
+          value: tmpJson[idx].split('-')[1],
+          code: tmpJson[idx].split('-')[2],
+          key: tmpJson[idx]
+        })
       }
     },
-    created () {
-      this.isCanApply()
-      // 查询条件初始值备份
-      Object.assign(this.searchFormReset, this.searchForm)
-      // 查询列表
+    searchCommand (command) {
+      if (command === 'search') {
+        this.dialogVisible = true
+      } else if (command === 'clear') {
+        this.clearSearch()
+      }
+    },
+    // 列表排序功能
+    orderby (column) {
+      if (column.order === 'ascending') {
+        this.Column.Order = 'asc'
+      } else if (column.order === 'descending') {
+        this.Column.Order = 'desc'
+      }
+      this.Column.Prop = column.prop
       this.initDatas()
-      this.getDictOptions()
     },
-
-    methods: {
-      checkStatus (val) {
-        if (val === '0' || val === '' || val === '-1' || val === '-2' || val === '-4') {
-          return false
+    clearSearch () {
+      Object.assign(this.searchForm, this.searchFormReset)
+      // this.searchForm = this.searchFormReset;
+      this.CityAry = []
+      this.LinkCityAry = []
+      this.CreateOn = ''
+      this.initDatas()
+    },
+    handleSearch () {
+      this.currentPage = 1
+      this.dialogVisible = false
+      this.initDatas()
+    },
+    handleCurrentChange (value) {
+      this.currentPage = value
+      this.initDatas()
+    },
+    handleSizeChange (value) {
+      this.size = value
+      this.currentPage = 1
+      this.initDatas()
+    },
+    deleteEntity (row) {
+      row.deleteConfirmFlag = false
+      api.deleteAllEntity(row.Id, row.SupplierTypeCode, this.$axios).then(res => {
+        if (res.data.code === 0) {
+          this.initDatas()
+          this.isCanApply()
+          this.$message({
+            type: 'success',
+            message: res.data.message
+          })
         } else {
-          return true
-        }
-      },
-      handleLinkAreaChange (value) {
-        this.searchForm.LinkProvince = value[0]
-        this.searchForm.LinkCity = value[1]
-        this.searchForm.LinkStreet = value[2]
-      },
-      handleAreaChange (value) {
-        this.searchForm.Province = value[0]
-        this.searchForm.City = value[1]
-        this.searchForm.Street = value[2]
-      },
-      initDatas () {
-        // 分页及列表条件
-        let params = {
-          _currentPage: this.currentPage,
-          _size: this.size,
-          Order: this.Column.Order,
-          Prop: this.Column.Prop,
-          SupplierTypeCode: '01'
-        }
-        let myCreateOn = []
-        // 解析时间
-        if (this.CreateOn && this.CreateOn.length === 2) {
-          this.CreateOn[1].setHours(23)
-          this.CreateOn[1].setMinutes(59)
-          this.CreateOn[1].setSeconds(59)
-          myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
-          myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
-        }
-        // 查询条件
-        Object.assign(params, this.searchForm)
-        // 访问接口
-        api.getCertList(myCreateOn.join(','), params, this.$axios).then(res => {
-          this.entityList = res.data.items
-          this.currentItemCount = res.data.currentItemCount
-        }).catch(err => {
-          console.error(err)
-        })
-      },
-      getDictOptions () {
-        api.getDictList(this.$axios).then(res => {
-          this.dictData = res.data.items
-          console.log(this.dictData)
-          this.OperTypeOptions = this.dictData['OperType']
-          this.UnitRelationOptions = this.dictData['UnitRelation']
-          this.InOptions = this.dictData['InOptions']
-          this.CompanyTypeOptions = this.dictData['CompanyType']
-          this.getCountryList(this.dictData['CountryList'])
-          this.ManagementUnitOptions = this.dictData['ManagementUnit']
-          this.getCityList(this.dictData['GaodeMapChinaAreas'])
-        }).catch(err => {
-          console.error(err)
-        })
-      },
-      getCityList (val) {
-        let resultData = JSON.parse(val)
-        let countstr = JSON.stringify(resultData.districts[0].districts)
-        countstr = countstr.replace(/\,\"districts\"\:\[\]/g, '')
-        this.countryoptions = JSON.parse(countstr)
-      },
-      getCountryList (val) {
-        let tmpJson = JSON.parse(val)
-        this.countryListOptions = []
-        for (let idx in tmpJson) {
-          this.countryListOptions.push({
-            label: tmpJson[idx].split('-')[0],
-            value: tmpJson[idx].split('-')[1],
-            code: tmpJson[idx].split('-')[2],
-            key: tmpJson[idx]
+          this.$message({
+            type: 'warning',
+            message: res.data.message
           })
         }
-      },
-      searchCommand (command) {
-        if (command === 'search') {
-          this.dialogVisible = true
-        } else if (command === 'clear') {
-          this.clearSearch()
-        }
-      },
-      // 列表排序功能
-      orderby (column) {
-        if (column.order === 'ascending') {
-          this.Column.Order = 'asc'
-        } else if (column.order === 'descending') {
-          this.Column.Order = 'desc'
-        }
-        this.Column.Prop = column.prop
-        this.initDatas()
-      },
-      clearSearch () {
-        Object.assign(this.searchForm, this.searchFormReset)
-        // this.searchForm = this.searchFormReset;
-        this.CityAry = []
-        this.LinkCityAry = []
-        this.CreateOn = ''
-        this.initDatas()
-      },
-      handleSearch () {
-        this.currentPage = 1
-        this.dialogVisible = false
-        this.initDatas()
-      },
-      handleCurrentChange (value) {
-        this.currentPage = value
-        this.initDatas()
-      },
-      handleSizeChange (value) {
-        this.size = value
-        this.currentPage = 1
-        this.initDatas()
-      },
-      deleteEntity (row) {
-        row.deleteConfirmFlag = false
-        api.deleteAllEntity(row.Id, row.SupplierTypeCode, this.$axios).then(res => {
-          if (res.data.code === 0) {
-            this.initDatas()
-            this.isCanApply()
-            this.$message({
-              type: 'success',
-              message: res.data.message
-            })
-          } else {
-            this.$message({
-              type: 'warning',
-              message: res.data.message
-            })
-          }
-        }).catch(err => {
-          console.error(err)
-        })
-      },
+      }).catch(err => {
+        console.error(err)
+      })
+    },
 
-      isCanApply () {
-        api.isCanApply('01', this.$axios).then(res => {
-          if (res.data.code === 0) {
-            this.canApply = true
-          } else {
-            this.canApply = false
-          }
-        }).catch(err => {
-          console.error(err)
-        })
-      },
-      jstimehandle (val) {
-        if (val === '') {
-          return '----'
-        } else if (val === '0001-01-01T08:00:00+08:00') {
-          return '----'
-        } else if (val === '5000-01-01T23:59:59+08:00') {
-          return '永久'
+    isCanApply () {
+      api.isCanApply('01', this.$axios).then(res => {
+        console.log(res)
+        if (res.data.code === 0) {
+          this.canApply = true
+        } else if (res.data.code === -2) {
+          this.canApply = false
+          this.isSuspend = true
         } else {
-          val = val.replace('T', ' ')
-          return val.substring(0, 10)
+          this.canApply = false
         }
-      },
-
-      formatDateTime (date) {
-        var y = date.getFullYear()
-        var m = date.getMonth() + 1
-        m = m < 10 ? ('0' + m) : m
-        var d = date.getDate()
-        d = d < 10 ? ('0' + d) : d
-        var h = date.getHours()
-        var minute = date.getMinutes()
-        minute = minute < 10 ? ('0' + minute) : minute
-        return y + '-' + m + '-' + d + ' ' + h + ':' + minute
+      }).catch(err => {
+        console.error(err)
+      })
+    },
+    jstimehandle (val) {
+      if (val === '') {
+        return '----'
+      } else if (val === '0001-01-01T08:00:00+08:00') {
+        return '----'
+      } else if (val === '5000-01-01T23:59:59+08:00') {
+        return '永久'
+      } else {
+        val = val.replace('T', ' ')
+        return val.substring(0, 10)
       }
+    },
+
+    formatDateTime (date) {
+      var y = date.getFullYear()
+      var m = date.getMonth() + 1
+      m = m < 10 ? ('0' + m) : m
+      var d = date.getDate()
+      d = d < 10 ? ('0' + d) : d
+      var h = date.getHours()
+      var minute = date.getMinutes()
+      minute = minute < 10 ? ('0' + minute) : minute
+      return y + '-' + m + '-' + d + ' ' + h + ':' + minute
     }
   }
+}
 </script>
 
 <style lang="scss">
-  .el-pagination {
-    margin: 1rem 0 2rem;
-    text-align: right;
-  }
+.el-pagination {
+  margin: 1rem 0 2rem;
+  text-align: right;
+}
 </style>

+ 10 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/techlist.vue

@@ -17,6 +17,11 @@
                        v-if="canApply"
                        style="margin-left:10px; margin-top: -4px;">准入申请</el-button>
           </router-link>
+          <el-button type="primary"
+                     size="mini"
+                     style="margin-left:10px; margin-top: -4px;"
+                     disabled
+                     v-if="isSuspend">已暂停</el-button>
         </span>
         <el-form ref="form"
                  :inline="true"
@@ -431,6 +436,7 @@ export default {
   data () {
     return {
       canApply: false,
+      isSuspend: false,
       dialogVisible: false,
       // 列表数据
       countryoptions: [],
@@ -1013,8 +1019,12 @@ export default {
 
     isCanApply () {
       api.isCanApply('03', this.$axios).then(res => {
+        console.log(res)
         if (res.data.code === 0) {
           this.canApply = true
+        } else if (res.data.code === -2) {
+          this.canApply = false
+          this.isSuspend = true
         } else {
           this.canApply = false
         }

Some files were not shown because too many files changed in this diff