提交 48da0be2 authored 作者: 吴强's avatar 吴强

eslint error fix

上级 4f76889e
......@@ -289,9 +289,9 @@
"integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4="
},
"antd-mobile": {
"version": "2.0.2",
"resolved": "http://registry.npm.taobao.org/antd-mobile/download/antd-mobile-2.0.2.tgz",
"integrity": "sha1-H/AYqApnWjmAz+JnRgZAgBbBedA=",
"version": "2.0.3",
"resolved": "http://registry.npm.taobao.org/antd-mobile/download/antd-mobile-2.0.3.tgz",
"integrity": "sha1-fu4PLiUfcKfwdN0HuiDvxZsF6IU=",
"requires": {
"array-tree-filter": "1.0.1",
"babel-runtime": "6.26.0",
......@@ -2512,9 +2512,9 @@
}
},
"dva-loading": {
"version": "1.0.3",
"resolved": "http://registry.npm.taobao.org/dva-loading/download/dva-loading-1.0.3.tgz",
"integrity": "sha1-7/qUSW+086OvHhWUEPDtxVrPneg=",
"version": "1.0.4",
"resolved": "http://registry.npm.taobao.org/dva-loading/download/dva-loading-1.0.4.tgz",
"integrity": "sha1-QN3fui3bbgR9QqQtxR1Q+tZC0Cs=",
"requires": {
"babel-runtime": "6.26.0"
}
......@@ -5636,9 +5636,9 @@
}
},
"moment": {
"version": "2.19.1",
"resolved": "http://registry.npm.taobao.org/moment/download/moment-2.19.1.tgz",
"integrity": "sha1-VtoaLRy/AdOLfhr8McELz6GSkWc="
"version": "2.19.2",
"resolved": "http://registry.npm.taobao.org/moment/download/moment-2.19.2.tgz",
"integrity": "sha1-in93TJWmRVC0x+vUlmg5CPlBnb4="
},
"morgan": {
"version": "1.6.1",
......@@ -7124,9 +7124,9 @@
}
},
"react": {
"version": "16.0.0",
"resolved": "http://registry.npm.taobao.org/react/download/react-16.0.0.tgz",
"integrity": "sha1-zn348ZQbA28Cssyp29DLHw6FXi0=",
"version": "16.1.1",
"resolved": "http://registry.npm.taobao.org/react/download/react-16.1.1.tgz",
"integrity": "sha1-1cTveVUH4wEigt1RJh/5wOgk/h8=",
"requires": {
"fbjs": "0.8.16",
"loose-envify": "1.3.1",
......@@ -7477,6 +7477,11 @@
"react-native-drawer-layout": "1.3.2"
}
},
"react-native-fetch-polyfill": {
"version": "1.1.2",
"resolved": "http://registry.npm.taobao.org/react-native-fetch-polyfill/download/react-native-fetch-polyfill-1.1.2.tgz",
"integrity": "sha1-JWtaCr14zEmS96fPglQ9ovISSnM="
},
"react-native-menu": {
"version": "0.23.0",
"resolved": "http://registry.npm.taobao.org/react-native-menu/download/react-native-menu-0.23.0.tgz",
......
......@@ -34,22 +34,22 @@
"preset": "jest-expo"
},
"dependencies": {
"antd-mobile": "^2.0.2",
"antd-mobile": "^2.0.3",
"dva-core": "^1.1.0",
"dva-loading": "^1.0.3",
"dva-loading": "^1.0.4",
"fastjson_ref_resolver": "0.0.3",
"lodash": "^4.17.4",
"moment": "^2.19.1",
"moment": "^2.19.2",
"rc-form": "^1.4.8",
"react": "^16.0.0-beta.5",
"react": "^16.1.1",
"react-native": "^0.49.3",
"react-native-camera": "^0.12.0",
"react-native-code-push": "^5.1.3-beta",
"react-native-device-info": "^0.12.1",
"react-native-fetch-polyfill": "^1.1.2",
"react-native-splash-screen": "^3.0.6",
"react-native-vector-icons": "^4.4.2",
"react-navigation": "^1.0.0-beta.19",
"react-native-fetch-polyfill": "^1.1.2",
"react-redux": "^5.0.6",
"redux-persist": "^4.10.1"
}
......
......@@ -8,6 +8,8 @@ import DSRInfoDetail from './dangshireninfo/dsrinfodetail';
import peopleInfo from './peopleInfo/peopleInfo';
import domain from './domain';
import userInfo from './userinfo/userinfo';
import QSInfo from './quanshuInfo/qsinfo';
import QSInfoDetail from './quanshuInfo/qsinfodetail';
export default [
welcome,
......@@ -20,4 +22,6 @@ export default [
DSRInfoDetail,
peopleInfo,
userInfo,
QSInfo,
QSInfoDetail,
];
......@@ -3,12 +3,16 @@
*/
import { StackNavigator } from 'react-navigation';
import QuanshuList from './quanshuList';
import QuanshuDetailScreen from './quanshuDetail';
const quanshuInfoErJiScreen = StackNavigator(
{
quanshuInfoList: {
screen: QuanshuList,
},
quanshuInfoDetail: {
screen: QuanshuDetailScreen,
},
},
{
headerMode: 'none',
......
/**
* Created by zhouhuan on 2017/11/13.
* Created by zhouhuan on 2017/10/30.
*/
import React from 'react';
import { ScrollView } from 'react-native';
import { List, WhiteSpace, WingBlank } from 'antd-mobile';
import { connect } from 'react-redux';
import { createAction } from '../../../utils';
@connect(({ QSInfoDetail }) => ({ QSInfoDetail }))
class QuanshuDetailScreen extends React.Component {
componentDidMount() {
const { id } = this.props.navigation.state.params;
this.props.dispatch(createAction('QSInfoDetail/getDSRInfoDetail')(id));
}
validateNoNull = (rule, value, callback) => {
if (value) {
callback();
} else {
callback(new Error('At least four charactors for account'));
}
};
render() {
const { singularData, metas } = this.props.QSInfoDetail;
return (
<ScrollView>
<WhiteSpace />
<WingBlank>
<List>
{
metas.map((m) => {
return (
<List.Item
key={m.key}
extra={singularData[m.key]}
>
{m.label}
</List.Item>
);
})
}
</List>
</WingBlank>
</ScrollView>
);
}
}
export default QuanshuDetailScreen;
......@@ -9,28 +9,28 @@ import { createAction } from '../../../utils/index';
import FlatListItem from '../../../components/FlatListItem';
import SearchComponent from '../../../components/searchComponent';
@connect(({ DSRInfo }) => ({ DSRInfo/* , loading: !!loading.effects['obligeeInfo/getObligeeInfo'] */ }))
@connect(({ QSInfo }) => ({ QSInfo/* , loading: !!loading.effects['obligeeInfo/getObligeeInfo'] */ }))
class QuanshuList extends Component {
componentDidMount() {
const { dispatch } = this.props;
dispatch(createAction('DSRInfo/getDSRList')({ clear: '', pName: this.props.DSRInfo.searchValue }));
dispatch(createAction('QSInfo/getQSList')({ clear: '', pZhengShuMingCheng: this.props.QSInfo.searchValue }));
}
onSearchSubmit = (pName) => {
this.props.dispatch(createAction('DSRInfo/getDSRList')({ clear: 'clear', pName }));
onSearchSubmit = (pZhengShuMingCheng) => {
this.props.dispatch(createAction('QSInfo/getQSList')({ clear: 'clear', pZhengShuMingCheng }));
};
onSearchChange = (pName) => {
this.props.dispatch(createAction('DSRInfo/setSearchValue')(pName));
onSearchChange = (pZhengShuMingCheng) => {
this.props.dispatch(createAction('QSInfo/setSearchValue')(pZhengShuMingCheng));
};
// 上拉加载更多
onEndReached = () => {
// 以下是制造新数据
if (!this.props.loading) {
// console.info('执行了上啦加载');
this.props.dispatch(createAction('DSRInfo/getDSRList')({ clear: '', pName: this.props.DSRInfo.searchValue }));
this.props.dispatch(createAction('QSInfo/getQSList')({ clear: '', pZhengShuMingCheng: this.props.QSInfo.searchValue }));
}
};
onPressItem = (id) => {
this.props.dispatch(createAction('DSRInfo/jumpPage')(id));
this.props.dispatch(createAction('QSInfo/jumpPage')(id));
};
getItemLayout = (data, index) => (
{ length: 120, offset: (120 + 1) * index, index }
......@@ -65,7 +65,7 @@ class QuanshuList extends Component {
// 下拉刷新
renderRefresh = () => {
if (!this.props.loading) {
this.props.dispatch(createAction('DSRInfo/getDSRList')({ clear: 'clear', pName: this.props.DSRInfo.searchValue }));
this.props.dispatch(createAction('QSInfo/getQSList')({ clear: 'clear', pZhengShuMingCheng: this.props.QSInfo.searchValue }));
}
};
/**
......@@ -79,8 +79,8 @@ class QuanshuList extends Component {
renderItem = ({ item }) => {
return (
<FlatListItem
title={item.dangShiRenXingMing}
meta={this.props.DSRInfo.metas}
title={item.zhengShuMingCheng}
meta={this.props.QSInfo.metas}
item={item}
onPressItem={this.onPressItem}
/>
......@@ -92,7 +92,7 @@ class QuanshuList extends Component {
<View>
<SearchComponent onSearchSubmit={this.onSearchSubmit} onSearchChange={this.onSearchChange} />
<FlatList
data={this.props.DSRInfo.sourceData}
data={this.props.QSInfo.sourceData}
keyExtractor={this.keyExtractor}
renderItem={this.renderItem}
// 决定当距离内容最底部还有多远时触发onEndReached回调;数值范围0~1,例如:0.5表示可见布局的最底端距离content最底端等于可见布局一半高度的时候调用该回调
......
......@@ -30,8 +30,8 @@ const config = {
productId: 'manager-app-sz',
footerText: '上海铂蓝信息科技有限公司',
contextPath: '',
// apiContextPath: 'http://14.21.68.149:9089/test',
apiContextPath: 'http://192.168.1.22:8080/bm',
apiContextPath: 'http://14.21.68.149:9089/test',
// apiContextPath: 'http://192.168.1.22:8080/bm',
defaultDateFormat,
defaultTimeFormat,
defaultDateTimeFormat,
......
......@@ -35,6 +35,7 @@ export default async function request(url, params = {}, options = {}, auth = tru
if (queryParams) {
realUrl = `${url}?${queryParams}`;
}
console.log(fetch);
return fetch(realUrl, _.defaults(options, defaultOptions))
.then(checkStatus)
.then(parseObject);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论