Skip to content

Commit

Permalink
Merge branch 'feature/notification' into 'develop'
Browse files Browse the repository at this point in the history
pagination complete

See merge request snsmobile/UserHybrid!39
  • Loading branch information
Le Linh committed Jun 5, 2018
2 parents a2656a8 + c895263 commit 4a92839
Show file tree
Hide file tree
Showing 13 changed files with 678 additions and 87 deletions.
213 changes: 211 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@
"redux-form": "7.3.0",
"redux-thunk": "2.2.0",
"rxjs": "^5.5.8",
"socket.io-client": "^2.1.1",
"subscriptions-transport-ws": "^0.9.8",
"validator": "9.4.1"
}
Expand Down
23 changes: 17 additions & 6 deletions src/container/ChangePasswordScreen/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { Component } from "react";
import { Content, Text, Form, Button, View, Toast } from "native-base";
import { Content, Text, Form, Button, View, Toast, Header, Left, Right, Body, Icon, Title } from "native-base";
import { Field, reduxForm, formValueSelector } from "redux-form";
import { compose, graphql } from "react-apollo";
import { connect } from "react-redux";
Expand Down Expand Up @@ -71,9 +71,10 @@ class ChangePassword extends Component {
type: "success"
});
this.props.dispatch(utils.createAction(CHANGE_PASSWORD_SUCCESS));
setTimeout( () => this.props.logOut(this.props.navigation), 300);
setTimeout(() => this.props.logOut(this.props.navigation), 300);
} catch (error) {
const errorMessage = error && error.graphQLErrors && error.graphQLErrors[0].message || "Đổi password không thành công";
const errorMessage =
(error && error.graphQLErrors && error.graphQLErrors[0].message) || "Đổi password không thành công";
Toast.show({
text: errorMessage,
duration: 2500,
Expand All @@ -89,9 +90,19 @@ class ChangePassword extends Component {
render() {
const { handleSubmit, valid, submitting, pristine } = this.props;
return (
<Layout navigation={this.props.navigation}>
<Content padder style={{ backgroundColor: "#ccc" }}>
<Text style={{ textAlign: "center" }}>{"Đổi Mật Khẩu"}</Text>
<Layout navigation={this.props.navigation} >
<Header>
<Left>
<Button transparent onPress={() => this.props.navigation.goBack()}>
<Icon name="ios-arrow-back" />
</Button>
</Left>
<Body>
<Title> Đổi mật khẩu </Title>
</Body>
<Right />
</Header>
<Content padder style={{ backgroundColor: "rgba(85,186,255, 1)" }}>
{this.formRender()}
<View padder style={styles.btnLoginWrapper}>
<Button
Expand Down
Loading

0 comments on commit 4a92839

Please sign in to comment.