Commit 619f156d authored by GuanHua's avatar GuanHua

feat:修改新增采购单需要的物流字段

parent 6cf27540
...@@ -49,7 +49,7 @@ const Address: React.FC<AddressPropsType> = (props) => { ...@@ -49,7 +49,7 @@ const Address: React.FC<AddressPropsType> = (props) => {
if (selectItem) { if (selectItem) {
setSelectKey(selectItem.id) setSelectKey(selectItem.id)
let res = await PublicApi.getLogisticsReceiverAddressGet({ id: selectItem.id }) let res = await PublicApi.getLogisticsReceiverAddressGet({ id: selectItem.id })
onChange(res.data) onChange(Object.assign(selectItem, res.data))
} }
} }
...@@ -63,7 +63,7 @@ const Address: React.FC<AddressPropsType> = (props) => { ...@@ -63,7 +63,7 @@ const Address: React.FC<AddressPropsType> = (props) => {
} }
if (selectItem) { if (selectItem) {
let res = await PublicApi.getLogisticsReceiverAddressGet({ id: selectItem.id }) let res = await PublicApi.getLogisticsReceiverAddressGet({ id: selectItem.id })
onChange(res.data) onChange(Object.assign(selectItem, res.data))
} }
} }
......
...@@ -42,7 +42,7 @@ const Order: React.FC<OrderPropsType> = (props) => { ...@@ -42,7 +42,7 @@ const Order: React.FC<OrderPropsType> = (props) => {
const [orderList, setOrderList] = useState<any>() const [orderList, setOrderList] = useState<any>()
const [needTheInvoice, setNeedTheInvoice] = useState<boolean>(false) const [needTheInvoice, setNeedTheInvoice] = useState<boolean>(false)
const [needTheContract, setneedTheContract] = useState<boolean>(false) const [needTheContract, setneedTheContract] = useState<boolean>(false)
const [selectAddressInfo, setSelectAddressInfo] = useState<GetLogisticsReceiverAddressGetResponse>() const [selectAddressInfo, setSelectAddressInfo] = useState<any>()
const [selectInvoiceInfo, setSelectInvoiceInfo] = useState<any>() const [selectInvoiceInfo, setSelectInvoiceInfo] = useState<any>()
const [logisticsFee, setLogisticsFee] = useState<number>(0) const [logisticsFee, setLogisticsFee] = useState<number>(0)
const [isElectronicContract, setIsElectronicContract] = useState<boolean>(false) // 是否选用电子合同 const [isElectronicContract, setIsElectronicContract] = useState<boolean>(false) // 是否选用电子合同
...@@ -253,13 +253,14 @@ const Order: React.FC<OrderPropsType> = (props) => { ...@@ -253,13 +253,14 @@ const Order: React.FC<OrderPropsType> = (props) => {
if (orderInfo.logistics.deliveryType === 1 && !!selectAddressInfo) { if (orderInfo.logistics.deliveryType === 1 && !!selectAddressInfo) {
params.deliveryAddresId = selectAddressInfo.id params.deliveryAddresId = selectAddressInfo.id
params.addresName = selectAddressInfo.receiverName params.receiverName = selectAddressInfo.receiverName
params.isDefault = selectAddressInfo.isDefault params.isDefault = selectAddressInfo.isDefault
params.province = selectAddressInfo.provinceName params.fullAddress = selectAddressInfo.fullAddress
params.city = selectAddressInfo.cityName params.phone = selectAddressInfo.phone
params.area = selectAddressInfo.districtName // params.province = selectAddressInfo.provinceName
params.addres = selectAddressInfo.address // params.city = selectAddressInfo.cityName
params.tel = selectAddressInfo.phone // params.area = selectAddressInfo.districtName
// params.addres = selectAddressInfo.address
} }
let orderProductRequests = [] let orderProductRequests = []
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment