Commit 2aadb374 authored by chen's avatar chen

feat: 开发报价单详情页面

parent d291771a
......@@ -315,6 +315,16 @@ export default {
'order.inquiry.index.externalStatusConfirm': '待确认报价',
'order.inquiry.index.externalStatusOk': '接受报价',
'order.inquiry.index.externalStatusNoOk': '不接受报价',
'order.inquiry.details.baseInfo.title': '基本信息',
'order.inquiry.details.baseInfo.no': '报价单号',
'order.inquiry.details.baseInfo.correspondingNo': '对应询价单',
'order.inquiry.details.baseInfo.memberName': '报价会员',
'order.inquiry.details.baseInfo.makes': '报价单摘要',
'order.inquiry.details.baseInfo.enTime': '报价截止时间',
'order.inquiry.details.condition.title': '交易条件',
'order.inquiry.details.condition.time': '交付时间',
'order.inquiry.details.condition.address': '交付地址',
'order.inquiry.details.condition.endTime': '报价截止时间',
// 订单FilterBar
'order.filterBar.Delivery': '交付时间',
......
......@@ -32,6 +32,7 @@ import EnsureInquiryOrder from '../views/EnsureInquiryOrder';
import CheckQuotationOrder from '../views/CheckQuotationOrder';
import StatusLayout from '../views/StatusLayout';
import CheckQuotationOrderDetail from '../views/CheckQuotationOrder/pages/CheckQuotationOrderDetail';
import EnsureInquiryDetails from '../views/EnsureInquiryOrder/EnsureInquiryDetails';
export const ROUTERS = {
Login: {
......@@ -148,12 +149,18 @@ export const ROUTERS = {
headerShown: false,
},
// 确认询价单
// 确认询价单报价单
EnsureInquiryOrder: {
title: '确认询价报价单',
component: EnsureInquiryOrder,
headerShown: false,
},
// 确认询价报价单-详情
EnsureInquiryDetails: {
title: '报价单详情',
component: EnsureInquiryDetails,
headerShown: false,
},
ContractDetails: {
title: '合同详情',
......
......@@ -349,8 +349,50 @@ const StaySubmit = (props: Iprops) => {
// useEffect(() => {
// }, [dataSource])
// 定义 基本信息 展示字段
const basicInfoList = [
{ title: t('order.inquiry.details.baseInfo.no', '报价单号'), value: dataSource?.inquiryListNo, hasCopy: true },
{ title: t('order.inquiry.details.baseInfo.correspondingNo', '对应询价单'), value: dataSource?.inquiryListNo},
{ title: t('order.inquiry.details.baseInfo.memberName', '报价会员'), value: dataSource?.inquiryListNo},
{ title: t('order.inquiry.details.baseInfo.makes', '报价单摘要'), value: dataSource?.inquiryListNo},
{ title: t('order.inquiry.details.baseInfo.enTime', '报价截止时间'), value: dataSource?.inquiryListNo},
];
// 定义 交易添加 展示字段
const transactionConditionsList = [
{ title: t('order.inquiry.details.baseInfo.time', '交付时间'), value: dataSource?.inquiryListNo, hasCopy: true },
{ title: t('order.inquiry.details.condition.address', '交付地址'), value: dataSource?.inquiryListNo},
{ title: t('order.inquiry.details.condition.endTime', '报价截止时间'), value: dataSource?.inquiryListNo},
];
const renderCommonList = (item: any, index: number) => (
<View
style={myStyle.CellIem}
// onPress={() => (item.fn ? item.fn() : {})}
key={`${item.title}_${index}`}
>
<Text style={myStyle.CellName}>{t(item.title)}</Text>
<View style={{ flexDirection: 'row' }}>
<Text style={myStyle.CellText} numberOfLines={1}>
{item.value}
</Text>
{item.hasCopy && (
<Text
style={[myStyle.addressName, { marginLeft: 10 }]}
onPress={() => handleCopy(item.value)}
>
{t('order.btn.copy')}
</Text>
)}
</View>
</View>
)
return (
<View style={{ flexDirection: 'column', paddingHorizontal: 10 }}>
{/* 头部信息 */}
{(outerStatus === 6 || outerStatus === 8) && (
<View style={{ ...myStyle.cell, marginBottom: 40 }}>
<TouchableOpacity
......@@ -358,7 +400,7 @@ const StaySubmit = (props: Iprops) => {
onPress={() => !!dataSource.payTimes && goJump('PayList', { orderId: dataSource.orderId })}
>
<Text style={myStyle.HeadCellText}>
{t('order.detailInfo.pay')}
{t('order.detailInfo.pay', '支付信息')}
{/* {!!dataSource.payTimes && `(${t('order.other.d')}${dataSource.payTag}/${dataSource.payTimes})`} */}
</Text>
<TouchableOpacity>
......@@ -371,10 +413,10 @@ const StaySubmit = (props: Iprops) => {
<View
style={{ ...myStyle.CellIem, justifyContent: 'flex-start', alignItems: 'flex-end' }}
>
<Text style={myStyle.CellName}>{t('order.detailInfo.needPay')}</Text>
<Text style={myStyle.CellName}>{t('order.detailInfo.needPay', '需付款')}</Text>
<Text style={{ ...myStyle.CellText }}>
{!(dataSource?.orderMode === 10 || dataSource?.orderMode === 11) && (
<Text style={cStyle.Color}>{t('order:orderList.orderItem.unit$')}</Text>
<Text style={cStyle.Color}>{t('order:orderList.orderItem.unit$', '¥')}</Text>
)}
<Text
style={[
......@@ -398,7 +440,7 @@ const StaySubmit = (props: Iprops) => {
]}
>
{dataSource?.orderMode === 10 || dataSource?.orderMode === 11
? `${totalAmount?.split('.')[1]}${t('order.other.integral')}`
? `${totalAmount?.split('.')[1]}${t('order.other.integral', '积分')}`
: totalAmount?.split('.')[1]}
</Text>
</Text>
......@@ -406,14 +448,14 @@ const StaySubmit = (props: Iprops) => {
{!noBtn && (
<TouchableOpacity style={myStyle.CellIem} onPress={() => fnClosePayType?.()}>
<View style={myStyle.payBtn}>
<Text style={{ color: '#fff', fontSize: 12 }}>{t('order.detail.toPay')}</Text>
<Text style={{ color: '#fff', fontSize: 12 }}>{t('order.detail.toPay', '去支付')}</Text>
</View>
</TouchableOpacity>
)}
</View>
)}
{/* 地址 */}
{/* {!!dataSource?.areaName && ( */}
{
orderOperation == 2 ? <View style={[myStyle.address, { flexDirection: 'row', alignItems: 'center' }]}>
{/* <SvgXml xml={MapIcon} width={15} height={15} /> */}
......@@ -438,64 +480,47 @@ const StaySubmit = (props: Iprops) => {
{dataSource?.orderNo}
</Text>
<Text style={[myStyle.addressName]} onPress={() => handleCopy(dataSource?.orderNo)}>
{t('order.btn.copy')}
{t('order.btn.copy', '复制')}
</Text>
</View>
<Text style={myStyle.addressText}>
{t('order.info.buyer')}
{t('order.info.buyer', '采购商')}
{' : '}
{dataSource?.vendorMemberName}
</Text>
<Text style={myStyle.addressText}>
{t('order.info.orderFrom')}
{t('order.info.orderFrom', '订单类型')}
{' : '}
{dataSource?.orderModeName}
</Text>
<Text style={myStyle.addressText}>
{t('order.status.inner', '内部状态')}
{' : '}
{dataSource?.innerStatusName}
</Text>
</View>
</View>
}
{/* )} */}
{/* 拼团 */}
{/* {
countdown?.status === 1 && (
<View style={myStyle.Collage}>
<View style={myStyle.CollageBox}>
<View style={{ justifyContent: 'center', marginBottom: 5, position: 'relative' }}>
{
countdown.itemList.map((item: any) => (
<Image source={{ uri: item.logo }} style={myStyle.CollageImg} width={34} height={34} />
))
}
</View>
<View style={{ justifyContent: 'center' }}>
{CountDom()}
</View>
</View>
{
flag && (
<View style={myStyle.CollageBtn} onPress={() => share && share(countdown)}>
<Text style={myStyle.CollageBtntext}>{i18n.t('stockSellStorage:stockSellStorage.yaoqinghaoyou')}</Text>
</View>
)
}
</View>
)
} */}
{/* 失败和成功 */}
{
(dataSource.promotionStatus === 3 || dataSource.promotionStatus === 4) && (
<View style={[myStyle.Collage, { paddingVertical: 10 }]}>
(dataSource.Status === 3 || dataSource.promotionStatus === 4) && (
<View style={[myStyle.Collage, { paddingVertical: 10 }]}>promotion
<View style={myStyle.CollageItem}>
<View style={myStyle.CollageItem}>
<Image source={{ uri: (dataSource.promotionStatus === 4) ? urisuss : urierr }} style={myStyle.CollageImg} width={24} height={24} />
<Text style={{ fontSize: 12 }}>{(dataSource.promotionStatus === 4) ? i18n.t('stockSellStorage:stockSellStorage.gongxi') : i18n.t('stockSellStorage:stockSellStorage.yihang')}</Text>
<Image source={{ uri: (dataSource.promotionStatus === 4) ? urisuss : urierr }} style={{...myStyle.CollageImg, width: 24, height: 24}} />
<Text style={{ fontSize: 12 }}>
{
(dataSource?.promotionStatus === 4) ? t('stockSellStorage:stockSellStorage.gongxi')
: t('stockSellStorage:stockSellStorage.yihang')
}
</Text>
</View>
{dataSource.promotionStatus !== 3 && (
<View style={{ justifyContent: 'center', marginBottom: 5, position: 'relative' }}>
{
countdown.itemList.map((item: any) => (
<Image source={{ uri: item.logo }} style={myStyle.CollageImg} width={32} height={32} />
<Image source={{ uri: item.logo }} style={{...myStyle.CollageImg, width: 32, height: 32}}/>
))
}
<View style={myStyle.tag}>
......@@ -507,6 +532,7 @@ const StaySubmit = (props: Iprops) => {
</View>
)
}
{/* 0818需求:增加显示核销码、核销二维码、核销状态 */}
{!!dataSource?.verificationCode && (
<View style={myStyle.cell}>
......@@ -528,6 +554,23 @@ const StaySubmit = (props: Iprops) => {
</View>
</View>
)}
{/* 基本信息 */}
<View style={myStyle.cell}>
<View style={myStyle.HeadCell}>
<Text style={myStyle.HeadCellText}>
{ t('order.inquiry.details.baseInfo.title', '基本信息') }
</Text>
</View>
{basicInfoList.map((item, index) => {
item.value = '测试数据'
if (item.value) {
return renderCommonList(item, index);
}
return false;
})}
</View>
{/* 商品卡槽 */}
{dataSource.products && (
<Card
......@@ -544,6 +587,23 @@ const StaySubmit = (props: Iprops) => {
/>
)}
{/* 交易条件 */}
<View style={myStyle.cell}>
<View style={myStyle.HeadCell}>
<Text style={myStyle.HeadCellText}>
{ t('order.inquiry.details.condition.title', '交易条件') }
</Text>
</View>
{transactionConditionsList.map((item, index) => {
item.value = '测试数据'
if (item.value) {
return renderCommonList(item, index);
}
return false;
})}
</View>
{/* 在线客服 */}
{
// customerServiceInfo?.id && (
......
/*
* @Author: cgh
* @Date: 2023-03-02 19:50:27
* @LastEditors: cgh
* @LastEditTime: 2023-03-03 18:22:21
* @Description: 确认询价报价单-详情
*/
import React, { useEffect, useRef, useState } from 'react';
// import { View, Text, Icons, Toast } from '@linkseeks/god-mobile';
import { ScrollView, NativeScrollEvent, NativeSyntheticEvent,View, Text } from 'react-native';
......@@ -53,7 +61,7 @@ showAfterSales 申请售后
// };
// };
// }) => {
const MycommodityDetails = (props:any) => {
const EnsureInquiryDetails = (props:any) => {
const {
route: {
params: { orderId, categoryIndex, showAfterSales, noBtn, noBtnClick,showbutton,orderOperation },
......@@ -611,7 +619,7 @@ const MycommodityDetails = (props:any) => {
{/* <Examine dataSource={detailData}/> */}
{/* 待提交 */}
{/* {dqr && ( */}
<StaySubmit
<StaySubmit
dataSource={detailData}
outerStatus={sendInfo.outerStatus}
fnClosePayType={fnShowPayType}
......@@ -624,7 +632,7 @@ const MycommodityDetails = (props:any) => {
orderOperation={orderOperation}
share={share}
setDetailData={setDetailData}
/>
/>
{/* )} */}
{/* */}
{/* {dqr && detailData?.deliveries && (
......@@ -701,4 +709,4 @@ const MycommodityDetails = (props:any) => {
</View>
);
};
export default MycommodityDetails;
export default EnsureInquiryDetails;
......@@ -33,13 +33,15 @@ const CheckOrderItem = (props: any) => {
label = t('order.detail.sub', '提交');
break;
}
return (
<>
{label ? (
<View style={myStyle['box-bottome-foot']}>
<TouchableOpacity
onPress={() => {
navigation.navigate('RequirePriceOrderDetail', {
navigation.navigate('EnsureInquiryDetails', {
quoteNoId: item?.quoteId,
askPurchaseId: item?.askPurchaseId,
innerStatus: item?.innerStatus,
......@@ -78,81 +80,89 @@ const CheckOrderItem = (props: any) => {
return fmtText.join('');
};
// 查看商品详情
const Jump = (showbutton: boolean = false) => {
navigation.navigate('EnsureInquiryDetails', { orderId: item.orderId })
}
return (
<View style={myStyle.box}>
<View style={myStyle['box-top']}>
<View style={{ flexDirection: 'row', alignItems: 'center' }}>
<View
style={[
myStyle['box-point'],
item.externalState === 4 ? { backgroundColor: '#01B67B' } : null,
item.externalState === 5 ? { backgroundColor: '#F0364E' } : null,
]}
/>
<Text style={myStyle['box-top-text']}>
{CheckOrderExternalStatusEnum.getLabelByValue(item.externalState)}
</Text>
</View>
{item?.interiorState ? (
<Text style={myStyle['box-top-text']}>
{CheckOrderInnerStatusEnum.getLabelByValue(item?.interiorState)}
</Text>
) : null}
</View>
{/* -------------------------- */}
<View style={myStyle['box-bottome']}>
<View style={myStyle['box-bottome-container']}>
<View style={myStyle['box-article']}>
<View style={myStyle['box-line']}></View>
<TouchableOpacity onPress={() => Jump()}>
<View style={myStyle.box}>
<View style={myStyle['box-top']}>
<View style={{ flexDirection: 'row', alignItems: 'center' }}>
<View
style={[
myStyle['box-point'],
item.externalState === 4 ? { backgroundColor: '#01B67B' } : null,
item.externalState === 5 ? { backgroundColor: '#F0364E' } : null,
]}
/>
<Text style={myStyle['box-top-text']}>
{CheckOrderExternalStatusEnum.getLabelByValue(item.externalState)}
</Text>
</View>
<View>
<View style={myStyle['box-bottome-title']}>
<Image style={myStyle['box-bottome-block']} source={BaoIcon} />
<Text style={myStyle['box-bottome-title-text']}>
{item?.details}
</Text>
{item?.interiorState ? (
<Text style={myStyle['box-top-text']}>
{CheckOrderInnerStatusEnum.getLabelByValue(item?.interiorState)}
</Text>
) : null}
</View>
{/* -------------------------- */}
<View style={myStyle['box-bottome']}>
<View style={myStyle['box-bottome-container']}>
<View style={myStyle['box-article']}>
<View style={myStyle['box-line']}></View>
</View>
<View style={myStyle['box-bottome-content']}>
<View style={myStyle['box-bottome-content-left']}>
<View style={myStyle['box-bottome-content-left-text']}>
<Icons style={myStyle['date-icon']} name="clockcircleo" size={14} color="#C0C4CC" />
<Text
style={myStyle['box-bottome-content-left-text-label']}
>
{`\t${fmtView(interval(item.deliveryTime))}`}
</Text>
</View>
<View style={{...myStyle['box-bottome-content-left-text'], ...myStyle['box-bottome-content-left-text-end']}}>
<Icons style={myStyle['date-icon']} name="user" size={14} color="#C0C4CC" />
<Text
style={myStyle['box-bottome-content-left-text-label']}
>
{`\t${item?.memberName}`}
</Text>
<View>
<View style={myStyle['box-bottome-title']}>
<Image style={myStyle['box-bottome-block']} source={BaoIcon} />
<Text style={myStyle['box-bottome-title-text']}>
{item?.details}
</Text>
</View>
<View style={myStyle['box-bottome-content']}>
<View style={myStyle['box-bottome-content-left']}>
<View style={myStyle['box-bottome-content-left-text']}>
<Icons style={myStyle['date-icon']} name="clockcircleo" size={14} color="#C0C4CC" />
<Text
style={myStyle['box-bottome-content-left-text-label']}
>
{`\t${fmtView(interval(item.deliveryTime))}`}
</Text>
</View>
<View style={{...myStyle['box-bottome-content-left-text'], ...myStyle['box-bottome-content-left-text-end']}}>
<Icons style={myStyle['date-icon']} name="user" size={14} color="#C0C4CC" />
<Text
style={myStyle['box-bottome-content-left-text-label']}
>
{`\t${item?.memberName}`}
</Text>
</View>
</View>
<View style={myStyle['box-bottome-content-right']}>
{/* source={{ uri: products.logo }} */}
{/* <Image
source={lingxi_icon}
style={myStyle['box-bottome-content-right-img']}
/> */}
</View>
</View>
<View style={myStyle['box-bottome-content-right']}>
{/* source={{ uri: products.logo }} */}
{/* <Image
source={lingxi_icon}
style={myStyle['box-bottome-content-right-img']}
/> */}
{/* 这里~~~~~~· */}
<View style={myStyle['box-bottome-title']}>
<Image style={myStyle['box-bottome-block']} source={XunIcon} />
<Text style={myStyle['box-bottome-title-text']}>
{item?.details}
</Text>
</View>
</View>
{/* 这里~~~~~~· */}
<View style={myStyle['box-bottome-title']}>
<Image style={myStyle['box-bottome-block']} source={XunIcon} />
<Text style={myStyle['box-bottome-title-text']}>
{item?.details}
</Text>
</View>
</View>
{/* 这里~~~~~~· */}
{/* 内部状态:1.待提交审核2.待审核(一级)3.待审核(二级)4.待提交报价单5.审核通过6.审核不通过 */}
{renderButton()}
</View>
{/* 这里~~~~~~· */}
{/* 内部状态:1.待提交审核2.待审核(一级)3.待审核(二级)4.待提交报价单5.审核通过6.审核不通过 */}
{renderButton()}
</View>
</View>
</TouchableOpacity>
);
};
export default CheckOrderItem;
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