wjx 1 سال پیش
والد
کامیت
1aa900c811

+ 2 - 2
src/pages/gameDataStatistics/gameServer/serverGsData/index.tsx

@@ -25,7 +25,7 @@ const ServerGsData: React.FC = () => {
     useEffect(() => {
         getGameServerGsTotal.run(queryForm).then((res: { id: number; dt?: string; gameName: string; }) => {
             res.id = 1
-            res.dt = queryForm.beginDate
+            res.dt = queryForm?.beginDate ? queryForm?.beginDate : moment().subtract(90, 'days').format('YYYY-MM-DD')
             res.gameName = '总计'
             setTotalData([res])
         })
@@ -124,7 +124,7 @@ const ServerGsData: React.FC = () => {
             page={getGameServerGsList?.data?.current || 1}
             pageSize={getGameServerGsList?.data?.size || 20}
             total={getGameServerGsList?.data?.total || 0}
-            dataSource={getGameServerGsList?.data?.records}
+            dataSource={getGameServerGsList?.data?.records?.map((item: any, index: number) => ({ ...item, id: Number(queryForm.pageNum.toString() + index.toString()) }))}
             onChange={(pagination: any, _: any, sortData: any) => {
                 let { current, pageSize } = pagination
                 let newQueryForm = JSON.parse(JSON.stringify(queryForm))

+ 14 - 5
src/pages/gameDataStatistics/gameServer/serverGsData/tableConfig.tsx

@@ -8,7 +8,7 @@ import { getNumber } from "@/utils/utils"
 
 function columns12(): { label: string, fieldSHow?: { label: string, saveField: string, defaultValue: any[], data: any[] }, data: any[] }[] {
 
-    let defaultStart = 8
+    let defaultStart = 9
     const day = Array(90).fill('').map((_item: string, index: number) => {
         let field = `daRetention${index + 1}`
         let data = {
@@ -137,6 +137,15 @@ function columns12(): { label: string, fieldSHow?: { label: string, saveField: s
 
 
     return [
+        {
+            label: 'GS信息',
+            data: [
+                {
+                    title: 'GS名称', dataIndex: 'gsNames', label: 'GS信息', align: 'center', width: 70, default: 4,
+                    render: (a: string) => (<WidthEllipsis value={a} />)
+                } 
+            ]
+        },
         {
             label: '游戏信息',
             data: [
@@ -155,7 +164,7 @@ function columns12(): { label: string, fieldSHow?: { label: string, saveField: s
                 },
                 { title: '区服ID', dataIndex: 'serverId', label: '游戏信息', align: 'center', width: 90 },
                 {
-                    title: '开服时间', dataIndex: 'dt', label: '游戏信息', align: 'center', width: 90, default: 4, sorter: true,
+                    title: '开服时间', dataIndex: 'dt', label: '游戏信息', align: 'center', width: 90, default: 5, sorter: true,
                     render: (a: any, b: any) => {
                         if (b.gameName === '总计') {
                             return '--'
@@ -169,15 +178,15 @@ function columns12(): { label: string, fieldSHow?: { label: string, saveField: s
             label: '数据',
             data: [
                 {
-                    title: '新用户人数', dataIndex: 'totalRegNum', label: '数据', align: 'center', width: 70, sorter: true, default: 5,
+                    title: '新用户人数', dataIndex: 'totalRegNum', label: '数据', align: 'center', width: 70, sorter: true, default: 6,
                     render: (a: number) => <Statistic value={a || 0} />
                 },
                 {
-                    title: '创角人数', dataIndex: 'totalRoleNum', label: '数据', align: 'center', width: 70, sorter: true, default: 6,
+                    title: '创角人数', dataIndex: 'totalRoleNum', label: '数据', align: 'center', width: 70, sorter: true, default: 7,
                     render: (a: number) => <Statistic value={a || 0} />
                 },
                 {
-                    title: '付费人数', dataIndex: 'totalAmountNum', label: '数据', align: 'center', width: 70, sorter: true, default: 7,
+                    title: '付费人数', dataIndex: 'totalAmountNum', label: '数据', align: 'center', width: 70, sorter: true, default: 8,
                     render: (a: number) => <Statistic value={a || 0} />
                 }
             ]

+ 4 - 0
src/services/gameData/roleOperate.ts

@@ -463,6 +463,10 @@ export async function getCreateRoleConfigListApi(data: CreateRoleConfigProps) {
         method: 'POST',
         data
     });
+//     return request('/role/validRoleConfig/list', {
+//         method: 'POST',
+//         data
+//     });
 }
 
 interface AeGameServerProps {