Commit 73968f49 authored by cellee's avatar cellee

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

parent 9c89611f
...@@ -23,7 +23,7 @@ const PictureOptionsRow = (props: any) => { ...@@ -23,7 +23,7 @@ const PictureOptionsRow = (props: any) => {
const [previewImage, setPreviewImage] = useState(''); const [previewImage, setPreviewImage] = useState('');
const [limitNum, setLimitNum] = useState(5); const [limitNum, setLimitNum] = useState(5);
const handleCancel = () => setPreviewVisible(false); const handleCancel = () => setPreviewVisible(false);
// const [imgLoad, setimgLoad] = useState(false); //图片上传 load状态 const [imgLoad, setimgLoad] = useState(false); //图片上传 load状态
useEffect(() => { useEffect(() => {
if (limitNums != null) { if (limitNums != null) {
...@@ -80,8 +80,8 @@ const PictureOptionsRow = (props: any) => { ...@@ -80,8 +80,8 @@ const PictureOptionsRow = (props: any) => {
// 加载logo // 加载logo
const uploadButton = ( const uploadButton = (
<div> <div>
{/* {loadding ? <LoadingOutlined /> : <PlusOutlined />} */} {imgLoad ? <LoadingOutlined /> : <PlusOutlined />}
<PlusOutlined /> {/* <PlusOutlined /> */}
<div className="ant-upload-text">Upload</div> <div className="ant-upload-text">Upload</div>
</div> </div>
); );
...@@ -115,7 +115,8 @@ const PictureOptionsRow = (props: any) => { ...@@ -115,7 +115,8 @@ const PictureOptionsRow = (props: any) => {
}); });
setFileList(tmp); setFileList(tmp);
console.log(tmp); setimgLoad(false);
var result = new Array(); var result = new Array();
tmp.map((item: any, index: number) => { tmp.map((item: any, index: number) => {
// 如果没返回就用原来的名称 // 如果没返回就用原来的名称
...@@ -126,6 +127,10 @@ const PictureOptionsRow = (props: any) => { ...@@ -126,6 +127,10 @@ const PictureOptionsRow = (props: any) => {
result.push(name); result.push(name);
}); });
onChange && onChange(result); onChange && onChange(result);
} else if (file.status == 'error') {
setimgLoad(false);
} else {
setimgLoad(true);
} }
}; };
......
...@@ -21,14 +21,14 @@ const service = (props: any) => { ...@@ -21,14 +21,14 @@ const service = (props: any) => {
width: 240, width: 240,
}, },
{ {
title: 'Rapporteur', title: 'Reported By',
dataIndex: 'reporterName', dataIndex: 'reporterName',
key: 'reporterName', key: 'reporterName',
width: 160, width: 160,
}, },
{ {
title: 'Upload description', title: 'Description',
dataIndex: 'reportContent', dataIndex: 'reportContent',
key: 'reportContent', key: 'reportContent',
width: 400, width: 400,
...@@ -66,13 +66,15 @@ const service = (props: any) => { ...@@ -66,13 +66,15 @@ const service = (props: any) => {
}, },
]; ];
const { Data, dispatch, loading, Init } = props; const { Data, dispatch, loading, Init, location } = props;
const [locationkey, setlocationkey] = useState(null as any); // 是否从其他列表刷新来的
const [term, setTerm] = useState(null as any); // 拉取数据的条件存储 const [term, setTerm] = useState(null as any); // 拉取数据的条件存储
// 监听是否有数据 // 监听是否有数据
useEffect(() => { useEffect(() => {
if (Init.CommunityList !== null && Data == null) { if (location.key !== locationkey && Init.CommunityList !== null) {
setlocationkey(location.key);
let obj = { let obj = {
communityNameList: Init.CommunityList, communityNameList: Init.CommunityList,
reporterName: null, reporterName: null,
...@@ -81,7 +83,7 @@ const service = (props: any) => { ...@@ -81,7 +83,7 @@ const service = (props: any) => {
setTerm({ ...obj }); setTerm({ ...obj });
RA(68, obj, module, dispatch); RA(68, obj, module, dispatch);
} }
}, [Init, Data]); }, [location, Init]);
// 清除操作之前的数据 // 清除操作之前的数据
const emptys = (data: any, url: any) => { const emptys = (data: any, url: any) => {
......
/* /*
* @Author: your name * @Author: your name
* @Date: 2021-03-02 14:39:40 * @Date: 2021-03-02 14:39:40
* @LastEditTime: 2021-03-15 15:25:59 * @LastEditTime: 2021-03-16 11:08:58
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx * @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx
...@@ -164,7 +164,7 @@ const service = (props: any) => { ...@@ -164,7 +164,7 @@ const service = (props: any) => {
<span>{term ? `${term.communityAddress} , ${term.postCode}` : null}</span> <span>{term ? `${term.communityAddress} , ${term.postCode}` : null}</span>
</Form.Item> </Form.Item>
{/* 报告人 */} {/* 报告人 */}
<Form.Item label="Rapporteur"> <Form.Item label="Reported By">
<span>{term ? term.reporterName : null}</span> <span>{term ? term.reporterName : null}</span>
</Form.Item> </Form.Item>
{/* 报告人联系方式 */} {/* 报告人联系方式 */}
...@@ -195,7 +195,7 @@ const service = (props: any) => { ...@@ -195,7 +195,7 @@ const service = (props: any) => {
{/* --------------------------------------------------------------------------------------------- */} {/* --------------------------------------------------------------------------------------------- */}
{/* 回复人信息 */} {/* 回复人信息 */}
{DataSave && DataSave.replyData.length > 0 ? ( {DataSave && DataSave.replyData.length > 0 ? (
<Form.Item label="Replier"> <Form.Item label="Amended By">
{DataSave.replyData[0].replyName} {DataSave.replyData[0].replyName}
<span style={{ display: 'inline-block', margin: '0 10px 0 50px' }}> <span style={{ display: 'inline-block', margin: '0 10px 0 50px' }}>
Contact Details :{' '} Contact Details :{' '}
......
/* /*
* @Author: your name * @Author: your name
* @Date: 2021-03-02 14:39:40 * @Date: 2021-03-02 14:39:40
* @LastEditTime: 2021-03-15 15:21:27 * @LastEditTime: 2021-03-16 10:59:31
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx * @FilePath: \tostumi\src\pages\AccountManagement\Service\serviceEdit.tsx
...@@ -137,7 +137,7 @@ const service = (props: any) => { ...@@ -137,7 +137,7 @@ const service = (props: any) => {
<span>{term ? `${term.communityAddress} , ${term.postCode}` : null}</span> <span>{term ? `${term.communityAddress} , ${term.postCode}` : null}</span>
</Form.Item> </Form.Item>
{/* 报告人 */} {/* 报告人 */}
<Form.Item label="Rapporteur"> <Form.Item label="Reported By">
<span>{term ? term.reporterName : null}</span> <span>{term ? term.reporterName : null}</span>
</Form.Item> </Form.Item>
{/* 报告人联系方式 */} {/* 报告人联系方式 */}
......
...@@ -9,16 +9,18 @@ import moment from 'moment'; ...@@ -9,16 +9,18 @@ import moment from 'moment';
import './index.less'; import './index.less';
const SystemFeedback = (props: any) => { const SystemFeedback = (props: any) => {
const { dispatch, Data, loading } = props; const { dispatch, Data, loading, location } = props;
const module = 'Bug'; const module = 'Bug';
const [locationkey, setlocationkey] = useState(null as any); // 是否从其他列表刷新来的
const [term, setTerm] = useState({ pageNum: 1 } as any); //页码 const [term, setTerm] = useState({ pageNum: 1 } as any); //页码
useEffect(() => { useEffect(() => {
if (!Data) { if (location.key !== locationkey) {
setlocationkey(location.key);
Refresh(); Refresh();
} }
}, [Data]); }, [location]);
const columns = [ const columns = [
{ title: 'Brand', dataIndex: 'phoneBrand' }, { title: 'Brand', dataIndex: 'phoneBrand' },
......
...@@ -9,19 +9,19 @@ import './Account.less'; ...@@ -9,19 +9,19 @@ import './Account.less';
import moment from 'moment'; import moment from 'moment';
const Account = (props: any) => { const Account = (props: any) => {
const { user, dispatch, Data, Result, loading } = props; const { user, dispatch, Data, Result, loading, location } = props;
const RA = (index: any, values: any) => { const RA = (index: any, values: any) => {
dispatch({ type: 'Account/RA', playload: { index: index, body: values } }); dispatch({ type: 'Account/RA', playload: { index: index, body: values } });
}; };
const [term, setTerm] = useState({} as any); // 拉取数据的条件存储 const [term, setTerm] = useState({} as any); // 拉取数据的条件存储
const [locationkey, setlocationkey] = useState(null as any); // 是否从其他列表刷新来的
// 数据 // 数据
useEffect(() => { useEffect(() => {
console.log(Data); if (location.key !== locationkey) {
if (Data == null) { setlocationkey(location.key);
Refresh(); Refresh();
} }
}, [Data]); //监听Data执行一次 }, [location]); //监听Data执行一次
// 监听改变状态提交结果 // 监听改变状态提交结果
useEffect(() => { useEffect(() => {
......
...@@ -36,6 +36,9 @@ const Detail = (props: any) => { ...@@ -36,6 +36,9 @@ const Detail = (props: any) => {
// 新加坡测 http://120.77.240.215:8611/ 图片名称 h51 // 新加坡测 http://120.77.240.215:8611/ 图片名称 h51
// 正式 http://47.74.233.180:8611/ 图片名称 h52 // 正式 http://47.74.233.180:8611/ 图片名称 h52
// const usage = 'http://192.168.1.28:8611/';
// const codeUrl = require('@/assets/h5.png');
const usage = 'http://120.77.240.215:8611/'; const usage = 'http://120.77.240.215:8611/';
const codeUrl = require('@/assets/h51.png'); const codeUrl = require('@/assets/h51.png');
......
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