Commit ca8929ef authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

fix: 处理送货计划查询-详情里面商品物流区块样式问题

parent 587f00d3
......@@ -62,7 +62,7 @@ const PlanMaterial: AnchorsItem = {
const PlannedDelivery: AnchorsItem = {
key: 'PlannedDelivery',
name: "计划送货"
name: "计划送货商品"
}
const DeliveryGood: AnchorsItem = {
......@@ -154,4 +154,4 @@ export {
ShippingInfo,
DeliveryList,
DeliveryNoticeAwaitAnchors,
}
\ No newline at end of file
}
......@@ -9,7 +9,7 @@ import moment from 'moment'
import { Steps, Table, Tag } from 'antd'
import AnchorPage, { AnchorsItem } from "@/components/AnchorPage"
import BaseInfo from '@/components/BaseInfo/BaseInfo'
import { BaseInfo as base_Info, Circulation, ConfirmDeliveryPlan, ExternalRoamRecord, ExternalState, PlannedDelivery, PlanningCycle, PlanNumber, PlanSummary, Purchaser, SubmitDeliveryPlan, Supplier, SupplyMember, SupplyMembersLabel, } from '../../constants'
import { BaseInfo as base_Info, Circulation, ConfirmDeliveryPlan, ExternalRoamRecord, ExternalState, PlanMaterial, PlannedDelivery, PlanningCycle, PlanNumber, PlanSummary, Purchaser, SubmitDeliveryPlan, Supplier, SupplyMember, SupplyMembersLabel, } from '../../constants'
import { ExternalRoamRecordTableColumn } from '../../constants/page-table-column'
import { BrandColumn, ClassColumn, CommodityNoColumn, ConsigneeNumColumn, DeliveredNumColumn, MaterialModelColumn, MaterialNameColumn, MaterialNoColumn, OrderCreatedAtColumn, OrderNoColumn, OrderNumColumn, OrderSummaryColumn, PlannedDeliveryNumColumn, TradeNameColumn, TransitNumColumn, UntilColumn } from '../../constants/table-column'
import { getDayAll, godAtob, integrationArrToObj, integrationOjb, TagStatus } from '../../utils'
......@@ -20,29 +20,29 @@ import styles from './index.less'
const intl = getIntl();
const columnB2B = [
{ ...CommodityNoColumn, dataIndex: 'skuId', width: 80, },
{ ...TradeNameColumn, dataIndex: 'productName', width: 192, },
{ ...ClassColumn, dataIndex: 'category', width: 96, },
{ ...BrandColumn, dataIndex: 'brand', width: 96, },
{ ...UntilColumn, dataIndex: 'unit', width: 64, },
{ ...OrderNumColumn, dataIndex: 'purchaseCountSum', width: 96, },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCountSum', width: 96, },
{ ...TransitNumColumn, dataIndex: 'transitCountSum', width: 96, },
{ ...DeliveredNumColumn, dataIndex: 'leftCountSum', width: 96, },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCountSum', width: 128, },
{ ...CommodityNoColumn, dataIndex: 'skuId', width: 80, align: 'left', },
{ ...TradeNameColumn, dataIndex: 'productName', width: 192, align: 'left', },
{ ...ClassColumn, dataIndex: 'category', width: 96, align: 'left', },
{ ...BrandColumn, dataIndex: 'brand', width: 96, align: 'left', },
{ ...UntilColumn, dataIndex: 'unit', width: 64, align: 'left', },
{ ...OrderNumColumn, dataIndex: 'purchaseCountSum', width: 96, align: 'left', },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCountSum', width: 96, align: 'left', },
{ ...TransitNumColumn, dataIndex: 'transitCountSum', width: 96, align: 'left', },
{ ...DeliveredNumColumn, dataIndex: 'leftCountSum', width: 96, align: 'left', },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCountSum', width: 128, align: 'left', },
]
const columnSRM = [
{ ...MaterialNoColumn, dataIndex: 'skuId', width: 80, },
{ ...MaterialNameColumn, dataIndex: 'productName', width: 192, },
{ ...MaterialModelColumn, dataIndex: 'productName', width: 128, },
{ ...ClassColumn, dataIndex: 'category', width: 96, },
{ ...BrandColumn, dataIndex: 'brand', width: 96, },
{ ...UntilColumn, dataIndex: 'unit', width: 64, },
{ ...OrderNumColumn, dataIndex: 'purchaseCountSum', width: 96, },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCountSum', width: 96, },
{ ...TransitNumColumn, dataIndex: 'transitCountSum', width: 96, },
{ ...DeliveredNumColumn, dataIndex: 'leftCountSum', width: 96, },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCountSum', width: 128, },
{ ...MaterialNoColumn, dataIndex: 'skuId', width: 80, align: 'left', },
{ ...MaterialNameColumn, dataIndex: 'productName', width: 192, align: 'left', },
{ ...MaterialModelColumn, dataIndex: 'spec', width: 128, align: 'left', },
{ ...ClassColumn, dataIndex: 'category', width: 96, align: 'left', },
{ ...BrandColumn, dataIndex: 'brand', width: 96, align: 'left', },
{ ...UntilColumn, dataIndex: 'unit', width: 64, align: 'left', },
{ ...OrderNumColumn, dataIndex: 'purchaseCountSum', width: 96, align: 'left', },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCountSum', width: 96, align: 'left', },
{ ...TransitNumColumn, dataIndex: 'transitCountSum', width: 96, align: 'left', },
{ ...DeliveredNumColumn, dataIndex: 'leftCountSum', width: 96, align: 'left', },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCountSum', width: 128, align: 'left', },
]
const tagStatus = new TagStatus()
......@@ -63,15 +63,17 @@ const DeliveryPlanManagementDetails: React.FC = () => {
// 动态 TableColumn
const [tableColumn, setTableColumn] = useState<any>([])
// 动态 expandIconColumn
const dynamicWidth = deliveryPlanType === '1' ? 214 : 342
console.log(dynamicWidth)
const [expandIconColumn, setExpandIconColumn] = useState<any>([
{ ...OrderNoColumn, dataIndex: 'orderNo', width: 80, },
{ ...OrderSummaryColumn, dataIndex: 'orderDigest', width: 200, },
{ ...OrderCreatedAtColumn, dataIndex: 'createTime', width: 160, },
{ ...OrderNumColumn, dataIndex: 'purchaseCount', width: 96, },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCount', width: 96, },
{ ...TransitNumColumn, dataIndex: 'transitCount', width: 96, },
{ ...DeliveredNumColumn, dataIndex: 'leftCount', width: 96, },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCount', width: 128, },
{ ...OrderNoColumn, dataIndex: 'orderNo', width: 80, align: 'left', },
{ ...OrderSummaryColumn, dataIndex: 'orderDigest', width: 192, align: 'left', },
{ ...OrderCreatedAtColumn, dataIndex: 'createTime', width: dynamicWidth, align: 'left', },
{ ...OrderNumColumn, dataIndex: 'purchaseCount', width: 96, align: 'left', },
{ ...ConsigneeNumColumn, dataIndex: 'receiveCount', width: 96, align: 'left', },
{ ...TransitNumColumn, dataIndex: 'transitCount', width: 96, align: 'left', },
{ ...DeliveredNumColumn, dataIndex: 'leftCount', width: 96, align: 'left', },
{ ...PlannedDeliveryNumColumn, dataIndex: 'planCount', width: 128, align: 'left', },
])
const expandedRowRender = (record) => {
return <Table rowKey={'orderProductId'} columns={expandIconColumn} dataSource={record.orders} pagination={false} tableLayout="fixed" />
......@@ -165,17 +167,17 @@ const DeliveryPlanManagementDetails: React.FC = () => {
<BaseInfo.BaseInfoItem label={SupplyMembersLabel}> {details?.vendorMemberName} </BaseInfo.BaseInfoItem>
<BaseInfo.BaseInfoItem label={PlanningCycle}> {moment(details?.planStartTime).format('YYYY-MM-DD')} {intl.formatMessage({ id: 'common.text.to', defaultMessage: '至' })} {moment(details?.planEndTime).format('YYYY-MM-DD')} </BaseInfo.BaseInfoItem>
<BaseInfo.BaseInfoItem label={PlanSummary}> {details?.digest} </BaseInfo.BaseInfoItem>
<BaseInfo.BaseInfoItem label={PlanningCycle}> {moment(details?.planStartTime).format('YYYY-MM-DD')} {intl.formatMessage({ id: 'common.text.to', defaultMessage: '至' })} {moment(details?.planEndTime).format('YYYY-MM-DD')} </BaseInfo.BaseInfoItem>
<BaseInfo.BaseInfoItem label={ExternalState}>
<Tag color={tagStatus.getTagStyle(details?.status).bgColor}>
<span style={{ color: tagStatus.getTagStyle(details?.status).fontColor }}>{statusTxt.get(details?.status)}</span>
</Tag>
</BaseInfo.BaseInfoItem>
</BaseInfo>
<BaseInfo className='mt-16' title={PlannedDelivery.name} id={PlannedDelivery.key} cols={1}>
<BaseInfo className='mt-16' title={deliveryPlanType === '1' ? PlannedDelivery.name : PlanMaterial.name} id={PlannedDelivery.key} cols={1}>
{/* B2B 显示计划送货物料,SRM显示计划送货商品 */}
<Table
// defaultExpandAllRows
......
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