Commit f7079474 authored by cellee's avatar cellee

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

parent b2039d32
/*
* @Author: your name
* @Date: 2020-11-24 11:24:06
* @LastEditTime: 2020-12-04 10:48:48
* @LastEditors: your name
* @Description: In User Settings Edit
* @FilePath: \tostumi\config\defaultSettings.ts
*/
import { Settings as ProSettings } from '@ant-design/pro-layout'; import { Settings as ProSettings } from '@ant-design/pro-layout';
type DefaultSettings = ProSettings & { type DefaultSettings = ProSettings & {
...@@ -16,7 +24,7 @@ const proSettings: DefaultSettings = { ...@@ -16,7 +24,7 @@ const proSettings: DefaultSettings = {
menu: { menu: {
locale: true, locale: true,
}, },
title: 'TOS Manager', title: 'TOS Management',
pwa: false, pwa: false,
iconfontUrl: '', iconfontUrl: '',
}; };
......
...@@ -134,7 +134,7 @@ const TitleSearch = (props: any) => { ...@@ -134,7 +134,7 @@ const TitleSearch = (props: any) => {
{/* 小区列表的管理员姓名搜索 */} {/* 小区列表的管理员姓名搜索 */}
{username != null ? ( {username != null ? (
<Col key={'username_' + username[0]}> <Col key={'username_' + username[0]}>
<Form.Item name={username[0]} style={{ marginBottom: 15, width: 240 }}> <Form.Item name={username[0]} style={{ width: 240 }}>
<Input placeholder={username[1]} allowClear /> <Input placeholder={username[1]} allowClear />
</Form.Item> </Form.Item>
</Col> </Col>
......
...@@ -18,6 +18,8 @@ import Authorized from '@/utils/Authorized'; ...@@ -18,6 +18,8 @@ import Authorized from '@/utils/Authorized';
import RightContent from '@/components/GlobalHeader/RightContent'; import RightContent from '@/components/GlobalHeader/RightContent';
import { ConnectState } from '@/models/connect'; import { ConnectState } from '@/models/connect';
import { getAuthorityFromRouter } from '@/utils/utils'; import { getAuthorityFromRouter } from '@/utils/utils';
import style from './logo.less';
import logo from '../assets/logo.svg'; import logo from '../assets/logo.svg';
import tsIcon from '../assets/logo.png'; import tsIcon from '../assets/logo.png';
...@@ -110,34 +112,19 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => { ...@@ -110,34 +112,19 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
return ( return (
<ProLayout <ProLayout
logo={logo} logo={tsIcon}
contentStyle={{ backgroundColor: '#fff' }}
formatMessage={formatMessage} formatMessage={formatMessage}
menuHeaderRender={(logoDom, titleDom) => ( menuHeaderRender={(logo, title) => (
<div <div id={style.customize_menu_header}>
style={{ <Link to="/">
marginLeft: -25, {logo}
width: 260, {title}
height: 64, </Link>
backgroundColor: '#ffffff',
paddingLeft: 16,
paddingTop: 10,
}}
>
<img src={tsIcon} style={{ width: 50, height: 50 }} />
<span
style={{
fontSize: 18,
fontFamily: 'Source Han Sans CN',
fontWeight: 'bold',
color: 'rgba(51,51,51,1)',
}}
>
{' '}
TOS Management
</span>
</div> </div>
// <Link to="/"> // <Link to="/">
// {/* {logoDom} */} // {logoDom}
// {titleDom} // {titleDom}
// </Link> // </Link>
)} )}
......
#customize_menu_header {
margin-left: -24px;
width: 256px;
height: 64px;
line-height: 64px;
background-color: #ffffff;
padding-left: 24px;
h1 {
font-weight: bold;
color: rgb(51, 51, 51);
}
}
...@@ -93,6 +93,8 @@ const Model: LoginModelType = { ...@@ -93,6 +93,8 @@ const Model: LoginModelType = {
setCookie('id', userMessage.userModel.id); setCookie('id', userMessage.userModel.id);
setCookie('name', userMessage.userModel.tosUserName); setCookie('name', userMessage.userModel.tosUserName);
setCookie('phone', userMessage.userModel.tosUserPhone); setCookie('phone', userMessage.userModel.tosUserPhone);
// 更新用户信息
localStorage.setItem('userInfo', JSON.stringify(userMessage));
localStorage.setItem('permission', JSON.stringify(userMessage.permission)); localStorage.setItem('permission', JSON.stringify(userMessage.permission));
console.log('获取到Token:' + getCookie('token')); console.log('获取到Token:' + getCookie('token'));
yield put({ yield put({
...@@ -102,22 +104,26 @@ const Model: LoginModelType = { ...@@ -102,22 +104,26 @@ const Model: LoginModelType = {
password: payload.password, password: payload.password,
result: false, result: false,
}); });
const urlParams = new URL(window.location.href);
const params = getPageQuery(); // 路由缓存 再次登录回到上次打开页面
let { redirect } = params as { redirect: string }; // const urlParams = new URL(window.location.href);
if (redirect) { // const params = getPageQuery();
const redirectUrlParams = new URL(redirect); // let { redirect } = params as { redirect: string };
if (redirectUrlParams.origin === urlParams.origin) { // if (redirect) {
redirect = redirect.substr(urlParams.origin.length); // const redirectUrlParams = new URL(redirect);
if (redirect.match(/^\/.*#/)) { // if (redirectUrlParams.origin === urlParams.origin) {
redirect = redirect.substr(redirect.indexOf('#') + 1); // redirect = redirect.substr(urlParams.origin.length);
} // if (redirect.match(/^\/.*#/)) {
} else { // redirect = redirect.substr(redirect.indexOf('#') + 1);
window.location.href = '/'; // }
return; // } else {
} // window.location.href = '/';
} // return;
history.replace(redirect || '/'); // }
// }
// history.replace(redirect || '/');
// 只跳到首页
history.replace('/');
} else { } else {
message.error('Login Error! Username or Password is wrong!', 3); message.error('Login Error! Username or Password is wrong!', 3);
} }
...@@ -129,6 +135,7 @@ const Model: LoginModelType = { ...@@ -129,6 +135,7 @@ const Model: LoginModelType = {
// const response = yield call(AccountOut, payload); // const response = yield call(AccountOut, payload);
if (window.location.pathname !== '/user/login' && !redirect) { if (window.location.pathname !== '/user/login' && !redirect) {
// 清楚用户信息 // 清楚用户信息
localStorage.removeItem('userInfo');
localStorage.removeItem('permission'); localStorage.removeItem('permission');
setCookie('token', ''); setCookie('token', '');
setCookie('id', ''); setCookie('id', '');
......
...@@ -8,7 +8,7 @@ hr { ...@@ -8,7 +8,7 @@ hr {
background: #fff; background: #fff;
padding: 20px; padding: 20px;
border-right: 4px; border-right: 4px;
margin-bottom: 15px; margin-bottom: 0;
h3 { h3 {
margin-bottom: 15px; margin-bottom: 15px;
position: relative; position: relative;
......
import React, { useState, useEffect, useRef } from 'react'; import React, { useState, useEffect, useRef } from 'react';
import { Form, Input, Button, Pagination, message, Descriptions, Spin, Tree, Radio } from 'antd'; import { Form, Input, Button, message, Descriptions, Spin, Tree, Radio } from 'antd';
import { connect, history } from 'umi'; import { connect, history } from 'umi';
import { SearchOutlined, ClearOutlined, EditOutlined, LeftOutlined } from '@ant-design/icons'; import { EditOutlined, LeftOutlined } from '@ant-design/icons';
import { getCookie } from '@/utils/method'; import { getCookie } from '@/utils/method';
import './Account.less'; import './Account.less';
...@@ -12,12 +12,10 @@ import SelectCommunity from '@/components/SelectCommunity'; ...@@ -12,12 +12,10 @@ import SelectCommunity from '@/components/SelectCommunity';
import { getNumber } from '@/utils/string'; // 正则 import { getNumber } from '@/utils/string'; // 正则
import { RA } from '@/utils/method'; import { RA } from '@/utils/method';
import moment from 'moment';
const Account = (props: any) => { const Account = (props: any) => {
const module = 'Account'; const module = 'Account';
const { dispatch, Data, DataSave, SubResult, CommunityList, loading, user } = props; const { dispatch, SubResult, CommunityList, loading, user } = props;
// 权限列表 // 权限列表
const treeData = enUsFaci || zhCnFaci; const treeData = enUsFaci || zhCnFaci;
...@@ -119,13 +117,14 @@ const Account = (props: any) => { ...@@ -119,13 +117,14 @@ const Account = (props: any) => {
let obj = { let obj = {
userName: value.tosUserName, userName: value.tosUserName,
userPassword: value.tosUserPwd, userPassword: value.tosUserPwd,
permissionArray: checkedKeys.sort((n1, n2) => { permissionArray: checkedKeys.sort((n1: any, n2: any) => {
return parseInt(n1) - parseInt(n2); return parseInt(n1) - parseInt(n2);
}), }),
}; };
RA(38, value, module, dispatch); // 信息上传 RA(38, value, module, dispatch); // 信息上传
RA(42, obj, module, dispatch); // 权限上传 RA(42, obj, module, dispatch); // 权限上传
return true;
} }
}; };
...@@ -199,7 +198,7 @@ const Account = (props: any) => { ...@@ -199,7 +198,7 @@ const Account = (props: any) => {
> >
<Descriptions column={{ xs: 1, sm: 2, md: 3 }}> <Descriptions column={{ xs: 1, sm: 2, md: 3 }}>
<Descriptions.Item> <Descriptions.Item>
<Form.Item name="tosUserName" label="Account ID" rules={AccountTip[0]}> <Form.Item name="tosUserName" label="Account ID" rules={AccountTip[0] as any}>
<Input placeholder="Login Account" className="input" /> <Input placeholder="Login Account" className="input" />
</Form.Item> </Form.Item>
</Descriptions.Item> </Descriptions.Item>
...@@ -207,12 +206,12 @@ const Account = (props: any) => { ...@@ -207,12 +206,12 @@ const Account = (props: any) => {
<Descriptions column={{ xs: 1, sm: 2, md: 3 }}> <Descriptions column={{ xs: 1, sm: 2, md: 3 }}>
<Descriptions.Item> <Descriptions.Item>
<Form.Item name="tosAccountName" label="Name" rules={AccountTip[1]}> <Form.Item name="tosAccountName" label="Name" rules={AccountTip[1] as any}>
<Input placeholder="Name Of Administrator" className="input" /> <Input placeholder="Name Of Administrator" className="input" />
</Form.Item> </Form.Item>
</Descriptions.Item> </Descriptions.Item>
<Descriptions.Item> <Descriptions.Item>
<Form.Item name="tosUserPhone" label="Phone" rules={AccountTip[2]}> <Form.Item name="tosUserPhone" label="Phone" rules={AccountTip[2] as any}>
<Input <Input
placeholder="Contact Information" placeholder="Contact Information"
className="input" className="input"
......
import React, { useState, useEffect, useRef } from 'react'; import React, { useState, useEffect, useRef } from 'react';
import { Input, Tabs, Form, InputNumber, Col, Button, Row, message } from 'antd'; import { Input, Form, Button, message } from 'antd';
const { TabPane } = Tabs;
import { connect } from 'umi'; import { connect } from 'umi';
...@@ -119,7 +118,7 @@ const Add = (props: any) => { ...@@ -119,7 +118,7 @@ const Add = (props: any) => {
<Line /> <Line />
{extend.length > 0 ? ( {extend.length > 0 ? (
<> <>
<Form.Item wrapperCol={{ ...layout.wrapperCol, offset: 2 }} style={{ marginBottom: 0 }}> <Form.Item wrapperCol={{ offset: 2 }} style={{ marginBottom: 0 }}>
<Form.Item <Form.Item
style={{ display: 'inline-block', width: '200' }} style={{ display: 'inline-block', width: '200' }}
name={'balouscheduleFile'} name={'balouscheduleFile'}
...@@ -157,7 +156,7 @@ const Add = (props: any) => { ...@@ -157,7 +156,7 @@ const Add = (props: any) => {
</> </>
) : null} ) : null}
<Form.Item wrapperCol={{ ...layout.wrapperCol, offset: 2 }}> <Form.Item wrapperCol={{ offset: 2 }}>
<Button type="primary" htmlType="submit"> <Button type="primary" htmlType="submit">
Submit Submit
</Button> </Button>
......
...@@ -28,9 +28,6 @@ import PDF from 'react-pdf-js'; ...@@ -28,9 +28,6 @@ import PDF from 'react-pdf-js';
const { RangePicker } = TimePicker; const { RangePicker } = TimePicker;
// 接口申明
interface objc {}
const Adds = (props: any) => { const Adds = (props: any) => {
const module = 'CellList'; const module = 'CellList';
...@@ -195,7 +192,7 @@ const Adds = (props: any) => { ...@@ -195,7 +192,7 @@ const Adds = (props: any) => {
// 保质期上传 // 保质期上传
const upload3 = { const upload3 = {
onChange({ file, fileList }: any) { onChange({ file }: any) {
file.status === 'uploading' ? setimgLoad(true) : setimgLoad(false); file.status === 'uploading' ? setimgLoad(true) : setimgLoad(false);
if (file.status === 'done') { if (file.status === 'done') {
setPeriod(BackFormat(file.name, file.response.data)); setPeriod(BackFormat(file.name, file.response.data));
...@@ -233,7 +230,7 @@ const Adds = (props: any) => { ...@@ -233,7 +230,7 @@ const Adds = (props: any) => {
// 表单验证 // 表单验证
const onFinish = (values: any) => { const onFinish = (values: any) => {
let { residentialZipCode, residentialAddress, residentialName } = values.des; let { residentialZipCode } = values.des;
let tel = values.info.tel; let tel = values.info.tel;
if (values.residentialManagerUserName.length < 2) { if (values.residentialManagerUserName.length < 2) {
message.error('Please Enter 2-digit Zip Code!'); message.error('Please Enter 2-digit Zip Code!');
......
import React, { useState, useEffect } from 'react'; import React, { useState, useEffect } from 'react';
import { Space, Button, Form, message, Pagination, Tag } from 'antd'; import { Space, Button, message, Pagination } from 'antd';
import { connect, history } from 'umi'; import { connect, history } from 'umi';
// 图标 // 图标
...@@ -9,7 +9,6 @@ import ProTable from '@ant-design/pro-table'; ...@@ -9,7 +9,6 @@ import ProTable from '@ant-design/pro-table';
import TitleSearch from '@/components/TitleSearch/TitleSearch'; import TitleSearch from '@/components/TitleSearch/TitleSearch';
import { RA, SA } from '@/utils/method'; import { RA, SA } from '@/utils/method';
import { objectColumns } from '@/utils/string'; import { objectColumns } from '@/utils/string';
import { Prompt } from 'react-router';
const module = 'CellList'; const module = 'CellList';
import './celllist.less'; import './celllist.less';
...@@ -63,14 +62,14 @@ const CellLists = (props: any) => { ...@@ -63,14 +62,14 @@ const CellLists = (props: any) => {
const [term, setTerm] = useState({} as any); // 拉取数据的条件存储 const [term, setTerm] = useState({} as any); // 拉取数据的条件存储
// 翻页数据 // 翻页数据
function pagesList(name: string, list: any, num: number) { // function pagesList(name: string, list: any, num: number) {
let msg = { // let msg = {
residentialManagerUserName: name ? name : '', // residentialManagerUserName: name ? name : '',
communityNameList: list, // communityNameList: list,
pageNum: num, // pageNum: num,
}; // };
return msg; // return msg;
} // }
// 监听是否有小区列表 // 监听是否有小区列表
useEffect(() => { useEffect(() => {
...@@ -93,11 +92,8 @@ const CellLists = (props: any) => { ...@@ -93,11 +92,8 @@ const CellLists = (props: any) => {
} }
}, [village]); }, [village]);
const CallbackSearch = (values: any) => {
RA(24, { communityName: values }, module, dispatch);
};
const goToAdd = () => { const goToAdd = () => {
SA(null, module, dispatch); // 清空之前传递的数据 SA(null as any, module, dispatch); // 清空之前传递的数据
dispatch({ type: module + '/urlRemove' }); // 清掉图片信息 dispatch({ type: module + '/urlRemove' }); // 清掉图片信息
history.push('/CommunityManagement/CellList/Add'); history.push('/CommunityManagement/CellList/Add');
}; };
......
...@@ -2,7 +2,7 @@ li { ...@@ -2,7 +2,7 @@ li {
list-style: none; list-style: none;
} }
.contop { .contop {
padding: 16px; padding: 15px 15px 10px;
background: #fff; background: #fff;
margin-bottom: 15px; margin-bottom: 15px;
} }
......
import React, { useState, useEffect } from 'react'; import React, { useEffect } from 'react';
import { connect, history, useModel, Loading } from 'umi'; import { connect, history } from 'umi';
import { Input, Tabs, Table, Space, Button, Tooltip, Form, message, Pagination, Tag } from 'antd'; import { Input, Space, Button, Form, message, Pagination, Tag } from 'antd';
const { TabPane } = Tabs;
import moment from 'moment'; import moment from 'moment';
import { PlusOutlined, SearchOutlined, ClearOutlined } from '@ant-design/icons'; import { PlusOutlined, SearchOutlined, ClearOutlined } from '@ant-design/icons';
import ProTable from '@ant-design/pro-table'; import ProTable from '@ant-design/pro-table';
import { RA, SA } from '@/utils/method'; import { RA, SA } from '@/utils/method';
// import { objectColumns } from '@/utils/string'; // import { objectColumns } from '@/utils/string';
import { timestampToTime3, timestampToTime } from '@/utils/time';
import SearchOptionsCommnity from '@/components/SearchOptions/SearchOptionsCommnity'; import SearchOptionsCommnity from '@/components/SearchOptions/SearchOptionsCommnity';
const module = 'CommunityAnnouncement'; const module = 'CommunityAnnouncement';
const CommunityAnnouncement = (props: any) => { const CommunityAnnouncement = (props: any) => {
const { dispatch, Data, curString, userListLoading, DataSaveDetail } = props; const { dispatch, Data, userListLoading, DataSaveDetail } = props;
// 先清空 其他信息 // 先清空 其他信息
useEffect(() => { useEffect(() => {
...@@ -176,14 +174,14 @@ const CommunityAnnouncement = (props: any) => { ...@@ -176,14 +174,14 @@ const CommunityAnnouncement = (props: any) => {
SA(DetailPage(mlist), module, dispatch); SA(DetailPage(mlist), module, dispatch);
}; };
const onKeyUp = (value) => { const onKeyUp = (value: any) => {
console.log(value); console.log(value);
return false; return false;
}; };
return ( return (
<> <>
<div style={{ width: '100%', padding: 20, marginBottom: 15, backgroundColor: '#ffffff' }}> <div style={{ width: '100%', padding: 20, marginBottom: 0, backgroundColor: '#ffffff' }}>
<Form <Form
autoComplete="off" autoComplete="off"
layout="inline" layout="inline"
......
...@@ -198,7 +198,7 @@ const BookingDetail = (props: any) => { ...@@ -198,7 +198,7 @@ const BookingDetail = (props: any) => {
<InputNumber <InputNumber
placeholder="00.00" placeholder="00.00"
min={0} min={0}
max={parseInt(DataSave.communityMargin).toFixed(2)} max={parseInt(DataSave.communityMargin).toFixed(2) as any}
maxLength={6} maxLength={6}
step={0.01} step={0.01}
prefix="$" prefix="$"
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
.base { .base {
width: 100%; width: 100%;
background-color: #ffffff; background-color: #ffffff;
padding: 20px; padding: 15px;
} }
//头部组件 //头部组件
......
import React, { useState, useEffect, useRef } from 'react'; import React, { useState, useEffect, useRef } from 'react';
import { Input, Tabs, Table, Form, Button, message, DatePicker } from 'antd'; import { Input, Tabs, Tag, Form, Button, message, DatePicker } from 'antd';
const { TabPane } = Tabs; const { TabPane } = Tabs;
import { connect } from 'umi'; import { connect } from 'umi';
import { objectColumns } from '@/utils/string'; import { objectColumns } from '@/utils/string';
...@@ -39,7 +39,22 @@ const VisitorRecord = (props: any) => { ...@@ -39,7 +39,22 @@ const VisitorRecord = (props: any) => {
{ title: 'Security Guard', dataIndex: 'securityGuardName' }, { title: 'Security Guard', dataIndex: 'securityGuardName' },
{ title: 'Number Plate', dataIndex: 'numberPlate' }, { title: 'Number Plate', dataIndex: 'numberPlate' },
// 隐藏的搜索框 // 隐藏的搜索框
{ title: 'Visitor Time', dataIndex: 'updateTime', valueType: 'date' }, {
title: 'Visitor Time',
dataIndex: 'updateTime',
valueType: 'date',
render: (text: any, record: any) => {
if (record.linkStatus == 1) {
return text;
} else {
return (
<>
{text} <Tag color="red">Temporary</Tag>
</>
);
}
},
},
{ title: 'Community', dataIndex: 'visitorCommunity' }, { title: 'Community', dataIndex: 'visitorCommunity' },
// { title: 'Unit', dataIndex: 'inviterAddress' }, // { title: 'Unit', dataIndex: 'inviterAddress' },
{ {
...@@ -236,14 +251,14 @@ const VisitorRecord = (props: any) => { ...@@ -236,14 +251,14 @@ const VisitorRecord = (props: any) => {
Reset Reset
</Button> </Button>
</Form.Item> </Form.Item>
<div style={{ maxWidth: '100%', marginTop: 15, width: '100%' }}> <div style={{ marginTop: 24, marginRight: -16 }}>
<Form.Item name="community" label=""> <Form.Item name="community" label="">
<SelectCommunity /> <SelectCommunity />
</Form.Item> </Form.Item>
</div> </div>
</Form> </Form>
</div> </div>
<div style={{ width: '100%', padding: 16, backgroundColor: '#ffffff' }}> <div style={{ width: '100%', padding: '0px 15px 15px 15px', backgroundColor: '#ffffff' }}>
<ProTable <ProTable
loading={loading} loading={loading}
rowKey="id" rowKey="id"
......
...@@ -5,5 +5,5 @@ ...@@ -5,5 +5,5 @@
.VisitorRecord { .VisitorRecord {
padding: 15px; padding: 15px;
background: #fff; background: #fff;
margin-bottom: 15px; margin-bottom: 0;
} }
import React, { useState, useEffect, useRef } from 'react'; import React, { useState, useEffect, useRef } from 'react';
import { Input, Tabs, Table, Form, Button, message, DatePicker } from 'antd'; import { Input, Tabs, Tag, Form, Button, message, DatePicker } from 'antd';
const { TabPane } = Tabs; const { TabPane } = Tabs;
import { connect } from 'umi'; import { connect } from 'umi';
import { objectColumns } from '@/utils/string'; import { objectColumns } from '@/utils/string';
...@@ -39,7 +39,22 @@ const VisitorRecord = (props: any) => { ...@@ -39,7 +39,22 @@ const VisitorRecord = (props: any) => {
{ title: 'Security Guard', dataIndex: 'securityGuardName' }, { title: 'Security Guard', dataIndex: 'securityGuardName' },
{ title: 'Number Plate', dataIndex: 'numberPlate' }, { title: 'Number Plate', dataIndex: 'numberPlate' },
// 隐藏的搜索框 // 隐藏的搜索框
{ title: 'Visitor Time', dataIndex: 'updateTime', valueType: 'date' }, {
title: 'Visitor Time',
dataIndex: 'updateTime',
valueType: 'date',
render: (text: any, record: any) => {
if (record.linkStatus == 1) {
return text;
} else {
return (
<>
{text} <Tag color="red">Temporary</Tag>
</>
);
}
},
},
{ title: 'Community', dataIndex: 'visitorCommunity' }, { title: 'Community', dataIndex: 'visitorCommunity' },
// { title: 'Unit', dataIndex: 'inviterAddress' }, // { title: 'Unit', dataIndex: 'inviterAddress' },
{ {
...@@ -236,14 +251,14 @@ const VisitorRecord = (props: any) => { ...@@ -236,14 +251,14 @@ const VisitorRecord = (props: any) => {
Reset Reset
</Button> </Button>
</Form.Item> </Form.Item>
<div style={{ maxWidth: '100%', marginTop: 15, width: '100%' }}> <div style={{ marginTop: 24, marginRight: -16 }}>
<Form.Item name="community" label=""> <Form.Item name="community" label="">
<SelectCommunity /> <SelectCommunity />
</Form.Item> </Form.Item>
</div> </div>
</Form> </Form>
</div> </div>
<div style={{ width: '100%', padding: 16, backgroundColor: '#ffffff' }}> <div style={{ width: '100%', padding: '0px 15px 15px 15px', backgroundColor: '#ffffff' }}>
<ProTable <ProTable
loading={loading} loading={loading}
rowKey="id" rowKey="id"
......
...@@ -2,231 +2,227 @@ ...@@ -2,231 +2,227 @@
//基石 //基石
.base { .base {
width: 100%; width: 100%;
background-color: #ffffff; background-color: #ffffff;
padding: 20px; padding: 20px;
} }
//头部组件 //头部组件
.box{ .box {
width: 100%; width: 100%;
height: 64px; height: 64px;
position: relative; position: relative;
}
.item1{
position: absolute;
width: 400px;
text-indent: 15px;
border-left: 5px solid rgba(24,144,255,1);
font-family:'Source Han Sans CN';
font-size: 18px;
font-weight: 600;
color: #000000;
}
.item3{
width:80px;
height: 32px;
position: absolute;
right: 0;
outline: none;
background:none;
cursor: pointer;
border:1px solid rgba(217,217,217,1);
border-radius:2px;
}
.box1{
width: 100%;
height: 34px;
position: relative;
margin-bottom: 28px;
line-height: 34px;
}
.box1item1{
position: absolute;
}
.box1item2{
position: absolute;
left: 164px;
} }
.box1item3{ .item1 {
position: absolute; position: absolute;
left: 373px; width: 400px;
text-indent: 15px;
border-left: 5px solid rgba(24, 144, 255, 1);
font-family: 'Source Han Sans CN';
font-size: 18px;
font-weight: 600;
color: #000000;
}
.item3 {
width: 80px;
height: 32px;
position: absolute;
right: 0;
outline: none;
background: none;
cursor: pointer;
border: 1px solid rgba(217, 217, 217, 1);
border-radius: 2px;
}
.box1 {
width: 100%;
height: 34px;
position: relative;
margin-bottom: 28px;
line-height: 34px;
}
.box1item1 {
position: absolute;
}
.box1item2 {
position: absolute;
left: 164px;
}
.box1item3 {
position: absolute;
left: 373px;
}
.box1item4 {
position: absolute;
left: 530px;
}
.box1item5 {
position: absolute;
left: 740px;
}
.box1item6 {
position: absolute;
left: 890px;
}
.box4 {
width: 100%;
height: 34px;
position: relative;
margin-bottom: 28px;
}
.box4item1 {
position: absolute;
}
.box4item2 {
position: absolute;
left: 164px;
}
.box5 {
width: 100%;
height: 34px;
position: relative;
margin-bottom: 28px;
} }
.box1item4{ .box5item1 {
position: absolute; position: absolute;
left: 530px;
} }
.box1item5{ .box5item2 {
position: absolute; position: absolute;
left: 740px; left: 164px;
} }
.box1item6{
position: absolute;
left: 890px;
}
.box4{ .box6 {
width: 100%; width: 100%;
height: 34px; height: 34px;
position: relative; position: relative;
margin-bottom: 28px; margin-bottom: 28px;
} }
.box4item1{ .box6item1 {
position: absolute; position: absolute;
} }
.box4item2{ .box6item2 {
position: absolute; position: absolute;
left: 164px; left: 164px;
} }
.box5{ .box6item3 {
width: 100%; position: absolute;
height: 34px; left: 330px;
position: relative;
margin-bottom: 28px;
} }
.box5item1{ .box6item2x1 {
position: absolute; width: 120px;
} height: 34px;
.box5item2{ background: rgba(255, 255, 255, 1);
position: absolute; border: 1px solid rgba(217, 217, 217, 1);
left: 164px; border-radius: 2px;
text-align: center;
font-family: 'Source Han Sans CN';
font-weight: 400;
color: rgba(191, 191, 191, 1);
line-height: 34px;
} }
.box6{ .box7 {
width: 100%; width: 100%;
height: 34px; height: 34px;
position: relative; position: relative;
margin-bottom: 28px; margin-bottom: 28px;
} }
.box6item1{ .box7p {
position: absolute; width: 100%;
position: relative;
margin-bottom: 28px;
} }
.box6item2{ .box7item0 {
position: absolute; padding-left: 164px;
left: 164px; width: 400px;
} }
.box7item1 {
.box6item3{ position: absolute;
position: absolute; width: 100%;
left: 330px; height: 34px;
}
.box6item2x1{
width:120px;
height:34px;
background:rgba(255,255,255,1);
border:1px solid rgba(217,217,217,1);
border-radius:2px;
text-align: center;
font-family:'Source Han Sans CN';
font-weight:400;
color:rgba(191,191,191,1);
line-height:34px;
} }
.box7item2 {
.box7{ position: absolute;
width: 100%; left: 164px;
height: 34px; }
position: relative; .box7item3 {
margin-bottom: 28px; position: absolute;
} margin-left: 330px;
.box7p{
width: 100%;
position: relative;
margin-bottom: 28px;
}
.box7item0{
padding-left: 164px;
width: 400px;
}
.box7item1{
position: absolute;
width: 100%;
height: 34px;
}
.box7item2{
position: absolute;
left: 164px;
}
.box7item3{
position: absolute;
margin-left: 330px;
} }
.box8{ .box8 {
width: 100%; width: 100%;
height:194px; height: 194px;
position: relative; position: relative;
margin-bottom: 56px; margin-bottom: 56px;
} }
.box8item1{ .box8item1 {
position: absolute; position: absolute;
} }
.box8item2{ .box8item2 {
position: absolute; position: absolute;
left: 164px; left: 164px;
} }
.box8item2x2{ .box8item2x2 {
font-size: 12px;
font-size:12px; font-family: 'Source Han Sans CN';
font-family:'Source Han Sans CN'; font-weight: 400;
font-weight:400; color: rgba(153, 153, 153, 1);
color:rgba(153,153,153,1); line-height: 30px;
line-height:30px;
} }
.contop {
.contop{ padding: 20px 20px 10px;
padding: 20px; background: #fff;
background: #fff; margin-bottom: 0;
margin-bottom: 20px;
} }
// 字符串变红 // 字符串变红
.red{ .red {
color: red; color: red;
} }
// 合同详情 // 合同详情
.contract_box{ .contract_box {
overflow: hidden; overflow: hidden;
.list_1{ .list_1 {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
justify-items: center; justify-items: center;
flex-wrap: wrap; flex-wrap: wrap;
.item_1{ .item_1 {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
justify-items: center; justify-items: center;
line-height: 34px; line-height: 34px;
margin-right: 20px; margin-right: 20px;
label{ label {
display: inline-block;
width: 150px;
line-height: 32px;
}
}
}
.ant-form-item-label > label,.label{
display: inline-block; display: inline-block;
width: 150px; width: 150px;
line-height: 32px; line-height: 32px;
}
} }
}
.ant-form-item-label > label,
.label {
display: inline-block;
width: 150px;
line-height: 32px;
}
} }
.listbox{ .listbox {
width: 100%; width: 100%;
background-color: #ffffff; background-color: #ffffff;
padding: 10px; padding: 10px;
} }
.pages{ .pages {
text-align: right; text-align: right;
padding: 10px ; padding: 10px;
} }
\ No newline at end of file
/* /*
* @Author: your name * @Author: your name
* @Date: 2020-11-19 16:54:53 * @Date: 2020-11-19 16:54:53
* @LastEditTime: 2020-12-02 16:32:42 * @LastEditTime: 2020-12-04 11:41:39
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: \tostumi\src\utils\tip.ts * @FilePath: \tostumi\src\utils\tip.ts
*/ */
// 只能输入字母数字限制
const inputNumberStr = (rule: any, value: any, callback: any) => {
if (value) {
if (/^[a-zA-Z0-9]+$/g.test(value)) {
callback();
} else {
callback(new Error('Only numbers and letters can be entered!'));
}
}
callback();
};
// 只能输入数字限制
const inputNumber = (rule: any, value: any, callback: any) => {
if (value) {
if (/^[0-9]+$/g.test(value)) {
callback();
} else {
callback(new Error('Only numbers!'));
}
}
callback();
};
const reqMes = (msg: string) => {
return {
required: true,
message: msg,
};
};
// 合同提示 // 合同提示
export const tipList = [ export const tipList = [
['Please Input Contract Numbe!'], [reqMes('Please Input Contract Numbe!')],
['Please Input Contract Party A!'], [reqMes('Please Input Contract Party A!')],
['Please Input Contract Party B!'], [reqMes('Please Input Contract Party B!')],
['Please Choice CommunityName!'], [reqMes('Please Choice CommunityName!')],
['Please Choice Contract Title!'], [reqMes('Please Choice Contract Title!')],
['Please Choice Contract Time!'], [reqMes('Please Choice Contract Time!')],
['Please upload Contract Annex!'], [reqMes('Please upload Contract Annex!')],
// ['Please Input Contract Remarks!'], // [reqMes('Please Input Contract Remarks!')],
]; ];
// 小区提示 // 小区提示
export const village = [ export const village = [
[{ required: true, message: 'Please enter the postcode' }], [reqMes('Please enter the postcode !')],
[{ required: true, message: 'Please enter the address of the community !' }], [reqMes('Please enter the address of the community !')],
[{ required: true, message: 'Please enter the cell name !' }], [reqMes('Please enter the cell name !')],
[{ required: true, message: 'Please select the time !' }], [reqMes('Please select the time !')],
[{ required: true, message: 'Please enter your mobile phone number !' }], [reqMes('Please enter your mobile phone number !')],
[ [{ ...reqMes('Please enter the correct email address !'), type: 'email' }],
{ [reqMes('Please enter the name of the community administrator !')],
required: true,
type: 'email',
message: 'Please enter the correct email address !',
},
],
[{ required: true, message: 'Please enter the name of the community administrator !' }],
]; ];
//公告提示 //公告提示
export const Notice = [ export const Notice = [
[{ required: true, message: 'Please select community' }], [reqMes('Please select community')],
[{ required: true, message: 'Please input the notice title.' }], [reqMes('Please input the notice title.')],
[{ required: true, message: 'Please input the announcement content.' }], [reqMes('Please input the announcement content.')],
[{ required: true, message: 'Please choose the effective time of the announcement.' }], [reqMes('Please choose the effective time of the announcement.')],
]; ];
// 新增设施 // 新增设施
export const NewFaci = [ export const NewFaci = [
[{ required: true, message: 'Please select community' }], [reqMes('Please select community')],
[{ required: true, message: 'Please input Facility Name' }], [reqMes('Please input Facility Name')],
[{ required: false, message: 'Please Set management fee' }], [reqMes('Please Set management fee')],
[{ required: false, message: 'Please Set Setting deposit' }], [reqMes('Please Set Setting deposit')],
[{ required: true, message: 'Please Upload facility photos' }], [reqMes('Please Upload facility photos')],
[{ required: true, message: 'Required' }], [reqMes('Required')],
[{ required: true, message: 'Required' }], [reqMes('Required')],
[{ required: true, message: 'Required' }], [reqMes('Required')],
[{ required: true, message: 'Required' }], [reqMes('Required')],
[{ required: true, message: 'Required' }], [reqMes('Required')],
]; ];
// 设施预订 // 设施预订
export const BookingsTip = [ export const BookingsTip = [
[{ required: true, message: 'Please input Name ' }], [reqMes('Please input Name ')],
[{ required: true, message: 'Please input Contact Details' }], [reqMes('Please input Contact Details')],
[{ required: true, pattern: new RegExp(/^[1-9]\d*$/, 'g'), message: 'Only numbers!' }], // [{ required: true, pattern: new RegExp(/^[1-9]\d*$/, 'g'), message: 'Only numbers!')],
[{ required: true, pattern: new RegExp(/^[1-9]\d*$/, 'g'), message: 'Only numbers!' }], [{ ...reqMes(''), validator: inputNumber }],
[{ required: true, message: 'Required' }], [{ ...reqMes(''), validator: inputNumber }],
[{ required: true, message: 'Please Select The Date' }], [{ ...reqMes(''), validator: inputNumberStr }],
[reqMes('Please Select The Date')],
]; ];
// 账号新增编辑 // 账号新增编辑
export const AccountTip = [ export const AccountTip = [
[{ required: true, type: 'email', message: 'Please enter email address !' }], [{ ...reqMes('Please enter email address !'), type: 'email' }],
[{ required: true, message: 'Required' }], [reqMes('Required')],
[{ required: true, message: 'Please enter the correct contact information !' }], [reqMes('Please enter the correct contact information !')],
[{ required: true, message: 'Required' }],
[{ required: true, message: 'Required' }],
[{ required: true, message: 'Required' }],
[{ required: true, message: 'Required' }],
]; ];
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