Commit 41b855dd authored by 前端-彭佳文's avatar 前端-彭佳文

Merge branch 'v2-220418' into 'v2-220418'

修复广告管理/业绩管理bug See merge request linkseeks-design/pro-platform!97
parents 8267f740 62d5a473
......@@ -99,26 +99,26 @@
hideInMenu: true,
hidePageHeader: true,
},
//广告管理 todo:wuting
// {
// path: '/memberCenter/contentAbility/advertisement',
// name: 'advertisement',
// component: '@/pages/content/advertisement',
// },
// {
// path: '/memberCenter/contentAbility/advertisement/add',
// name: 'advertisementAdd',
// component: '@/pages/content/advertisement/advertisementInfo',
// hideInMenu: true,
// hidePageHeader: true,
// },
// {
// path: '/memberCenter/contentAbility/advertisement/detail',
// name: 'advertisementInfo',
// component: '@/pages/content/advertisement/advertisementInfo',
// hideInMenu: true,
// hidePageHeader: true,
// },
//广告管理
{
path: '/memberCenter/contentAbility/advertisement',
name: 'advertisement',
component: '@/pages/content/advertisement',
},
{
path: '/memberCenter/contentAbility/advertisement/add',
name: 'advertisementAdd',
component: '@/pages/content/advertisement/advertisementInfo',
hideInMenu: true,
hidePageHeader: true,
},
{
path: '/memberCenter/contentAbility/advertisement/detail',
name: 'advertisementInfo',
component: '@/pages/content/advertisement/advertisementInfo',
hideInMenu: true,
hidePageHeader: true,
},
]
}
......
......@@ -170,26 +170,6 @@ export const purchaseInquiryRoute = [
hideInMenu: true,
noMargin: true,
},
// //广告管理
// {
// path: '/memberCenter/procurementAbility/purchaseInquiry/advertisement',
// name: 'advertisement',
// component: '@/pages/content/advertisement',
// },
// {
// path: '/memberCenter/procurementAbility/purchaseInquiry/advertisement/add',
// name: 'advertisementAdd',
// component: '@/pages/content/advertisement/advertisementInfo',
// hideInMenu: true,
// hidePageHeader: true,
// },
// {
// path: '/memberCenter/procurementAbility/purchaseInquiry/advertisement/detail',
// name: 'advertisementInfo',
// component: '@/pages/content/advertisement/advertisementInfo',
// hideInMenu: true,
// hidePageHeader: true,
// },
]
},
]
......@@ -38,7 +38,7 @@ const AllQuery = () => {
dataIndex: 'title',
render: (text: string, record: any) => (
<EyePreview
url={`/content/advertisement/detail?id=${record.id}&preview=1`}
url={`/memberCenter/contentAbility/advertisement/detail?id=${record.id}&preview=1`}
>
{text}
</EyePreview>
......@@ -118,7 +118,7 @@ const AllQuery = () => {
<Space>
<Button
type="primary"
onClick={() => { history.push('/content/advertisement/add') }}
onClick={() => { history.push('/memberCenter/contentAbility/advertisement/add') }}
icon={<PlusOutlined />}
>
{getIntl().formatMessage({ id: 'common.button.add'})}
......
......@@ -17,10 +17,7 @@ import StatusTag from '@/components/StatusTag';
import {
getMemberAbilityAssignedPage,
getMemberAbilityAssignedPageitems,
getMemberAbilityMaintenancePage,
getMemberAbilityMaintenancePageitems,
postMemberAbilityAssignedBind,
postMemberDepositVerifyBatch,
} from '@/services/MemberV2Api';
import useSpliceArray from '@/hooks/useSpliceArray';
import { querySchema } from './schema2';
......
......@@ -15,7 +15,7 @@ const SalesPerformanceStatistics: React.FC = () => {
const intl = getIntl();
const { token } = (getAuth() || {})
const ref = useRef<any>({});
const [organizationList,setOrganizationList] = useState<Array<{value:string,label:string}>>()
const [organizationList,setOrganizationList] = useState<Array<{value:number,label:string}>>()
const [paramsData,setParamsData] = useState<{ name:string,time:string,organization:number,pageSize:number,current:number }>()
const defaultColumns: ColumnType<any>[] = [
......@@ -139,8 +139,8 @@ const SalesPerformanceStatistics: React.FC = () => {
/** 获取机构列表 */
const getOrganizationList = async ()=>{
let res = await getMemberFeignAbilitySalesOrganizationList()
const list = res.data?.map((i)=>({
value:i,
const list = res.data?.map((i,k)=>({
value:k,
label:i
}))
setOrganizationList(list)
......@@ -164,7 +164,6 @@ const SalesPerformanceStatistics: React.FC = () => {
console.log('exporturl:',`${process.env.BACK_GATEWAY}/order/member/sales/achievement/count/export/memberSales/information?token=${token}${exportParams}`)
window.open(`${process.env.BACK_GATEWAY}/order/member/sales/achievement/count/export/memberSales/information?token=${token}${exportParams}`, '_blank')
}
return (
<PageHeaderWrapper>
<Card>
......@@ -176,7 +175,12 @@ const SalesPerformanceStatistics: React.FC = () => {
currentRef={ref}
rowKey='userId'
fetchTableData={(params: any) => {
console.log('params:',params)
delete params.account
let num = Number(params.title)
if(num > -1 && organizationList?.length){
params.title = organizationList[params.title].label
}
setParamsData({...params})
return fetchListData(params)
}}
......@@ -227,7 +231,7 @@ const SalesPerformanceStatistics: React.FC = () => {
type: 'Search',
"x-component-props": {
placeholder: intl.formatMessage({ id: 'salesPerformanceStatistics.placeholder.name' }),
allowClear:true,
allowClear:true,
}
},
......
......@@ -234,7 +234,7 @@ const StatistticsList: React.FC<{ searchType: string; id: number }> = ({
return new Promise((resolve, reject) => {
api(
{
userId: 700,
userId: id,
...rest,
countTime: searchType === 'membership' ? memberTime : productTime,
},
......
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