Commit b9f735c9 authored by Bill's avatar Bill

fix: 修改装修翻译

parent 4a013cdf
...@@ -152,8 +152,8 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => { ...@@ -152,8 +152,8 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
minWidth: '1280px', minWidth: '1280px',
} }
: {} : {}
// console.log(currentRouter) console.log(currentRouter)
return currentRouter.noLayout ? props.children : ( return currentRouter?.noLayout ? props.children : (
<ProLayout <ProLayout
pageTitleRender={() => currentRouter ? currentRouter.name : window.location.href} pageTitleRender={() => currentRouter ? currentRouter.name : window.location.href}
// contentStyle={{minWidth: '1280px'}} // contentStyle={{minWidth: '1280px'}}
......
...@@ -86,7 +86,7 @@ const Add = () => { ...@@ -86,7 +86,7 @@ const Add = () => {
okText: intl.formatMessage({ id: 'activityPage.decorationImmediate' }), okText: intl.formatMessage({ id: 'activityPage.decorationImmediate' }),
cancelText: intl.formatMessage({ id: 'activityPage.waitMin' }), cancelText: intl.formatMessage({ id: 'activityPage.waitMin' }),
onOk: () => { onOk: () => {
history.push(`/memberCenter/marketingAbility/activityPage/management/fixtures?id=${data}`); history.push(`/memberCenter/marketingAbility/activityPages/management/fixtures?id=${data}`);
}, },
onCancel: () => { onCancel: () => {
history.goBack(); history.goBack();
...@@ -174,7 +174,7 @@ const Add = () => { ...@@ -174,7 +174,7 @@ const Add = () => {
<Space> <Space>
{ {
isEdit && ( isEdit && (
<Link to={`/memberCenter/marketingAbility/activityPage/management/fixtures?id=${id}`}> <Link to={`/memberCenter/marketingAbility/activityPages/management/fixtures?id=${id}`}>
<Button icon={<BgColorsOutlined />}>{intl.formatMessage({ id: 'activityPage.activityPageDecorate' })}</Button> <Button icon={<BgColorsOutlined />}>{intl.formatMessage({ id: 'activityPage.activityPageDecorate' })}</Button>
</Link> </Link>
) || null ) || null
......
...@@ -82,7 +82,7 @@ const ActiveItem: React.FC<Iprops> = (props: Iprops) => { ...@@ -82,7 +82,7 @@ const ActiveItem: React.FC<Iprops> = (props: Iprops) => {
</div> </div>
{ {
[PENDIGN_ONLINE, OFFLINE].includes(status) && ( [PENDIGN_ONLINE, OFFLINE].includes(status) && (
<Link to={`/memberCenter/marketingAbility/activityPage/management/edit?id=${id}`}> <Link to={`/memberCenter/marketingAbility/activityPages/management/edit?id=${id}`}>
<Button icon={<EditOutlined />}></Button> <Button icon={<EditOutlined />}></Button>
</Link> </Link>
) || null ) || null
......
import React, { CSSProperties, useMemo } from 'react'; import React, { CSSProperties, useMemo } from 'react';
import cx from 'classnames'; import cx from 'classnames';
import { Tooltip } from 'antd'; import { Tooltip } from 'antd';
import { useIntl} from 'umi' import { getIntl } from 'umi'
const intl = getIntl();
interface Iprops { interface Iprops {
imageUrl: string, imageUrl: string,
width: number | string, width: number | string,
...@@ -12,7 +13,6 @@ interface Iprops { ...@@ -12,7 +13,6 @@ interface Iprops {
} }
const Advertisement: React.FC<Iprops> = (props: Iprops) => { const Advertisement: React.FC<Iprops> = (props: Iprops) => {
const intl = useIntl();
const { imageUrl, width = "100%", height = 176, style = {}, className, ...other } = props; const { imageUrl, width = "100%", height = 176, style = {}, className, ...other } = props;
const cacheWidth = useMemo(() => typeof width === 'number' ? `${width}px` : width, [width]); const cacheWidth = useMemo(() => typeof width === 'number' ? `${width}px` : width, [width]);
const cacheHeight = useMemo(() => typeof height === 'number' ? `${height}px` : height, [height]); const cacheHeight = useMemo(() => typeof height === 'number' ? `${height}px` : height, [height]);
......
...@@ -3,8 +3,9 @@ import { MarketingCard } from '@lingxi-design/ui'; ...@@ -3,8 +3,9 @@ import { MarketingCard } from '@lingxi-design/ui';
import cx from 'classnames'; import cx from 'classnames';
import styles from './index.less'; import styles from './index.less';
import { Tooltip } from 'antd'; import { Tooltip } from 'antd';
import { useIntl} from 'umi' import { getIntl } from 'umi'
const intl = getIntl();
const { CouponsItem } = MarketingCard; const { CouponsItem } = MarketingCard;
interface Iprops { interface Iprops {
...@@ -21,7 +22,6 @@ interface Iprops { ...@@ -21,7 +22,6 @@ interface Iprops {
} }
const Coupon: React.FC<Iprops> & { Item: typeof CouponItem } = (props: Iprops) => { const Coupon: React.FC<Iprops> & { Item: typeof CouponItem } = (props: Iprops) => {
const intl = useIntl();
const { children, className, visible = true, ...other } = props; const { children, className, visible = true, ...other } = props;
const classNameStr = cx( const classNameStr = cx(
styles.container, styles.container,
......
...@@ -2,15 +2,16 @@ ...@@ -2,15 +2,16 @@
import React, { useState } from 'react'; import React, { useState } from 'react';
import cx from 'classnames'; import cx from 'classnames';
import { Tooltip } from 'antd'; import { Tooltip } from 'antd';
import { useIntl} from 'umi' import { getIntl } from 'umi'
const intl = getIntl();
interface Iprops { interface Iprops {
className: any, className: any,
children: any children: any
} }
const WrapCommodityList: React.FC<Iprops> = (props: Iprops) => { const WrapCommodityList: React.FC<Iprops> = (props: Iprops) => {
const intl = useIntl(); // const intl = useIntl();
const { children, className, ...other } = props; const { children, className, ...other } = props;
const classNameStr = cx(className); const classNameStr = cx(className);
......
...@@ -103,7 +103,7 @@ const ActivePage = () => { ...@@ -103,7 +103,7 @@ const ActivePage = () => {
<div className={styles.search}> <div className={styles.search}>
<Search placeholder={intl.formatMessage({ id: 'activityPage.searchshousuo' })} onChange={(e) => onChange(e.target.value)} onSearch={handleSearch}/> <Search placeholder={intl.formatMessage({ id: 'activityPage.searchshousuo' })} onChange={(e) => onChange(e.target.value)} onSearch={handleSearch}/>
</div> </div>
<Link to='/memberCenter/marketingAbility/activityPage/management/add'> <Link to='/memberCenter/marketingAbility/activityPages/management/add'>
<Button icon={<PlusOutlined />} type="primary">{intl.formatMessage({ id: 'activityPage.add' })}</Button> <Button icon={<PlusOutlined />} type="primary">{intl.formatMessage({ id: 'activityPage.add' })}</Button>
</Link> </Link>
</div> </div>
......
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