Skip to content

Commit 182d003

Browse files
committed
dupi 添加头部注释信息
1 parent fa44150 commit 182d003

File tree

8 files changed

+58
-65
lines changed

8 files changed

+58
-65
lines changed

app/containers/App/leftNav/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export default class LeftNav extends Component {
2020
this.state = {
2121
current: pathname,
2222
openKeys: ['sub1'],
23-
isLeftNavMini: false,
23+
isLeftNavMini: true,
2424
}
2525

2626
this._handleClick = this._handleClick.bind(this)

app/pages/house/houseManage.js

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
/*
2+
* @Author: dupi
3+
* @Date: 2017-06-28 17:16:12
4+
* @Last Modified by: dupi
5+
* @Last Modified time: 2017-06-29 15:54:17
6+
*/
17
import React, { Component } from 'react'
28
import { connect } from 'react-redux'
39
import { Link } from 'react-router'
@@ -19,14 +25,18 @@ import SearchTable from 'components/searchTable'
1925
export default class houseCheckList extends Component {
2026
constructor(props) {
2127
super(props)
22-
this.state = { }
28+
this.state = {
29+
data: {
30+
31+
},
32+
}
2333
this._handleSubmit = this._handleSubmit.bind(this)
2434
this.cacheSearch = this.cacheSearch.bind(this)
2535
this._clear = this._clear.bind(this)
2636
}
2737

2838
componentDidMount() {
29-
this.props.dispatch(fetchHouseCheckList({ currentPage: 1 }))
39+
this.props.dispatch(fetchHouseCheckList({ currentPage: 1 }, (respose) => {}))
3040
}
3141

3242
_handleSubmit(query, currentPage) {
@@ -35,6 +45,10 @@ export default class houseCheckList extends Component {
3545
}
3646

3747
searchList() {
48+
const { data } = this.state
49+
data && data.list && data.list.map(item => {
50+
51+
})
3852
const { config } = this.props
3953
return [
4054
{
@@ -128,6 +142,7 @@ export default class houseCheckList extends Component {
128142

129143
render() {
130144
const { houseCheckSearchQuery, houseCheckSearchResult } = this.props
145+
131146
// console.log(houseCheckSearchResult)
132147
return (
133148
<div className="page">

app/pages/test/index.js

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,14 @@
1+
/*
2+
* @Author: dupi
3+
* @Date: 2017-06-29 15:34:19
4+
* @Last Modified by: dupi
5+
* @Last Modified time: 2017-06-29 15:39:44
6+
*/
7+
18
import React, { Component } from 'react'
29
import ReactDom from 'react-dom'
310
import { connect } from 'react-redux'
4-
import { Form, Input, Tooltip, Icon, Cascader, Select, Row, Col, Checkbox, Button } from 'antd'
11+
import { Cascader, Select, Row, Col, Checkbox, Button } from 'antd'
512

613

714
import Sub from './sub'
@@ -15,24 +22,23 @@ import Sub from './sub'
1522
export default class popCheck extends Component {
1623
constructor(props) {
1724
super(props)
18-
this.state = {
19-
show: true
25+
this.state = {
26+
show: true,
2027
}
2128
}
2229

2330
componentDidMount() {
24-
2531
console.log(this.props)
2632
}
2733

2834

29-
30-
3135
render() {
3236
return (
3337
<div className="page">
3438
测试
35-
<Sub/>
39+
<span>weorwe</span>
40+
<img src="../../images/default.png" />
41+
<Sub />
3642
</div>
3743
)
3844
}

app/pages/test/sub.js

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,19 @@ import Third from './third'
1313
export default class sub extends Component {
1414
constructor(props) {
1515
super(props)
16-
this.state = {
17-
16+
this.state = {
17+
1818
}
1919
}
2020

2121
componentDidMount() {
22-
23-
}
2422

23+
}
2524

2625

27-
2826
render() {
2927
return (
30-
<div className="page">
28+
<div className="page">
3129
<h1>我是二级页面</h1>
3230
<Third />
3331
</div>

app/pages/welcome.js

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
/*
2-
** creator: dupi 2016-11-10 11:30 创建js
3-
** editor: dupi 2016-02-09 16:00 在头部添加文件修改记录
4-
*/
2+
* @Author: dupi
3+
* @Date: 2017-06-27 13:51:09
4+
* @Last Modified by: dupi
5+
* @Last Modified time: 2017-06-27 15:09:38
6+
*/
7+
8+
59
import React, { Component } from 'react'
610
import { connect } from 'react-redux'
711

@@ -16,6 +20,7 @@ export default class welcome extends Component {
1620
constructor(props, context) {
1721
super(props)
1822
this.state = {
23+
data: {},
1924
}
2025
}
2126

mockapi/data.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
"totalCount": 100,
8787
"currentPage": 1
8888
},
89-
"msg":"",
89+
"msg":"没有权限",
9090
"errorCode": "",
9191
"status": 1
9292
}

mockserver.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
var http = require('http');
2-
var fs = require('fs');
1+
const http = require('http');
2+
const fs = require('fs');
33

4-
http.createServer(function(req,res){
5-
var content = "";
6-
res.writeHead(200, {
4+
http.createServer(function (req, res) {
5+
let content = '';
6+
res.writeHead(200, {
77
'Content-Type': 'text/plain',
8-
'Access-Control-Allow-Origin':'*'
9-
});
8+
'Access-Control-Allow-Origin': '*',
9+
});
1010
// console.log("URL--->",req.url)
11-
try{
12-
content = fs.readFileSync(__dirname+req.url);
13-
}catch(e){
14-
content = "";
11+
try {
12+
content = fs.readFileSync(__dirname + req.url);
13+
} catch (e) {
14+
content = '';
1515
}
1616
res.write(content);
1717
res.end();
18-
}).listen(8080);
18+
}).listen(8080);

package.json

Lines changed: 2 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
"version": "0.0.1",
44
"description": "duxiaodu",
55
"repository": {
6-
"type": "gitlab",
7-
"url": "http://192.168.1.88/duxiaodu"
6+
"type": "git",
7+
"url": "https://github.com/duxianwei520/react"
88
},
99
"private": true,
1010
"scripts": {
@@ -84,36 +84,5 @@
8484
"redux-actions": "~0.10.1",
8585
"redux-thunk": "~2.1.0",
8686
"webpack": "~1.13.1"
87-
},
88-
"ava": {
89-
"files": [
90-
"./app/**/*.test.js"
91-
],
92-
"require": [
93-
"./test/setup-test-env.js"
94-
],
95-
"failFast": true,
96-
"tap": true,
97-
"babel": "inherit"
98-
},
99-
"config": {
100-
"validate-commit-msg": {
101-
"types": [
102-
"feat",
103-
"fix",
104-
"docs",
105-
"style",
106-
"refactor",
107-
"perf",
108-
"test",
109-
"chore",
110-
"revert"
111-
],
112-
"warnOnFail": false,
113-
"maxSubjectLength": 100,
114-
"subjectPattern": ".+",
115-
"subjectPatternErrorMsg": "subject does not match subject pattern!",
116-
"helpMessage": ""
117-
}
11887
}
11988
}

0 commit comments

Comments
 (0)