Browse Source

企业用户增项bug修改

huahaiyan 6 years ago
parent
commit
ea903db56c

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

@@ -104,7 +104,7 @@ func (this *OilSupplierCertAppendController) GetList() {
 	}
 	}
 	//企业用户必须加创建人条件
 	//企业用户必须加创建人条件
 	if this.User.IsCompanyUser == 1 {
 	if this.User.IsCompanyUser == 1 {
-		where = where + " and a.CreateUserId = '" + this.User.Id + "'"
+		where = where + " and CreateUserId = '" + this.User.Id + "'"
 	} else {
 	} else {
 		//超级管理员和有查看所有数据权限的用户不加条件
 		//超级管理员和有查看所有数据权限的用户不加条件
 		svcPerm := permission.GetPermissionService(utils.DBE)
 		svcPerm := permission.GetPermissionService(utils.DBE)

+ 6 - 5
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/basisdataopera.vue

@@ -344,7 +344,8 @@
         entrydetail: {
         entrydetail: {
           process: "",
           process: "",
           business: "",
           business: "",
-          instance: ""
+          instance: "",
+          Status: '',
         },
         },
         SupplierId: 0,
         SupplierId: 0,
         SupplierTypeCode: '',
         SupplierTypeCode: '',
@@ -553,7 +554,6 @@
             _this.subfileList = res.data.items
             _this.subfileList = res.data.items
             _this.currentItemCount = res.data.currentItemCount
             _this.currentItemCount = res.data.currentItemCount
             for (let idx in _this.subfileList) {
             for (let idx in _this.subfileList) {
-              console.log(_this.subfileList[idx])
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
             }
             }
           })
           })
@@ -784,8 +784,10 @@
         let _this = this
         let _this = this
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
           _this.formData = res.data
           _this.formData = res.data
-          this.backhistroy.certId = _this.Id
-          this.backhistroy.workflowId = _this.formData.WorkFlowId
+          this.entrydetail.process = this.formData.ProcessKey
+          this.entrydetail.business = this.formData.BusinessKey
+          this.entrydetail.instance = this.formData.WorkFlowId;
+          this.entrydetail.Status = this.formData.Status
           this.getFileList()
           this.getFileList()
           //显示公司名
           //显示公司名
           _this.supplierOptions = _this.formData.SupplierId.toString()
           _this.supplierOptions = _this.formData.SupplierId.toString()
@@ -872,7 +874,6 @@
         //访问接口
         //访问接口
         api.getMyList(params, this.$axios).then(res => {
         api.getMyList(params, this.$axios).then(res => {
           this.myentityList = res.data.item
           this.myentityList = res.data.item
-          console.log("------res.entityList==--", this.entityList)
           // this.currentItemCount = res.data.currentItemCount
           // this.currentItemCount = res.data.currentItemCount
         }).catch(err => {
         }).catch(err => {
           console.error(err)
           console.error(err)

+ 3 - 8
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/goodsdataopera.vue

@@ -363,7 +363,8 @@
         entrydetail: {
         entrydetail: {
           process: "",
           process: "",
           business: "",
           business: "",
-          instance: ""
+          instance: "",
+          Status: '',
         },
         },
         auditform: {
         auditform: {
           FirstAuditName: '',
           FirstAuditName: '',
@@ -644,10 +645,10 @@
         let _this = this
         let _this = this
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
           _this.formData = res.data
           _this.formData = res.data
-          console.log("---this.formData---", _this.formData)
           this.entrydetail.process = this.formData.ProcessKey
           this.entrydetail.process = this.formData.ProcessKey
           this.entrydetail.business = this.formData.BusinessKey
           this.entrydetail.business = this.formData.BusinessKey
           this.entrydetail.instance = this.formData.WorkFlowId;
           this.entrydetail.instance = this.formData.WorkFlowId;
+          this.entrydetail.Status = this.formData.Status
           this.getFileList()
           this.getFileList()
           //显示公司名
           //显示公司名
           _this.supplierOptions = _this.formData.SupplierId.toString()
           _this.supplierOptions = _this.formData.SupplierId.toString()
@@ -673,10 +674,8 @@
           })
           })
           .then(res => {
           .then(res => {
             _this.subfileList = res.data.items
             _this.subfileList = res.data.items
-            console.log("---this.subfileList---", this.subfileList)
             _this.currentItemCount = res.data.currentItemCount
             _this.currentItemCount = res.data.currentItemCount
             for (let idx in _this.subfileList) {
             for (let idx in _this.subfileList) {
-              console.log(_this.subfileList[idx])
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
             }
             }
           })
           })
@@ -887,7 +886,6 @@
         //访问接口
         //访问接口
         api.getList(params, this.$axios).then(res => {
         api.getList(params, this.$axios).then(res => {
           this.entityList = res.data.item
           this.entityList = res.data.item
-          console.log("------res.entityList==--", this.entityList)
           // this.currentItemCount = res.data.currentItemCount
           // this.currentItemCount = res.data.currentItemCount
         }).catch(err => {
         }).catch(err => {
           console.error(err)
           console.error(err)
@@ -909,7 +907,6 @@
         //访问接口
         //访问接口
         api.getMyList(params, this.$axios).then(res => {
         api.getMyList(params, this.$axios).then(res => {
           this.myentityList = res.data.item
           this.myentityList = res.data.item
-          console.log("------res.entityList==--", this.entityList)
           // this.currentItemCount = res.data.currentItemCount
           // this.currentItemCount = res.data.currentItemCount
         }).catch(err => {
         }).catch(err => {
           console.error(err)
           console.error(err)
@@ -1077,7 +1074,6 @@
           })
           })
           return
           return
         }
         }
-        console.log("parmas", params)
         _this.$axios.post('/suppliercertappendsub/addgoodsbus/', params)
         _this.$axios.post('/suppliercertappendsub/addgoodsbus/', params)
           .then(res => {
           .then(res => {
             if (res.data.code === 0) {
             if (res.data.code === 0) {
@@ -1196,7 +1192,6 @@
         this.auditform.CertId = this.formData.Id
         this.auditform.CertId = this.formData.Id
         this.auditform.SecondAudit = this.fushenauditer
         this.auditform.SecondAudit = this.fushenauditer
         this.auditform.ThirdAudit = this.majorDept[this.majorDept.length - 1]
         this.auditform.ThirdAudit = this.majorDept[this.majorDept.length - 1]
-        console.log("---this.auditform---", this.auditform)
         api2.auditEntity(this.formData.Id, this.auditform, this.$axios).then(res => {
         api2.auditEntity(this.formData.Id, this.auditform, this.$axios).then(res => {
           if (res.data.code === 0) {
           if (res.data.code === 0) {
             // 保存成功后,初始化数据,变成修改
             // 保存成功后,初始化数据,变成修改

+ 3 - 8
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/techdataopera.vue

@@ -323,7 +323,8 @@
         entrydetail: {
         entrydetail: {
           process: "",
           process: "",
           business: "",
           business: "",
-          instance: ""
+          instance: "",
+          Status: '',
         },
         },
         auditform: {
         auditform: {
           FirstAuditName: '',
           FirstAuditName: '',
@@ -505,7 +506,6 @@
         _this.$axios.get('/suppliercertappend/getsupplier/' + '03', {})
         _this.$axios.get('/suppliercertappend/getsupplier/' + '03', {})
           .then(res => {
           .then(res => {
             _this.supplierList = res.data
             _this.supplierList = res.data
-            console.log("-_this.supplierList---",_this.supplierList)
           })
           })
           .catch(err => {
           .catch(err => {
             console.error(err)
             console.error(err)
@@ -574,10 +574,10 @@
         let _this = this
         let _this = this
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
         api2.getEntityById(_this.Id, _this.$axios).then(res => {
           _this.formData = res.data
           _this.formData = res.data
-          console.log("---this.formData---", _this.formData)
           this.entrydetail.process = this.formData.ProcessKey
           this.entrydetail.process = this.formData.ProcessKey
           this.entrydetail.business = this.formData.BusinessKey
           this.entrydetail.business = this.formData.BusinessKey
           this.entrydetail.instance = this.formData.WorkFlowId;
           this.entrydetail.instance = this.formData.WorkFlowId;
+          this.entrydetail.Status = this.formData.Status
           this.getFileList()
           this.getFileList()
           //显示公司名
           //显示公司名
           _this.supplierOptions = _this.formData.SupplierId.toString()
           _this.supplierOptions = _this.formData.SupplierId.toString()
@@ -603,10 +603,8 @@
           })
           })
           .then(res => {
           .then(res => {
             _this.subfileList = res.data.items
             _this.subfileList = res.data.items
-            console.log("---this.subfileList---", this.subfileList)
             _this.currentItemCount = res.data.currentItemCount
             _this.currentItemCount = res.data.currentItemCount
             for (let idx in _this.subfileList) {
             for (let idx in _this.subfileList) {
-              console.log(_this.subfileList[idx])
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
               _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
             }
             }
           })
           })
@@ -815,7 +813,6 @@
         //访问接口
         //访问接口
         api.getList(params, this.$axios).then(res => {
         api.getList(params, this.$axios).then(res => {
           this.entityList = res.data.item
           this.entityList = res.data.item
-          console.log("------res.entityList==--", this.entityList)
           // this.currentItemCount = res.data.currentItemCount
           // this.currentItemCount = res.data.currentItemCount
         }).catch(err => {
         }).catch(err => {
           console.error(err)
           console.error(err)
@@ -837,7 +834,6 @@
         //访问接口
         //访问接口
         api.getMyList(params, this.$axios).then(res => {
         api.getMyList(params, this.$axios).then(res => {
           this.myentityList = res.data.item
           this.myentityList = res.data.item
-          console.log("------res.entityList==--", this.entityList)
           // this.currentItemCount = res.data.currentItemCount
           // this.currentItemCount = res.data.currentItemCount
         }).catch(err => {
         }).catch(err => {
           console.error(err)
           console.error(err)
@@ -1051,7 +1047,6 @@
         this.auditform.CertId = this.formData.Id
         this.auditform.CertId = this.formData.Id
         this.auditform.SecondAudit = this.fushenauditer
         this.auditform.SecondAudit = this.fushenauditer
         this.auditform.ThirdAudit = this.majorDept[this.majorDept.length - 1]
         this.auditform.ThirdAudit = this.majorDept[this.majorDept.length - 1]
-        console.log("---this.auditform---", this.auditform)
         api2.auditEntity(this.formData.Id, this.auditform, this.$axios).then(res => {
         api2.auditEntity(this.formData.Id, this.auditform, this.$axios).then(res => {
           if (res.data.code === 0) {
           if (res.data.code === 0) {
             // 保存成功后,初始化数据,变成修改
             // 保存成功后,初始化数据,变成修改

+ 3 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/basislist.vue

@@ -297,6 +297,7 @@
       addappendcom() {
       addappendcom() {
         let _this = this
         let _this = this
         _this.appendformData.AppendType = '02'
         _this.appendformData.AppendType = '02'
+        console.log("----this.appendformData--",this.appendformData)
         _this.$axios.post('/suppliercertappend/addappend/', _this.appendformData)
         _this.$axios.post('/suppliercertappend/addappend/', _this.appendformData)
           .then(res => {
           .then(res => {
             if (res.data.code === 0) {
             if (res.data.code === 0) {
@@ -334,8 +335,8 @@
             _this.supplierList = res.data
             _this.supplierList = res.data
             if (_this.supplierList) {
             if (_this.supplierList) {
               _this.suplen = _this.supplierList.length
               _this.suplen = _this.supplierList.length
-              _this.appendformData.SupplierId = _this.supplierList[0].SupplierId
-              _this.appendformData.SupplierCertId = _this.supplierList[0].SupplierCertId
+              _this.appendformData.SupplierId = parseInt(_this.supplierList[0].SupplierId)
+              _this.appendformData.SupplierCertId = parseInt(_this.supplierList[0].SupplierCertId)
               _this.appendformData.SupplierName = _this.supplierList[0].SupplierName
               _this.appendformData.SupplierName = _this.supplierList[0].SupplierName
             }
             }
           })
           })