Explorar o código

基本信息录入

lining %!s(int64=5) %!d(string=hai) anos
pai
achega
5ac19d7b6b

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

@@ -1692,7 +1692,7 @@ func (this *OilSupplierController) UpdateEntity() {
 	//}
 	//}
 
 
 	if err == nil {
 	if err == nil {
-		svc.DBE.Exec("update OilSupplierCert set InStyle='" + instyle +  " where SupplierId=" + id + " and SupplierTypeCode='" + typeCode + "'") // "', IsPay= " + isPay +
+		svc.DBE.Exec("update OilSupplierCert set InStyle='" + instyle +  "' where SupplierId=" + id + " and SupplierTypeCode='" + typeCode + "'") // "', IsPay= " + isPay +
 		errinfo.Message = "修改成功!"
 		errinfo.Message = "修改成功!"
 		errinfo.Code = 0
 		errinfo.Code = 0
 		this.Data["json"] = &errinfo
 		this.Data["json"] = &errinfo

+ 4 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/basisedit.vue

@@ -297,7 +297,7 @@
         </el-tab-pane>
         </el-tab-pane>
 
 
         <el-tab-pane label="准入范围"
         <el-tab-pane label="准入范围"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <business-list ref="businessList"
           <business-list ref="businessList"
                          :data.sync="businessList"
                          :data.sync="businessList"
                          @close="getbuslist"
                          @close="getbuslist"
@@ -307,7 +307,7 @@
                          style="margin-top: 20px"></business-list>
                          style="margin-top: 20px"></business-list>
         </el-tab-pane>
         </el-tab-pane>
         <el-tab-pane label="企业资质"
         <el-tab-pane label="企业资质"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <subfile-list ref="subfileList"
           <subfile-list ref="subfileList"
                         :data.sync="subfileList"
                         :data.sync="subfileList"
                         :canadd="add_flat"
                         :canadd="add_flat"
@@ -578,6 +578,7 @@ export default {
       }
       }
     }
     }
     return {
     return {
+      WorkerTotal: 0,
       allowpre: true,
       allowpre: true,
       totalTab: 3,
       totalTab: 3,
       activeName: '0',
       activeName: '0',
@@ -1133,6 +1134,7 @@ export default {
         api.getEntityAndCert(this.certId, this.$axios).then(res => {
         api.getEntityAndCert(this.certId, this.$axios).then(res => {
           this.formData = res.data
           this.formData = res.data
           this.formDataCert.WorkerTotal = this.formData.WorkerTotal
           this.formDataCert.WorkerTotal = this.formData.WorkerTotal
+          this.WorkerTotal = this.formData.WorkerTotal
           this.formDataCert.ContractNum = this.formData.ContractNum
           this.formDataCert.ContractNum = this.formData.ContractNum
           this.formDataCert.UniversityNum = this.formData.UniversityNum
           this.formDataCert.UniversityNum = this.formData.UniversityNum
           this.formDataCert.TechnicalNum = this.formData.TechnicalNum
           this.formDataCert.TechnicalNum = this.formData.TechnicalNum

+ 28 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/goodsedit.vue

@@ -306,7 +306,7 @@
         </el-tab-pane>
         </el-tab-pane>
 
 
         <el-tab-pane label="准入范围"
         <el-tab-pane label="准入范围"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <goods-list ref="goodsList"
           <goods-list ref="goodsList"
                       :data.sync="goodsList"
                       :data.sync="goodsList"
                       @close="getbuslist"
                       @close="getbuslist"
@@ -315,10 +315,11 @@
                       :operType="formData.OperType"
                       :operType="formData.OperType"
                       :Grade="formData.Grade"
                       :Grade="formData.Grade"
                       height="360px"
                       height="360px"
+                      @tab-click="tabclick()"
                       style="margin-top: 20px"></goods-list>
                       style="margin-top: 20px"></goods-list>
         </el-tab-pane>
         </el-tab-pane>
         <el-tab-pane label="企业资质"
         <el-tab-pane label="企业资质"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <subfile-list ref="subfileList"
           <subfile-list ref="subfileList"
                         :data.sync="subfileList"
                         :data.sync="subfileList"
                         :canadd="add_flat"
                         :canadd="add_flat"
@@ -583,6 +584,7 @@ export default {
       }
       }
     }
     }
     return {
     return {
+      WorkerTotal: 0,
       isInvestigate: false,
       isInvestigate: false,
       goodsloading: false,
       goodsloading: false,
       operType: '',
       operType: '',
@@ -834,6 +836,29 @@ export default {
     this.changeOrgUnit(this.selectDept)
     this.changeOrgUnit(this.selectDept)
   },
   },
   methods: {
   methods: {
+    tabclick () {
+      // if (this.formDataCert.WorkerTotal <= 0) {
+      //   this.$message({
+      //     type: 'warning',
+      //     message: ''
+      //   })
+      //   return
+      // }
+      // if (this.formDataCert.TechnicalNum <= 0) {
+      //   this.$message({
+      //     type: 'warning',
+      //     message: '技术、管理人员数量必须大于0'
+      //   })
+      //   return
+      // }
+      // if (this.formDataCert.SkillerTotal <= 0) {
+      //   this.$message({
+      //     type: 'warning',
+      //     message: '技术工人总数必须大于0'
+      //   })
+      //   return
+      // }
+    },
     nextStep () {
     nextStep () {
       this.$refs['subfileList'].nextStep()
       this.$refs['subfileList'].nextStep()
     },
     },
@@ -1161,6 +1186,7 @@ export default {
           .then(res => {
           .then(res => {
             this.formData = res.data
             this.formData = res.data
             this.formDataCert.WorkerTotal = this.formData.WorkerTotal
             this.formDataCert.WorkerTotal = this.formData.WorkerTotal
+            this.WorkerTotal = this.formData.WorkerTotal
             this.formDataCert.ContractNum = this.formData.ContractNum
             this.formDataCert.ContractNum = this.formData.ContractNum
             this.formDataCert.UniversityNum = this.formData.UniversityNum
             this.formDataCert.UniversityNum = this.formData.UniversityNum
             this.formDataCert.TechnicalNum = this.formData.TechnicalNum
             this.formDataCert.TechnicalNum = this.formData.TechnicalNum

+ 4 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplier/_opera/techedit.vue

@@ -296,7 +296,7 @@
           </el-card>
           </el-card>
         </el-tab-pane>
         </el-tab-pane>
         <el-tab-pane label="准入范围"
         <el-tab-pane label="准入范围"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <tech-list ref="techList"
           <tech-list ref="techList"
                      :data.sync="techList"
                      :data.sync="techList"
                      @close="getbuslist"
                      @close="getbuslist"
@@ -306,7 +306,7 @@
                      style="margin-top: 20px"></tech-list>
                      style="margin-top: 20px"></tech-list>
         </el-tab-pane>
         </el-tab-pane>
         <el-tab-pane label="企业资质"
         <el-tab-pane label="企业资质"
-                     :disabled="!certId">
+                     :disabled="(!certId) || (WorkerTotal == 0)">
           <subfile-list ref="subfileList"
           <subfile-list ref="subfileList"
                         :data.sync="subfileList"
                         :data.sync="subfileList"
                         :canadd="add_flat"
                         :canadd="add_flat"
@@ -570,6 +570,7 @@ export default {
       }
       }
     }
     }
     return {
     return {
+      WorkerTotal: 0,
       allowpre: true,
       allowpre: true,
       totalTab: 3,
       totalTab: 3,
       activeName: '0',
       activeName: '0',
@@ -1125,6 +1126,7 @@ export default {
         api.getEntityAndCert(this.certId, this.$axios).then(res => {
         api.getEntityAndCert(this.certId, this.$axios).then(res => {
           this.formData = res.data
           this.formData = res.data
           this.formDataCert.WorkerTotal = this.formData.WorkerTotal
           this.formDataCert.WorkerTotal = this.formData.WorkerTotal
+          this.WorkerTotal = this.formData.WorkerTotal
           this.formDataCert.ContractNum = this.formData.ContractNum
           this.formDataCert.ContractNum = this.formData.ContractNum
           this.formDataCert.UniversityNum = this.formData.UniversityNum
           this.formDataCert.UniversityNum = this.formData.UniversityNum
           this.formDataCert.TechnicalNum = this.formData.TechnicalNum
           this.formDataCert.TechnicalNum = this.formData.TechnicalNum

+ 5 - 2
src/dashoo.cn/frontend_web/src/pages/signup.vue

@@ -151,7 +151,7 @@
                 <router-link to="#">《麦吉轮用户注册协议》</router-link><router-link to="#">《隐私政策》</router-link> -->
                 <router-link to="#">《麦吉轮用户注册协议》</router-link><router-link to="#">《隐私政策》</router-link> -->
               </el-row>
               </el-row>
               <el-row style="margin-left: 50%; margin-top: 10px; margin-bottom: 20px;">
               <el-row style="margin-left: 50%; margin-top: 10px; margin-bottom: 20px;">
-                <el-button type="primary" @click="register" style="width: 30%">立即注册</el-button>
+                <el-button type="primary" @click="register" style="width: 30%" v-if="isShow">立即注册</el-button>
               </el-row>
               </el-row>
             </el-form>
             </el-form>
 
 
@@ -344,6 +344,7 @@
         }
         }
       }
       }
       return {
       return {
+        isShow: true,
         activeIndex: '1',
         activeIndex: '1',
         waituploads: [], // 等待上传的文件列表
         waituploads: [], // 等待上传的文件列表
         limitNumb: 2, // 文件上传限制数
         limitNumb: 2, // 文件上传限制数
@@ -601,7 +602,7 @@
             _this.formData.CheckUnitId = this.auditorg
             _this.formData.CheckUnitId = this.auditorg
             _this.formData.CheckUnitName = _this.$refs.auditorgselect.selectedLabel
             _this.formData.CheckUnitName = _this.$refs.auditorgselect.selectedLabel
             // 添加注册信息
             // 添加注册信息
-            console.log(_this.formData)
+            _this.isShow = false
             _this.$axios.post('/register/addentity', _this.formData)
             _this.$axios.post('/register/addentity', _this.formData)
               .then(function (response) {
               .then(function (response) {
                 if (response.data.code === 0) {
                 if (response.data.code === 0) {
@@ -615,12 +616,14 @@
                   })
                   })
                   _this.$router.push('/login') // 跳转到登录页
                   _this.$router.push('/login') // 跳转到登录页
                 } else {
                 } else {
+                  _this.isShow = true
                   _this.$alert(response.data.message, '提示', {
                   _this.$alert(response.data.message, '提示', {
                     confirmButtonText: '确定'
                     confirmButtonText: '确定'
                   })
                   })
                 }
                 }
               })
               })
               .catch(function (error) {
               .catch(function (error) {
+                _this.isShow = true
                 console.log(error)
                 console.log(error)
               })
               })
           }
           }