样式调整

main
liuyiliang 3 months ago
parent 0a3825a449
commit 90bad9816a
  1. 4
      packages/examination/src/style/common.css
  2. 226
      packages/examination/src/views/exam-online/compoents/ExamListPage.tsx
  3. 182
      packages/examination/src/views/examPaper/examPaperList.tsx
  4. 228
      packages/examination/src/views/question/questionList.tsx
  5. 4
      packages/examination/src/views/statistical/serviceStatistics.tsx

@ -382,3 +382,7 @@ table.ikd-input-table {
height: 100%; height: 100%;
font-size: x-large; font-size: x-large;
} }
.ant-btn-dangerous {
color: #ff4d4f !important;
border-color: #ff4d4f !important;
}

@ -472,119 +472,125 @@ const ExamListPage = ({ history }: { history: any }) => {
} }
return ( return (
<div className="list-filter"> <div className="container">
<Form <div>
//ref={this.formRef} <div className="header-filter">
className="filter" <div className="list-filter" style={{display: 'flex', padding: 15}}>
layout="inline" <Form
> //ref={this.formRef}
<Form.Item className="filter"
label="考试名称:" layout="inline"
> >
<Input <Form.Item
placeholder="请输入考试名称" label="考试名称:"
value={searchForm.examName} >
onChange={(e) => <Input
setSearchForm({...searchForm, examName: e.target.value}) placeholder="请输入考试名称"
} value={searchForm.examName}
style={{width: 240}} onChange={(e) =>
/> setSearchForm({...searchForm, examName: e.target.value})
</Form.Item> }
<Form.Item style={{width: 240}}
label="试卷名称:" />
> </Form.Item>
<Input <Form.Item
placeholder="请输入试卷名称" label="试卷名称:"
value={searchForm.paperName} >
onChange={(e) => <Input
setSearchForm({...searchForm, paperName: e.target.value}) placeholder="请输入试卷名称"
} value={searchForm.paperName}
style={{width: 240}} onChange={(e) =>
/> setSearchForm({...searchForm, paperName: e.target.value})
</Form.Item> }
<Form.Item style={{width: 240}}
label="监管行业:" />
> </Form.Item>
<Select <Form.Item
placeholder="监管行业" label="监管行业:"
value={searchForm.regulatedIndustry} >
onChange={(value) => <Select
setSearchForm({...searchForm, regulatedIndustry: value}) placeholder="监管行业"
} value={searchForm.regulatedIndustry}
style={{width: 240}} onChange={(value) =>
> setSearchForm({...searchForm, regulatedIndustry: value})
<Option key="" value=""></Option> }
{industryOptions.map(option => ( style={{width: 240}}
<Option key={option.value} value={option.value}> >
{option.label} <Option key="" value=""></Option>
</Option> {industryOptions.map(option => (
))} <Option key={option.value} value={option.value}>
</Select> {option.label}
</Form.Item> </Option>
<Form.Item ))}
label="考试有效日期:" </Select>
> </Form.Item>
<DatePicker <Form.Item
value={searchForm.validTime} // 使用 Moment 类型 label="考试有效日期:"
onChange={(value: Moment | null) => >
setSearchForm({...searchForm, validTime: value}) <DatePicker
} value={searchForm.validTime} // 使用 Moment 类型
style={{width: 240}} onChange={(value: Moment | null) =>
/> setSearchForm({...searchForm, validTime: value})
</Form.Item> }
<Form.Item> style={{width: 240}}
<Button onClick={handleReset}></Button> />
</Form.Item> </Form.Item>
<Form.Item> <Form.Item>
<Button onClick={() => handleSearch(1)} type="primary" style={{marginLeft: 8}}> <Button onClick={handleReset}></Button>
</Form.Item>
</Button> <Form.Item>
</Form.Item> <Button onClick={() => handleSearch(1)} type="primary" style={{marginLeft: 8}}>
</Form>
<div style={{marginBottom: 16, textAlign: "right"}}> </Button>
<Button onClick={handleDeleteSelected} danger> </Form.Item>
</Form>
</Button>
<Button onClick={handleWithdrawSelected} style={{marginLeft: 8}}>
</Button>
<Button onClick={handlePublishSelected} style={{marginLeft: 8}}>
</Button>
<Button onClick={handleAddExam} type="primary" style={{marginLeft: 8}}>
</Button>
</div>
<Table
columns={columns}
loading={loading}
dataSource={currentPageExamList}
rowKey="examId"
pagination={pagination}
bordered={true}
size={'small'}
onChange={handleTableChange}
/>
<Modal
title={<div style={{ textAlign: 'center' }}></div>}
visible={qrCodeVisible}
onCancel={() => setQrCodeVisible(false)}
onOk={handleDownloadQRCode}
centered
okText="确认"
>
<div style={{ display: 'flex', justifyContent: 'center', marginBottom: '20px' }}>
<div ref={qrCodeRef} className="qrCodeRef">
<QRCode value={'https://4s27589r64.zicp.fun/wx/'+qrCodeData} size={200} fgColor="#000000" ecLevel="H"/>
<div className="overlay">
<a onClick={() => handleRefreshQRCode(examId)} className="refresh-link"><UndoOutlined /></a>
</div>
</div> </div>
</div> </div>
<div style={{ display: 'flex', justifyContent: 'center', marginBottom: '20px',fontWeight: 'bolder', fontSize: 'larger' }}> <div style={{marginBottom: 16, textAlign: "right"}}>
<span>{captcha}</span> <Button onClick={handleDeleteSelected} danger>
</Button>
<Button onClick={handleWithdrawSelected} style={{marginLeft: 8}}>
</Button>
<Button onClick={handlePublishSelected} style={{marginLeft: 8}}>
</Button>
<Button onClick={handleAddExam} type="primary" style={{marginLeft: 8}}>
</Button>
</div> </div>
</Modal> <Table
columns={columns}
loading={loading}
dataSource={currentPageExamList}
rowKey="examId"
pagination={pagination}
bordered={true}
size={'small'}
onChange={handleTableChange}
/>
<Modal
title={<div style={{ textAlign: 'center' }}></div>}
visible={qrCodeVisible}
onCancel={() => setQrCodeVisible(false)}
onOk={handleDownloadQRCode}
centered
okText="确认"
>
<div style={{ display: 'flex', justifyContent: 'center', marginBottom: '20px' }}>
<div ref={qrCodeRef} className="qrCodeRef">
<QRCode value={'https://4s27589r64.zicp.fun/wx/'+qrCodeData} size={200} fgColor="#000000" ecLevel="H"/>
<div className="overlay">
<a onClick={() => handleRefreshQRCode(examId)} className="refresh-link"><UndoOutlined /></a>
</div>
</div>
</div>
<div style={{ display: 'flex', justifyContent: 'center', marginBottom: '20px',fontWeight: 'bolder', fontSize: 'larger' }}>
<span>{captcha}</span>
</div>
</Modal>
</div>
</div> </div>
); );
}; };

@ -349,95 +349,101 @@ class ExamPaperList extends Component<any, States> {
]; ];
return ( return (
<div className="list-filter"> <div className="container">
<Form <div>
ref={this.formRef} <div className="header-filter">
className="filter" <div className="list-filter" style={{display: 'flex', padding: 15}}>
layout="inline" <Form
> ref={this.formRef}
<Form.Item className="filter"
label="监管行业:" layout="inline"
name="industryId" >
<Form.Item
label="监管行业:"
name="industryId"
>
<Select
placeholder="请选择监管行业"
style={{ width: 240 }}
allowClear
>
{
industryDict && industryDict.length > 0?
(() => {
let rows = [];
for (let i = 0; i < industryDict.length; i++) {
const item = industryDict[i];
rows.push(
<Option value={item.industryId}>{item.industryName}</Option>
);
}
return rows;
})()
:
<Option disabled></Option>
}
</Select>
</Form.Item>
<Form.Item
label="试卷名称:"
name="paperName"
>
<Input placeholder="请输入试卷名称" style={{ width: 240 }} />
</Form.Item>
<Form.Item>
<Button type="default" onClick={this.handleReset}></Button>
</Form.Item>
<Form.Item>
<Button type="primary" htmlType="submit" onClick={() => {
this.handlegetList('init');
}}></Button>
</Form.Item>
</Form>
</div>
</div>
<Form
className="filter"
layout="inline"
style={{ justifyContent: 'flex-end' }}
> >
<Select <Form.Item>
placeholder="请选择监管行业" <Button type="default" onClick={this.handleBatchDeleteExamPaper} danger></Button>
style={{ width: 240 }} </Form.Item>
allowClear <Form.Item>
> <Button type="default" onClick={() => this.handleBatchUpdatePaperStatus(1)}></Button>
{ </Form.Item>
industryDict && industryDict.length > 0? <Form.Item>
(() => { <Button type="default" onClick={() => this.handleBatchUpdatePaperStatus(0)}></Button>
let rows = []; </Form.Item>
for (let i = 0; i < industryDict.length; i++) { <Form.Item>
const item = industryDict[i]; <Button type="primary" onClick={() => { this.props.history.push(`/examPaperAdd`); }}></Button>
rows.push( </Form.Item>
<Option value={item.industryId}>{item.industryName}</Option> </Form>
); <Table
} dataSource={list}
return rows; columns={columns}
})() rowKey="id"
: bordered={true}
<Option disabled></Option> size={'small'}
} loading={loading}
</Select> scroll={{ y: 500 }}
</Form.Item> rowSelection={{
<Form.Item selectedRowKeys: selectedRowKeys,
label="试卷名称:" onChange: this.handleOnChange,
name="paperName" getCheckboxProps: () => ({
> disabled: false
<Input placeholder="请输入试卷名称" style={{ width: 240 }} /> })
</Form.Item> }}
<Form.Item> pagination={{
<Button type="default" onClick={this.handleReset}></Button> total: this.state.total,
</Form.Item> current: this.state.page,
<Form.Item> showQuickJumper: true,
<Button type="primary" htmlType="submit" onClick={() => { showSizeChanger: true,
this.handlegetList('init'); showTotal: (total) => `${total}`,
}}></Button> onChange: changePage
</Form.Item> }}
</Form> />
<Form </div>
className="filter"
layout="inline"
style={{ justifyContent: 'flex-end' }}
>
<Form.Item>
<Button type="default" onClick={this.handleBatchDeleteExamPaper}></Button>
</Form.Item>
<Form.Item>
<Button type="default" onClick={() => this.handleBatchUpdatePaperStatus(1)}></Button>
</Form.Item>
<Form.Item>
<Button type="default" onClick={() => this.handleBatchUpdatePaperStatus(0)}></Button>
</Form.Item>
<Form.Item>
<Button type="primary" onClick={() => { this.props.history.push(`/examPaperAdd`); }}></Button>
</Form.Item>
</Form>
<Table
dataSource={list}
columns={columns}
rowKey="id"
bordered={true}
size={'small'}
loading={loading}
scroll={{ y: 500 }}
rowSelection={{
selectedRowKeys: selectedRowKeys,
onChange: this.handleOnChange,
getCheckboxProps: () => ({
disabled: false
})
}}
pagination={{
total: this.state.total,
current: this.state.page,
showQuickJumper: true,
showSizeChanger: true,
showTotal: (total) => `${total}`,
onChange: changePage
}}
/>
</div> </div>
); );
} }

@ -281,120 +281,126 @@ class QuestionList extends Component<any, States> {
]; ];
return ( return (
<div className="list-filter"> <div className="container">
<Form <div>
ref={this.formRef} <div className="header-filter">
className="filter" <div className="list-filter" style={{display: 'flex', padding: 15}}>
layout="inline" <Form
> ref={this.formRef}
<Form.Item className="filter"
label="监管行业:" layout="inline"
name="industryId" >
> <Form.Item
<Select label="监管行业:"
placeholder="请选择监管行业" name="industryId"
style={{ width: 240 }} >
allowClear <Select
> placeholder="请选择监管行业"
{ style={{ width: 240 }}
industryDict && industryDict.length > 0? allowClear
(() => { >
let rows = []; {
for (let i = 0; i < industryDict.length; i++) { industryDict && industryDict.length > 0?
const item = industryDict[i]; (() => {
rows.push( let rows = [];
<Option value={item.industryId}>{item.industryName}</Option> for (let i = 0; i < industryDict.length; i++) {
); const item = industryDict[i];
rows.push(
<Option value={item.industryId}>{item.industryName}</Option>
);
}
return rows;
})()
:
<Option disabled></Option>
} }
return rows; </Select>
})() </Form.Item>
: <Form.Item
<Option disabled></Option> label="AQ服务类型:"
} name="serviceTypeId"
</Select> >
</Form.Item> <Select
<Form.Item placeholder="请选择AQ服务类型"
label="AQ服务类型:" style={{ width: 240 }}
name="serviceTypeId" allowClear
> >
<Select {
placeholder="请选择AQ服务类型" serviceTypeDict && serviceTypeDict.length > 0?
style={{ width: 240 }} (() => {
allowClear let rows = [];
> for (let i = 0; i < serviceTypeDict.length; i++) {
{ const item = serviceTypeDict[i];
serviceTypeDict && serviceTypeDict.length > 0? rows.push(
(() => { <Option value={item.dictKey}>{item.dictValue}</Option>
let rows = []; );
for (let i = 0; i < serviceTypeDict.length; i++) { }
const item = serviceTypeDict[i]; return rows;
rows.push( })()
<Option value={item.dictKey}>{item.dictValue}</Option> :
); <Option disabled></Option>
} }
return rows; </Select>
})() </Form.Item>
: <Form.Item
<Option disabled></Option> label="题干条件:"
} name="questionContent"
</Select> >
</Form.Item> <Input
<Form.Item placeholder="请输入题干条件"
label="题干条件:" style={{ width: 240 }}
name="questionContent" />
</Form.Item>
<Form.Item>
<Button type="default" onClick={this.handleReset}></Button>
</Form.Item>
<Form.Item>
<Button type="primary" htmlType="submit" onClick={() => {
this.handlegetList('init');
}}></Button>
</Form.Item>
</Form>
</div>
</div>
<Form
className="filter"
layout="inline"
style={{ justifyContent: 'flex-end' }}
> >
<Input <Form.Item>
placeholder="请输入题干条件" <Button type="default" onClick={this.handleBatchDeleteQuestions} danger></Button>
style={{ width: 240 }} </Form.Item>
/> <Form.Item>
</Form.Item> <Button type="primary" onClick={() => {
<Form.Item> this.props.history.push('/questionAdd');
<Button type="default" onClick={this.handleReset}></Button> }}></Button>
</Form.Item> </Form.Item>
<Form.Item> </Form>
<Button type="primary" htmlType="submit" onClick={() => { <Table
this.handlegetList('init'); dataSource={list}
}}></Button> columns={columns}
</Form.Item> rowKey="id"
</Form> bordered={true}
<Form size={'small'}
className="filter" scroll={{ y: 500 }}
layout="inline" loading={loading}
style={{ justifyContent: 'flex-end' }} rowSelection={{
> selectedRowKeys: selectedRowKeys,
<Form.Item> onChange: this.handleOnChange,
<Button type="default" onClick={this.handleBatchDeleteQuestions}></Button> getCheckboxProps: () => ({
</Form.Item> disabled: false
<Form.Item> })
<Button type="primary" onClick={() => { }}
this.props.history.push('/questionAdd'); pagination={{
}}></Button> total: this.state.total,
</Form.Item> current: this.state.page,
</Form> showQuickJumper: true,
<Table showSizeChanger: true,
dataSource={list} showTotal: (total) => `${total}`,
columns={columns} onChange: changePage
rowKey="id" }}
bordered={true} />
size={'small'} </div>
scroll={{ y: 500 }}
loading={loading}
rowSelection={{
selectedRowKeys: selectedRowKeys,
onChange: this.handleOnChange,
getCheckboxProps: () => ({
disabled: false
})
}}
pagination={{
total: this.state.total,
current: this.state.page,
showQuickJumper: true,
showSizeChanger: true,
showTotal: (total) => `${total}`,
onChange: changePage
}}
/>
</div> </div>
); );
} }

@ -75,14 +75,14 @@ const App: React.FC = () => {
key: 'serviceStatusName', key: 'serviceStatusName',
}, },
{ {
title: '启保时间', title: '起保日期',
dataIndex: 'startDate', dataIndex: 'startDate',
align: 'center', align: 'center',
width: 150, width: 150,
key: 'startDate', key: 'startDate',
}, },
{ {
title: '终保时间', title: '终保日期',
dataIndex: 'doneDate', dataIndex: 'doneDate',
align: 'center', align: 'center',
width: 150, width: 150,

Loading…
Cancel
Save