Commit ea6b1c9f authored by 前端-黄佳鑫's avatar 前端-黄佳鑫
parents 4de268db 8a548bcd
......@@ -44,7 +44,7 @@
"antd-img-crop": "^3.12.0",
"bizcharts": "^4.0.14",
"copy-to-clipboard": "^3.3.1",
"god": "0.2.1",
"god": "^0.2.1",
"immutability-helper": "^3.1.1",
"lingxi-design": "^1.0.8",
"lingxi-design-ui": "^1.1.10",
......
......@@ -99,7 +99,7 @@ const CommodityList: React.FC<CommodityListPropsType> = (props) => {
{
commodityList.map((item, index) => (
<div key={`commodity_list_item_column_${index}`} className={cx(styles.commodity_list_item, styles.column)}>
<a href={`/${layoutType === LAYOUT_TYPE.channel ? 'channelmall' : 'shop'}/commodity/detail?id=${item.id}&type=${item.priceType}&shopId=${btoa(JSON.stringify({ shopId: item.storeId, memberId: item.memberId }))}`} target="_blank">
<a href={getCommodityDetailLink(item)} target="_blank">
<div className={styles.goods_img}>
{
item.mainPic ? <img src={item.mainPic} /> : <Skeleton.Image style={{ width: 120, height: 120 }} />
......
......@@ -532,6 +532,7 @@ const CommodityDetail = (props) => {
name: commodityDetail.name,
packing: commodityDetail.packing,
unitName: commodityDetail.unitName,
attribute: attrAndValList.attributeAndValueList
}
let sessionKey = `inquiry${selectCommodityId}${new Date().getTime()}`
......
......@@ -326,13 +326,13 @@ const Order: React.FC<OrderPropsType> = (props) => {
const linkToUrl = (path: string) => {
switch(layoutType) {
case LAYOUT_TYPE.channel:
history.replace(`${GlobalConfig.channelRootRoute}${path}?channelId=${shopUrlParam}`)
history.replace(`${GlobalConfig.channelRootRoute}${path}&channelId=${shopUrlParam}`)
break
case LAYOUT_TYPE.ichannel:
history.replace(`${GlobalConfig.ichannelRootRoute}${path}?channelId=${shopUrlParam}`)
history.replace(`${GlobalConfig.ichannelRootRoute}${path}&channelId=${shopUrlParam}`)
break
default:
history.replace(`${path}?channelId=${shopUrlParam}`)
history.replace(`${path}`)
break
}
......
......@@ -89,7 +89,6 @@ const CreditPayWay: React.FC<CreditPayWayPropsType> = (props) => {
message.destroy()
message.success("支付成功")
linkToUrl(`/pay/result?orderId=${orderId}`, layoutType, shopUrlParam )
history.replace(`/pay/result?orderId=${orderId}`)
} else {
setConfirmLoading(false)
message.destroy()
......
......@@ -5,13 +5,13 @@ import { LAYOUT_TYPE } from '@/constants'
export const linkToUrl = (path: string, layoutType, shopUrlParam) => {
switch (layoutType) {
case LAYOUT_TYPE.channel:
history.replace(`${GlobalConfig.channelRootRoute}${path}?channelId=${shopUrlParam}`)
history.replace(`${GlobalConfig.channelRootRoute}${path}&channelId=${shopUrlParam}`)
break
case LAYOUT_TYPE.ichannel:
history.replace(`${GlobalConfig.ichannelRootRoute}${path}?channelId=${shopUrlParam}`)
history.replace(`${GlobalConfig.ichannelRootRoute}${path}&channelId=${shopUrlParam}`)
break
default:
history.replace(`${path}?channelId=${shopUrlParam}`)
history.replace(`${path}`)
break
}
......
......@@ -710,7 +710,9 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => {
</div>
<div className={cx(styles.order_list_item_item, styles.goods_info)}>
<div className={styles.order_list_item_item_imgbox}>
<ImageBox width={80} height={80} imgUrl={childItem.commodityUnitPrice.commodityPic[0]} direction="column" />
{
childItem.commodityUnitPrice.commodityPic && <ImageBox width={80} height={80} imgUrl={childItem.commodityUnitPrice.commodityPic[0]} direction="column" />
}
</div>
<div>
<div className={styles.order_list_item_item_name}>
......
import React, {useState, useEffect} from 'react'
import React, {useState, useEffect, useRef} from 'react'
import { usePageStatus, PageStatus } from '@/hooks/usePageStatus'
import { useInitValue } from '@/formSchema/effects/useInitValue'
import EyePreview from '@/components/EyePreview'
import { findItemAndDelete } from '@/utils'
import { ISchemaFormActions, ISchema, FormEffectHooks } from '@formily/antd'
import { ISchemaFormActions, ISchema, FormEffectHooks, createAsyncFormActions } from '@formily/antd'
import { useRowSelectionTable } from '@/hooks/useRowSelectionTable'
import { createAddRepositoryEffect, useUnitPreview } from '../effects'
import { PublicApi } from '@/services/api'
......@@ -238,6 +238,7 @@ const PositionSetting:React.FC<PositionSettingProps> = (props) => {
addSchemaAction.setFieldValue('goodsId', goodsId)
addSchemaAction.setFieldValue('itemNo', data?.code || '')
}
}
......@@ -530,6 +531,7 @@ const PositionSetting:React.FC<PositionSettingProps> = (props) => {
schema: formSearch,
components: { ModalSearch: Search, SearchSelect, Submit, Select } ,
effects: ($, actions) => {
actions.reset()
useStateFilterSearchLinkageEffect(
$,
actions,
......@@ -540,6 +542,9 @@ const PositionSetting:React.FC<PositionSettingProps> = (props) => {
}
}
}
resetModal={{
destroyOnClose: true
}}
tableProps={{
rowKey: 'memberId'
}}
......@@ -558,6 +563,7 @@ const PositionSetting:React.FC<PositionSettingProps> = (props) => {
schema: formProduct,
components: { ModalSearch: Search, SearchSelect, Submit } ,
effects: ($, actions) => {
actions.reset()
useStateFilterSearchLinkageEffect(
$,
actions,
......@@ -568,6 +574,9 @@ const PositionSetting:React.FC<PositionSettingProps> = (props) => {
}
}
}
resetModal={{
destroyOnClose: true
}}
tableProps={{
rowKey: 'id',
onRow: (record) => ({
......
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