From 0729debb4fc94680471f598a615b8655904f28ac Mon Sep 17 00:00:00 2001
From: guoxing <1369478551@qq.com>
Date: Fri, 2 Jun 2023 16:54:27 +0800
Subject: [PATCH] 2023-6-2
---
.../yxt-supervise-cyf-ui/.env.development | 2 +-
.../src/api/oilTypeProcure/oilTypeProcure.js | 4 +-
.../views/business/oilTypeProcure/index.vue | 35 ++--
.../oilTypeProcure/oilTypeProcureAdd.vue | 10 +-
.../oilTypeProcure/oilTypeProcureInfo.vue | 195 ++++++++++--------
5 files changed, 131 insertions(+), 115 deletions(-)
diff --git a/yxt-supervise-cyf/yxt-supervise-cyf-ui/.env.development b/yxt-supervise-cyf/yxt-supervise-cyf-ui/.env.development
index 70aafd96..c17cca5d 100644
--- a/yxt-supervise-cyf/yxt-supervise-cyf-ui/.env.development
+++ b/yxt-supervise-cyf/yxt-supervise-cyf-ui/.env.development
@@ -6,7 +6,7 @@ VUE_APP_BASE_API = '/api'
## 配置测试和本地开发时的 接口地址
## VUE_APP_URL = "http://cg9jzr.natappfree.cc"
-## VUE_APP_URL = "http://192.168.1.177:7101"
+##VUE_APP_URL = "http://192.168.1.177:7101"
VUE_APP_URL = "http://192.168.1.193:7101"
diff --git a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/api/oilTypeProcure/oilTypeProcure.js b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/api/oilTypeProcure/oilTypeProcure.js
index aa0b1ef9..c5f7e84a 100644
--- a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/api/oilTypeProcure/oilTypeProcure.js
+++ b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/api/oilTypeProcure/oilTypeProcure.js
@@ -35,7 +35,7 @@ export default {
// 修改
procureUpdateData: function(data) {
return request({
- url: '/v1/warehouselocation/update',
+ url: '/cyf/procurement//update',
method: 'post',
data: data
});
@@ -49,7 +49,7 @@ export default {
})
},
- // 新增提交
+ // 提交
procureAddSubmitInfo: function(data) {
return request({
url: '/cyf/procurement/submit',
diff --git a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/index.vue b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/index.vue
index 541bedfc..fdd09231 100644
--- a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/index.vue
+++ b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/index.vue
@@ -20,8 +20,8 @@
-
-
+
@@ -36,7 +36,7 @@
-
+
详情
-
-
-
-
-
-
-
+
+
+
+
@@ -178,9 +175,9 @@
params: {
orderNumber: '',
date: '',
- tradeName: '',
+ supplierName: '',
type: '1', // 原油1 包装物2 原料3
- state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
+ // state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
},
total: 0
},
@@ -192,9 +189,9 @@
params: {
orderNumber: '',
date: '',
- tradeName: '',
+ supplierName: '',
type: '1', // 原油1 包装物2 原料3
- state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
+ // state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
},
total: 0
},
@@ -330,7 +327,7 @@
tradeName: '',
date: "",
type: '1',
- state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
+ // state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
}
}
this.loadLogList()
@@ -352,7 +349,7 @@
tradeName: '',
date: "",
type: '1',
- state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
+ // state: "1", // 1待提交 2经理 3监管 4银行 5财务 6待入库 7已办结
}
}
this.loadIn112List()
@@ -404,7 +401,7 @@
}
})
}
-
+
if ("1" == this.index) {
req.procureDelBySids(row.sid).then((response) => {
if (response.success) {
@@ -428,7 +425,7 @@
},
toDetail(row) {
this.viewState = 4
- this.$refs['divInfo'].showAdd(row.sid)
+ this.$refs['divInfo'].showAdd(row)
},
resetState() {
this.viewState = 1
@@ -442,4 +439,4 @@
}
\ No newline at end of file
+
diff --git a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureAdd.vue b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureAdd.vue
index 1c708396..9399d3a9 100644
--- a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureAdd.vue
+++ b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureAdd.vue
@@ -85,15 +85,15 @@
删除
-
+
-
-
+
@@ -323,8 +323,8 @@
console.log(">>>>>>>>>getType", index)
const choose = this.crudeLists.filter((item) => item.sid === value)
console.log(">>>>>>>>>getType", choose[0])
- this.formobj.commodityList[index].crudeNumber = choose[0].number
- this.formobj.commodityList[index].crudeName = choose[0].name
+ this.formobj.commodityList[index].number = choose[0].number
+ this.formobj.commodityList[index].name = choose[0].name
this.formobj.commodityList[index].sid = value
},
diff --git a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureInfo.vue b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureInfo.vue
index c53f0c45..4305a65f 100644
--- a/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureInfo.vue
+++ b/yxt-supervise-cyf/yxt-supervise-cyf-ui/src/views/business/oilTypeProcure/oilTypeProcureInfo.vue
@@ -2,128 +2,93 @@
-
+
采购信息
- 库房位置
+ 合同编号
- {{temp.address}}
-
-
-
-
- 省-市-县
-
-
-
-
- {{temp.province}} - {{temp.city}} - {{temp.county}}
-
-
-
-
-
-
- 库房面积
-
-
-
-
- {{temp.squareMeasure}}
-
-
-
-
- 库房层高
-
-
-
-
- {{temp.floorHeight}}
-
-
-
-
-
-
- 库房价格
-
-
-
-
- {{temp.price}}
-
-
-
-
- 库房性质
-
-
-
-
- {{temp.properties}}
-
-
-
-
-
-
- 房源
-
-
-
-
- {{temp.housingResources}}
+ {{formobj.orderNumber}}
+
- 备注
+ 合同日期
- {{temp.remarks}}
+ {{formobj.contractSigningDate}}
+
- 联系人
+ 供货商名称
- {{temp.contacts}}
+ {{formobj.supplierName}}
+
- 联系电话
+ 到货日期
- {{temp.telephone}}
+ {{formobj.arrivalDate}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -136,31 +101,85 @@
import req from '@/api/oilTypeProcure/oilTypeProcure'
export default {
- name: 'CustomerManagementInfo',
data() {
return {
- temp: {} // 添加和修改
+ submitdisabled: false,
+ listLoading: false,
+ activeNames: ['1'],
+ formobj: {
+ sid: "",
+ orderNumber: "",
+ contractSigningDate: "",
+ arrivalDate: "",
+ supplierSid: "",
+ supplierName: "",
+ commodityList: [],
+ }
}
},
+ methods: {
+ submitData() {
+ console.log(">>>>>>>>>submit", this.formobj)
+ if (this.formobj.state = 5) {
+ // 财务审批 需要填数据
+
+ } else {
+ // 财务之前 直接提交
+ req.procureAddSubmitInfo(this.formobj)
+ .then(resp => {
+ if (resp.success) {
+ this.$message({
+ showClose: true,
+ type: 'success',
+ message: resp.msg
+ })
+ this.handleReturn("true")
+ } else {
+ // 根据resp.code进行异常情况处理
+ }
+ })
+ .catch(() => {})
+ }
- methods: {
- showAdd(sid) {
- req.fetchBySid(sid)
+
+ },
+ handleReturn(isreload) {
+ console.log(">>>>>>>>>")
+ if (isreload === 'true') this.$emit('reloadlist')
+
+ this.$emit('doback')
+ this.formobj = {
+ sid: "",
+ orderNumber: "",
+ contractSigningDate: "",
+ arrivalDate: "",
+ supplierSid: "",
+ supplierName: "",
+ commodityList: [],
+ }
+
+ },
+ showAdd(row) {
+ console.log(">>>>>>>>>", row)
+ req.procureFetchBySid(row.sid)
.then(resp => {
if (resp.success) {
- this.temp = resp.data
+ this.formobj = resp.data
}
})
.catch(e => {
- this.$emit('doback')
+ this.formobj = row
})
},
- // 组件返回
- handleReturn() {
- this.$emit('doback')
- }
+ // 序号
+ indexMethod(index) {
+ // var pagestart = (this.listQuery.current - 1) * this.listQuery.size
+ // var pageindex = index + 1 + pagestart
+ return index + 1
+ },
+
}
}