wjx vor 11 Monaten
Ursprung
Commit
4148102f56

+ 51 - 8
src/components/QueryForm/index.tsx

@@ -204,6 +204,8 @@ interface Props {
     isCreateRole?: boolean
     /** 是否开启 角色VIP 搜索 */
     isVipLevel?: boolean
+    /** 是否开启 角色等级 搜索 */
+    isRoleLevel?: boolean
     /** 是否开启 是否转端 搜索 */
     isIsChange?: boolean
     /** 是否开启 邮件是否发送 搜索 */
@@ -253,6 +255,8 @@ interface Props {
     isRechargeAmountWithin24h?: boolean
     /** 是否开启 创角24小时以内累计充值金额 搜索 */
     isRechargeTotalAmountWithin24h?: boolean
+    /** 是否开启 玩家注册渠道类型 搜索 */
+    isRegisterType?: boolean
 }
 /**
  * 游戏数据系统 请求参数
@@ -265,9 +269,9 @@ const QueryForm: React.FC<Props> = (props) => {
         onChange, initialValues, isSource, isAccount, isAccountId, isAccountIds, isCompanyId, isAgentKey, isAgentName, isCpId, isCpName, isCpOrderId, isCpStatus, isCreateDay, isCreateDayXz, isDevice, isGameName, isRechargeGameName, isGameId, isGameIds, isOrderGameId, isGameRoleId,
         isGameRoleName, isFirstRecharge, isSwitch, isMerchantNo, isOrderId, isMerchantOrderNo, isPayStatus, isPayWay, isProductName, isRegAgent, isAgentId, isPutAgent, isRegDay, isOs, isParentId, isParentIds, isProjectId, isProjectName, isPromotionId, isPromotionId1, isPromotionName,
         isSysUserName, isRechargeDate, isBGGameClassify, isGameUserId, isSysUserId, isSysUserIds, isUserName, isUserId, isSelectRanking, isGameType, isConsumeDay, rechargeDay, isBeginDay, isType, isAdTTStatus, isUserEnterType, isServerName, isServerId, isServerDay, isAdTXStatus,
-        payTimeDay, placeAnOrderDay, isPayIntervalTime, isActiveTypes, isNickname, isMobile, isRegIp, isIsAuth, isIsBindMobile, isIsRecharge, isUserStatus, isCreateRole, isRoleCount, isVipLevel, isCreateRoleDay, isLastActiveTime, isIsChange, isIsSendMail, isWeChatCompany, isWeChat,
+        payTimeDay, placeAnOrderDay, isPayIntervalTime, isActiveTypes, isNickname, isMobile, isRegIp, isIsAuth, isIsBindMobile, isIsRecharge, isUserStatus, isCreateRole, isRoleCount, isVipLevel, isRoleLevel, isCreateRoleDay, isLastActiveTime, isIsChange, isIsSendMail, isWeChatCompany, isWeChat,
         isCustomerServerId, isOperatorId, isGsId, isServerIds, isRankingNum, isIsMergeServer, isIsParticipateMerge, isSuperParentGameId, isGameServerName, isIp, isDeviceType, isLoginType, isServerIdUn, isSourceServerName, isProjectId1, isRemoveGame, isRemoveGameForSystem, isOrderLy, isAddCorpWechat,
-        isWakeUp, isBackStatus, isGameDimension, isUserLastRegTime, isUserLastRegAgentId, isUserLastPitcherId, isRechargeAmountWithin24h, isRechargeTotalAmountWithin24h
+        isWakeUp, isBackStatus, isGameDimension, isUserLastRegTime, isUserLastRegAgentId, isUserLastPitcherId, isRechargeAmountWithin24h, isRechargeTotalAmountWithin24h, isRegisterType
     } = props
     const [form] = Form.useForm()
     const parentId = Form.useWatch('parentId', form)
@@ -359,12 +363,19 @@ const QueryForm: React.FC<Props> = (props) => {
     useEffect(() => {
         if (isGameId || isOrderGameId || isParentId || isParentIds || isGameIds || isSuperParentGameId) {
             getGameListNew.run({ sourceSystem }).then((res: { gameList: any; parentGameList: any; superGameList: any }) => {
-                const { gameList, parentGameList, superGameList } = res
-                // if (['BG_OLD', 'BG_NEW', 'ZX_SDK'].includes(sourceSystem)) {
-                setGameList(gameList?.map((item: { id: any; game_name: any }) => ({ id: item.id, name: item.game_name })) || [])
-                // }
-                setParentGameList(parentGameList)
-                setSuperGameList(superGameList)
+                if (res) {
+                    const { gameList, parentGameList, superGameList } = res
+                    // if (['BG_OLD', 'BG_NEW', 'ZX_SDK'].includes(sourceSystem)) {
+                    setGameList(gameList?.map((item: { id: any; game_name: any }) => ({ id: item.id, name: item.game_name })) || [])
+                    // }
+                    // let isBg = ['289', '399', '402', '432', '445', '472'].includes(localStorage.getItem('userId') || '')
+                    // let newparentGameList: { parent_game_id: number }[] = parentGameList || []
+                    // if (isBg) {  //布谷过滤
+                    //     newparentGameList = newparentGameList.filter(item => ![9, 1, 7, 15, 11, 16, 13].includes(item.parent_game_id))
+                    // }
+                    setParentGameList(parentGameList)
+                    setSuperGameList(superGameList)
+                }
             })
 
             // if (sourceSystem === 'ZX_ONE') {
@@ -564,6 +575,21 @@ const QueryForm: React.FC<Props> = (props) => {
                     <Select.Option value="nature">自然量</Select.Option>
                 </Select>
             </Form.Item></Col>}
+            {/* 玩家注册渠道类型 */}
+            {isRegisterType && <Col><Form.Item name='registerType'>
+                <Select
+                    showSearch
+                    style={{ width: 150 }}
+                    allowClear
+                    placeholder={'玩家注册渠道类型'}
+                    filterOption={(input, option) =>
+                        (option?.children as any)?.toLowerCase().indexOf(input.toLowerCase()) >= 0
+                    }
+                >
+                    <Select.Option value={1}>非自然量</Select.Option>
+                    <Select.Option value={0}>自然量</Select.Option>
+                </Select>
+            </Form.Item></Col>}
             {isActiveTypes && <Col><Form.Item name='activeTypes'>
                 <Select
                     showSearch
@@ -1383,6 +1409,7 @@ const QueryForm: React.FC<Props> = (props) => {
                 <Select
                     showSearch
                     allowClear
+                    mode="multiple"
                     style={{ width: 110 }}
                     placeholder={'是否转端'}
                     filterOption={(input, option) =>
@@ -1431,6 +1458,7 @@ const QueryForm: React.FC<Props> = (props) => {
                 <Select
                     showSearch
                     allowClear
+                    mode="multiple"
                     style={{ width: 110 }}
                     placeholder={'是否退游'}
                     filterOption={(input, option) =>
@@ -1448,6 +1476,7 @@ const QueryForm: React.FC<Props> = (props) => {
                 <Select
                     showSearch
                     allowClear
+                    mode="multiple"
                     style={{ width: 135 }}
                     placeholder={'是否添加企微'}
                     filterOption={(input, option) =>
@@ -1467,6 +1496,7 @@ const QueryForm: React.FC<Props> = (props) => {
                     allowClear
                     style={{ width: 110 }}
                     placeholder={'是否唤醒'}
+                    mode="multiple"
                     filterOption={(input, option) =>
                         (option?.children as any)?.toLowerCase().indexOf(input.toLowerCase()) >= 0
                     }
@@ -1494,6 +1524,19 @@ const QueryForm: React.FC<Props> = (props) => {
                 </Select>
             </Form.Item></Col>}
 
+            {/* 角色等级 */}
+            {isRoleLevel && <Col><Form.Item>
+                <Space>
+                    <Form.Item name='roleLevelMin' noStyle>
+                        <InputNumber style={{ width: 130 }} placeholder="角色等级最小值" />
+                    </Form.Item>
+                    <span>~</span>
+                    <Form.Item name='roleLevelMax' noStyle>
+                        <InputNumber style={{ width: 130 }} placeholder="角色等级最小值" />
+                    </Form.Item>
+                </Space>
+            </Form.Item></Col>}
+
             {/* 操作系统 */}
             {isOs && <Col><Form.Item name='os'>
                 <Select

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

@@ -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?.map((item: any, index: number) => ({ ...item, id: Number(queryForm.pageNum.toString() + index.toString()) }))}
+            dataSource={getGameServerGsList?.data?.records?.map((item: any, index: number) => ({ ...item, id: Number(queryForm.pageNum.toString() + (index + '')) }))}
             onChange={(pagination: any, _: any, sortData: any) => {
                 let { current, pageSize } = pagination
                 let newQueryForm = JSON.parse(JSON.stringify(queryForm))
@@ -135,8 +135,8 @@ const ServerGsData: React.FC = () => {
                     delete newQueryForm['sortType']
                     delete newQueryForm['sortFiled']
                 }
-                newQueryForm.pageNum = current
-                newQueryForm.pageSize = pageSize
+                newQueryForm.pageNum = current || newQueryForm.pageNum
+                newQueryForm.pageSize = pageSize || newQueryForm.pageSize 
                 setQueryForm({ ...newQueryForm })
             }}
         />

+ 8 - 1
src/pages/gameDataStatistics/roleOperate/roleRechargeRanking/index.tsx

@@ -102,11 +102,14 @@ const RoleRechargeRanking: React.FC = () => {
                 initialValues={{ sourceSystem: 'ZX_ONE', rechargeDay: [moment(), moment()] }}
                 onChange={(data: any) => {
                     setSelectedRowKeys([])
-                    const { rechargeDay, createRoleDay, superParentGameId, mobile, regPayIntervalTime, lastActiveTime, ...par } = data
+                    const { rechargeDay, createRoleDay, superParentGameId, mobile, regPayIntervalTime, lastActiveTime, agentId, regStartDay, regEndDay, ...par } = data
                     let newQueryForm = JSON.parse(JSON.stringify(queryForm))
                     newQueryForm.pageNum = 1
                     newQueryForm.phone = mobile
                     newQueryForm.superGameId = superParentGameId
+                    newQueryForm.agentIds = agentId
+                    newQueryForm.registerTimeMin = regStartDay
+                    newQueryForm.registerTimeMax = regEndDay
                     if (rechargeDay && rechargeDay?.length === 2) {
                         newQueryForm['rechargeBeginDate'] = moment(rechargeDay[0]).format('YYYY-MM-DD')
                         newQueryForm['rechargeEndDate'] = moment(rechargeDay[1]).format('YYYY-MM-DD')
@@ -163,6 +166,10 @@ const RoleRechargeRanking: React.FC = () => {
                 isRechargeAmountWithin24h
                 isRechargeTotalAmountWithin24h
                 isLastActiveTime={{ }}
+                isAgentId
+                isRegisterType
+                isRegDay={{}}
+                isRoleLevel
             />}
             scroll={{ x: 1000, y: 600 }}
             isVirtually={false}

+ 36 - 4
src/pages/gameDataStatistics/roleOperate/roleRechargeRanking/taskList.tsx

@@ -20,6 +20,8 @@ const TaskList: React.FC<Props> = ({ sourceSystem }) => {
     const [visible, setVisible] = useState<boolean>(false)
     const [gameList, setGameList] = useState<any[]>([])
     const [gameId, setGameId] = useState<number>()
+    const [taskStatus, setTaskStatus] = useState<string>()
+    const [sendStatus, setSendStatus] = useState<string>()
     const [queryForm, setQueryForm] = useState<{ pageNum: number, pageSize: number }>({ pageNum: 1, pageSize: 20 })
     const [queryFormLog, setQueryFormLog] = useState<{ pageNum: number, pageSize: number }>({ pageNum: 1, pageSize: 20 })
     const [taskId, setTaskId] = useState<number>()
@@ -33,15 +35,15 @@ const TaskList: React.FC<Props> = ({ sourceSystem }) => {
 
     useEffect(() => {
         if (visible) {
-            getSendMsgTaskList.run({ ...queryForm, gameId })
+            getSendMsgTaskList.run({ ...queryForm, gameId, taskStatus })
         }
-    }, [queryForm, gameId, visible])
+    }, [queryForm, gameId, taskStatus, visible])
 
     useEffect(() => {
         if (taskId && visibleLog) {
-            getSendLogList.run({ ...queryFormLog, taskId })
+            getSendLogList.run({ ...queryFormLog, taskId, sendStatus })
         }
-    }, [taskId, visibleLog, queryFormLog])
+    }, [taskId, visibleLog, queryFormLog, sendStatus])
 
     const open = () => {
         if (sourceSystem) {
@@ -82,6 +84,21 @@ const TaskList: React.FC<Props> = ({ sourceSystem }) => {
                 >
                     {gameList?.map((item: any) => <Select.Option value={item.id} key={item.id}>{item.name}</Select.Option>)}
                 </Select>
+                <Select
+                    maxTagCount={1}
+                    showSearch
+                    style={{ minWidth: 100 }}
+                    placeholder={'任务状态'}
+                    filterOption={(input, option) =>
+                        (option?.children as any)?.toLowerCase().indexOf(input.toLowerCase()) >= 0
+                    }
+                    allowClear
+                    value={taskStatus}
+                    onChange={(e) => setTaskStatus(e)}
+                >
+                    <Select.Option value="SUCCESS_SEND">已发送</Select.Option>
+                    <Select.Option value="WAIT_SEND">待发送</Select.Option>
+                </Select>
                 <Button type="link" icon={<SyncOutlined />} onClick={() => getSendMsgTaskList.refresh()} loading={getSendMsgTaskList.loading} />
             </Space>}
             visible={visible}
@@ -113,6 +130,21 @@ const TaskList: React.FC<Props> = ({ sourceSystem }) => {
         {visibleLog && <Modal
             title={<Space>
                 <strong>{taskName} 发送记录</strong>
+                <Select
+                    maxTagCount={1}
+                    showSearch
+                    style={{ minWidth: 100 }}
+                    placeholder={'发送状态'}
+                    filterOption={(input, option) =>
+                        (option?.children as any)?.toLowerCase().indexOf(input.toLowerCase()) >= 0
+                    }
+                    allowClear
+                    value={sendStatus}
+                    onChange={(e) => setSendStatus(e)}
+                >
+                    <Select.Option value="CP_SEND_ROLE_RESULT_SUCCESS">发送成功</Select.Option>
+                    <Select.Option value="CP_SEND_ROLE_RESULT_FAIL">发送失败</Select.Option>
+                </Select>
                 <Button type="link" icon={<SyncOutlined />} onClick={() => getSendLogList.refresh()} loading={getSendLogList.loading} />
             </Space>}
             visible={visibleLog}