列表分页接口开发完成
This commit is contained in:
@ -4,7 +4,7 @@ import { Button, Spin, message } from 'antd';
|
|||||||
import React, { useRef, useState } from 'react';
|
import React, { useRef, useState } from 'react';
|
||||||
import { useHistory } from 'umi';
|
import { useHistory } from 'umi';
|
||||||
import ViewModal from '../../ViewModal';
|
import ViewModal from '../../ViewModal';
|
||||||
import { getPage } from '../service';
|
import { getPage } from '../../service';
|
||||||
|
|
||||||
interface ViewDetailsProps {
|
interface ViewDetailsProps {
|
||||||
entity?: {
|
entity?: {
|
||||||
@ -18,7 +18,6 @@ interface ViewDetailsProps {
|
|||||||
* @returns
|
* @returns
|
||||||
*/
|
*/
|
||||||
const OnlineSupervision: React.FC<{}> = () => {
|
const OnlineSupervision: React.FC<{}> = () => {
|
||||||
|
|
||||||
const [spin, spinSet] = useState<boolean>(false);
|
const [spin, spinSet] = useState<boolean>(false);
|
||||||
const [visible, setVisible] = useState<boolean>(false);
|
const [visible, setVisible] = useState<boolean>(false);
|
||||||
const [record, setRecord] = useState<any[]>([]);
|
const [record, setRecord] = useState<any[]>([]);
|
||||||
@ -47,7 +46,6 @@ const OnlineSupervision: React.FC<{}> = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const columns: ProColumns<any>[] = [
|
const columns: ProColumns<any>[] = [
|
||||||
|
|
||||||
{
|
{
|
||||||
valueType: 'index',
|
valueType: 'index',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
@ -63,52 +61,61 @@ const OnlineSupervision: React.FC<{}> = () => {
|
|||||||
{
|
{
|
||||||
title: '项目编号',
|
title: '项目编号',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'projectNumber',
|
dataIndex: 'projectNum',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '标段',
|
title: '标段',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'sectionName',
|
dataIndex: 'packageNames',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '评审室名称',
|
title: '评审室名称',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'reviewRoomName',
|
dataIndex: 'areaName',
|
||||||
hideInSearch: false,
|
hideInSearch: false,
|
||||||
width: '10%',
|
width: '10%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '预计评标开始时间',
|
title: '预计评标开始时间',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'startTime',
|
dataIndex: 'reserveStartDate',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '15%',
|
width: '15%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '预计评标结束时间',
|
title: '预计评标结束时间',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'endTime',
|
dataIndex: 'reserveEndDate',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '9.5%',
|
width: '9.5%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '状态',
|
title: '状态',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'state',
|
dataIndex: 'status',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '4.5%',
|
width: '4.5%',
|
||||||
valueEnum: {
|
valueEnum: {
|
||||||
0: {
|
'-1': {
|
||||||
text: '未开始'
|
text: '待确认'
|
||||||
},
|
},
|
||||||
1: {
|
'0': {
|
||||||
text: '评标中'
|
text: '未开启'
|
||||||
},
|
},
|
||||||
2: {
|
'1': {
|
||||||
|
text: '进行中'
|
||||||
|
},
|
||||||
|
'2': {
|
||||||
text: '已结束'
|
text: '已结束'
|
||||||
},
|
},
|
||||||
|
'3': {
|
||||||
|
text: '已取消'
|
||||||
|
},
|
||||||
|
'4': {
|
||||||
|
text: '结束未使用'
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -154,34 +161,25 @@ const OnlineSupervision: React.FC<{}> = () => {
|
|||||||
search={{ labelWidth: 'auto', span: 6 }}
|
search={{ labelWidth: 'auto', span: 6 }}
|
||||||
loading={false}
|
loading={false}
|
||||||
request={async (params) => {
|
request={async (params) => {
|
||||||
// spinSet(true);
|
spinSet(true);
|
||||||
// return await getPage({
|
return await getPage({
|
||||||
// ...params,
|
...params,
|
||||||
// basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
||||||
// }).then((res) => {
|
queryType: 1,
|
||||||
// const result = {
|
areaRoomName: params.areaName
|
||||||
// data: res.data.records,
|
}).then((res) => {
|
||||||
// total: res.data.total,
|
const result = {
|
||||||
// success: res.success,
|
data: res.data.records,
|
||||||
// pageSize: res.data.size,
|
total: res.data.total,
|
||||||
// current: res.data.current
|
success: res.success,
|
||||||
// }
|
pageSize: res.data.size,
|
||||||
// return result;
|
current: res.data.current
|
||||||
// }).finally(() => {
|
}
|
||||||
// isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
return result;
|
||||||
// spinSet(false);
|
}).finally(() => {
|
||||||
// })
|
isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
||||||
return {data:[{projectName: '2022年中国联通集团大厦A1913会议室智能化改造项目',
|
spinSet(false);
|
||||||
projectNumber: 'SS25102022000211',
|
})
|
||||||
sectionName: '标段一',
|
|
||||||
reviewRoomName: '集团第一评审室',
|
|
||||||
state : 1,
|
|
||||||
startTime : '2022-07-13 12:30',
|
|
||||||
endTime : '2022-07-13 12:30'}],
|
|
||||||
total:1,
|
|
||||||
pageSize:10,
|
|
||||||
current:1}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pagination={{
|
pagination={{
|
||||||
|
@ -4,7 +4,7 @@ import { Button, Spin, Modal } from 'antd';
|
|||||||
import React, { useRef, useState } from 'react';
|
import React, { useRef, useState } from 'react';
|
||||||
import { useHistory } from 'umi';
|
import { useHistory } from 'umi';
|
||||||
import ViewModal from '../../ViewModal';
|
import ViewModal from '../../ViewModal';
|
||||||
import { getPage } from '../service';
|
import { getPage } from '../../service';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 预约项目列表
|
* 预约项目列表
|
||||||
@ -35,68 +35,76 @@ const ReservedItems: React.FC<{}> = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const columns: ProColumns<any>[] = [
|
const columns: ProColumns<any>[] = [
|
||||||
|
{
|
||||||
{
|
valueType: 'index',
|
||||||
valueType: 'index',
|
align: 'center',
|
||||||
align: 'center',
|
hideInSearch: true,
|
||||||
hideInSearch: true,
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '项目名称',
|
||||||
title: '项目名称',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'projectName',
|
||||||
dataIndex: 'projectName',
|
width: '20%',
|
||||||
width: '20%',
|
hideInSearch: false,
|
||||||
hideInSearch: false,
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '项目编号',
|
||||||
title: '项目编号',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'projectNum',
|
||||||
dataIndex: 'projectNumber',
|
hideInSearch: true,
|
||||||
hideInSearch: true,
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '标段',
|
||||||
title: '标段',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'packageNames',
|
||||||
dataIndex: 'sectionName',
|
hideInSearch: true,
|
||||||
hideInSearch: true,
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '评审室名称',
|
||||||
title: '评审室名称',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'areaName',
|
||||||
dataIndex: 'reviewRoomName',
|
hideInSearch: false,
|
||||||
hideInSearch: false,
|
width: '10%',
|
||||||
width: '10%',
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '预计评标开始时间',
|
||||||
title: '预计评标开始时间',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'reserveStartDate',
|
||||||
dataIndex: 'startTime',
|
hideInSearch: true,
|
||||||
hideInSearch: true,
|
width: '15%',
|
||||||
width: '15%',
|
},
|
||||||
},
|
{
|
||||||
{
|
title: '预计评标结束时间',
|
||||||
title: '预计评标结束时间',
|
align: 'center',
|
||||||
align: 'center',
|
dataIndex: 'reserveEndDate',
|
||||||
dataIndex: 'endTime',
|
hideInSearch: true,
|
||||||
hideInSearch: true,
|
width: '9.5%',
|
||||||
width: '9.5%',
|
},
|
||||||
},
|
|
||||||
{
|
{
|
||||||
title: '状态',
|
title: '状态',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'state',
|
dataIndex: 'status',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '4.5%',
|
width: '4.5%',
|
||||||
valueEnum: {
|
valueEnum: {
|
||||||
0: {
|
'-1': {
|
||||||
text: '未开始'
|
text: '待确认'
|
||||||
},
|
},
|
||||||
1: {
|
'0': {
|
||||||
text: '评标中'
|
text: '未开启'
|
||||||
},
|
},
|
||||||
2: {
|
'1': {
|
||||||
|
text: '进行中'
|
||||||
|
},
|
||||||
|
'2': {
|
||||||
text: '已结束'
|
text: '已结束'
|
||||||
},
|
},
|
||||||
|
'3': {
|
||||||
|
text: '已取消'
|
||||||
|
},
|
||||||
|
'4': {
|
||||||
|
text: '结束未使用'
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -133,34 +141,25 @@ const ReservedItems: React.FC<{}> = () => {
|
|||||||
search={{ labelWidth: 'auto', span: 6 }}
|
search={{ labelWidth: 'auto', span: 6 }}
|
||||||
loading={false}
|
loading={false}
|
||||||
request={async (params) => {
|
request={async (params) => {
|
||||||
// spinSet(true);
|
spinSet(true);
|
||||||
// return await getPage({
|
return await getPage({
|
||||||
// ...params,
|
...params,
|
||||||
// basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
||||||
// }).then((res) => {
|
queryType: 0,
|
||||||
// const result = {
|
areaRoomName: params.areaName
|
||||||
// data: res.data.records,
|
}).then((res) => {
|
||||||
// total: res.data.total,
|
const result = {
|
||||||
// success: res.success,
|
data: res.data.records,
|
||||||
// pageSize: res.data.size,
|
total: res.data.total,
|
||||||
// current: res.data.current
|
success: res.success,
|
||||||
// }
|
pageSize: res.data.size,
|
||||||
// return result;
|
current: res.data.current
|
||||||
// }).finally(() => {
|
}
|
||||||
// isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
return result;
|
||||||
// spinSet(false);
|
}).finally(() => {
|
||||||
// })
|
isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
||||||
return {data:[{projectName: '2022年中国联通集团大厦A1913会议室智能化改造项目',
|
spinSet(false);
|
||||||
projectNumber: 'SS25102022000211',
|
})
|
||||||
sectionName: '标段一',
|
|
||||||
reviewRoomName: '集团第一评审室',
|
|
||||||
state : 0,
|
|
||||||
startTime : '2022-07-13 12:30',
|
|
||||||
endTime : '2022-07-13 12:30'}],
|
|
||||||
total:1,
|
|
||||||
pageSize:10,
|
|
||||||
current:1}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pagination={{
|
pagination={{
|
||||||
|
@ -6,19 +6,11 @@ import { useHistory } from 'umi';
|
|||||||
import ViewModal from '../ViewModal';
|
import ViewModal from '../ViewModal';
|
||||||
import { getPage } from '../service';
|
import { getPage } from '../service';
|
||||||
|
|
||||||
interface ViewDetailsProps {
|
|
||||||
entity?: {
|
|
||||||
projectName?:string|null,
|
|
||||||
projectNumber?:string|null,
|
|
||||||
} | null,
|
|
||||||
visibleDefault?:boolean| false,
|
|
||||||
}
|
|
||||||
/**
|
/**
|
||||||
* 事后监督列表
|
* 事后监督列表
|
||||||
* @returns
|
* @returns
|
||||||
*/
|
*/
|
||||||
const PostSupervision: React.FC<{}> = () => {
|
const PostSupervision: React.FC<{}> = () => {
|
||||||
|
|
||||||
const [spin, spinSet] = useState<boolean>(false);
|
const [spin, spinSet] = useState<boolean>(false);
|
||||||
const [visible, setVisible] = useState<boolean>(false);
|
const [visible, setVisible] = useState<boolean>(false);
|
||||||
const [record, setRecord] = useState<any[]>([]);
|
const [record, setRecord] = useState<any[]>([]);
|
||||||
@ -47,7 +39,6 @@ const PostSupervision: React.FC<{}> = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const columns: ProColumns<any>[] = [
|
const columns: ProColumns<any>[] = [
|
||||||
|
|
||||||
{
|
{
|
||||||
valueType: 'index',
|
valueType: 'index',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
@ -63,52 +54,61 @@ const PostSupervision: React.FC<{}> = () => {
|
|||||||
{
|
{
|
||||||
title: '项目编号',
|
title: '项目编号',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'projectNumber',
|
dataIndex: 'projectNum',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '标段',
|
title: '标段',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'sectionName',
|
dataIndex: 'packageNames',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '评审室名称',
|
title: '评审室名称',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'reviewRoomName',
|
dataIndex: 'areaName',
|
||||||
hideInSearch: false,
|
hideInSearch: false,
|
||||||
width: '10%',
|
width: '10%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '预计评标开始时间',
|
title: '预计评标开始时间',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'startTime',
|
dataIndex: 'reserveStartDate',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '15%',
|
width: '15%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '预计评标结束时间',
|
title: '预计评标结束时间',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'endTime',
|
dataIndex: 'reserveEndDate',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '9.5%',
|
width: '9.5%',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '状态',
|
title: '状态',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'state',
|
dataIndex: 'status',
|
||||||
hideInSearch: true,
|
hideInSearch: true,
|
||||||
width: '4.5%',
|
width: '4.5%',
|
||||||
valueEnum: {
|
valueEnum: {
|
||||||
0: {
|
'-1': {
|
||||||
text: '未开始'
|
text: '待确认'
|
||||||
},
|
},
|
||||||
1: {
|
'0': {
|
||||||
text: '评标中'
|
text: '未开启'
|
||||||
},
|
},
|
||||||
2: {
|
'1': {
|
||||||
|
text: '进行中'
|
||||||
|
},
|
||||||
|
'2': {
|
||||||
text: '已结束'
|
text: '已结束'
|
||||||
},
|
},
|
||||||
|
'3': {
|
||||||
|
text: '已取消'
|
||||||
|
},
|
||||||
|
'4': {
|
||||||
|
text: '结束未使用'
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -154,34 +154,25 @@ const PostSupervision: React.FC<{}> = () => {
|
|||||||
search={{ labelWidth: 'auto', span: 6 }}
|
search={{ labelWidth: 'auto', span: 6 }}
|
||||||
loading={false}
|
loading={false}
|
||||||
request={async (params) => {
|
request={async (params) => {
|
||||||
// spinSet(true);
|
spinSet(true);
|
||||||
// return await getPage({
|
return await getPage({
|
||||||
// ...params,
|
...params,
|
||||||
// basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
basePageRequest: { pageNo: pageData.pageNo, pageSize: pageData.pageSize },
|
||||||
// }).then((res) => {
|
queryType: 2,
|
||||||
// const result = {
|
areaRoomName: params.areaName
|
||||||
// data: res.data.records,
|
}).then((res) => {
|
||||||
// total: res.data.total,
|
const result = {
|
||||||
// success: res.success,
|
data: res.data.records,
|
||||||
// pageSize: res.data.size,
|
total: res.data.total,
|
||||||
// current: res.data.current
|
success: res.success,
|
||||||
// }
|
pageSize: res.data.size,
|
||||||
// return result;
|
current: res.data.current
|
||||||
// }).finally(() => {
|
}
|
||||||
// isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
return result;
|
||||||
// spinSet(false);
|
}).finally(() => {
|
||||||
// })
|
isNotEmpty(window.location.search) && history.push(window.location.pathname);
|
||||||
return {data:[{projectName: '2022年中国联通集团大厦A1913会议室智能化改造项目',
|
spinSet(false);
|
||||||
projectNumber: 'SS25102022000211',
|
})
|
||||||
sectionName: '标段一',
|
|
||||||
reviewRoomName: '集团第一评审室',
|
|
||||||
state : 2,
|
|
||||||
startTime : '2022-07-13 12:30',
|
|
||||||
endTime : '2022-07-13 12:30'}],
|
|
||||||
total:1,
|
|
||||||
pageSize:10,
|
|
||||||
current:1}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pagination={{
|
pagination={{
|
||||||
|
@ -1,11 +0,0 @@
|
|||||||
import request from '@/utils/request';
|
|
||||||
/**
|
|
||||||
* 查询数据并分页
|
|
||||||
* @param params
|
|
||||||
*/
|
|
||||||
export async function getPage(params?: any) {
|
|
||||||
return request('/api/biz-service-ebtp-project/v1/projectRecord/supervisor/getPage', {
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
});
|
|
||||||
}
|
|
@ -108,7 +108,7 @@ const columns: ColumnsType<DataType> = [
|
|||||||
<Descriptions>
|
<Descriptions>
|
||||||
<Descriptions.Item label="项目编号">{data?.projectNumber}</Descriptions.Item>
|
<Descriptions.Item label="项目编号">{data?.projectNumber}</Descriptions.Item>
|
||||||
<Descriptions.Item label="标段名称">{data?.sectionName}</Descriptions.Item>
|
<Descriptions.Item label="标段名称">{data?.sectionName}</Descriptions.Item>
|
||||||
<Descriptions.Item label="评标室名称">{data?.reviewRoomName}</Descriptions.Item>
|
<Descriptions.Item label="评标室名称">{data?.areaRoomName}</Descriptions.Item>
|
||||||
<Descriptions.Item label="评标状态">{getStateName(data?.state)}</Descriptions.Item>
|
<Descriptions.Item label="评标状态">{getStateName(data?.state)}</Descriptions.Item>
|
||||||
<Descriptions.Item label="预计开始时间">{data?.startTime}</Descriptions.Item>
|
<Descriptions.Item label="预计开始时间">{data?.startTime}</Descriptions.Item>
|
||||||
<Descriptions.Item label="预计结束时间">{data?.endTime}</Descriptions.Item>
|
<Descriptions.Item label="预计结束时间">{data?.endTime}</Descriptions.Item>
|
||||||
|
@ -4,7 +4,7 @@ import request from '@/utils/request';
|
|||||||
* @param params
|
* @param params
|
||||||
*/
|
*/
|
||||||
export async function getPage(params?: any) {
|
export async function getPage(params?: any) {
|
||||||
return request('/api/biz-service-ebtp-project/v1/projectRecord/supervisor/getPage', {
|
return request('/api/biz-service-ebtp-evaluation//v1/eval/room/reserve/supervise/list', {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: params,
|
data: params,
|
||||||
});
|
});
|
Reference in New Issue
Block a user