Correction de bugs
This commit is contained in:
parent
0a1c1f896a
commit
4a574e9a6f
45
App.js
45
App.js
|
@ -6,12 +6,17 @@
|
|||
* @flow
|
||||
*/
|
||||
|
||||
import React, { Component } from 'react';
|
||||
import { ActionSheetProvider, connectActionSheet } from '@expo/react-native-action-sheet'
|
||||
import { Platform, StyleSheet, Text, View, YellowBox, AsyncStorage } from 'react-native';
|
||||
import { createAppContainer, HeaderBackButton, createSwitchNavigator, createStackNavigator, createBottomTabNavigator, createDrawerNavigator } from 'react-navigation';
|
||||
import React from 'react';
|
||||
import {ActionSheetProvider} from '@expo/react-native-action-sheet'
|
||||
import {AsyncStorage, Platform, StyleSheet} from 'react-native';
|
||||
import {
|
||||
createAppContainer,
|
||||
createBottomTabNavigator,
|
||||
createDrawerNavigator,
|
||||
createStackNavigator,
|
||||
createSwitchNavigator
|
||||
} from 'react-navigation';
|
||||
import OneSignal from 'react-native-onesignal';
|
||||
import _ from 'lodash';
|
||||
import Connect from "./screens/login/Connect";
|
||||
import SplashScreen from "./screens/splashscreen/SplashScreen";
|
||||
import HelpMenu from "./screens/help/HelpMenu";
|
||||
|
@ -26,8 +31,6 @@ import ActivateAccount from "./screens/login/ActivateAccount";
|
|||
import Notifications from "./screens/notifications/Notifications";
|
||||
import About from "./screens/configurations/About";
|
||||
import Configurations from "./screens/configurations/Configurations";
|
||||
|
||||
import History from './screens/history-request/History'
|
||||
import OptionsMenu from "./screens/optionMenu/OptionsMenu";
|
||||
import Home from "./screens/home/Home";
|
||||
import HistoryItemDetails from "./screens/history-request/HistoryItemDetails";
|
||||
|
@ -36,18 +39,13 @@ import HistoryRequester from "./screens/history-request/HistoryRequester";
|
|||
import AddNetwork from "./screens/account/AddNetwork";
|
||||
import MyHistory from "./screens/history-request/MyHistory";
|
||||
import Icon from "react-native-vector-icons/FontAwesome5";
|
||||
import { Appbar } from 'react-native-paper';
|
||||
|
||||
import IconWithBadge from "./screens/IconWithBadge"
|
||||
import I18n from "react-native-i18n";
|
||||
import Filter from './screens/home/Filter';
|
||||
import { createMaterialBottomTabNavigator } from 'react-navigation-material-bottom-tabs';
|
||||
|
||||
import WalletDetail from './screens/wallet/WalletDetail';
|
||||
import WalletSelect from './screens/wallet/WalletSelect';
|
||||
import {PersistGate} from 'redux-persist/integration/react';
|
||||
import { store, persistor } from './redux/store';
|
||||
import { Provider, connect } from 'react-redux';
|
||||
import {persistor, store} from './redux/store';
|
||||
import {Provider} from 'react-redux';
|
||||
import WalletDepot from './screens/wallet/WalletDepot';
|
||||
import WalletRetrait from './screens/wallet/WalletRetrait';
|
||||
import CreateIdentification from './screens/identification/createIdentification';
|
||||
|
@ -73,10 +71,8 @@ import EnvoieCashVersCarteAgent from './screens/wallet/agent/EnvoieCashVersCarte
|
|||
import EnvoiCashVersCashAgent from './screens/wallet/agent/EnvoiCashVersCashAgent';
|
||||
import ModifyIdentificationUser from './screens/identification/ModifyIdentificationUser';
|
||||
import CreateGroupNanoCredit from './screens/nano-credit/CreateGroupNanoCredit';
|
||||
import { bindActionCreators } from 'redux';
|
||||
import DemandValidationGroup from './screens/nano-credit/DemandGroupNanoCredit';
|
||||
import DemandGroupNanoCreditDetail from './screens/nano-credit/DemandGroupNanoCreditDetail';
|
||||
import NavigationService from './utils/NavigationService';
|
||||
import AdhererGroupNanoCredit from './screens/nano-credit/AdhererGroupNanoCredit';
|
||||
import MyNanoCreditGroup from './screens/nano-credit/MyNanoCreditGroup';
|
||||
import AskNanoCredit from './screens/nano-credit/AskNanoCredit';
|
||||
|
@ -85,8 +81,6 @@ import CautionNanoCreditAgent from './screens/nano-credit/CautionNanoCreditAgent
|
|||
import EpargnerArgentUser from './screens/nano-credit/EpargnerArgentUser';
|
||||
import CasserEpargneUser from './screens/nano-credit/CasserEpargneUser';
|
||||
import {IlinkEmitter} from './utils/events';
|
||||
import { fromBottom, fromLeft, zoomIn } from 'react-navigation-transitions';
|
||||
import { readUser } from './webservice/AuthApi';
|
||||
import EnvoieWalletToBankAgent from "./screens/wallet/agent/EnvoieWalletToBankAgent";
|
||||
|
||||
|
||||
|
@ -119,8 +113,7 @@ const AppStack = createDrawerNavigator({
|
|||
network:Networks,*/
|
||||
useraccount: {
|
||||
screen: UserAccount,
|
||||
navigationOptions: {
|
||||
},
|
||||
navigationOptions: {},
|
||||
},
|
||||
walletSelect: WalletSelect,
|
||||
createIdentificationUser: CreateIdentificationUser,
|
||||
|
@ -403,9 +396,13 @@ class App extends React.Component {
|
|||
global.appHasLoaded = false;
|
||||
//Remove this method to stop OneSignal Debugging
|
||||
OneSignal.setLogLevel(6, 0);
|
||||
|
||||
IlinkEmitter.on("langueChange", this.updateLangue.bind(this))
|
||||
// Replace 'YOUR_ONESIGNAL_APP_ID' with your OneSignal App ID.
|
||||
OneSignal.init("e8e7251f-713d-4658-9510-86d877fa6a7c", { kOSSettingsKeyAutoPrompt: false, kOSSettingsKeyInAppLaunchURL: false, kOSSettingsKeyInFocusDisplayOption: 2 });
|
||||
OneSignal.init("e8e7251f-713d-4658-9510-86d877fa6a7c", {
|
||||
kOSSettingsKeyAutoPrompt: false,
|
||||
kOSSettingsKeyInAppLaunchURL: false,
|
||||
kOSSettingsKeyInFocusDisplayOption: 2
|
||||
});
|
||||
OneSignal.inFocusDisplaying(2); // Controls what should happen if a notification is received while the app is open. 2 means that the notification will go directly to the device's notification center.
|
||||
|
||||
// The promptForPushNotifications function code will show the iOS push notification prompt. We recommend removing the following code and instead using an In-App Message to prompt for notification permission (See step below)
|
||||
|
@ -416,6 +413,10 @@ class App extends React.Component {
|
|||
OneSignal.addEventListener('ids', this.onIds);
|
||||
}
|
||||
|
||||
updateLangue() {
|
||||
this.forceUpdate()
|
||||
}
|
||||
|
||||
_getOneSignalIds = () => {
|
||||
return new Promise(async (resolve, reject) => {
|
||||
try {
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -159,7 +159,9 @@
|
|||
"DEPOSIT_TO_BANK": "Your Wallet to bank",
|
||||
"NANO_CREDIT": "Nano credit",
|
||||
"NANO_CREDIT_LIST": "Nano credit list",
|
||||
"SAVINGS_LIST": "Savings list",
|
||||
"NO_NANO_CREDIT": "No nano credit demand",
|
||||
"NO_SAVINGS": "No savings",
|
||||
"NANO_CREDIT_DESCRIPTION": "Nano credit description",
|
||||
"NANO_SANTE": "Nano health",
|
||||
"NANO_SANTE_DESCRIPTION": "Nano health description",
|
||||
|
@ -172,6 +174,8 @@
|
|||
"CAUTION_CREDIT": "Caution credit demand",
|
||||
"CAUTIONNEMENT_DONE": "Caution done",
|
||||
"ID_DEMAND": "Demand ID",
|
||||
"ID_SAVINGS": "Saving ID",
|
||||
"NON_APPLICABLE": "Not applicable",
|
||||
"DATE": "Date",
|
||||
"PAIEMENT_EAU_ELECTRICITY": "Water bill",
|
||||
"PAIEMENT_ELECTRICITY": "Electricity bill",
|
||||
|
@ -182,6 +186,7 @@
|
|||
"DATE_REMBOURSEMENT_PREVU": "Expected refund date",
|
||||
"DATE_REMBOURSEMENT": "Refund date",
|
||||
"AMOUNT_REFUND": "Amount reimbursed",
|
||||
"AMOUNT_WITHDRAWAL": "Amount withdrawal",
|
||||
"AMOUNT_PARTIALLY_REFUND": "Amount partially refunded",
|
||||
"FINAL_DATE": "End date",
|
||||
"CASSATION_DATE": "Cassation date",
|
||||
|
|
|
@ -166,7 +166,9 @@
|
|||
"DEPOSIT_TO_BANK": "Votre Wallet vers banque",
|
||||
"NANO_CREDIT": "Nano crédit",
|
||||
"NANO_CREDIT_LIST": "Liste des nano crédit",
|
||||
"SAVINGS_LIST": "Liste des épargnes",
|
||||
"NO_NANO_CREDIT": "Aucune demande de nano crédit",
|
||||
"NO_SAVINGS": "Aucune épargne",
|
||||
"NANO_CREDIT_DESCRIPTION": "Nano crédit iLink",
|
||||
"NANO_SANTE": "Nano santé",
|
||||
"NANO_SANTE_DESCRIPTION": "Nano santé iLink",
|
||||
|
@ -179,16 +181,19 @@
|
|||
"CAUTION_CREDIT": "Cautionner une demande de crédit",
|
||||
"CAUTIONNEMENT_DONE": "Cautionnement effectué",
|
||||
"ID_DEMAND": "Identifiant de la demande",
|
||||
"ID_SAVINGS": "Identifiant de l'épargne",
|
||||
"PAIEMENT_EAU": "Paiement eau",
|
||||
"PAIEMENT_ELECTRICITY": "Paiement électricité",
|
||||
"PAIEMENT_ECOLE": "Paiement école",
|
||||
"PAIEMENT_CREDIT_TELEPHONIQUE": "Paiement crédit téléphonique",
|
||||
"PAIEMENT_ABONNEMENT_TV": "Paiement abonnement TV",
|
||||
"NON_APPLICABLE": "Non applicable",
|
||||
"DATE": "Date",
|
||||
"DEMAND_DATE": "Date de la demande",
|
||||
"DATE_REMBOURSEMENT_PREVU": "Date de remboursement prévu",
|
||||
"DATE_REMBOURSEMENT": "Date de remboursement",
|
||||
"AMOUNT_REFUND": "Montant remboursé",
|
||||
"AMOUNT_WITHDRAWAL": "Montant retiré",
|
||||
"AMOUNT_PARTIALLY_REFUND": "Montant partiellement remboursé",
|
||||
"FINAL_DATE": "Date de fin",
|
||||
"CASSATION_DATE": "Date de cassation",
|
||||
|
@ -216,8 +221,8 @@
|
|||
"DEPOSIT_TRANSACTION_HISTORY_DESCRIPTION": "Dépôt de",
|
||||
"NO_WALLET_HISTORY": "Aucune transaction à ce jour",
|
||||
"DEMAND_SEND": "Demande envoyé",
|
||||
"EPARGNE_DEPOSE": "Epargne déposé",
|
||||
"BREAK_EPARGNE_DONE": "Epargne cassé avec succès",
|
||||
"EPARGNE_DEPOSE": "Epargne déposée",
|
||||
"BREAK_EPARGNE_DONE": "Epargne cassée avec succès",
|
||||
"BREAK_EPARGNE": "Casser mon épargne",
|
||||
"ID_EPARGNE": "Identifiant de l'épargne",
|
||||
"NO_DEMAND_CREATION_GROUP": "Aucune demande de création de groupe",
|
||||
|
|
|
@ -1,20 +1,19 @@
|
|||
import React, { Component } from 'react'
|
||||
import { StyleSheet, Text, View, Alert, Platform, StatusBar } from 'react-native'
|
||||
import React from 'react'
|
||||
import {Platform, StatusBar, StyleSheet, Text, View} from 'react-native'
|
||||
import BaseScreen from "../BaseScreen";
|
||||
import { responsiveWidth, responsiveHeight } from 'react-native-responsive-dimensions'
|
||||
import {responsiveWidth} from 'react-native-responsive-dimensions'
|
||||
import {Dropdown} from 'react-native-material-dropdown'
|
||||
import { disconnect } from './../../webservice/AuthApi'
|
||||
const theme = require('./../../utils/theme.json');
|
||||
const route = require('./../../route.json')
|
||||
import I18n, { getLanguages } from 'react-native-i18n'
|
||||
import I18n from 'react-native-i18n'
|
||||
import Configuration from "../../webservice/persistences/Configuration";
|
||||
import Button from "apsl-react-native-button"
|
||||
require("./../../utils/Translations")
|
||||
import {IlinkEmitter} from "./../../utils/events"
|
||||
import { Header } from "react-native-elements";
|
||||
import Icon from 'react-native-vector-icons/MaterialIcons';
|
||||
import {SafeAreaView} from 'react-navigation';
|
||||
|
||||
const theme = require('./../../utils/theme.json');
|
||||
const route = require('./../../route.json')
|
||||
|
||||
require("./../../utils/Translations")
|
||||
|
||||
export default class Configurations extends BaseScreen {
|
||||
|
||||
static navigationOptions = {
|
||||
|
@ -26,6 +25,7 @@ export default class Configurations extends BaseScreen {
|
|||
/>
|
||||
)
|
||||
};
|
||||
|
||||
constructor(props) {
|
||||
super(props, true)
|
||||
this.state = this.initState()
|
||||
|
@ -45,6 +45,7 @@ export default class Configurations extends BaseScreen {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
render() {
|
||||
console.log(this.state)
|
||||
return (<View style={styles.container}>
|
||||
|
|
|
@ -123,7 +123,7 @@ export default class SuperViseurGroupeHome extends BaseScreen {
|
|||
}
|
||||
})
|
||||
IlinkEmitter.on("langueChange", this.updateLangue.bind(this))
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
}
|
||||
|
|
|
@ -4,20 +4,17 @@ import {responsiveFontSize, responsiveWidth} from 'react-native-responsive-dimen
|
|||
import Icon from 'react-native-vector-icons/FontAwesome5';
|
||||
import I18n from "react-native-i18n"
|
||||
|
||||
import 'moment/locale/fr'
|
||||
import 'moment/locale/es-us'
|
||||
import 'moment/locale/en-au'
|
||||
import 'moment/locale/en-ca'
|
||||
import 'moment/locale/en-ie'
|
||||
import 'moment/locale/en-il'
|
||||
import 'moment/locale/en-nz'
|
||||
import 'moment/locale/en-gb'
|
||||
|
||||
import DeviceInfo from 'react-native-device-info'
|
||||
import 'moment/locale/fr';
|
||||
import 'moment/locale/es-us';
|
||||
import 'moment/locale/en-au';
|
||||
import 'moment/locale/en-ca';
|
||||
import 'moment/locale/en-ie';
|
||||
import 'moment/locale/en-il';
|
||||
import 'moment/locale/en-nz';
|
||||
import {Color} from '../../config/Color';
|
||||
|
||||
var moment = require('moment-timezone')
|
||||
const momentJS = require('moment')
|
||||
let moment = require('moment-timezone');
|
||||
const momentJS = require('moment');
|
||||
|
||||
let route = require('./../../route.json');
|
||||
var theme = require('./../../utils/theme.json');
|
||||
|
@ -26,6 +23,9 @@ export class HistoryItem extends React.Component {
|
|||
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-us";
|
||||
console.log("Current Locale item", this.currentLocale);
|
||||
moment.locale(this.currentLocale);
|
||||
this.state = this.initState();
|
||||
}
|
||||
|
||||
|
@ -75,8 +75,6 @@ export class HistoryItem extends React.Component {
|
|||
var today = new Date();
|
||||
var l = this.props.selfData.date_creation;
|
||||
let t = this.props.selfData.status;
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
var re = moment.tz(this.props.selfData.date_creation, moment.tz.guess()).format();
|
||||
re = moment(re)
|
||||
return {
|
||||
|
@ -134,6 +132,8 @@ export class HistoryItemSectionned extends PureComponent {
|
|||
constructor(props) {
|
||||
super(props);
|
||||
this.state = this.initState();
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-us";
|
||||
moment.locale(this.currentLocale);
|
||||
}
|
||||
|
||||
render() {
|
||||
|
@ -246,6 +246,8 @@ export class HistoryListItem extends React.Component {
|
|||
constructor(props) {
|
||||
super(props);
|
||||
this.state = this.initState();
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-us";
|
||||
moment.locale(this.currentLocale);
|
||||
}
|
||||
|
||||
initState() {
|
||||
|
|
|
@ -6,7 +6,6 @@ import {responsiveWidth} from 'react-native-responsive-dimensions'
|
|||
import Icons from 'react-native-vector-icons/Ionicons'
|
||||
import {readUser} from "../../webservice/AuthApi";
|
||||
import isNil from 'lodash/isNil';
|
||||
import I18n from "react-native-i18n";
|
||||
import {creditDemandResetReducer, treatCreditDemand} from '../../webservice/CreditTreatDemandApi';
|
||||
import {creditCancelResetReducer, treatCancelDemand} from '../../webservice/CreditCancelDemandeApi';
|
||||
import {getAgentNetworksList} from "../../webservice/NetworkApi";
|
||||
|
@ -16,11 +15,21 @@ import Toast from 'react-native-root-toast';
|
|||
import {Color} from '../../config/Color'
|
||||
import Dialog from "react-native-dialog";
|
||||
import {FontWeight} from '../../config/typography'
|
||||
import DeviceInfo from 'react-native-device-info'
|
||||
import I18n from "react-native-i18n";
|
||||
|
||||
import 'moment/locale/fr';
|
||||
import 'moment/locale/es-us';
|
||||
import 'moment/locale/en-au';
|
||||
import 'moment/locale/en-ca';
|
||||
import 'moment/locale/en-ie';
|
||||
import 'moment/locale/en-il';
|
||||
import 'moment/locale/en-nz';
|
||||
|
||||
let moment = require('moment-timezone');
|
||||
const momentJS = require('moment');
|
||||
|
||||
let typesta = 0;
|
||||
|
||||
let moment = require('moment-timezone')
|
||||
var colorback = 'white'
|
||||
|
||||
let theme = require('./../../utils/theme.json');
|
||||
|
@ -52,7 +61,10 @@ class HistoryItemDetails extends Component {
|
|||
} else {
|
||||
this.item = this.props.navigation.getParam("item", null).item;
|
||||
}
|
||||
console.log('HISTORY ITEM PROPS', this.props);
|
||||
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-us";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
let sta = ''
|
||||
if (this.item.status === '1') {
|
||||
typesta = 1
|
||||
|
@ -87,9 +99,6 @@ class HistoryItemDetails extends Component {
|
|||
this.setState({user: user, networks: networks.networks})
|
||||
});
|
||||
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
}
|
||||
|
||||
isNormalInteger = (str) => {
|
||||
|
|
|
@ -1,52 +1,39 @@
|
|||
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Platform,
|
||||
StyleSheet,
|
||||
AppState,
|
||||
FlatList,
|
||||
ProgressBarAndroid,
|
||||
TouchableOpacity,
|
||||
Text,
|
||||
View,
|
||||
Animated,
|
||||
StatusBar
|
||||
} from 'react-native';
|
||||
import React from 'react';
|
||||
import {Animated, AppState, ProgressBarAndroid, StatusBar, StyleSheet, Text, View} from 'react-native';
|
||||
import ActionButton from 'react-native-action-button';
|
||||
import Icon from 'react-native-vector-icons/MaterialIcons';
|
||||
import { responsiveFontSize, responsiveHeight, responsiveWidth } from 'react-native-responsive-dimensions';
|
||||
import { HistoryListItem, HistoryItemSectionned } from './HistoryItem';
|
||||
import { credrequester } from './../../route.json';
|
||||
import {responsiveHeight, responsiveWidth} from 'react-native-responsive-dimensions';
|
||||
import {HistoryItemSectionned, HistoryListItem} from './HistoryItem';
|
||||
import {loadDemandeCredit, loadMyDemandeCredit} from './../../webservice/HistoryRequestApi';
|
||||
import FontAwesome5 from 'react-native-vector-icons/FontAwesome5';
|
||||
import BaseScreen from './../../screens/BaseScreen'
|
||||
import Button from 'apsl-react-native-button'
|
||||
import {readUser} from "../../webservice/AuthApi";
|
||||
import Calendar from 'react-native-calendario';
|
||||
let route = require('./../../route.json')
|
||||
import 'moment';
|
||||
import 'moment/locale/fr'
|
||||
import 'moment/locale/es-us'
|
||||
import 'moment/locale/en-au'
|
||||
import 'moment/locale/en-ca'
|
||||
import 'moment/locale/en-ie'
|
||||
import 'moment/locale/en-il'
|
||||
import 'moment/locale/en-nz'
|
||||
import 'moment/locale/en-gb'
|
||||
import moment from 'moment-timezone';
|
||||
let theme = require('./../../utils/theme.json')
|
||||
import { primary, primaryDark, accent, purpleLight, primaryLight } from './../../utils/theme.json';
|
||||
import { PagerTabIndicator, PagerTitleIndicator, PagerDotIndicator } from 'react-native-best-viewpager'
|
||||
import I18n from "react-native-i18n";
|
||||
|
||||
import 'moment/locale/fr';
|
||||
import 'moment/locale/es-us';
|
||||
import 'moment/locale/en-au';
|
||||
import 'moment/locale/en-ca';
|
||||
import 'moment/locale/en-ie';
|
||||
import 'moment/locale/en-il';
|
||||
import 'moment/locale/en-nz';
|
||||
import {accent, primary, primaryDark, purpleLight} from './../../utils/theme.json';
|
||||
import {PagerTabIndicator} from 'react-native-best-viewpager'
|
||||
import IconWithBadge from "../IconWithBadge";
|
||||
import {Appbar, Divider, Menu, Provider} from 'react-native-paper';
|
||||
import DeviceInfo from 'react-native-device-info';
|
||||
|
||||
var moment = require('moment-timezone');
|
||||
const momentJS = require('moment');
|
||||
|
||||
let route = require('./../../route.json');
|
||||
let theme = require('./../../utils/theme.json');
|
||||
|
||||
var sortIcons;
|
||||
var sectionIcons;
|
||||
import I18n from 'react-native-i18n'
|
||||
|
||||
require('./../../utils/Translations')
|
||||
import { SinglePickerMaterialDialog } from 'react-native-material-dialog';
|
||||
import { Header } from "react-native-elements";
|
||||
import { withNavigationFocus } from "react-navigation";
|
||||
import IconWithBadge from "../IconWithBadge";
|
||||
import { Appbar, Paragraph, Menu, Divider, Provider } from 'react-native-paper';
|
||||
import DeviceInfo from 'react-native-device-info'
|
||||
|
||||
class MyHistory extends React.Component {
|
||||
|
||||
static navigatorStyle = {
|
||||
|
@ -85,14 +72,16 @@ class MyHistory extends React.Component {
|
|||
|
||||
constructor(props) {
|
||||
super(props, true);
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-us";
|
||||
moment.locale(this.currentLocale);
|
||||
this.state = this.initState();
|
||||
readUser().then((user) => { this.setState({ user: user }) })
|
||||
readUser().then((user) => {
|
||||
this.setState({user: user})
|
||||
})
|
||||
this._populateIcons().then(() => {
|
||||
});
|
||||
|
||||
this.navigation = this.props.navigation
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
//moment.locale(this.currentLocale);
|
||||
|
||||
};
|
||||
|
||||
|
@ -285,6 +274,7 @@ class MyHistory extends React.Component {
|
|||
this.setState({listdata: rev, conserve: rev, isLoaded: true});
|
||||
}
|
||||
}
|
||||
|
||||
updateMyList(data) {
|
||||
if (!this.state.filter) {
|
||||
let rev = data.reverse()
|
||||
|
@ -347,6 +337,7 @@ class MyHistory extends React.Component {
|
|||
</View>
|
||||
)
|
||||
}
|
||||
|
||||
animateSlidingUp(state = false) {
|
||||
const height = responsiveHeight(100)
|
||||
let initialValue = !state ? 0 : height,
|
||||
|
@ -365,6 +356,7 @@ class MyHistory extends React.Component {
|
|||
}
|
||||
).start()
|
||||
}
|
||||
|
||||
_openMenu = () => this.setState({visibleMenu: true});
|
||||
|
||||
_closeMenu = () => this.setState({visibleMenu: false});
|
||||
|
@ -384,14 +376,21 @@ class MyHistory extends React.Component {
|
|||
|
||||
<Appbar.Header dark={true} style={{backgroundColor: theme.primary}}>
|
||||
<Appbar.BackAction
|
||||
onPress={() => { this.props.navigation.pop() }}
|
||||
onPress={() => {
|
||||
this.props.navigation.pop()
|
||||
}}
|
||||
/>
|
||||
<Appbar.Content
|
||||
title={I18n.t('CREDIT_MANAGE')}
|
||||
subtitle={this.state.position === 0 ? I18n.t('MY_DEMAND') : I18n.t('DEMAND_RECEIVE')}
|
||||
/>
|
||||
<Appbar.Action icon="refresh" onPress={() => { this.refreshData() }} />
|
||||
<Appbar.Action icon="more-vert" onPress={() => { this._openMenu(); this.renderSliding(); }} />
|
||||
<Appbar.Action icon="refresh" onPress={() => {
|
||||
this.refreshData()
|
||||
}}/>
|
||||
<Appbar.Action icon="more-vert" onPress={() => {
|
||||
this._openMenu();
|
||||
this.renderSliding();
|
||||
}}/>
|
||||
</Appbar.Header>
|
||||
{this.renderOptionsMenu()}
|
||||
|
||||
|
@ -401,6 +400,7 @@ class MyHistory extends React.Component {
|
|||
);
|
||||
|
||||
}
|
||||
|
||||
renderSliding() {
|
||||
return (
|
||||
<Animated.View style={[styles.slidingup, {translateY: this.state.translateAnim}]}>
|
||||
|
@ -460,6 +460,7 @@ class MyHistory extends React.Component {
|
|||
</View>
|
||||
</Animated.View>)
|
||||
}
|
||||
|
||||
renderSectionnedList(list) {
|
||||
|
||||
if (this.state.isLoaded) {
|
||||
|
@ -505,7 +506,9 @@ class MyHistory extends React.Component {
|
|||
return (<HistoryListItem
|
||||
user={this.state.user}
|
||||
list={list}
|
||||
refreshing={() => { this.refreshData() }}
|
||||
refreshing={() => {
|
||||
this.refreshData()
|
||||
}}
|
||||
refresh={() => this.refreshData()}
|
||||
isRefreshing={this.state.isRefreshing}
|
||||
navigator={this.props.navigation}
|
||||
|
@ -557,6 +560,7 @@ class MyHistory extends React.Component {
|
|||
renderLoading() {
|
||||
return (<View><ProgressBarAndroid/><Text>{I18n.t('LOADING_DOTS')}</Text></View>)
|
||||
}
|
||||
|
||||
showSlidingUpPanel() {
|
||||
/* return (<SlidingUpPanel
|
||||
style={styles.slidingup}
|
||||
|
@ -633,6 +637,7 @@ class MyHistory extends React.Component {
|
|||
_showDateEndPicker = () => this.setState({isDateEndTimePickerVisible: true});
|
||||
|
||||
_hideDateTimePicker = () => this.setState({isDateTimePickerVisible: false, isDateEndTimePickerVisible: false});
|
||||
|
||||
/*
|
||||
_handleDatePicked = (fromdate, enddate) => {
|
||||
console.log([fromdate, enddate]);
|
||||
|
@ -786,6 +791,7 @@ class MyHistory extends React.Component {
|
|||
});
|
||||
}
|
||||
}
|
||||
|
||||
export default MyHistory;
|
||||
const datefilter = StyleSheet.create({
|
||||
titleHeader: {
|
||||
|
@ -853,8 +859,7 @@ const styles = StyleSheet.create({
|
|||
backgroundd_drawer: {
|
||||
backgroundColor: '#000',
|
||||
},
|
||||
listbackground: {
|
||||
},
|
||||
listbackground: {},
|
||||
actionButtonIcon: {
|
||||
fontSize: 20,
|
||||
height: 22,
|
||||
|
|
|
@ -23,7 +23,7 @@ import {IlinkEmitter} from '../../utils/events';
|
|||
import {readUser} from '../../webservice/AuthApi';
|
||||
import {getEpargneInProgressAction, getEpargneInProgressReset} from '../../webservice/NanoCreditApi';
|
||||
import {casserEpargneUserAction, casserEpargneUserReset} from '../../webservice/user/NanoCreditApi';
|
||||
import {cutStringWithoutDot, displayTransactionType, nanoCreditHistoryLabel} from "../../utils/UtilsFunction";
|
||||
import {cutStringWithoutDot, nanoCreditHistoryLabel} from "../../utils/UtilsFunction";
|
||||
import * as Utils from "../../utils/DeviceUtils";
|
||||
import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
|
||||
import thousands from "thousands";
|
||||
|
@ -195,16 +195,7 @@ class CasserEpargneUser extends Component {
|
|||
<View style={[styles.blockView, {borderBottomColor: Color.borderColor}]}>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>Type</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{I18n.t(displayTransactionType(this.state.historyItemDetail.type_historique))}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>{I18n.t('ID_DEMAND')}</Text>
|
||||
<Text style={[styles.body2]}>{I18n.t('ID_SAVINGS')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
|
@ -289,7 +280,7 @@ class CasserEpargneUser extends Component {
|
|||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_fin}</Text>
|
||||
style={[Typography.caption1, Color.grayColor]}>{ isEqual(this.state.historyItemDetail.type, 'SIMPLE') ? I18n.t('NON_APPLICABLE') : this.state.historyItemDetail.date_fin}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -378,7 +369,7 @@ class CasserEpargneUser extends Component {
|
|||
this.setState({displayModalHistory: true, historyItemDetail: item})
|
||||
}} style={[styles.contentService, {borderBottomColor: Color.primaryColor}]}>
|
||||
{
|
||||
Object.keys(omit(item, ['id', 'id_epargne', 'date_demande', 'date_fin', 'date_remboursement_prevu', 'date_validation', 'date_cassation', 'date_remboursement', 'id_demande', 'duree_mois', 'taxe', '', 'date_fin', 'date_cassation', 'id_user', 'id_network', 'user', 'partiellement_rembourse', 'user_phone', 'interet', 'date_remboursement_prevu', 'date_remboursement', 'id_wallet_agent', 'retrait_cash', 'codeParrain', 'agent', 'montant_rembourse', ''])).map((element, i) => (
|
||||
Object.keys(omit(item, ['id', 'id_epargne', 'montant_retire', 'date_demande', 'date_fin', 'date_remboursement_prevu', 'date_validation', 'date_cassation', 'date_remboursement', 'id_demande', 'duree_mois', 'taxe', '', 'date_fin', 'date_cassation', 'id_user', 'id_network', 'user', 'partiellement_rembourse', 'user_phone', 'interet', 'date_remboursement_prevu', 'date_remboursement', 'id_wallet_agent', 'retrait_cash', 'codeParrain', 'agent', 'montant_rembourse', ''])).map((element, i) => (
|
||||
<View style={{alignItems: 'center'}} key={i}>
|
||||
|
||||
<Text style={[Typography.overline, Color.grayColor], {marginTop: 4}}>
|
||||
|
@ -443,7 +434,7 @@ class CasserEpargneUser extends Component {
|
|||
) :
|
||||
(
|
||||
<View style={{flex: 1, justifyContent: 'center', alignItems: 'flex-start'}}>
|
||||
<Text style={Typography.body1}>{I18n.t('NO_NANO_CREDIT')}</Text>
|
||||
<Text style={Typography.body1}>{I18n.t('NO_SAVINGS')}</Text>
|
||||
</View>
|
||||
)
|
||||
)
|
||||
|
|
|
@ -1,30 +1,19 @@
|
|||
|
||||
import React, { Component } from 'react';
|
||||
import React from 'react';
|
||||
import {
|
||||
Alert,
|
||||
Platform,
|
||||
StyleSheet,
|
||||
AppState,
|
||||
FlatList,
|
||||
ProgressBarAndroid,
|
||||
TouchableOpacity,
|
||||
Text,
|
||||
View,
|
||||
Animated,
|
||||
StatusBar
|
||||
AppState,
|
||||
Platform,
|
||||
ProgressBarAndroid,
|
||||
StatusBar,
|
||||
StyleSheet,
|
||||
Text,
|
||||
TouchableOpacity,
|
||||
View
|
||||
} from 'react-native';
|
||||
import ActionButton from 'react-native-action-button';
|
||||
import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
|
||||
import {responsiveFontSize, responsiveHeight, responsiveWidth} from 'react-native-responsive-dimensions';
|
||||
import { HistoryListItem, HistoryItemSectionned } from '../history-request/HistoryItem';
|
||||
import { credrequester } from './../../route.json';
|
||||
import { loadDemandeCredit, loadMyDemandeCredit } from './../../webservice/HistoryRequestApi';
|
||||
import FontAwesome5 from 'react-native-vector-icons/FontAwesome5';
|
||||
import BaseScreen from './../../screens/BaseScreen'
|
||||
import Button from 'apsl-react-native-button'
|
||||
import {readUser} from "../../webservice/AuthApi";
|
||||
import Calendar from 'react-native-calendario';
|
||||
let route = require('./../../route.json')
|
||||
import 'moment';
|
||||
import 'moment/locale/fr'
|
||||
import 'moment/locale/es-us'
|
||||
|
@ -35,19 +24,9 @@ import 'moment/locale/en-il'
|
|||
import 'moment/locale/en-nz'
|
||||
import 'moment/locale/en-gb'
|
||||
import moment from 'moment-timezone';
|
||||
let theme = require('./../../utils/theme.json')
|
||||
import { primary, primaryDark, accent, purpleLight, primaryLight } from './../../utils/theme.json';
|
||||
import { PagerTabIndicator, PagerTitleIndicator, PagerDotIndicator } from 'react-native-best-viewpager'
|
||||
var sortIcons;
|
||||
var sectionIcons;
|
||||
import {accent, primary, primaryDark, purpleLight} from './../../utils/theme.json';
|
||||
import I18n from 'react-native-i18n'
|
||||
require('./../../utils/Translations')
|
||||
import { SinglePickerMaterialDialog } from 'react-native-material-dialog';
|
||||
import { Header } from "react-native-elements";
|
||||
import { withNavigationFocus } from "react-navigation";
|
||||
import IconWithBadge from "../IconWithBadge";
|
||||
import { Appbar, Paragraph, Menu, Divider, Provider } from 'react-native-paper';
|
||||
import DeviceInfo from 'react-native-device-info'
|
||||
import {Appbar, Provider} from 'react-native-paper';
|
||||
import {bindActionCreators} from 'redux';
|
||||
import {connect} from 'react-redux';
|
||||
import {getNanoCreditDemandsAction, getNanoCreditDemandsReset} from '../../webservice/user/NanoCreditApi';
|
||||
|
@ -55,7 +34,15 @@ import { IlinkEmitter } from '../../utils/events';
|
|||
import {Typography} from '../../config/typography';
|
||||
import {ScrollView} from 'react-native-gesture-handler';
|
||||
import {Color} from '../../config/Color';
|
||||
import { color } from 'react-native-reanimated';
|
||||
|
||||
let route = require('./../../route.json')
|
||||
|
||||
let theme = require('./../../utils/theme.json')
|
||||
|
||||
var sortIcons;
|
||||
var sectionIcons;
|
||||
|
||||
require('./../../utils/Translations')
|
||||
|
||||
|
||||
class DemandValidationGroup extends React.Component {
|
||||
|
@ -93,8 +80,8 @@ class DemandValidationGroup extends React.Component {
|
|||
|
||||
this.props.getNanoCreditDemandsReset();
|
||||
this.navigation = this.props.navigation
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
//moment.locale(this.currentLocale);
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
//IlinkEmitter.on('treatNanoGroupDemand', this.refreshData);
|
||||
};
|
||||
|
||||
|
@ -154,20 +141,29 @@ class DemandValidationGroup extends React.Component {
|
|||
|
||||
getDemandTypeIcon = (type) => {
|
||||
switch (type) {
|
||||
case 'creation': return 'account-multiple-plus';
|
||||
case 'suppression': return 'account-multiple-minus';
|
||||
case 'adhesion': return 'account-multiple-check'
|
||||
case 'nano_credit': return 'cash'
|
||||
default: return 'account-multiple'
|
||||
case 'creation':
|
||||
return 'account-multiple-plus';
|
||||
case 'suppression':
|
||||
return 'account-multiple-minus';
|
||||
case 'adhesion':
|
||||
return 'account-multiple-check'
|
||||
case 'nano_credit':
|
||||
return 'cash'
|
||||
default:
|
||||
return 'account-multiple'
|
||||
}
|
||||
}
|
||||
|
||||
getDemandTypeColor = (type) => {
|
||||
switch (type) {
|
||||
case 'creation': return 'green';
|
||||
case 'suppression': return 'red';
|
||||
case 'adhesion': return Color.primaryColor
|
||||
case 'nano_credit': return Color.primaryColor
|
||||
case 'creation':
|
||||
return 'green';
|
||||
case 'suppression':
|
||||
return 'red';
|
||||
case 'adhesion':
|
||||
return Color.primaryColor
|
||||
case 'nano_credit':
|
||||
return Color.primaryColor
|
||||
default:
|
||||
return Color.primaryColor
|
||||
}
|
||||
|
@ -188,7 +184,8 @@ class DemandValidationGroup extends React.Component {
|
|||
<View style={{flexDirection: 'row', alignItems: 'center',}}>
|
||||
<View style={styles.iconContent}>
|
||||
|
||||
<Icon name={this.getDemandTypeIcon(item.type)} color={this.getDemandTypeColor(item.type)} size={35} />
|
||||
<Icon name={this.getDemandTypeIcon(item.type)} color={this.getDemandTypeColor(item.type)}
|
||||
size={35}/>
|
||||
</View>
|
||||
</View>
|
||||
<View style={styles.content}>
|
||||
|
@ -217,10 +214,12 @@ class DemandValidationGroup extends React.Component {
|
|||
</View>
|
||||
|
||||
<View style={{alignContent: 'flex-end', flex: 1, flexDirection: 'row'}}>
|
||||
<Icon name="map-marker" style={[styles.descriptionIcon], { color: Color.accentColor, marginTop: 5 }} />
|
||||
<Icon name="map-marker"
|
||||
style={[styles.descriptionIcon], {color: Color.accentColor, marginTop: 5}}/>
|
||||
<Text style={styles.time}>{item.country}</Text>
|
||||
|
||||
<Icon name="clock" style={[styles.descriptionIcon], { color: Color.accentColor, marginTop: 5 }} />
|
||||
<Icon name="clock"
|
||||
style={[styles.descriptionIcon], {color: Color.accentColor, marginTop: 5}}/>
|
||||
<Text style={styles.time}> {dateFormat}</Text>
|
||||
</View>
|
||||
|
||||
|
@ -242,8 +241,7 @@ class DemandValidationGroup extends React.Component {
|
|||
<Text style={Typography.body1}>{errorGetDemandsGroup.data.error}</Text>
|
||||
</View>
|
||||
)
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
return (
|
||||
<View style={{flex: 1, justifyContent: 'center', alignItems: 'center'}}>
|
||||
<Text style={Typography.body1}>{errorGetDemandsGroup}</Text>
|
||||
|
@ -332,13 +330,17 @@ class DemandValidationGroup extends React.Component {
|
|||
|
||||
<Appbar.Header dark={true} style={{backgroundColor: theme.primary}}>
|
||||
<Appbar.BackAction
|
||||
onPress={() => { this.props.navigation.pop() }}
|
||||
onPress={() => {
|
||||
this.props.navigation.pop()
|
||||
}}
|
||||
/>
|
||||
<Appbar.Content
|
||||
title={I18n.t('MANAGE_GROUP')}
|
||||
subtitle={this.state.position === 0 ? I18n.t('VALIDATION_DEMAND') : I18n.t('DELETE_DEMAND')}
|
||||
/>
|
||||
<Appbar.Action icon="refresh" onPress={() => { this.refreshData() }} />
|
||||
<Appbar.Action icon="refresh" onPress={() => {
|
||||
this.refreshData()
|
||||
}}/>
|
||||
{/* <Appbar.Action icon="more-vert" onPress={() => { this._openMenu(); this.renderSliding(); }} /> */}
|
||||
</Appbar.Header>
|
||||
|
||||
|
@ -394,8 +396,7 @@ const styles = StyleSheet.create({
|
|||
backgroundd_drawer: {
|
||||
backgroundColor: '#000',
|
||||
},
|
||||
listbackground: {
|
||||
},
|
||||
listbackground: {},
|
||||
actionButtonIcon: {
|
||||
fontSize: 20,
|
||||
height: 22,
|
||||
|
|
|
@ -75,7 +75,7 @@ class DemandGroupNanoCreditDetail extends Component {
|
|||
isBtnModifyAmountEnabled: false,
|
||||
id: this.props.navigation.getParam("id", null)
|
||||
}
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
this.props.getNanoCreditUniqueDemandsReset();
|
||||
|
|
|
@ -82,7 +82,7 @@ class MyNanoCreditGroup extends Component {
|
|||
isBtnModifyAmountEnabled: false,
|
||||
id: this.props.navigation.getParam("id", null)
|
||||
}
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
this.props.createGroupReset();
|
||||
|
|
|
@ -52,7 +52,7 @@ class Notifications extends BaseScreen {
|
|||
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
||||
}
|
||||
|
|
|
@ -93,11 +93,11 @@ class OperateurOptionSelect extends Component {
|
|||
|
||||
redirectToRoute = (item) => {
|
||||
|
||||
console.log("Redirection");
|
||||
console.log("Item selected", item);
|
||||
if (this.state.options.length > 0) {
|
||||
|
||||
this.props.navigation.push(this.state.options[0].screen, {
|
||||
title: this.state.options[0].title,
|
||||
title: item.operator_name,
|
||||
type: this.state.options[0].type
|
||||
});
|
||||
} else {
|
||||
|
|
|
@ -53,7 +53,7 @@ export default class PaiementFacture extends Component {
|
|||
return I18n.t('IDENTIFIANT_ETUDIANT')
|
||||
case 'PAIEMENT_EAU':
|
||||
return I18n.t('NUMERO_ABONNE')
|
||||
case 'PAIEMENT_ELECTRICITE':
|
||||
case 'PAIEMENT_EAU_ELECTRICITE':
|
||||
return I18n.t('NUMERO_ABONNE')
|
||||
case 'PAIEMENT_CREDIT_TELEPHONE':
|
||||
return I18n.t('PHONE_NUMBER')
|
||||
|
|
|
@ -9,8 +9,19 @@ import 'moment/locale/en-nz';
|
|||
import 'moment/locale/es-us';
|
||||
import 'moment/locale/fr';
|
||||
import React, {Component} from 'react';
|
||||
import { ActivityIndicator, Alert, Animated, Platform, ProgressBarAndroid, ScrollView, StatusBar, StyleSheet, Text, TouchableOpacity, View } from 'react-native';
|
||||
import DeviceInfo from 'react-native-device-info';
|
||||
import {
|
||||
ActivityIndicator,
|
||||
Alert,
|
||||
Animated,
|
||||
Platform,
|
||||
ProgressBarAndroid,
|
||||
ScrollView,
|
||||
StatusBar,
|
||||
StyleSheet,
|
||||
Text,
|
||||
TouchableOpacity,
|
||||
View
|
||||
} from 'react-native';
|
||||
import I18n from 'react-native-i18n';
|
||||
import {responsiveWidth} from 'react-native-responsive-dimensions';
|
||||
import {TabBar} from 'react-native-tab-view';
|
||||
|
@ -24,13 +35,31 @@ import Dialog from "react-native-dialog";
|
|||
import {Typography} from '../../config/typography';
|
||||
import * as Utils from '../../utils/DeviceUtils';
|
||||
import {IlinkEmitter} from "../../utils/events";
|
||||
import { cutString, cutStringWithoutDot, isEmptyObject, transactionHistoryIlinkLabel, isIlinkWorldWallet, optionDepotScreen, optionIdentificationScreen, optionPaiementFacture, optionRetraitScreen, transactionHistoryLabel, optionNanoCreditScreen, optionNanoCreditAgentScreen, displayTransactionType } from '../../utils/UtilsFunction';
|
||||
import {
|
||||
cutString,
|
||||
cutStringWithoutDot,
|
||||
displayTransactionType,
|
||||
isEmptyObject,
|
||||
isIlinkWorldWallet,
|
||||
optionDepotScreen,
|
||||
optionIdentificationScreen,
|
||||
optionNanoCreditAgentScreen,
|
||||
optionPaiementFacture,
|
||||
optionRetraitScreen,
|
||||
transactionHistoryIlinkLabel
|
||||
} from '../../utils/UtilsFunction';
|
||||
import {depositActionReset} from '../../webservice/DepositApi';
|
||||
import {baseUrl} from '../../webservice/IlinkConstants';
|
||||
import {getWalletDetailActivated, resetWalletListDetailReducer} from '../../webservice/WalletApi';
|
||||
import { getWalletTransactionHistory, getWalletTransactionHistoryReset,getHyperSuperTransactionHistoryAction, getHyperSuperTransactionHistoryReset } from '../../webservice/WalletTransactionHistoryApi';
|
||||
import {
|
||||
getHyperSuperTransactionHistoryAction,
|
||||
getHyperSuperTransactionHistoryReset,
|
||||
getWalletTransactionHistory,
|
||||
getWalletTransactionHistoryReset
|
||||
} from '../../webservice/WalletTransactionHistoryApi';
|
||||
import {resetCommissionReducer, transferCommissionAction} from '../../webservice/WalletTransferCommission';
|
||||
import {readUser} from '../../webservice/AuthApi';
|
||||
|
||||
let moment = require('moment-timezone');
|
||||
const thousands = require('thousands');
|
||||
|
||||
|
@ -78,15 +107,13 @@ class WalletDetail extends Component {
|
|||
this.props.depositActionReset();
|
||||
this.props.resetWalletListDetailReducer();
|
||||
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
if (this.isHomeRootView) {
|
||||
let agentId = this.props.navigation.state.params.agentId;
|
||||
this.props.getWalletDetailActivated(agentId, true);
|
||||
this.props.getHyperSuperTransactionHistoryReset();
|
||||
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
this.props.getWalletDetailActivated(this.props.navigation.state.params.wallet.id, false);
|
||||
if (isIlinkWorldWallet(this.props.navigation.state.params.wallet.type))
|
||||
this.props.getWalletTransactionHistory(this.props.navigation.state.params.wallet.id, true);
|
||||
|
@ -94,6 +121,22 @@ class WalletDetail extends Component {
|
|||
this.props.getWalletTransactionHistory(this.props.navigation.state.params.wallet.id, false);
|
||||
}
|
||||
|
||||
readUser().then((user) => {
|
||||
if (user !== null && user !== undefined) {
|
||||
if (user.category !== undefined) {
|
||||
switch (user.category) {
|
||||
case "super":
|
||||
this.props.getHyperSuperTransactionHistoryAction(user.code_membre, false);
|
||||
break;
|
||||
case "hyper":
|
||||
this.props.getHyperSuperTransactionHistoryAction(user.network_id, true);
|
||||
break;
|
||||
}
|
||||
this.setState({});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
this.willFocus = this.props.navigation.addListener(
|
||||
'willFocus',
|
||||
payload => {
|
||||
|
@ -107,7 +150,7 @@ class WalletDetail extends Component {
|
|||
if (user.category !== undefined) {
|
||||
switch (user.category) {
|
||||
case "super":
|
||||
this.props.getHyperSuperTransactionHistoryAction(result.response.id, false);
|
||||
this.props.getHyperSuperTransactionHistoryAction(user.code_membre, false);
|
||||
break;
|
||||
case "hyper":
|
||||
this.props.getHyperSuperTransactionHistoryAction(user.network_id, true);
|
||||
|
@ -126,6 +169,7 @@ class WalletDetail extends Component {
|
|||
});
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
static options(passProps) {
|
||||
return {
|
||||
|
@ -182,12 +226,12 @@ class WalletDetail extends Component {
|
|||
};
|
||||
|
||||
componentDidMount() {
|
||||
|
||||
console.log('RESULT REQUEST', result);
|
||||
const {result} = this.props;
|
||||
if (result !== null) {
|
||||
if (typeof result.response !== 'undefined') {
|
||||
const wallet = result.response[0];
|
||||
readUser().then((user) => {
|
||||
/* readUser().then((user) => {
|
||||
if (user !== null && user !== undefined) {
|
||||
if (user.category !== undefined) {
|
||||
switch (user.category) {
|
||||
|
@ -201,7 +245,7 @@ class WalletDetail extends Component {
|
|||
this.setState({});
|
||||
}
|
||||
}
|
||||
});
|
||||
});*/
|
||||
this.setState({
|
||||
wallet: wallet,
|
||||
isTriggerRefresh: false
|
||||
|
@ -305,9 +349,7 @@ class WalletDetail extends Component {
|
|||
/* if (typeof this.props.navigation.state.params.onRefreshDetail !== 'undefined')
|
||||
this.props.navigation.state.params.onRefreshDetail(); */
|
||||
|
||||
}
|
||||
|
||||
else {
|
||||
} else {
|
||||
let agentId = this.props.navigation.state.params.agentId;
|
||||
this.props.getWalletDetailActivated(agentId, true);
|
||||
}
|
||||
|
@ -394,8 +436,16 @@ class WalletDetail extends Component {
|
|||
<View style={{flexDirection: 'row'}}>
|
||||
|
||||
<Tag primary
|
||||
icon={<Icon name='swap-horizontal' size={20} color={Color.whiteColor} style={{ marginLeft: 15 }} />}
|
||||
style={{ paddingRight: 10, width: 120, borderTopRightRadius: 0, borderBottomRightRadius: 0, borderRightWidth: 1, borderRightColor: Color.whiteColor }}
|
||||
icon={<Icon name='swap-horizontal' size={20} color={Color.whiteColor}
|
||||
style={{marginLeft: 15}}/>}
|
||||
style={{
|
||||
paddingRight: 10,
|
||||
width: 120,
|
||||
borderTopRightRadius: 0,
|
||||
borderBottomRightRadius: 0,
|
||||
borderRightWidth: 1,
|
||||
borderRightColor: Color.whiteColor
|
||||
}}
|
||||
onPress={() => {
|
||||
const {result} = this.props;
|
||||
|
||||
|
@ -415,8 +465,7 @@ class WalletDetail extends Component {
|
|||
],
|
||||
{cancelable: false}
|
||||
)
|
||||
}
|
||||
else
|
||||
} else
|
||||
this.renderDialogConfirmTransferCommission()
|
||||
}
|
||||
|
||||
|
@ -456,8 +505,10 @@ class WalletDetail extends Component {
|
|||
</View>
|
||||
</View>
|
||||
<View style={styles.contentLeftItem}>
|
||||
<Text numberOfLines={1} style={[Typography.caption2, Typography.semibold]} >{I18n.t('CREATION_DATE')}</Text>
|
||||
<Text numberOfLines={1} adjustsFontSizeToFit={true} style={Typography.caption1}>{moment(wallet.created_date).format('DD/MM/YYYY')}</Text>
|
||||
<Text numberOfLines={1}
|
||||
style={[Typography.caption2, Typography.semibold]}>{I18n.t('CREATION_DATE')}</Text>
|
||||
<Text numberOfLines={1} adjustsFontSizeToFit={true}
|
||||
style={Typography.caption1}>{moment(wallet.created_date).format('DD/MM/YYYY')}</Text>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
|
@ -505,7 +556,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[Typography.title3, Color.primaryColor], {marginBottom: 3}}>
|
||||
{I18n.t('PRINCIPAL_ACCOUNT_TITLE')}
|
||||
</Text>
|
||||
<Text style={[Typography.body2]}>{`${thousands(wallet.balance_princ, ' ')} ${wallet.currency_code}`}</Text>
|
||||
<Text
|
||||
style={[Typography.body2]}>{`${thousands(wallet.balance_princ, ' ')} ${wallet.currency_code}`}</Text>
|
||||
</View>
|
||||
</View>
|
||||
|
||||
|
@ -528,7 +580,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[Typography.title3, Color.primaryColor], {marginBottom: 3}}>
|
||||
{I18n.t('COMMISSION_ACCOUNT_TITLE')}
|
||||
</Text>
|
||||
<Text style={Typography.body2}>{`${thousands(wallet.balance_com, ' ')} ${wallet.currency_code}`}</Text>
|
||||
<Text
|
||||
style={Typography.body2}>{`${thousands(wallet.balance_com, ' ')} ${wallet.currency_code}`}</Text>
|
||||
</View>
|
||||
</View>
|
||||
|
||||
|
@ -551,7 +604,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('OPERATION')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.operation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.operation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -559,7 +613,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('TRANSACTION_ID')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_transaction}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_transaction}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -567,7 +622,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>Date</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -575,7 +631,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('INIT_COUNTRY')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.init_country}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.init_country}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -583,7 +640,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -591,7 +649,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('FEES_AND_TAXES')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.frais}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.frais}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -599,7 +658,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('NET_AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_init}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_init}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -607,7 +667,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('EMETTEUR')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.emetteur}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.emetteur}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -615,7 +676,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('DESTINATAIRE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.destinataire}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.destinataire}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -623,7 +685,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('FINAL_COUNTRY')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.final_country}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.final_country}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -631,7 +694,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('NET_AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_final}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_final}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -639,7 +703,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('ACTIVE_WALLET')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.reseau_payeur}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.reseau_payeur}</Text>
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
|
@ -661,9 +726,11 @@ class WalletDetail extends Component {
|
|||
renderSuperHyperHistoryTransactionItem = (item, index) => {
|
||||
|
||||
return (
|
||||
<TouchableOpacity onPress={() => { this.setState({ displaySuperHyperModalHistory: true, historyItemDetail: item }) }} style={[styles.contentService, { borderBottomColor: Color.primaryColor }]}>
|
||||
<TouchableOpacity onPress={() => {
|
||||
this.setState({displaySuperHyperModalHistory: true, historyItemDetail: item})
|
||||
}} style={[styles.contentService, {borderBottomColor: Color.primaryColor}]}>
|
||||
{
|
||||
Object.keys(omit(item, ['id', 'id_transaction', 'montant2', 'date_cassation', 'etat', 'type', 'date_fin', 'duree_mois', 'id_epargne', 'type_historique', 'frais', 'init_country', 'final_country', 'source', 'emetteur', 'montant_net_final', 'montant_net_init', 'reseau_payeur', 'operation', 'retrait_cash', 'type_historique', 'type_caution', 'id_demande', 'montant_rembourse', 'partiellement_rembourse', 'duree_mois', 'etat', 'interet', 'taxe', 'date_validation', 'date_remboursement_prevu', 'date_remboursement', 'id_user', 'id_wallet_agent', 'id_network', 'user', 'user_phone', 'agent', 'codeParrain'])).map((element, i) => (
|
||||
Object.keys(omit(item, ['id', 'id_transaction', 'montant_retire', 'montant2', 'date_cassation', 'etat', 'type', 'date_fin', 'duree_mois', 'id_epargne', 'type_historique', 'frais', 'init_country', 'final_country', 'source', 'emetteur', 'montant_net_final', 'montant_net_init', 'reseau_payeur', 'operation', 'retrait_cash', 'type_historique', 'type_caution', 'id_demande', 'montant_rembourse', 'partiellement_rembourse', 'duree_mois', 'etat', 'interet', 'taxe', 'date_validation', 'date_remboursement_prevu', 'date_remboursement', 'id_user', 'id_wallet_agent', 'id_network', 'user', 'user_phone', 'agent', 'codeParrain'])).map((element, i) => (
|
||||
<View style={{alignItems: 'center'}} key={i}>
|
||||
<Text style={[Typography.overline, Color.grayColor], {marginTop: 4}}>
|
||||
{
|
||||
|
@ -701,7 +768,17 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>Type</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{I18n.t(displayTransactionType(this.state.historyItemDetail.type_historique))}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{I18n.t(displayTransactionType(this.state.historyItemDetail.type_historique))}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>{I18n.t('CAUTION_TYPE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.type_caution}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -709,7 +786,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('ID_DEMAND')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_demande}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_demande}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -717,7 +795,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('STATUS')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.etat}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.etat}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -725,7 +804,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('DEMAND_DURATION_IN_MONTH')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.duree_mois}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.duree_mois}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -733,7 +813,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -741,7 +822,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT_REFUND')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_rembourse + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_rembourse + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -749,7 +831,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT_PARTIALLY_REFUND')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.partiellement_rembourse + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.partiellement_rembourse + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -757,7 +840,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('TAXES')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.taxe + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.taxe + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -765,7 +849,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('INTERET')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.interet + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.interet + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -773,7 +858,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('WITHDRAWAL_IN_CASH')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.retrait_cash + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.retrait_cash + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -781,7 +867,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('CREATION_DATE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -789,7 +876,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('DEMAND_DATE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_demande}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_demande}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -797,7 +885,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('DATE_REMBOURSEMENT_PREVU')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_remboursement_prevu}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_remboursement_prevu}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -805,7 +894,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('DATE_REMBOURSEMENT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_remboursement}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_remboursement}</Text>
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
|
@ -820,7 +910,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>Type</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{displayTransactionType(this.state.historyItemDetail.type_historique)}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{displayTransactionType(this.state.historyItemDetail.type_historique)}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -828,7 +919,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('ID_DEMAND')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_demande}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_demande}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -836,7 +928,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('STATUS')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.etat}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.etat}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -844,7 +937,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('DEMAND_DURATION_IN_MONTH')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.duree_mois}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.duree_mois}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -852,7 +946,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>Type</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.type}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.type}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -860,7 +955,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -868,7 +964,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('TAXES')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.taxe + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.taxe + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -876,7 +973,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('INTERET')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.interet + ' ' + wallet.currency_code}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.interet + ' ' + wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -884,7 +982,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('CREATION_DATE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -892,7 +991,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('FINAL_DATE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_fin}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{isEqual(this.state.historyItemDetail.type, 'SIMPLE') ? I18n.t('NON_APPLICABLE') : this.state.historyItemDetail.date_fin}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -900,7 +1000,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('CASSATION_DATE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_cassation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_cassation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
|
@ -915,7 +1016,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('OPERATION')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.operation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.operation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -923,7 +1025,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>{I18n.t('TRANSACTION_ID')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_transaction}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_transaction}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -931,7 +1034,8 @@ class WalletDetail extends Component {
|
|||
<Text style={[styles.body2]}>Date</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_creation}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -939,7 +1043,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('INIT_COUNTRY')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.init_country}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.init_country}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -947,7 +1052,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant2}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant2}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -955,7 +1061,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('FEES_AND_TAXES')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.frais}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.frais}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -963,7 +1070,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('NET_AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_init}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_init}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -971,7 +1079,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('EMETTEUR')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.emetteur}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.emetteur}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -979,7 +1088,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('DESTINATAIRE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.destinataire}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.destinataire}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -987,7 +1097,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('FINAL_COUNTRY')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.final_country}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.final_country}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -995,7 +1106,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('NET_AMOUNT')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_final}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_net_final}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -1003,7 +1115,8 @@ class WalletDetail extends Component {
|
|||
<Text tyle={[Typography.body2]}>{I18n.t('ACTIVE_WALLET')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.reseau_payeur}</Text>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.reseau_payeur}</Text>
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
|
@ -1032,8 +1145,7 @@ class WalletDetail extends Component {
|
|||
<Text style={Typography.body1}>{errorHistoryHyperSuper.data.error}</Text>
|
||||
</View>
|
||||
)
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
return (
|
||||
<View style={{flex: 1, justifyContent: 'center', alignItems: 'center'}}>
|
||||
<Text style={Typography.body1}>{errorHistoryHyperSuper}</Text>
|
||||
|
@ -1155,7 +1267,11 @@ class WalletDetail extends Component {
|
|||
},
|
||||
},
|
||||
],
|
||||
{ listener: (event) => { this.setState({ scrollHeaderY: event.nativeEvent.contentOffset.y }); } })}>
|
||||
{
|
||||
listener: (event) => {
|
||||
this.setState({scrollHeaderY: event.nativeEvent.contentOffset.y});
|
||||
}
|
||||
})}>
|
||||
<View style={{marginTop: 80,}}>
|
||||
|
||||
{this.renderHeader(wallet)}
|
||||
|
@ -1208,13 +1324,16 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={styles.contentTitle}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('DEPOSIT')}
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[Typography.overline, Color.grayColor], { paddingVertical: 5 }} numberOfLines={5}>
|
||||
<Text
|
||||
style={[Typography.overline, Color.grayColor], {paddingVertical: 5}}
|
||||
numberOfLines={5}>
|
||||
{I18n.t('DEPOSIT_DESCRIPTION')}
|
||||
</Text>
|
||||
</View>
|
||||
|
@ -1253,13 +1372,16 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={styles.contentTitle}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('WITHDRAWAL')}
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[Typography.overline, Color.grayColor], { paddingVertical: 5 }} numberOfLines={5}>
|
||||
<Text
|
||||
style={[Typography.overline, Color.grayColor], {paddingVertical: 5}}
|
||||
numberOfLines={5}>
|
||||
{I18n.t('WITHDRAWAL_DESCRIPTION')}
|
||||
</Text>
|
||||
</View>
|
||||
|
@ -1298,7 +1420,8 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={{paddingTop: 20,}}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('NANO_CREDIT')}
|
||||
</Text>
|
||||
</View>
|
||||
|
@ -1309,7 +1432,8 @@ class WalletDetail extends Component {
|
|||
|
||||
<View style={[styles.containerTouch]}>
|
||||
<TouchableOpacity style={styles.contain}
|
||||
onPress={() => { }}
|
||||
onPress={() => {
|
||||
}}
|
||||
activeOpacity={0.9}>
|
||||
<Icon name='heart-multiple'
|
||||
color={Color.primaryColor}
|
||||
|
@ -1319,7 +1443,8 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={{paddingTop: 20,}}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('NANO_SANTE')}
|
||||
</Text>
|
||||
</View>
|
||||
|
@ -1354,13 +1479,16 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={styles.contentTitle}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('PAIEMENT_FACTURE')}
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[Typography.overline, Color.grayColor], { paddingVertical: 5 }} numberOfLines={5}>
|
||||
<Text
|
||||
style={[Typography.overline, Color.grayColor], {paddingVertical: 5}}
|
||||
numberOfLines={5}>
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
|
@ -1390,13 +1518,16 @@ class WalletDetail extends Component {
|
|||
<View style={[styles.content]}>
|
||||
|
||||
<View style={styles.contentTitle}>
|
||||
<Text style={[Typography.headline, Typography.semibold]}>
|
||||
<Text
|
||||
style={[Typography.headline, Typography.semibold]}>
|
||||
{I18n.t('CREATION_IDENTIFICATION_DESCRIPTION')}
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[Typography.overline, Color.grayColor], { paddingVertical: 5 }} numberOfLines={5}>
|
||||
<Text
|
||||
style={[Typography.overline, Color.grayColor], {paddingVertical: 5}}
|
||||
numberOfLines={5}>
|
||||
</Text>
|
||||
</View>
|
||||
|
||||
|
@ -1434,7 +1565,9 @@ class WalletDetail extends Component {
|
|||
renderHistoryTransactionItem = (item, index, wallet) => {
|
||||
|
||||
return (
|
||||
<TouchableOpacity onPress={() => { this.setState({ displayModalHistory: true, historyItemDetail: item }) }} style={[styles.contentService, { borderBottomColor: Color.primaryColor }]}>
|
||||
<TouchableOpacity onPress={() => {
|
||||
this.setState({displayModalHistory: true, historyItemDetail: item})
|
||||
}} style={[styles.contentService, {borderBottomColor: Color.primaryColor}]}>
|
||||
{
|
||||
isIlinkWorldWallet(wallet.type) ?
|
||||
Object.keys(omit(item, ['id', 'id_transaction', 'type', 'frais', 'init_country', 'final_country', 'source', 'emetteur', 'montant_net_final', 'montant_net_init', 'reseau_payeur', 'operation'])).map((element, i) => (
|
||||
|
@ -1499,8 +1632,7 @@ class WalletDetail extends Component {
|
|||
<Text style={Typography.body1}>{errorTransaction.data.error}</Text>
|
||||
</View>
|
||||
)
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
return (
|
||||
<View style={{flex: 1, justifyContent: 'center', alignItems: 'center'}}>
|
||||
<Text style={Typography.body1}>{errorTransaction}</Text>
|
||||
|
|
|
@ -94,7 +94,7 @@ class WalletDetailUser extends Component {
|
|||
|
||||
this.heightImageBanner = Utils.scaleWithPixel(250, 1);
|
||||
this.marginTopBanner = this.heightImageBanner - this.state.heightHeader - 40;
|
||||
this.currentLocale = DeviceInfo.getDeviceLocale().includes("fr") ? "fr" : "en-gb";
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
IlinkEmitter.on("langueChange", this.updateLangue.bind(this));
|
||||
IlinkEmitter.on("refreshWallet", this.refresh);
|
||||
|
|
|
@ -448,7 +448,7 @@ class WalletOptionSelect extends Component {
|
|||
{
|
||||
|
||||
!isNil(this.state.user.category) ?
|
||||
Object.keys(omit(item, ['id', 'retrait_cash', 'type_historique', 'type_caution', 'id_demande', 'montant_rembourse', 'partiellement_rembourse', 'duree_mois', 'etat', 'interet', 'taxe', 'date_validation', 'date_remboursement_prevu', 'date_remboursement', 'id_user', 'id_wallet_agent', 'id_network', 'user', 'user_phone', 'agent', 'codeParrain'])).map((element, i) => (
|
||||
Object.keys(omit(item, ['id', 'retrait_cash', 'montant_retire', 'type_historique', 'type_caution', 'id_demande', 'montant_rembourse', 'partiellement_rembourse', 'duree_mois', 'etat', 'interet', 'taxe', 'date_validation', 'date_remboursement_prevu', 'date_remboursement', 'id_user', 'id_wallet_agent', 'id_network', 'user', 'user_phone', 'agent', 'codeParrain'])).map((element, i) => (
|
||||
<View style={{alignItems: 'center'}} key={i}>
|
||||
|
||||
<Text style={[Typography.overline, Color.grayColor], {marginTop: 4}}>
|
||||
|
@ -463,7 +463,7 @@ class WalletOptionSelect extends Component {
|
|||
</View>
|
||||
))
|
||||
:
|
||||
Object.keys(omit(item, ['id', 'type', 'id_epargne', 'type_historique', 'date_demande', 'date_fin', 'date_remboursement_prevu', 'date_validation', 'date_cassation', 'date_remboursement', 'id_demande', 'duree_mois', 'taxe', '', 'date_fin', 'date_cassation', 'etat', 'id_user', 'id_network', 'user', 'partiellement_rembourse', 'user_phone', 'type_caution', 'interet', 'date_remboursement_prevu', 'date_remboursement', 'id_wallet_agent', 'retrait_cash', 'codeParrain', 'agent', 'montant_rembourse', ''])).map((element, i) => (
|
||||
Object.keys(omit(item, ['id', 'type', 'montant_retire', 'id_epargne', 'type_historique', 'date_demande', 'date_fin', 'date_remboursement_prevu', 'date_validation', 'date_cassation', 'date_remboursement', 'id_demande', 'duree_mois', 'taxe', '', 'date_fin', 'date_cassation', 'etat', 'id_user', 'id_network', 'user', 'partiellement_rembourse', 'user_phone', 'type_caution', 'interet', 'date_remboursement_prevu', 'date_remboursement', 'id_wallet_agent', 'retrait_cash', 'codeParrain', 'agent', 'montant_rembourse', ''])).map((element, i) => (
|
||||
<View style={{alignItems: 'center'}} key={i}>
|
||||
|
||||
<Text style={[Typography.overline, Color.grayColor], {marginTop: 4}}>
|
||||
|
@ -504,6 +504,15 @@ class WalletOptionSelect extends Component {
|
|||
style={[Typography.caption1, Color.grayColor]}>{I18n.t(displayTransactionType(this.state.historyItemDetail.type_historique))}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>{I18n.t('CAUTION_TYPE')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.type_caution}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>{I18n.t('ID_DEMAND')}</Text>
|
||||
|
@ -636,11 +645,11 @@ class WalletOptionSelect extends Component {
|
|||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text style={[styles.body2]}>{I18n.t('ID_DEMAND')}</Text>
|
||||
<Text style={[styles.body2]}>{I18n.t('ID_SAVINGS')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_demande}</Text>
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.id_epargne}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
@ -679,6 +688,15 @@ class WalletOptionSelect extends Component {
|
|||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant + ' ' + this.state.wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text tyle={[Typography.body2]}>{I18n.t('AMOUNT_WITHDRAWAL')}</Text>
|
||||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.montant_retire + ' ' + this.state.wallet.currency_code}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
<View style={{flex: 1}}>
|
||||
<Text tyle={[Typography.body2]}>{I18n.t('TAXES')}</Text>
|
||||
|
@ -712,7 +730,7 @@ class WalletOptionSelect extends Component {
|
|||
</View>
|
||||
<View style={{flex: 1, alignItems: 'flex-end'}}>
|
||||
<Text
|
||||
style={[Typography.caption1, Color.grayColor]}>{this.state.historyItemDetail.date_fin}</Text>
|
||||
style={[Typography.caption1, Color.grayColor]}>{isEqual(this.state.historyItemDetail.type, 'SIMPLE') ? I18n.t('NON_APPLICABLE') : this.state.historyItemDetail.date_fin}</Text>
|
||||
</View>
|
||||
</View>
|
||||
<View style={{flexDirection: 'row', marginTop: 10}}>
|
||||
|
|
|
@ -373,11 +373,7 @@ export const optionRetraitUserScreen = {
|
|||
screen: '',
|
||||
icon: 'credit-card',
|
||||
title: 'WITHDRAWAL_BANK_TO_WALLET',
|
||||
}, {
|
||||
screen: '',
|
||||
icon: 'credit-card',
|
||||
title: 'WITHDRAWAL_BANK_TO_CASH',
|
||||
},
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
|
|
|
@ -161,6 +161,7 @@
|
|||
"NANO_CREDIT_LIST": "Nano credit list",
|
||||
"SAVINGS_LIST": "Savings list",
|
||||
"NO_NANO_CREDIT": "No nano credit demand",
|
||||
"NO_SAVINGS": "No savings",
|
||||
"NANO_CREDIT_DESCRIPTION": "Nano credit description",
|
||||
"NANO_SANTE": "Nano health",
|
||||
"NANO_SANTE_DESCRIPTION": "Nano health description",
|
||||
|
@ -173,8 +174,10 @@
|
|||
"CAUTION_CREDIT": "Caution credit demand",
|
||||
"CAUTIONNEMENT_DONE": "Caution done",
|
||||
"ID_DEMAND": "Demand ID",
|
||||
"ID_SAVINGS": "Saving ID",
|
||||
"NON_APPLICABLE": "Not applicable",
|
||||
"DATE": "Date",
|
||||
"PAIEMENT_EAU_ELECTRICITY": "Water bill",
|
||||
"PAIEMENT_EAU": "Water bill",
|
||||
"PAIEMENT_ELECTRICITY": "Electricity bill",
|
||||
"PAIEMENT_ECOLE": "School fees",
|
||||
"PAIEMENT_CREDIT_TELEPHONIQUE": "Phone credit bills",
|
||||
|
|
|
@ -168,6 +168,7 @@
|
|||
"NANO_CREDIT_LIST": "Liste des nano crédit",
|
||||
"SAVINGS_LIST": "Liste des épargnes",
|
||||
"NO_NANO_CREDIT": "Aucune demande de nano crédit",
|
||||
"NO_SAVINGS": "Aucune épargne",
|
||||
"NANO_CREDIT_DESCRIPTION": "Nano crédit iLink",
|
||||
"NANO_SANTE": "Nano santé",
|
||||
"NANO_SANTE_DESCRIPTION": "Nano santé iLink",
|
||||
|
@ -180,11 +181,13 @@
|
|||
"CAUTION_CREDIT": "Cautionner une demande de crédit",
|
||||
"CAUTIONNEMENT_DONE": "Cautionnement effectué",
|
||||
"ID_DEMAND": "Identifiant de la demande",
|
||||
"ID_SAVINGS": "Identifiant de l'épargne",
|
||||
"PAIEMENT_EAU": "Paiement eau",
|
||||
"PAIEMENT_ELECTRICITY": "Paiement électricité",
|
||||
"PAIEMENT_ECOLE": "Paiement école",
|
||||
"PAIEMENT_CREDIT_TELEPHONIQUE": "Paiement crédit téléphonique",
|
||||
"PAIEMENT_ABONNEMENT_TV": "Paiement abonnement TV",
|
||||
"NON_APPLICABLE": "Non applicable",
|
||||
"DATE": "Date",
|
||||
"DEMAND_DATE": "Date de la demande",
|
||||
"DATE_REMBOURSEMENT_PREVU": "Date de remboursement prévu",
|
||||
|
@ -218,8 +221,8 @@
|
|||
"DEPOSIT_TRANSACTION_HISTORY_DESCRIPTION": "Dépôt de",
|
||||
"NO_WALLET_HISTORY": "Aucune transaction à ce jour",
|
||||
"DEMAND_SEND": "Demande envoyé",
|
||||
"EPARGNE_DEPOSE": "Epargne déposé",
|
||||
"BREAK_EPARGNE_DONE": "Epargne cassé avec succès",
|
||||
"EPARGNE_DEPOSE": "Epargne déposée",
|
||||
"BREAK_EPARGNE_DONE": "Epargne cassée avec succès",
|
||||
"BREAK_EPARGNE": "Casser mon épargne",
|
||||
"ID_EPARGNE": "Identifiant de l'épargne",
|
||||
"NO_DEMAND_CREATION_GROUP": "Aucune demande de création de groupe",
|
||||
|
|
|
@ -69,6 +69,7 @@ export const getNanoCreditAccount = testBaseUrl + '/walletService/groups/nanoCre
|
|||
export const getNanoCreditUserHistoryUrl = testBaseUrl + '/walletService/groups/nanoCredit/all_demands';
|
||||
export const getNanoCreditAgentHistoryUrl = testBaseUrl + '/walletService/groups/nanoCredit/guarantee_demands';
|
||||
export const getHyperviseurHistoriqueUrl = testBaseUrl + '/walletService/wallets/all_hyper_history';
|
||||
export const getSuperviseurHistoriqueUrl = testBaseUrl + '/walletService/wallets/all_super_history';
|
||||
export const getBankUrl = testBaseUrl + '/walletService/wallets/users/operators/bank';
|
||||
export const getHistoryNanoPendingCreditUrl = testBaseUrl + '/walletService/groups/nanoCredit/demands_in_progress';
|
||||
export const getHistoryEpargnePendingUrl = testBaseUrl + '/walletService/groups/nanoCredit/savings/demands_in_progress';
|
||||
|
|
|
@ -6,6 +6,7 @@ export default class Configuration {
|
|||
constructor() {
|
||||
|
||||
}
|
||||
|
||||
async getCurrentLangue() {
|
||||
const da = await _getData()
|
||||
if (da) resolve(da)
|
||||
|
@ -26,6 +27,7 @@ export default class Configuration {
|
|||
return pasObject.valeur_bool;
|
||||
} else return pasObject;
|
||||
}
|
||||
|
||||
async setPubActive(data) {
|
||||
try {
|
||||
if (data.pub) {
|
||||
|
@ -39,6 +41,7 @@ export default class Configuration {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
_getPubData() {
|
||||
return new Promise(async (resolve, reject) => {
|
||||
|
||||
|
@ -52,12 +55,14 @@ export default class Configuration {
|
|||
|
||||
})
|
||||
}
|
||||
|
||||
setCurrentLangue(lang) {
|
||||
this._storeData(lang)
|
||||
db.update({"configuration.lang": {$exists: true}}, {configuration: {lang: lang}}, {upsert: true}, (err, num, upsert) => {
|
||||
console.log([err, num, upsert])
|
||||
})
|
||||
}
|
||||
|
||||
setCurrentPas = async (pas) => {
|
||||
try {
|
||||
await AsyncStorage.setItem('@config:pasObject', JSON.stringify(pas.pas));
|
||||
|
|
Loading…
Reference in New Issue