Commit b751d25a authored by cellee's avatar cellee

Signed-off-by: cellee <893264950@qq.com>

parent 6044e9a5
......@@ -44,5 +44,5 @@ hr {
.flex {
display: flex;
align-items: center;
justify-content: end;
justify-content: initial;
}
/*
* @Author: your name
* @Date: 2021-03-02 14:39:40
* @LastEditTime: 2021-05-20 16:32:22
* @LastEditTime: 2021-05-24 14:29:56
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx
......@@ -178,7 +178,7 @@ const service = (props: any) => {
imageType: 'tosReportImage',
identification: '',
}}
limitNums={10}
limitNums={5}
imgs={ImageSrc}
over={loading}
/>
......@@ -220,7 +220,7 @@ const service = (props: any) => {
imageType: 'tosReportImage',
identification: '',
}}
limitNums={10}
limitNums={5}
imgs={ImageSrc}
over={loading}
/>
......
/*
* @Author: your name
* @Date: 2021-03-02 14:39:40
* @LastEditTime: 2021-05-21 17:24:18
* @LastEditTime: 2021-05-25 10:28:07
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx
......@@ -39,7 +39,7 @@ const service = (props: any) => {
// 监听是否有数据
useEffect(() => {
if (match.params.id) {
RA(69, { id: match.params.id }, module, dispatch);
RA(69, { id: match.params.id, pageNum: 1 }, module, dispatch);
}
}, [match]);
......@@ -75,7 +75,14 @@ const service = (props: any) => {
const onFinish = (values: any) => {
values.reportId = reportList[listIdx].reportId;
console.log(values);
// 去掉http和阿里云oss后缀
values.imageNames = values.imageNames.map((item: any, idx: any) => {
if (item.indexOf('http') !== -1) {
let a = [item.lastIndexOf('/') + 1, item.indexOf('?')];
item = item.substring(a[0], a[1]);
}
return item;
});
let obj = {
imageContentDtos: [values],
......@@ -111,7 +118,7 @@ const service = (props: any) => {
setReportList([...arr]);
} else if (Result.state == 2) {
dispatch({ type: module + '/Results' });
RA(69, { id: match.params.id }, module, dispatch);
RA(69, { id: match.params.id, pageNum: 1 }, module, dispatch);
}
}
}, [Result]);
......@@ -161,9 +168,10 @@ const service = (props: any) => {
}
// 再开始分页
let a = JSON.parse(JSON.stringify(term.list));
let b = a.splice((page - 1) * 10, 10);
setReportList([...b]);
RA(69, { id: match.params.id, pageNum: page }, module, dispatch);
// let a = JSON.parse(JSON.stringify(term.list));
// let b = a.splice((page - 1) * 10, 10);
// setReportList([...b]);
};
return (
......@@ -214,7 +222,7 @@ const service = (props: any) => {
<Form.Item label="Description:" name="content" rules={[{ required: true }]}>
<TextArea rows={4} style={{ maxWidth: 600, width: '100%' }} />
</Form.Item>
<Form.Item label="Remarks:" name="reportRemark" rules={[{ required: true }]}>
<Form.Item label="Remarks:" name="reportRemark">
<TextArea rows={4} style={{ maxWidth: 600, width: '100%' }} />
</Form.Item>
......@@ -306,8 +314,8 @@ const service = (props: any) => {
<div style={{ textAlign: 'right' }}>
<Pagination
defaultCurrent={1}
defaultPageSize={10}
total={term && term.list ? term.list.length : 10}
defaultPageSize={term && term.page ? term.page.curPageSize : 5}
total={term && term.page ? term.page.totalRow : 5}
onChange={onChange}
/>
</div>
......
/*
* @Author: your name
* @Date: 2021-03-02 14:39:40
* @LastEditTime: 2021-05-21 18:07:39
* @LastEditTime: 2021-05-24 14:30:11
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx
......@@ -182,7 +182,7 @@ const service = (props: any) => {
imageType: 'tosReportImage',
identification: '',
}}
limitNums={10}
limitNums={5}
imgs={ImageSrc}
over={loading}
/>
......@@ -224,7 +224,7 @@ const service = (props: any) => {
imageType: 'tosReportImage',
identification: '',
}}
limitNums={10}
limitNums={5}
imgs={ImageSrc}
over={loading}
/>
......
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