提交 87c8123a authored 作者: vipcxj's avatar vipcxj

继续补完文档

上级 5f99a08b
...@@ -4355,6 +4355,11 @@ ...@@ -4355,6 +4355,11 @@
"integrity": "sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY=", "integrity": "sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY=",
"dev": true "dev": true
}, },
"batch-processor": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/batch-processor/-/batch-processor-1.0.0.tgz",
"integrity": "sha1-dclcMrdI4IUNEMKxaPa9vpiRrOg="
},
"bcrypt-pbkdf": { "bcrypt-pbkdf": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz", "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz",
...@@ -6786,6 +6791,14 @@ ...@@ -6786,6 +6791,14 @@
"integrity": "sha1-H71tl779crim+SHcONIkE9L2/d8=", "integrity": "sha1-H71tl779crim+SHcONIkE9L2/d8=",
"dev": true "dev": true
}, },
"element-resize-detector": {
"version": "1.1.14",
"resolved": "https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.1.14.tgz",
"integrity": "sha1-rwZKCmGKggrVcKlcXuxbd74BKME=",
"requires": {
"batch-processor": "1.0.0"
}
},
"elliptic": { "elliptic": {
"version": "6.4.0", "version": "6.4.0",
"resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.4.0.tgz", "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.4.0.tgz",
...@@ -9792,8 +9805,7 @@ ...@@ -9792,8 +9805,7 @@
"highlight.js": { "highlight.js": {
"version": "9.12.0", "version": "9.12.0",
"resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.12.0.tgz", "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.12.0.tgz",
"integrity": "sha1-5tnb5Xy+/mB1HwKvM2GVhwyQwB4=", "integrity": "sha1-5tnb5Xy+/mB1HwKvM2GVhwyQwB4="
"dev": true
}, },
"history": { "history": {
"version": "4.7.2", "version": "4.7.2",
...@@ -16375,11 +16387,19 @@ ...@@ -16375,11 +16387,19 @@
"integrity": "sha512-H0nT+KHADICdFgflNZ0A6+EBcExajxY8XM100tKOT5Oidhdo/0bAi26ffBhraEls4FIi8Lm4917tMq8LIWN7Qg==" "integrity": "sha512-H0nT+KHADICdFgflNZ0A6+EBcExajxY8XM100tKOT5Oidhdo/0bAi26ffBhraEls4FIi8Lm4917tMq8LIWN7Qg=="
}, },
"react-async-wrapper": { "react-async-wrapper": {
"version": "0.1.2", "version": "0.1.4",
"resolved": "https://registry.npmjs.org/react-async-wrapper/-/react-async-wrapper-0.1.2.tgz", "resolved": "https://registry.npmjs.org/react-async-wrapper/-/react-async-wrapper-0.1.4.tgz",
"integrity": "sha512-rUsqvpgVWLZaPnbai6oJu5sQcgpr1lgCCarAuFTzPd6wTlUecotU96+dYCdfVDpibTXwxsnzEAvn3fb2k1UpXA==", "integrity": "sha512-rdDNiq78DMh/O2+Eo/vaoO3hid+9Mw0AZJUveZgFhDdhdv/ZmiTX5qhHWkO5qPhmWMcTx27Z0Q11I5jilFAwIA==",
"requires": { "requires": {
"hoist-non-react-statics": "2.5.0",
"is-promise": "2.1.0" "is-promise": "2.1.0"
},
"dependencies": {
"hoist-non-react-statics": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-2.5.0.tgz",
"integrity": "sha512-6Bl6XsDT1ntE0lHbIhr4Kp2PGcleGZ66qu5Jqk8lc0Xc/IeG6gVLmwUGs/K0Us+L8VWoKgj0uWdPMataOsm31w=="
}
} }
}, },
"react-base16-styling": { "react-base16-styling": {
...@@ -16647,7 +16667,7 @@ ...@@ -16647,7 +16667,7 @@
"requires": { "requires": {
"hoist-non-react-statics": "2.5.0", "hoist-non-react-statics": "2.5.0",
"invariant": "2.2.4", "invariant": "2.2.4",
"react-async-wrapper": "0.1.2" "react-async-wrapper": "0.1.4"
} }
}, },
"react-router-dom": { "react-router-dom": {
...@@ -16673,6 +16693,17 @@ ...@@ -16673,6 +16693,17 @@
"react-router": "4.2.0" "react-router": "4.2.0"
} }
}, },
"react-sizeme": {
"version": "2.4.0",
"resolved": "https://registry.npmjs.org/react-sizeme/-/react-sizeme-2.4.0.tgz",
"integrity": "sha512-vddGHZBEQLqovIX+Vkf6TlugxRHgvAII66j4t4lGM+7N8da+j9OtcaEMtzmNrtrcYYawaZ5FM9JgC9RlLa1CBw==",
"requires": {
"element-resize-detector": "1.1.14",
"invariant": "2.2.4",
"lodash.debounce": "4.0.8",
"lodash.throttle": "4.1.1"
}
},
"react-slick": { "react-slick": {
"version": "0.21.0", "version": "0.21.0",
"resolved": "https://registry.npmjs.org/react-slick/-/react-slick-0.21.0.tgz", "resolved": "https://registry.npmjs.org/react-slick/-/react-slick-0.21.0.tgz",
......
...@@ -16,11 +16,13 @@ ...@@ -16,11 +16,13 @@
"antd": "^3.3.0", "antd": "^3.3.0",
"axo": "0.0.2", "axo": "0.0.2",
"bowser": "^1.8.1", "bowser": "^1.8.1",
"classnames": "latest",
"dva": "^2.1.0", "dva": "^2.1.0",
"dva-loading": "^1.0.4", "dva-loading": "^1.0.4",
"fastjson_ref_resolver": "latest", "fastjson_ref_resolver": "latest",
"fingerprintjs": "^0.5.3", "fingerprintjs": "^0.5.3",
"github-markdown-css": "^2.10.0", "github-markdown-css": "^2.10.0",
"highlight.js": "^9.12.0",
"history": "latest", "history": "latest",
"is-promise": "^2.1.0", "is-promise": "^2.1.0",
"lodash": "^4.17.4", "lodash": "^4.17.4",
...@@ -28,11 +30,12 @@ ...@@ -28,11 +30,12 @@
"moment": "^2.18.1", "moment": "^2.18.1",
"prop-types": "^15.6.1", "prop-types": "^15.6.1",
"react": "^16.2.0", "react": "^16.2.0",
"react-async-wrapper": "^0.1.2", "react-async-wrapper": "^0.1.4",
"react-dom": "^16.2.0", "react-dom": "^16.2.0",
"react-json-view": "^1.11.4", "react-json-view": "^1.11.4",
"react-markdown": "^3.3.0", "react-markdown": "^3.3.0",
"react-router-4-compat": "^0.1.8", "react-router-4-compat": "^0.1.8",
"react-sizeme": "^2.4.0",
"resolve-pathname": "^2.1.0", "resolve-pathname": "^2.1.0",
"uuid": "^3.1.0", "uuid": "^3.1.0",
"word-wrap": "^1.2.3", "word-wrap": "^1.2.3",
......
...@@ -5,12 +5,12 @@ import styles from './app.less'; ...@@ -5,12 +5,12 @@ import styles from './app.less';
const App = ({ children }) => { const App = ({ children }) => {
return ( return (
<div className={styles.app}>{children}</div> <div className={styles.app}>{children || null}</div>
); );
}; };
App.propTypes = { App.propTypes = {
children: PropTypes.oneOfType(PropTypes.element, PropTypes.arrayOf(PropTypes.element)).isRequired, children: PropTypes.oneOfType([PropTypes.element, PropTypes.arrayOf(PropTypes.element)]),
}; };
export default connect()(App); export default connect()(App);
...@@ -62,7 +62,7 @@ class Main extends React.Component { ...@@ -62,7 +62,7 @@ class Main extends React.Component {
<HeaderPane {...headerProps} /> <HeaderPane {...headerProps} />
</Header> </Header>
<Content> <Content>
{ children } { children || null }
</Content> </Content>
<Footer> <Footer>
<span className={styles.company}>®上海铂蓝信息科技有限公司</span> <span className={styles.company}>®上海铂蓝信息科技有限公司</span>
...@@ -75,7 +75,7 @@ class Main extends React.Component { ...@@ -75,7 +75,7 @@ class Main extends React.Component {
} }
Main.propTypes = { Main.propTypes = {
children: PropTypes.element, children: PropTypes.oneOfType([PropTypes.element, PropTypes.arrayOf(PropTypes.element)]),
main: PropTypes.object, main: PropTypes.object,
}; };
......
import React from 'react';
import PropTypes from 'prop-types';
import cs from 'classnames';
import hljs from 'highlight.js';
import 'highlight.js/styles/github.css';
class Code extends React.Component {
componentDidMount() {
this.highlightCode();
}
componentDidUpdate() {
this.highlightCode();
}
setRef = (el) => {
this.codeEl = el;
};
highlightCode = () => {
hljs.highlightBlock(this.codeEl);
};
render() {
return (
<pre>
<code
ref={this.setRef}
className={cs({
[`language-${this.props.language}`]: !!this.props.language,
})}
>
{ this.props.value }
</code>
</pre>
);
}
}
Code.propTypes = {
value: PropTypes.string.isRequired,
language: PropTypes.string,
};
Code.defaultProps = {
language: '',
};
export default Code;
...@@ -14,17 +14,30 @@ ...@@ -14,17 +14,30 @@
[{ [{
anZhiFangShi: string, anZhiFangShi: string,
beiChaiQianRen: string, beiChaiQianRen: string,
buWeiPingGuJieHeChongXinDanJia: number, buWeiPingGuJieHeChongXinDanJia: double,
chongZhiJieHeChengXin: number, chongZhiJieHeChengXin: double,
devices: [{ devices: [{
danJia:double,
jiLiang:double,
name:string,
unit:string,
zongJia:double
}], }],
erTai: string, erTai: int,
fangWuXingZhi: string, fangWuXingZhi: string,
fangWuZuoLuo: string, fangWuZuoLuo: string,
fuShuWuJinE: number, fuShuWuJinE: double,
fuShuWus: [{ fuShuWus: [{
danJia:double,
jieGou:string,
jiLiang:double,
name:string,
type:string,
unit:string,
usage:string,
zongJia:double
}], }],
heDingMianJi: number, heDingMianJi: double,
identityCard: string, identityCard: string,
isLocked: string, isLocked: string,
jiXiRiQi: date, jiXiRiQi: date,
...@@ -32,11 +45,11 @@ ...@@ -32,11 +45,11 @@
juMinLeiXing: string, juMinLeiXing: string,
leiXing: string, leiXing: string,
number: string, number: string,
pingGuMianJi: number, pingGuMianJi: double,
shiCeMianJi: number, shiCeMianJi: double,
tuDiZhengHao: string, tuDiZhengHao: string,
weiRenDingMianJi: number, weiRenDingMianJi: double,
wuZhengMJ: number, wuZhengMJ: double,
yingJianWeiJian: string, yingJianWeiJian: string,
yingJianWeiJianMJ: string, yingJianWeiJianMJ: string,
youZhengDuoYuMianJi: string, youZhengDuoYuMianJi: string,
......
# 新增房屋
新增房屋数据,支持批量。批量能有效提高性能,所以能批量就批量。
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - 新增的数据,必须是数组,即使只有一条数据。
```
[{
name:string,
zhengZaiMianJi:double,
pingGuDanJia:double,
pingGuJiaGe:double,
fangWuYongTu:string,
shiFouRenDing:string,
yangTaiMianJi:double,
pengSheMianJi:double,
chaoLing:string,
fangWuLeiXing:string,
renDingMianJi:double,
ceHuiMianJi:double,
tengKongShiJian:timestamp
}]
```
## 返回值
`[int]` - 新增的房屋的id
# 新增People
新增People数据,支持批量。批量能有效提高性能,所以能批量就批量。
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - 新增的数据,必须是数组,即使只有一条数据。
```
[{
name:string,
idCard:string,
sex:string,
age:int,
chanQuanRen:boolean,
relationWithChanQuanRen:string,
huZhu:boolean,
relationWithHuZhu:string,
teKun:boolean,
daBing:boolean,
gaoLing:boolean,
daLingWeiHun:boolean,
canJi:boolean,
zaiCe:boolean,
anZhi:boolean,
weiYun:boolean,
duShengZiNv:boolean,
birthDay:date,
cunZaiWeiHeDingPeiOu:boolean
}]
```
## 返回值
`[int]` - 新增的people的id
\ No newline at end of file
# 协议报审
报审协议支持批量报审
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - 报审要传的参数名格式如下,其中1 2 3 为协议的id
```
[{
1,2,3
}]
```
## 返回值
# bindClerks
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - 绑定经办人要传的参数名格式如下,其中1 2 3 为baseID
```
[{
1,2,3
}]
```
## 返回值
# 生成pdf
生成协议的pdf
## 前置条件
- 必须切换到基地这一级别
## 参数
- data -生成pdf要传的参数名格式如下,其中1 2 3 为协议的id
```
[{
1,2,3
}]
```
## 返回值
# getClerks
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - 获取经办人要传的参数名格式如下,其中1 2 3 为baseID
```
[{
1,2,3
}]
```
## 返回值
# getXieYiPdf
## 前置条件
- 必须切换到基地这一级别
- 必须指定XieYi id
- 已报审数据
## 参数
- data - 获取XieYi PDF 要传的参数名格式如下,其中1 2 3 XieYi id
```
[{
1,2,3
}]
```
## 返回值
# importFangYuan
importFangYuan数据
## 前置条件
- 必须切换到基地这一级别
## 参数
- data - importFangYuan的数据,必须是数组,即使只有一条数据。
```
[{
number:string,
type:string,
nature:string,
peiTao:string,
qiOrXian:string,
laiYuan:string
huXing:string,
taoXing:string,
jieGou:string,
usage:string,
yuCeMianJi:double,
yuCeYangTaiMianJi:double,
shiCeMianJi:double,
shiCeYangTaiMianJi:double,
sheJiMianJi:double,
sheJiYangTaiMianJi:double,
anZhiMianJi:double,
usedAreaType:string,
usedArea:double,
danJia:double,
youHuiDanJia:double,
zongJia:double,
youHuiZongJia:double,
shiCeZongJia:double,
district:string,
subDistrict:string,
community:string,
lane:string,
building:string,
unit:string,
no:string,
floor:string,
room:string,
contractNumber:,
diKuai:string,
address:string,
jinHuRiQi:date,
yuJiJiaoFangRiQi:date,
shiJiJiaoFangRiQi:date,
createDate:date
}]
```
## 返回值
\ No newline at end of file
import React from 'react'; import { makeAsync } from 'react-async-wrapper';
import { AsyncComponent } from 'react-async-wrapper'; import md from '../markdown';
import ReactMarkdown from 'react-markdown';
export default (match) => { export default (match) => {
const linkBase = `${match.url}/dynamic-interface`; const linkBase = `${match.url}/dynamic-interface`;
const pathBase = `${match.path}/dynamic-interface`; const pathBase = `${match.path}/dynamic-interface`;
return [ return [
['addFamily', '新增两清'], ['addFamily', '新增两清'],
['updateFamily', '修改两清'], ['addHouse', '新增房屋'],
['addPeople', '新增人口'],
['approveXieYi', '协议报审'],
['bindClerks', '绑定经办人'],
['generateXieYiPdf', '生成协议pdf'],
['getClerks', '获取经办人'],
['getXieYiPdf', '获取协议pdf'],
['importFangYuan', '导入房源'],
['isLiangQingLocked', '查询两清是否锁定'],
['isXieYiApproved', '查询协议是否审核'],
['isXieYiLocked', '查询协议是否锁定'],
['lockLiangQing', '锁定两清'],
['lockXieYi', '锁定协议'],
['removeFamily', '删除两清'], ['removeFamily', '删除两清'],
['removeFangYuan', '删除房源'],
['removeHouse', '删除房屋'],
['removePeople', '删除人口'],
['requestCancelXieYi', '申请撤销协议'],
['requestUnLockLiangQing', '申请解锁两清'],
['updateFamily', '更新两清'],
['updateHouse', '更新房屋'],
['updatePeople', '更新人口'],
['updateXieYi', '更新协议'],
].map(([name, showName]) => ({ ].map(([name, showName]) => ({
name, name,
showName, showName,
link: `${linkBase}/${name}`, link: `${linkBase}/${name}`,
path: `${pathBase}/${name}`, path: `${pathBase}/${name}`,
component: props => ( component: makeAsync({})(import(`./${name}.md`).then(md)),
<AsyncComponent asyncComponent={
() => import(`./${name}.md`).then(md => p => (
<div style={{
padding: '1em',
background: '#fafafa',
}}
>
<ReactMarkdown {...p} {...props} className="markdown-body" source={md} />
</div>
))
}
/>
),
})); }));
}; };
# isLiangQingLocked
## 前置条件
- 只能查询当前区域的数据
- 必须指定LiangQing id
## 参数
- data - 判断两清是否锁定要传的参数名格式如下,其中1 2 3 LiangQing id
```
[{
1,2,3
}]
```
## 返回值
# isXieYiApproved
## 前置条件
- 只能查询当前区域的数据
- 必须指定XieYi id
## 参数
- data - 判断XieYi是否审核要传的参数名格式如下,其中1 2 3 XieYi id
```
[{
1,2,3
}]
```
## 返回值
# isXieYiLocked
## 前置条件
- 只能查询当前区域的数据
- 必须指定XieYi id
## 参数
- data - 判断XieYi是否锁定要传的参数名格式如下,其中1 2 3 XieYi id
```
[{
1,2,3
}]
```
## 返回值
# LockLiangQing
## 前置条件
- 只能查询当前区域的数据
- 必须指定LiangQing id
## 参数
- data - 锁定两清要传的参数名格式如下,其中1 2 3 LiangQing id
```
[{
1,2,3
}]
```
## 返回值
# LockXieYi
## 前置条件
- 只能查询当前区域的数据
- 必须指定XieYi id
## 参数
- data - 锁定XieYi要传的参数名格式如下,其中1 2 3 XieYi id
```
[{
1,2,3
}]
```
## 返回值
# 删除两清 # 删除两清
## 前置条件
- 只能查询当前区域的数据
- 必须指定两清id
- 只有解锁的两清数据才能进行删除
## 参数
- data -删除两清要传的参数名格式如下,其中1 2 3 两清id
```
[{
1,2,3
}]
```
## 返回值
# 删除房源
## 前置条件
- 必须指定id
- 已使用的房源不能删除
## 参数
- data -删除房源要传的参数名格式如下,其中1 2 3 房源id
```
[{
1,2,3
}]
```
## 返回值
# 删除House
## 前置条件
- 只能查询当前区域的数据
- 必须指定House id
- 只有解锁的两清数据才能进行删除
## 参数
- data -删除House要传的参数名格式如下,其中1 2 3 House id
```
[{
1,2,3
}]
```
## 返回值
# 删除人口
## 前置条件
- 只能查询当前区域的数据
- 必须指定人口id
- 只有解锁的两清数据才能进行删除
## 参数
- data -删除人口要传的参数名格式如下,其中1 2 3 人口id
```
[{
1,2,3
}]
```
## 返回值
# requestCancelXieYi
## 前置条件
- 只能查询当前区域的数据
- 必须指定XieYi id
## 参数
- data -requestCancelXieYi要传的参数名格式如下,其中1 2 3 XieYi id
```
[{
1,2,3
}]
```
## 返回值
# requestUnLockLiangQing
## 前置条件
- 只能查询当前区域的数据
- 必须指定LiangQing id
- 只有解锁的两清数据才能进行操作
## 参数
- data -requestUnLockLiangQingi要传的参数名格式如下,其中1 2 3 LiangQing id
```
[{
1,2,3
}]
```
## 返回值
...@@ -16,17 +16,30 @@ ...@@ -16,17 +16,30 @@
id: int, id: int,
anZhiFangShi: string, anZhiFangShi: string,
beiChaiQianRen: string, beiChaiQianRen: string,
buWeiPingGuJieHeChongXinDanJia: number, buWeiPingGuJieHeChongXinDanJia: double,
chongZhiJieHeChengXin: number, chongZhiJieHeChengXin: double,
devices: [{ devices: [{
danJia:double,
jiLiang:double,
name:string,
unit:string,
zongJia:double
}], }],
erTai: string, erTai: string,
fangWuXingZhi: string, fangWuXingZhi: string,
fangWuZuoLuo: string, fangWuZuoLuo: string,
fuShuWuJinE: number, fuShuWuJinE: double,
fuShuWus: [{ fuShuWus: [{
danJia:double,
jieGou:string,
jiLiang:double,
name:string,
type:string,
unit:string,
usage:string,
zongJia:double
}], }],
heDingMianJi: number, heDingMianJi: double,
identityCard: string, identityCard: string,
isLocked: string, isLocked: string,
jiXiRiQi: date, jiXiRiQi: date,
...@@ -34,11 +47,11 @@ ...@@ -34,11 +47,11 @@
juMinLeiXing: string, juMinLeiXing: string,
leiXing: string, leiXing: string,
number: string, number: string,
pingGuMianJi: number, pingGuMianJi: double,
shiCeMianJi: number, shiCeMianJi: double,
tuDiZhengHao: string, tuDiZhengHao: string,
weiRenDingMianJi: number, weiRenDingMianJi: double,
wuZhengMJ: number, wuZhengMJ: double,
yingJianWeiJian: string, yingJianWeiJian: string,
yingJianWeiJianMJ: string, yingJianWeiJianMJ: string,
youZhengDuoYuMianJi: string, youZhengDuoYuMianJi: string,
......
# 更新房屋
更新房屋数据,支持批量。批量能有效提高性能,所以能批量就批量。
## 前置条件
- 必须指定房屋id
- 只有解锁的两清数据才能进行修改
## 参数
- data - 更新的数据,必须是数组,即使只有一条数据。
```
[{
name:string,
zhengZaiMianJi:double,
pingGuDanJia:double,
pingGuJiaGe:double,
fangWuYongTu:string,
shiFouRenDing:string,
yangTaiMianJi:double,
pengSheMianJi:double,
chaoLing:string,
fangWuLeiXing:string,
renDingMianJi:double,
ceHuiMianJi:double,
tengKongShiJian:timestamp
}]
```
## 返回值
# 更新People
更新People数据,支持批量。批量能有效提高性能,所以能批量就批量。
## 前置条件
- 必须指定 People id
- 只有解锁的两清数据才能进行修改
## 参数
- data - 更新的数据,必须是数组,即使只有一条数据。
```
[{
name:string,
idCard:string,
sex:string,
age:int,
chanQuanRen:boolean,
relationWithChanQuanRen:string,
huZhu:boolean,
relationWithHuZhu:string,
teKun:boolean,
daBing:boolean,
gaoLing:boolean,
daLingWeiHun:boolean,
canJi:boolean,
zaiCe:boolean,
anZhi:boolean,
weiYun:boolean,
duShengZiNv:boolean,
birthDay:date,
cunZaiWeiHeDingPeiOu:boolean
}]
```
## 返回值
# 更新XieYi
更新XieYi数据,支持批量。批量能有效提高性能,所以能批量就批量。
## 前置条件
- 必须指定fid
- 只有解锁的两清数据才能进行修改
## 参数
- data - 更新的数据,必须是数组,即使只有一条数据。
```
[{
anZhiFangShi:string,
zhuangHuangBuTie:double,
zhuangHuangBuTieGongShi:string,
fangWuJiaZhiBuChangKuan:double,
fangWuJiaZhiBuChangKuanGongShi:string,
weiRenDingMianJiZongJia:double,
weiRenDingMianJiZongJiaGongShi:string,
fuShuWuJinE:double,
fuShuWuGongShi:string,
tingChanTingYeBuTie:double,
tingChanTingYeBuTieGongShi:string,
qianYueRiQi:date,
jiXiRiQi:date,
banQianRiQi:date,
zuiHouJinE:double,
daiLiRens:string,
chaJiaJieSuan:double,
clauses:[{
content:string,
title:string
}],
jiangLiBuTies:[{
formula:string,
money:double,
name:string,
order:int,
type:string
}]
}]
```
## 返回值
.main { .main {
width:100%; width:100%;
height: 100%; // height: 100%;
position: relative;
margin:0 auto; margin:0 auto;
overflow:auto; overflow:auto;
_display:inline-block; _display:inline-block;
.catalogue { .catalogue {
width:200px; width:200px;
height: 100%; // height: 100%;
float:left; float:left;
background:#6F0; // background:#6F0;
font-size: 16px;
font-weight: bold;
margin-top: 1em;
list-style-type: cjk-ideographic;
overflow-y: scroll;
li{
margin-bottom: 15px;
}
li ul {
margin-top: 10px;
}
}
.leftMenu {
position: fixed;
} }
.contents { .contents {
margin-left: 200px; margin-left: 200px;
......
...@@ -8,10 +8,10 @@ ...@@ -8,10 +8,10 @@
message: string message: string
} }
``` ```
> - *errorCode*: 错误码,0表示成功,无错误 - *errorCode*: 错误码,0表示成功,无错误
> - *data*: 真正的返回数据,后续文档如无特别说明,对于返回形式的描述都是指的data的格式。 - *data*: 真正的返回数据,后续文档如无特别说明,对于返回形式的描述都是指的data的格式。
另外,发生错误时,这个字段也可能保护错误相关信息。 另外,发生错误时,这个字段也可能保护错误相关信息。
> - *message*: 错误消息,`errorCode`为0时,不使用这个字段。 - *message*: 错误消息,`errorCode`为0时,不使用这个字段。
2. 除了登录接口(获取token的接口),所有其他接口都要使用令牌(token)进行权限验证。 2. 除了登录接口(获取token的接口),所有其他接口都要使用令牌(token)进行权限验证。
token使用方式目前统一为: token使用方式目前统一为:
......
/* eslint-disable no-undef */ /* eslint-disable no-undef */
import React from 'react'; import React from 'react';
import { Link, Route, Switch } from 'dva/router'; import { Link, Route, Switch } from 'dva/router';
import { Affix } from 'antd';
import ReactMarkdown from 'react-markdown';
import 'github-markdown-css'; import 'github-markdown-css';
import styles from './index.less'; import styles from './index.less';
import mdIndex from './index.md'; import mdIndex from './index.md';
...@@ -10,24 +8,15 @@ import mdAuth from './auth.md'; ...@@ -10,24 +8,15 @@ import mdAuth from './auth.md';
import mdDomain from './domain.md'; import mdDomain from './domain.md';
import mdDyInt from './dynamic-interface/index.md'; import mdDyInt from './dynamic-interface/index.md';
import createPages from './dynamic-interface'; import createPages from './dynamic-interface';
import md from './markdown';
const md = mdString => props => (
<div style={{
padding: '1em',
background: '#fafafa',
}}
>
<ReactMarkdown {...props} className="markdown-body" source={mdString} />
</div>
);
class DocMainPage extends React.Component { class DocMainPage extends React.Component {
render() { render() {
const { match } = this.props; const { match } = this.props;
const pages = createPages(match); const pages = createPages(match);
return ( return (
<div className={styles.main} ref={(node) => { this.container = node && node.parentElement; }}> <div className={styles.main}>
<Affix target={() => this.container}> <div className={styles.leftMenu}>
<ul className={styles.catalogue}> <ul className={styles.catalogue}>
<li> <li>
<Link to={`${match.url}/index`}>前置说明</Link> <Link to={`${match.url}/index`}>前置说明</Link>
...@@ -49,7 +38,7 @@ class DocMainPage extends React.Component { ...@@ -49,7 +38,7 @@ class DocMainPage extends React.Component {
</ul> </ul>
</li> </li>
</ul> </ul>
</Affix> </div>
<div className={styles.contents}> <div className={styles.contents}>
<Switch> <Switch>
<Route path={`${match.path}/index`} component={md(mdIndex)} /> <Route path={`${match.path}/index`} component={md(mdIndex)} />
......
import React from 'react';
import cs from 'classnames';
import ReactMarkdown from 'react-markdown';
import Code from './code';
import styles from './markdown.less';
export default mdString => props => (
<div style={{
padding: '1em',
background: '#fafafa',
}}
>
<ReactMarkdown
{...props}
className={cs({
'markdown-body': true,
[styles.markdown]: true,
})}
source={mdString}
renderers={{
code: Code,
}}
/>
</div>
);
.markdown {
ul, ol {
li + li {
margin-top: 1em;
}
li {
ul, ol {
li + li {
margin-top: 0.25em;
}
}
}
}
}
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论