This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import { connect } from 'react-redux'; | |
| import { StyleSheet, View, FlatList } from 'react-native'; | |
| import Icon from 'react-native-vector-icons/FontAwesome'; | |
| import { List, ListItem, SearchBar } from 'react-native-elements'; | |
| import { Container, Content, Text, Button, Label } from 'native-base'; | |
| import Spinner from 'react-native-loading-spinner-overlay'; | |
| import { requestAttachedFacilities } from '../actions/pickFacility'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -------------- REDUCER ----------------------- | |
| import { RESPONSE_ADMIN_ATTACHED_FACILITIES, ERROR, RESET_DATA } from '../actions/pickFacility'; | |
| const initialState = { | |
| isLoading: true, | |
| msg: null, | |
| attachedFacilities: [], | |
| }; | |
| export default (state = initialState, action) => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { | |
| RESPONSE_ADMIN_ATTACHED_FACILITIES, | |
| ERROR, | |
| REQUEST_ATTACHED_ENTITIES_STARTED, | |
| } from '../actions/pickFacility'; | |
| const initialState = { | |
| attachedFacilities: [], | |
| msg: false, | |
| isLoading: true, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| render() { | |
| console.log(`i am in the render method with this.props.PickFacility.msg ${this.props.PickFacility.msg}`); | |
| const displayView = this.props.PickFacility.msg ? ( | |
| <View | |
| style={{ | |
| flex: 1, | |
| alignSelf: 'center', | |
| marginTop: '50%', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { call, put, select, take, fork, all, takeLatest } from 'redux-saga/effects'; | |
| import axios from 'axios'; | |
| import querystring from 'query-string'; | |
| import Config from 'react-native-config'; | |
| import { | |
| REQUEST_ATTACHED_FACILITIES, | |
| responseAdminAttachedFacilities, | |
| errorFetchFacilties, | |
| } from '../../../actions/pickFacility'; |