From 48adbb5e7759f33efb0a97c8baf22aaebba7987a Mon Sep 17 00:00:00 2001
From: yangfeng <wanwan926_4@163.com>
Date: 星期三, 25 十月 2023 17:30:58 +0800
Subject: [PATCH] 销售明细单、销售退货单选择产品逻辑修改及新增字段
---
src/views/sales/refundForm/AddRefundFormDialog.vue | 42 ++++++++++++++++++++++++++----------------
1 files changed, 26 insertions(+), 16 deletions(-)
diff --git a/src/views/sales/refundForm/AddRefundFormDialog.vue b/src/views/sales/refundForm/AddRefundFormDialog.vue
index 0402e2c..5736232 100644
--- a/src/views/sales/refundForm/AddRefundFormDialog.vue
+++ b/src/views/sales/refundForm/AddRefundFormDialog.vue
@@ -312,10 +312,10 @@
import { getAddSalesRefund, getUpdateSalesRefund } from "@/api/sales/refundForm"
import SelectClientDialog from "@/views/other/commonDialog/SelectClientDialog"
import SelectCommonDialog from "@/views/other/commonDialog/SelectCommonDialog"
-import { getPaymentTypeList } from "@/api/common/payment"
+import {getBankAccountList, getPaymentTypeList} from "@/api/common/payment"
import codeMixin from "@/views/client/followupRecords/mixin/codeMixin"
import { getSalesReturnList } from "@/api/sales/salesReturn"
-import { mapActions } from 'vuex';
+import { mapActions } from "vuex"
export default {
name: "AddRefundFormDialog",
@@ -375,7 +375,7 @@
editVisible: false,
title: "",
infomation: {},
- clientId:""
+ clientId: ""
},
clientId: this.editCommonConfig.infomation.client_id,
sourceId: this.editCommonConfig.infomation.sourceId,
@@ -401,8 +401,8 @@
this.formInfo()
}
},
- methods: {
- ...mapActions(["getReturnListFliter"]),
+ methods: {
+ ...mapActions(["getReturnListFliter"]),
formInfo() {
this.objCode.type = "閿�鍞��娆剧紪鐮�"
this.objCode.codeStandID = ""
@@ -410,24 +410,35 @@
this.objCode.codeStandID = this.editConfig.infomation.codeStandID
}
this.getRCodeStandardList()
+ this.getBankAccountList()
},
getCommonData() {
getAllData().then((res) => {
this.memberOptions = res.data.member
- this.accountOptions = res.data.accountId
+ // this.accountOptions = res.data.accountId
})
this.getPaymentTypeList()
},
async getPaymentTypeList() {
await getPaymentTypeList().then((res) => {
- if (res.data.code === 200) {
- this.paymentTypeListOptions = res.data.data.data
+ if (res.code === 200) {
+ this.paymentTypeListOptions = res.data.data ?? []
+ }
+ })
+ },
+ async getBankAccountList() {
+ await getBankAccountList().then((res) => {
+ console.log("璐︽埛")
+ console.log('璐︽埛',res)
+ if (res.code === 200) {
+ this.accountOptions = res.data.data
}
})
},
// 淇濆瓨
saveClick(formName) {
this.$refs[formName].validate((valid) => {
+ this.validateFormNumber()
if (valid) {
console.log(this.editConfig.infomation)
for (let i = 0; i < this.tableData.length; i++) {
@@ -484,9 +495,9 @@
reason: data.reason || "",
refundDate: data.refundDate || "",
sourceId: this.sourceId || 0,
- sourceType: 1
- },
- codeRule: this.codeRule
+ sourceType: 1,
+ codeRule: this.codeRule
+ }
}
return params
},
@@ -516,14 +527,13 @@
async handleSelectClient(value, item) {
if (value === "client") {
this.clientId = item.id
- this.editSelCommonConfig.clientId=item.id
- console.log("瀹㈡埛鍚嶇О",this.clientId,value,item)
+ this.editSelCommonConfig.clientId = item.id
+ console.log("瀹㈡埛鍚嶇О", this.clientId, value, item)
await getSalesReturnList({
- clientId:this.clientId
- }).then((res)=>{
+ clientId: this.clientId
+ }).then((res) => {
this.getReturnListFliter(res.data.list)
})
-
} else if (value === "salesReturn") {
console.log(item)
this.editConfig.infomation.sale_return_nunber = item.number
--
Gitblit v1.8.0