Compare commits
10 Commits
cccee161ab
...
71f6af4766
Author | SHA1 | Date |
---|---|---|
|
71f6af4766 | |
|
1fdda31b81 | |
|
57a0571995 | |
|
372201ccbf | |
|
34a06b03b9 | |
|
2847ae7845 | |
|
250d25fc39 | |
|
bf6079b5e1 | |
|
6419efb521 | |
|
a9e7c2dd90 |
|
@ -40,7 +40,7 @@ import AddNetwork from "./screens/account/AddNetwork";
|
||||||
import MyHistory from "./screens/history-request/MyHistory";
|
import MyHistory from "./screens/history-request/MyHistory";
|
||||||
import Icon from "react-native-vector-icons/FontAwesome5";
|
import Icon from "react-native-vector-icons/FontAwesome5";
|
||||||
import I18n from "react-native-i18n";
|
import I18n from "react-native-i18n";
|
||||||
|
import WalletNanosante from './app/screens/wallet/user/WalletNanosante';
|
||||||
import WalletDetail from './screens/wallet/WalletDetail';
|
import WalletDetail from './screens/wallet/WalletDetail';
|
||||||
import WalletSelect from './screens/wallet/WalletSelect';
|
import WalletSelect from './screens/wallet/WalletSelect';
|
||||||
import {PersistGate} from 'redux-persist/integration/react';
|
import {PersistGate} from 'redux-persist/integration/react';
|
||||||
|
@ -57,6 +57,7 @@ import AutreCarteN from './screens/nano-sante/paymentCard/AutreCarteN';
|
||||||
import CarteLierN from './screens/nano-sante/paymentCard/carteLierN';
|
import CarteLierN from './screens/nano-sante/paymentCard/carteLierN';
|
||||||
import AutreCarte from './screens/wallet/user/AutreCarte';
|
import AutreCarte from './screens/wallet/user/AutreCarte';
|
||||||
import CarteLier from './screens/wallet/user/CarteLier'
|
import CarteLier from './screens/wallet/user/CarteLier'
|
||||||
|
import MobileMoneyNanoSante from './app/screens/wallet/user/MobileMoneyNanoSante'; './s'
|
||||||
import ValidateIdentification from './screens/identification/validateIdentification';
|
import ValidateIdentification from './screens/identification/validateIdentification';
|
||||||
import CreateIdentificationUser from './screens/identification/CreateIdentificationUser';
|
import CreateIdentificationUser from './screens/identification/CreateIdentificationUser';
|
||||||
import OperateurOptionSelect from './screens/wallet/OperateurOptionSelect';
|
import OperateurOptionSelect from './screens/wallet/OperateurOptionSelect';
|
||||||
|
@ -137,6 +138,7 @@ const AppStack = createDrawerNavigator({
|
||||||
paymentCarteVersAutreWalletNanosante: PaymentCarteVersAutreWalletNanosante,
|
paymentCarteVersAutreWalletNanosante: PaymentCarteVersAutreWalletNanosante,
|
||||||
autreCarteN: AutreCarteN,
|
autreCarteN: AutreCarteN,
|
||||||
carteLierN: CarteLierN,
|
carteLierN: CarteLierN,
|
||||||
|
mobileMoneyNanoSante: MobileMoneyNanoSante,
|
||||||
operateurOptionSelect: OperateurOptionSelect,
|
operateurOptionSelect: OperateurOptionSelect,
|
||||||
paiementFacture: PaiementFacture,
|
paiementFacture: PaiementFacture,
|
||||||
envoieWalletToWalletUser: EnvoieWalletToWalletUser,
|
envoieWalletToWalletUser: EnvoieWalletToWalletUser,
|
||||||
|
@ -269,6 +271,10 @@ const AppAgentStack = createDrawerNavigator({
|
||||||
walletOptionSelect: WalletOptionSelect,
|
walletOptionSelect: WalletOptionSelect,
|
||||||
CarteLier: CarteLier,
|
CarteLier: CarteLier,
|
||||||
AutreCarte: AutreCarte,
|
AutreCarte: AutreCarte,
|
||||||
|
AutreCarteN: AutreCarteN,
|
||||||
|
CarteLierN: CarteLierN,
|
||||||
|
MobileMoneyNanoSante: MobileMoneyNanoSante,
|
||||||
|
WalletNanosante: WalletNanosante,
|
||||||
operateurOptionSelect: OperateurOptionSelect,
|
operateurOptionSelect: OperateurOptionSelect,
|
||||||
paiementFacture: PaiementFacture,
|
paiementFacture: PaiementFacture,
|
||||||
retraitEnCashAgent: RetraitEnCashAgent,
|
retraitEnCashAgent: RetraitEnCashAgent,
|
||||||
|
|
|
@ -82,6 +82,14 @@ project.ext.react = [
|
||||||
|
|
||||||
apply from: "../../node_modules/react-native/react.gradle"
|
apply from: "../../node_modules/react-native/react.gradle"
|
||||||
|
|
||||||
|
// Force une version antérieure de work-runtime compatible avec compileSdkVersion 30
|
||||||
|
configurations.all {
|
||||||
|
resolutionStrategy {
|
||||||
|
force 'androidx.work:work-runtime:2.6.0'
|
||||||
|
force 'androidx.core:core:1.6.0'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to true to create two separate APKs instead of one:
|
* Set this to true to create two separate APKs instead of one:
|
||||||
* - An APK that only works on ARM devices
|
* - An APK that only works on ARM devices
|
||||||
|
@ -230,7 +238,7 @@ dependencies {
|
||||||
// Run this once to be able to run the application with BUCK
|
// Run this once to be able to run the application with BUCK
|
||||||
// puts all compile dependencies into folder libs for BUCK to use
|
// puts all compile dependencies into folder libs for BUCK to use
|
||||||
task copyDownloadableDepsToLibs(type: Copy) {
|
task copyDownloadableDepsToLibs(type: Copy) {
|
||||||
from configurations.compile
|
//from configurations.compile
|
||||||
into 'libs'
|
into 'libs'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -44,6 +44,7 @@
|
||||||
<activity
|
<activity
|
||||||
android:name=".MainActivity"
|
android:name=".MainActivity"
|
||||||
android:launchMode="singleTask"
|
android:launchMode="singleTask"
|
||||||
|
android:exported="true"
|
||||||
android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
|
android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
|
||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
android:windowSoftInputMode="adjustResize">
|
android:windowSoftInputMode="adjustResize">
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -12,7 +12,6 @@ buildscript {
|
||||||
}
|
}
|
||||||
repositories {
|
repositories {
|
||||||
google()
|
google()
|
||||||
//jcenter()
|
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
maven { url 'https://www.jitpack.io' }
|
maven { url 'https://www.jitpack.io' }
|
||||||
}
|
}
|
||||||
|
@ -55,7 +54,7 @@ allprojects {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
google()
|
google()
|
||||||
// jcenter()
|
//mavenCentral()
|
||||||
maven { url 'https://www.jitpack.io' }
|
maven { url 'https://www.jitpack.io' }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
|
@ -1,6 +1,6 @@
|
||||||
#Wed Oct 14 15:00:41 WAT 2020
|
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
|
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-all.zip
|
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
#!/usr/bin/env sh
|
#!/bin/sh
|
||||||
|
|
||||||
#
|
#
|
||||||
# Copyright 2015 the original author or authors.
|
# Copyright © 2015-2021 the original authors.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# https://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
@ -17,78 +17,113 @@
|
||||||
#
|
#
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
##
|
#
|
||||||
## Gradle start up script for UN*X
|
# Gradle start up script for POSIX generated by Gradle.
|
||||||
##
|
#
|
||||||
|
# Important for running:
|
||||||
|
#
|
||||||
|
# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
|
||||||
|
# noncompliant, but you have some other compliant shell such as ksh or
|
||||||
|
# bash, then to run this script, type that shell name before the whole
|
||||||
|
# command line, like:
|
||||||
|
#
|
||||||
|
# ksh Gradle
|
||||||
|
#
|
||||||
|
# Busybox and similar reduced shells will NOT work, because this script
|
||||||
|
# requires all of these POSIX shell features:
|
||||||
|
# * functions;
|
||||||
|
# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
|
||||||
|
# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
|
||||||
|
# * compound commands having a testable exit status, especially «case»;
|
||||||
|
# * various built-in commands including «command», «set», and «ulimit».
|
||||||
|
#
|
||||||
|
# Important for patching:
|
||||||
|
#
|
||||||
|
# (2) This script targets any POSIX shell, so it avoids extensions provided
|
||||||
|
# by Bash, Ksh, etc; in particular arrays are avoided.
|
||||||
|
#
|
||||||
|
# The "traditional" practice of packing multiple parameters into a
|
||||||
|
# space-separated string is a well documented source of bugs and security
|
||||||
|
# problems, so this is (mostly) avoided, by progressively accumulating
|
||||||
|
# options in "$@", and eventually passing that to Java.
|
||||||
|
#
|
||||||
|
# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
|
||||||
|
# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
|
||||||
|
# see the in-line comments for details.
|
||||||
|
#
|
||||||
|
# There are tweaks for specific operating systems such as AIX, CygWin,
|
||||||
|
# Darwin, MinGW, and NonStop.
|
||||||
|
#
|
||||||
|
# (3) This script is generated from the Groovy template
|
||||||
|
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||||
|
# within the Gradle project.
|
||||||
|
#
|
||||||
|
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||||
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
# Attempt to set APP_HOME
|
# Attempt to set APP_HOME
|
||||||
|
|
||||||
# Resolve links: $0 may be a link
|
# Resolve links: $0 may be a link
|
||||||
PRG="$0"
|
app_path=$0
|
||||||
# Need this for relative symlinks.
|
|
||||||
while [ -h "$PRG" ] ; do
|
# Need this for daisy-chained symlinks.
|
||||||
ls=`ls -ld "$PRG"`
|
while
|
||||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
|
||||||
if expr "$link" : '/.*' > /dev/null; then
|
[ -h "$app_path" ]
|
||||||
PRG="$link"
|
do
|
||||||
else
|
ls=$( ls -ld "$app_path" )
|
||||||
PRG=`dirname "$PRG"`"/$link"
|
link=${ls#*' -> '}
|
||||||
fi
|
case $link in #(
|
||||||
|
/*) app_path=$link ;; #(
|
||||||
|
*) app_path=$APP_HOME$link ;;
|
||||||
|
esac
|
||||||
done
|
done
|
||||||
SAVED="`pwd`"
|
|
||||||
cd "`dirname \"$PRG\"`/" >/dev/null
|
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||||
APP_HOME="`pwd -P`"
|
|
||||||
cd "$SAVED" >/dev/null
|
|
||||||
|
|
||||||
APP_NAME="Gradle"
|
APP_NAME="Gradle"
|
||||||
APP_BASE_NAME=`basename "$0"`
|
APP_BASE_NAME=${0##*/}
|
||||||
|
|
||||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||||
|
|
||||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||||
MAX_FD="maximum"
|
MAX_FD=maximum
|
||||||
|
|
||||||
warn () {
|
warn () {
|
||||||
echo "$*"
|
echo "$*"
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
die () {
|
die () {
|
||||||
echo
|
echo
|
||||||
echo "$*"
|
echo "$*"
|
||||||
echo
|
echo
|
||||||
exit 1
|
exit 1
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
# OS specific support (must be 'true' or 'false').
|
# OS specific support (must be 'true' or 'false').
|
||||||
cygwin=false
|
cygwin=false
|
||||||
msys=false
|
msys=false
|
||||||
darwin=false
|
darwin=false
|
||||||
nonstop=false
|
nonstop=false
|
||||||
case "`uname`" in
|
case "$( uname )" in #(
|
||||||
CYGWIN* )
|
CYGWIN* ) cygwin=true ;; #(
|
||||||
cygwin=true
|
Darwin* ) darwin=true ;; #(
|
||||||
;;
|
MSYS* | MINGW* ) msys=true ;; #(
|
||||||
Darwin* )
|
NONSTOP* ) nonstop=true ;;
|
||||||
darwin=true
|
|
||||||
;;
|
|
||||||
MINGW* )
|
|
||||||
msys=true
|
|
||||||
;;
|
|
||||||
NONSTOP* )
|
|
||||||
nonstop=true
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||||
|
|
||||||
|
|
||||||
# Determine the Java command to use to start the JVM.
|
# Determine the Java command to use to start the JVM.
|
||||||
if [ -n "$JAVA_HOME" ] ; then
|
if [ -n "$JAVA_HOME" ] ; then
|
||||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||||
# IBM's JDK on AIX uses strange locations for the executables
|
# IBM's JDK on AIX uses strange locations for the executables
|
||||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
JAVACMD=$JAVA_HOME/jre/sh/java
|
||||||
else
|
else
|
||||||
JAVACMD="$JAVA_HOME/bin/java"
|
JAVACMD=$JAVA_HOME/bin/java
|
||||||
fi
|
fi
|
||||||
if [ ! -x "$JAVACMD" ] ; then
|
if [ ! -x "$JAVACMD" ] ; then
|
||||||
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
||||||
|
@ -97,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the
|
||||||
location of your Java installation."
|
location of your Java installation."
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
JAVACMD="java"
|
JAVACMD=java
|
||||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||||
|
|
||||||
Please set the JAVA_HOME variable in your environment to match the
|
Please set the JAVA_HOME variable in your environment to match the
|
||||||
|
@ -105,85 +140,95 @@ location of your Java installation."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Increase the maximum file descriptors if we can.
|
# Increase the maximum file descriptors if we can.
|
||||||
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
|
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||||
MAX_FD_LIMIT=`ulimit -H -n`
|
case $MAX_FD in #(
|
||||||
if [ $? -eq 0 ] ; then
|
max*)
|
||||||
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
MAX_FD=$( ulimit -H -n ) ||
|
||||||
MAX_FD="$MAX_FD_LIMIT"
|
warn "Could not query maximum file descriptor limit"
|
||||||
fi
|
esac
|
||||||
ulimit -n $MAX_FD
|
case $MAX_FD in #(
|
||||||
if [ $? -ne 0 ] ; then
|
'' | soft) :;; #(
|
||||||
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
*)
|
||||||
fi
|
ulimit -n "$MAX_FD" ||
|
||||||
else
|
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||||
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# For Darwin, add options to specify how the application appears in the dock
|
|
||||||
if $darwin; then
|
|
||||||
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
|
|
||||||
fi
|
|
||||||
|
|
||||||
# For Cygwin or MSYS, switch paths to Windows format before running java
|
|
||||||
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
|
|
||||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
|
||||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
|
||||||
|
|
||||||
JAVACMD=`cygpath --unix "$JAVACMD"`
|
|
||||||
|
|
||||||
# We build the pattern for arguments to be converted via cygpath
|
|
||||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
|
||||||
SEP=""
|
|
||||||
for dir in $ROOTDIRSRAW ; do
|
|
||||||
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
|
||||||
SEP="|"
|
|
||||||
done
|
|
||||||
OURCYGPATTERN="(^($ROOTDIRS))"
|
|
||||||
# Add a user-defined pattern to the cygpath arguments
|
|
||||||
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
|
||||||
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
|
||||||
fi
|
|
||||||
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
|
||||||
i=0
|
|
||||||
for arg in "$@" ; do
|
|
||||||
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
|
||||||
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
|
||||||
|
|
||||||
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
|
||||||
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
|
||||||
else
|
|
||||||
eval `echo args$i`="\"$arg\""
|
|
||||||
fi
|
|
||||||
i=`expr $i + 1`
|
|
||||||
done
|
|
||||||
case $i in
|
|
||||||
0) set -- ;;
|
|
||||||
1) set -- "$args0" ;;
|
|
||||||
2) set -- "$args0" "$args1" ;;
|
|
||||||
3) set -- "$args0" "$args1" "$args2" ;;
|
|
||||||
4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
|
||||||
5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
|
||||||
6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
|
||||||
7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
|
||||||
8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
|
||||||
9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Escape application args
|
# Collect all arguments for the java command, stacking in reverse order:
|
||||||
save () {
|
# * args from the command line
|
||||||
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
|
# * the main class name
|
||||||
echo " "
|
# * -classpath
|
||||||
}
|
# * -D...appname settings
|
||||||
APP_ARGS=`save "$@"`
|
# * --module-path (only if needed)
|
||||||
|
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
|
||||||
|
|
||||||
# Collect all arguments for the java command, following the shell quoting and substitution rules
|
# For Cygwin or MSYS, switch paths to Windows format before running java
|
||||||
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
|
if "$cygwin" || "$msys" ; then
|
||||||
|
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
|
||||||
|
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
|
||||||
|
|
||||||
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
|
JAVACMD=$( cygpath --unix "$JAVACMD" )
|
||||||
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
|
|
||||||
cd "$(dirname "$0")"
|
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
||||||
|
for arg do
|
||||||
|
if
|
||||||
|
case $arg in #(
|
||||||
|
-*) false ;; # don't mess with options #(
|
||||||
|
/?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
|
||||||
|
[ -e "$t" ] ;; #(
|
||||||
|
*) false ;;
|
||||||
|
esac
|
||||||
|
then
|
||||||
|
arg=$( cygpath --path --ignore --mixed "$arg" )
|
||||||
|
fi
|
||||||
|
# Roll the args list around exactly as many times as the number of
|
||||||
|
# args, so each arg winds up back in the position where it started, but
|
||||||
|
# possibly modified.
|
||||||
|
#
|
||||||
|
# NB: a `for` loop captures its iteration list before it begins, so
|
||||||
|
# changing the positional parameters here affects neither the number of
|
||||||
|
# iterations, nor the values presented in `arg`.
|
||||||
|
shift # remove old arg
|
||||||
|
set -- "$@" "$arg" # push replacement arg
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Collect all arguments for the java command;
|
||||||
|
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||||
|
# shell script including quotes and variable substitutions, so put them in
|
||||||
|
# double quotes to make sure that they get re-expanded; and
|
||||||
|
# * put everything else in single quotes, so that it's not re-expanded.
|
||||||
|
|
||||||
|
set -- \
|
||||||
|
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||||
|
-classpath "$CLASSPATH" \
|
||||||
|
org.gradle.wrapper.GradleWrapperMain \
|
||||||
|
"$@"
|
||||||
|
|
||||||
|
# Use "xargs" to parse quoted args.
|
||||||
|
#
|
||||||
|
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
|
||||||
|
#
|
||||||
|
# In Bash we could simply go:
|
||||||
|
#
|
||||||
|
# readarray ARGS < <( xargs -n1 <<<"$var" ) &&
|
||||||
|
# set -- "${ARGS[@]}" "$@"
|
||||||
|
#
|
||||||
|
# but POSIX shell has neither arrays nor command substitution, so instead we
|
||||||
|
# post-process each arg (as a line of input to sed) to backslash-escape any
|
||||||
|
# character that might be a shell metacharacter, then use eval to reverse
|
||||||
|
# that process (while maintaining the separation between arguments), and wrap
|
||||||
|
# the whole thing up as a single "set" statement.
|
||||||
|
#
|
||||||
|
# This will of course break if any of these variables contains a newline or
|
||||||
|
# an unmatched quote.
|
||||||
|
#
|
||||||
|
|
||||||
|
eval "set -- $(
|
||||||
|
printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
|
||||||
|
xargs -n1 |
|
||||||
|
sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
|
||||||
|
tr '\n' ' '
|
||||||
|
)" '"$@"'
|
||||||
|
|
||||||
exec "$JAVACMD" "$@"
|
exec "$JAVACMD" "$@"
|
||||||
|
|
|
@ -6,16 +6,16 @@
|
||||||
* Date: 26/08/2021
|
* Date: 26/08/2021
|
||||||
*/
|
*/
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import {SafeAreaView} from 'react-native';
|
import {SafeAreaView, View} from 'react-native';
|
||||||
import {NetInfoBar} from './NetInfoBar';
|
import {NetInfoBar} from './NetInfoBar';
|
||||||
import {Color} from "../config/Color";
|
import {Color} from "../config/Color";
|
||||||
|
|
||||||
export const ScreenComponent = React.forwardRef((props, ref) => (
|
export const ScreenComponent = React.forwardRef((props, ref) => (
|
||||||
<SafeAreaView style={[{flex: 1, backgroundColor: Color.containerBackgroundColor}, props.style]} {...props}>
|
<SafeAreaView style={[ props.style]} {...props}>
|
||||||
<NetInfoBar/>
|
<NetInfoBar/>
|
||||||
{/* React.Children.map(props.children, child =>
|
{React.Children.map(props.children, child =>
|
||||||
React.cloneElement(child, {}),
|
React.cloneElement(child, {}),
|
||||||
) */}
|
)}
|
||||||
{props.children}
|
{/* {props.children} */}
|
||||||
</SafeAreaView>
|
</SafeAreaView>
|
||||||
));
|
));
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import { StyleSheet } from "react-native";
|
import { StyleSheet } from "react-native";
|
||||||
|
import { responsiveFontSize } from "react-native-responsive-dimensions";
|
||||||
|
|
||||||
export const FontWeight = {
|
export const FontWeight = {
|
||||||
thin: "100",
|
thin: "100",
|
||||||
|
@ -26,7 +27,7 @@ export const Typography = StyleSheet.create({
|
||||||
fontWeight: FontWeight.regular
|
fontWeight: FontWeight.regular
|
||||||
},
|
},
|
||||||
title3: {
|
title3: {
|
||||||
fontSize: 20,
|
fontSize: responsiveFontSize(2),
|
||||||
fontWeight: FontWeight.regular
|
fontWeight: FontWeight.regular
|
||||||
},
|
},
|
||||||
headline: {
|
headline: {
|
||||||
|
|
|
@ -12,7 +12,7 @@ import {
|
||||||
import {responsiveHeight, responsiveWidth} from "react-native-responsive-dimensions"
|
import {responsiveHeight, responsiveWidth} from "react-native-responsive-dimensions"
|
||||||
import BaseScreen from "../BaseScreen";
|
import BaseScreen from "../BaseScreen";
|
||||||
import Icon from "react-native-vector-icons/MaterialIcons";
|
import Icon from "react-native-vector-icons/MaterialIcons";
|
||||||
import BlurOverlay, {openOverlay, closeOverlay} from 'react-native-blur-overlay'
|
//import BlurOverlay, {openOverlay, closeOverlay} from 'react-native-blur-overlay'
|
||||||
import I18n from 'react-native-i18n';
|
import I18n from 'react-native-i18n';
|
||||||
import {WebView} from 'react-native-webview';
|
import {WebView} from 'react-native-webview';
|
||||||
|
|
||||||
|
@ -49,50 +49,50 @@ export default class InterticielAds
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
render() {
|
// render() {
|
||||||
return (<BlurOverlay radius={14}
|
// return (<BlurOverlay radius={14}
|
||||||
downsampling={2}
|
// downsampling={2}
|
||||||
onPress={() => {
|
// onPress={() => {
|
||||||
this.setState({isPubShow: false})
|
// this.setState({isPubShow: false})
|
||||||
}}
|
// }}
|
||||||
brightness={-200}
|
// brightness={-200}
|
||||||
|
|
||||||
>
|
// >
|
||||||
{this.renderChild()}
|
// {this.renderChild()}
|
||||||
</BlurOverlay>)
|
// </BlurOverlay>)
|
||||||
}
|
// }
|
||||||
|
|
||||||
renderChild() {
|
// renderChild() {
|
||||||
return (<View style={styles.container}>
|
// return (<View style={styles.container}>
|
||||||
|
|
||||||
<WebView
|
// <WebView
|
||||||
source={{uri: 'https://ilink-app.com/ads.html'}}
|
// source={{uri: 'https://ilink-app.com/ads.html'}}
|
||||||
style={{
|
// style={{
|
||||||
width: responsiveWidth(100),
|
// width: responsiveWidth(100),
|
||||||
marginTop: 37 + responsiveHeight(4),
|
// marginTop: 37 + responsiveHeight(4),
|
||||||
backgroundColor: 'white'
|
// backgroundColor: 'white'
|
||||||
}}
|
// }}
|
||||||
/>
|
// />
|
||||||
<View>
|
// <View>
|
||||||
<Button
|
// <Button
|
||||||
title={I18n.t('QUIT_')}
|
// title={I18n.t('QUIT_')}
|
||||||
color={theme.reddeconnect}
|
// color={theme.reddeconnect}
|
||||||
style={{position: 'absolute', zIndex: 10000}}
|
// style={{position: 'absolute', zIndex: 10000}}
|
||||||
onPress={() => {
|
// onPress={() => {
|
||||||
this.popOverLay()
|
// this.popOverLay()
|
||||||
}}
|
// }}
|
||||||
>{I18n.t('QUIT_')}</Button>
|
// >{I18n.t('QUIT_')}</Button>
|
||||||
|
|
||||||
</View>
|
// </View>
|
||||||
|
|
||||||
</View>)
|
// </View>)
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
componentDidMount() {
|
// componentDidMount() {
|
||||||
openOverlay()
|
// openOverlay()
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
async tryGetHtml() {
|
async tryGetHtml() {
|
||||||
response = await fetch('https://ad-server.ilink-app.com/ad_display/zone1/zone4.html')
|
response = await fetch('https://ad-server.ilink-app.com/ad_display/zone1/zone4.html')
|
||||||
|
@ -101,7 +101,7 @@ export default class InterticielAds
|
||||||
popOverLay() {
|
popOverLay() {
|
||||||
if (this.props.closeIntersticiel)
|
if (this.props.closeIntersticiel)
|
||||||
this.props.closeIntersticiel()
|
this.props.closeIntersticiel()
|
||||||
closeOverlay()
|
//closeOverlay()
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,6 +20,7 @@ import {
|
||||||
TouchableOpacity,
|
TouchableOpacity,
|
||||||
View
|
View
|
||||||
} from 'react-native';
|
} from 'react-native';
|
||||||
|
import { NetInfoBar } from '../../components/NetInfoBar';
|
||||||
import axios from "axios";
|
import axios from "axios";
|
||||||
import IMap from './IMap'
|
import IMap from './IMap'
|
||||||
import ActionButton from 'react-native-action-button';
|
import ActionButton from 'react-native-action-button';
|
||||||
|
@ -1736,8 +1737,10 @@ class Home extends BaseScreen {
|
||||||
<StatusBar
|
<StatusBar
|
||||||
backgroundColor="#00000030"
|
backgroundColor="#00000030"
|
||||||
barStyle="light-content"
|
barStyle="light-content"
|
||||||
translucent={true}
|
translucent={false}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|
||||||
{/* Start here to comment */}
|
{/* Start here to comment */}
|
||||||
{/* {
|
{/* {
|
||||||
(this.state.loadingDialog || this.props.loading) ?
|
(this.state.loadingDialog || this.props.loading) ?
|
||||||
|
@ -1793,6 +1796,8 @@ class Home extends BaseScreen {
|
||||||
}])
|
}])
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|
||||||
{this.makeCardSearch()}
|
{this.makeCardSearch()}
|
||||||
{this.showInterticiel()}
|
{this.showInterticiel()}
|
||||||
{this.makeSlidingUp()}
|
{this.makeSlidingUp()}
|
||||||
|
@ -1807,7 +1812,6 @@ class Home extends BaseScreen {
|
||||||
autoHidingTime={5000}
|
autoHidingTime={5000}
|
||||||
/>
|
/>
|
||||||
{this.makeActionButon()}
|
{this.makeActionButon()}
|
||||||
|
|
||||||
</View>
|
</View>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -102,8 +102,11 @@ export default class CreateUserStep2 extends Component {
|
||||||
|
|
||||||
retreiveCodeInformation() {
|
retreiveCodeInformation() {
|
||||||
const membre = this.state.user.member;
|
const membre = this.state.user.member;
|
||||||
|
console.log("membre===>> ", membre);
|
||||||
|
console.log("1===>>");
|
||||||
return new Promise(async (resolve, reject) => {
|
return new Promise(async (resolve, reject) => {
|
||||||
let datas = await getCodeInformation(membre)
|
let datas = await getCodeInformation(membre)
|
||||||
|
console.log("datas===>> ", datas);
|
||||||
resolve(datas)
|
resolve(datas)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -128,8 +131,9 @@ export default class CreateUserStep2 extends Component {
|
||||||
select_network: I18n.t("SELECT_NETWORK"),
|
select_network: I18n.t("SELECT_NETWORK"),
|
||||||
user: this.user,
|
user: this.user,
|
||||||
provider_class: null,
|
provider_class: null,
|
||||||
provider_classes: []
|
provider_classes: [],
|
||||||
|
latitude: "",
|
||||||
|
longitude: "",
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -144,8 +148,11 @@ export default class CreateUserStep2 extends Component {
|
||||||
if (indicatif) {
|
if (indicatif) {
|
||||||
let result = {}
|
let result = {}
|
||||||
try {
|
try {
|
||||||
|
console.log("RESULTAT1===>> ", indicatif);
|
||||||
result = await this.retreiveCodeInformation()
|
result = await this.retreiveCodeInformation()
|
||||||
const {category} = result
|
const {category} = result
|
||||||
|
console.log("RESULTAT===>> ", result);
|
||||||
|
this.setState({result});
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
result = false
|
result = false
|
||||||
}
|
}
|
||||||
|
@ -157,7 +164,10 @@ export default class CreateUserStep2 extends Component {
|
||||||
this.setState({
|
this.setState({
|
||||||
modalVisible: false, networks: [result.network],
|
modalVisible: false, networks: [result.network],
|
||||||
network: result.network, select_network: I18n.t("YOUR_NETWORK")
|
network: result.network, select_network: I18n.t("YOUR_NETWORK")
|
||||||
})
|
});
|
||||||
|
if (result.child === "geolocated" || result.child === "super") {
|
||||||
|
this.setState({network: result.network, select_network: I18n.t("YOUR_NETWORK_SELECTED")});
|
||||||
|
}
|
||||||
|
|
||||||
else {
|
else {
|
||||||
Alert.alert(I18n.t('TITLE_PROBLE_COME'), "Impossible de recuperer les informations du code parrain", [{
|
Alert.alert(I18n.t('TITLE_PROBLE_COME'), "Impossible de recuperer les informations du code parrain", [{
|
||||||
|
@ -166,13 +176,13 @@ export default class CreateUserStep2 extends Component {
|
||||||
}])
|
}])
|
||||||
}
|
}
|
||||||
|
|
||||||
if (result.hasOwnProperty('provider_classes'))
|
// if (result.hasOwnProperty('provider_classes'))
|
||||||
this.setState({provider_classes: result.provider_classes});
|
// this.setState({provider_classes: result.provider_classes});
|
||||||
} else {
|
} else {
|
||||||
console.log("need enable")
|
console.log("need enable")
|
||||||
getCountryNetwork(indicatif).then((result) => {
|
getCountryNetwork(indicatif).then((result) => {
|
||||||
this.reseaux = [];
|
this.reseaux = [];
|
||||||
let networks = result;
|
let networks = result;;
|
||||||
|
|
||||||
for (let prop in networks) {
|
for (let prop in networks) {
|
||||||
if (networks[prop] !== "") {
|
if (networks[prop] !== "") {
|
||||||
|
@ -240,7 +250,7 @@ export default class CreateUserStep2 extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
|
this.fetchCountries();
|
||||||
this.mounted = true;
|
this.mounted = true;
|
||||||
const {type} = this.props;
|
const {type} = this.props;
|
||||||
|
|
||||||
|
@ -254,6 +264,93 @@ export default class CreateUserStep2 extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
getCountryByLocation = async (countriesArray) => {
|
||||||
|
try {
|
||||||
|
// Vérification des permissions Android
|
||||||
|
if (Platform.OS === 'android') {
|
||||||
|
const granted = await PermissionsAndroid.request(
|
||||||
|
PermissionsAndroid.PERMISSIONS.ACCESS_FINE_LOCATION
|
||||||
|
);
|
||||||
|
|
||||||
|
if (granted !== PermissionsAndroid.RESULTS.GRANTED) {
|
||||||
|
return this.findDefaultCountry(countriesArray);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Récupération de la position
|
||||||
|
const position = await new Promise((resolve, reject) => {
|
||||||
|
Geolocation.getCurrentPosition(resolve, reject, GEOLOCATION_OPTIONS);
|
||||||
|
});
|
||||||
|
// Reverse geocoding
|
||||||
|
const geocodeResponse = await getPositionInformation(position.coords);
|
||||||
|
const countryComponent = geocodeResponse.results[0]?.address_components?.find(
|
||||||
|
c => c.types.includes("country")
|
||||||
|
);
|
||||||
|
|
||||||
|
if (!countryComponent) return this.findDefaultCountry(countriesArray);
|
||||||
|
|
||||||
|
// Recherche dans le tableau
|
||||||
|
const foundCountry = countriesArray.find(
|
||||||
|
country => country.code_country === countryComponent.short_name
|
||||||
|
);
|
||||||
|
return foundCountry || this.findDefaultCountry(countriesArray);
|
||||||
|
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Erreur de géolocalisation:', error);
|
||||||
|
return this.findDefaultCountry(countriesArray);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
// Fonction helper pour trouver le Cameroun
|
||||||
|
findDefaultCountry = (countriesArray) => {
|
||||||
|
return countriesArray.find(c => c.code_country === "CM") || countriesArray[0];
|
||||||
|
};
|
||||||
|
fetchCountries = async () => {
|
||||||
|
try {
|
||||||
|
const response = await getListCountriesActive();
|
||||||
|
|
||||||
|
let countriesData = [];
|
||||||
|
if (response.error === "error" && response.error_msg) {
|
||||||
|
const jsonMatch = response.error_msg.match(/\[.*\]/);
|
||||||
|
if (jsonMatch) {
|
||||||
|
countriesData = JSON.parse(jsonMatch[0]);
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
countriesData = response;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const formattedCountries = countriesData.map(country => ({
|
||||||
|
label: country.name,
|
||||||
|
value: country.name,
|
||||||
|
code_dial: country.code_dial,
|
||||||
|
code_country: country.code_country
|
||||||
|
}));
|
||||||
|
const detectedCountry = await this.getCountryByLocation(formattedCountries);
|
||||||
|
this.setState({
|
||||||
|
country: formattedCountries,
|
||||||
|
countries: formattedCountries[0],
|
||||||
|
isLoading: false,
|
||||||
|
selectedCountry: detectedCountry, // Sélectionne le premier pays par défaut
|
||||||
|
indicatif: detectedCountry?.code_dial
|
||||||
|
});
|
||||||
|
this.getNetworks(detectedCountry.code_dial);
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Erreur lors de la récupération des pays:', error);
|
||||||
|
this.setState({ isLoading: false });
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
handleCountryChange = (value, index, data) => {
|
||||||
|
const selectedCountry = this.state.countries[index];
|
||||||
|
this.setState({
|
||||||
|
selectedCountry: selectedCountry,
|
||||||
|
indicatif: selectedCountry.code_dial,
|
||||||
|
network: null
|
||||||
|
});
|
||||||
|
this.getNetworks(selectedCountry.code_dial);
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
async requestGeolocationPermission() {
|
async requestGeolocationPermission() {
|
||||||
try {
|
try {
|
||||||
|
@ -289,96 +386,289 @@ export default class CreateUserStep2 extends Component {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// async watchLocation() {
|
||||||
|
// Geolocation.getCurrentPosition((position) => {
|
||||||
|
// this.treatPosition(position)
|
||||||
|
// }, (e) => {
|
||||||
|
// this.showErrorDialog()
|
||||||
|
// }, this.props.geolocationOptions);
|
||||||
|
// if (!this.watchID) {
|
||||||
|
// Geolocation.watchPosition((position) => {
|
||||||
|
// this.treatPosition(position)
|
||||||
|
// }, (e) => {
|
||||||
|
// this.showErrorDialog()
|
||||||
|
// }, this.props.geolocationOptions)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// treatPosition(position) {
|
||||||
|
// const myLastPosition = this.state.myPosition;
|
||||||
|
// const myPosition = position.coords;
|
||||||
|
|
||||||
|
// if (!isEqual(myPosition, myLastPosition)) {
|
||||||
|
// getPositionInformation(myPosition).then((response) => {
|
||||||
|
// if (response.results !== undefined) {
|
||||||
|
// if (response.results.length > 0) {
|
||||||
|
// let most = response.results[0]
|
||||||
|
// let {address_components, formatted_address, place_id} = most
|
||||||
|
// this.setState({address: address_components, textadress: formatted_address, place: place_id})
|
||||||
|
|
||||||
|
// let results = response.results;
|
||||||
|
// let shortcountry;
|
||||||
|
// let mcountry;
|
||||||
|
// for (let i = 0; i < results[0].address_components.length; i++) {
|
||||||
|
// for (let j = 0; j < results[0].address_components[i].types.length; j++) {
|
||||||
|
// if (results[0].address_components[i].types[j] === "country") {
|
||||||
|
// mcountry = results[0].address_components[i];
|
||||||
|
// shortcountry = mcountry.short_name;
|
||||||
|
// this.setState({shortCountry: mcountry.short_name, longCountry: mcountry.long_name})
|
||||||
|
// } else if (results[0].address_components[i].types[j] === "locality") {
|
||||||
|
// const name = results[0].address_components[i].short_name;
|
||||||
|
// this.setState({townName: name});
|
||||||
|
// getTownInformationName(name).then((result) => {
|
||||||
|
// let town = null;
|
||||||
|
// if (result instanceof Array) {
|
||||||
|
// town = result[0];
|
||||||
|
// } else
|
||||||
|
// town = result;
|
||||||
|
// this.setState({town: town});
|
||||||
|
// })
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// getListCountriesActive().then((cnt) => {
|
||||||
|
// this.setState({countries: cnt})
|
||||||
|
// console.debug(cnt, shortcountry);
|
||||||
|
// var found = false
|
||||||
|
// for (let i of cnt) {
|
||||||
|
// if (i.code_country === shortcountry) {
|
||||||
|
// found = true
|
||||||
|
// this.setState({indicatif: i.code_dial, country: i.name})
|
||||||
|
// this.getNetworks(i.code_dial);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// if (!found) {
|
||||||
|
// Alert.alert("Impossible de recupérer vos informations", "Nous n'avons pas pu recuperer les informations de votre pays veuillez contacter les administrateurs", [{text: "OK"}]);
|
||||||
|
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
|
||||||
|
|
||||||
|
// }
|
||||||
|
|
||||||
|
// }
|
||||||
|
// }).catch((e) => {
|
||||||
|
// this.showErrorDialog()
|
||||||
|
// });
|
||||||
|
// this.setState({myPosition: myPosition});
|
||||||
|
// if (this.mapRef !== undefined && this.mapRef !== null) {
|
||||||
|
// this.mapRef.animateToCoordinate({
|
||||||
|
// latitude: myPosition.latitude,
|
||||||
|
// longitude: myPosition.longitude
|
||||||
|
// }, 1000);
|
||||||
|
// this.mapRef.animateToRegion({
|
||||||
|
// latitude: myPosition.latitude,
|
||||||
|
// longitude: myPosition.longitude,
|
||||||
|
// latitudeDelta: 0.03,
|
||||||
|
// longitudeDelta: 0.01,
|
||||||
|
// }, 1000)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// }
|
||||||
async watchLocation() {
|
async watchLocation() {
|
||||||
|
if (this.isOffline) {
|
||||||
|
Geolocation.getCurrentPosition((position) => {
|
||||||
|
this.setState({
|
||||||
|
modalVisible: false,
|
||||||
|
latitude: position.coords.latitude,
|
||||||
|
longitude: position.coords.longitude
|
||||||
|
}, () => {
|
||||||
|
|
||||||
|
});
|
||||||
|
if (this.result.child) {
|
||||||
|
this.setState({disableNetwork: true});
|
||||||
|
if (this.result.network) {
|
||||||
|
this.setState({
|
||||||
|
modalVisible: false, networks: [this.result.network],
|
||||||
|
});
|
||||||
|
if (this.result.child === "geolocated" || this.result.child === "super") {
|
||||||
|
this.setState({
|
||||||
|
network: this.result.network,
|
||||||
|
select_network: I18n.t("YOUR_NETWORK_SELECTED")
|
||||||
|
});
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.showErrorDialog();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}, (e) => {
|
||||||
|
Alert.alert(I18n.t('TITLE_PROBLE_COME'), "Impossible de recuperer les informations du code parrain", [{
|
||||||
|
text: "Reesayer",
|
||||||
|
onPress: () => this.watchLocation()
|
||||||
|
}])
|
||||||
|
console.warn("POSITION ERROR", e);
|
||||||
|
this.setState({modalVisible: false})
|
||||||
|
}, this.props.geolocationOptions);
|
||||||
|
} else {
|
||||||
Geolocation.getCurrentPosition((position) => {
|
Geolocation.getCurrentPosition((position) => {
|
||||||
this.treatPosition(position)
|
this.treatPosition(position)
|
||||||
}, (e) => {
|
}, (e) => {
|
||||||
this.showErrorDialog()
|
this.showErrorDialog();
|
||||||
}, this.props.geolocationOptions);
|
}, this.props.geolocationOptions);
|
||||||
if (!this.watchID) {
|
/* if (!this.watchID) {
|
||||||
Geolocation.watchPosition((position) => {
|
Geolocation.watchPosition((position) => {
|
||||||
this.treatPosition(position)
|
this.treatPosition(position)
|
||||||
}, (e) => {
|
}, (e) => {
|
||||||
this.showErrorDialog()
|
this.showErrorDialog();
|
||||||
}, this.props.geolocationOptions)
|
}, this.props.geolocationOptions)
|
||||||
}
|
}*/
|
||||||
}
|
}
|
||||||
|
|
||||||
treatPosition(position) {
|
}
|
||||||
const myLastPosition = this.state.myPosition;
|
|
||||||
|
// treatPosition(position) {
|
||||||
|
// console.log("debugTreatPosition1===>>")
|
||||||
|
// const myLastPosition = this.state.myPosition;
|
||||||
|
// const myPosition = position.coords;
|
||||||
|
|
||||||
|
// if (!isEqual(myPosition, myLastPosition)) {
|
||||||
|
// console.log("debugTreatPosition2===>>")
|
||||||
|
// getPositionInformation(myPosition).then((response) => {
|
||||||
|
// console.log("debugTreatPosition3===>>", response)
|
||||||
|
// if (response.results !== undefined) {
|
||||||
|
// console.log("debugTreatPosition4===>>")
|
||||||
|
// if (response.results.length > 0) {
|
||||||
|
// console.log("debugTreatPosition5===>>")
|
||||||
|
// let most = response.results[0]
|
||||||
|
// let {address_components, formatted_address, place_id} = most
|
||||||
|
// this.setState({address: address_components, textadress: formatted_address, place: place_id})
|
||||||
|
|
||||||
|
// let results = response.results;
|
||||||
|
// let shortcountry;
|
||||||
|
// let mcountry;
|
||||||
|
// for (let i = 0; i < results[0].address_components.length; i++) {
|
||||||
|
// for (let j = 0; j < results[0].address_components[i].types.length; j++) {
|
||||||
|
// console.log("debugTreatPositionX===>>",JSON.stringify(results))
|
||||||
|
// if (results[0].address_components[i].types[j] === "country") {
|
||||||
|
// console.log("debugTreatPosition6===>>")
|
||||||
|
// mcountry = results[0].address_components[i];
|
||||||
|
// shortcountry = mcountry.short_name;
|
||||||
|
// this.setState({shortCountry: mcountry.short_name, longCountry: mcountry.long_name})
|
||||||
|
// } else if (results[0].address_components[i].types[j] === "locality") {
|
||||||
|
// console.log("debugTreatPosition7===>>")
|
||||||
|
// const name = results[0].address_components[i].short_name;
|
||||||
|
// this.setState({townName: name});
|
||||||
|
// getTownInformationName(name).then((result) => {
|
||||||
|
// console.log("debugTreatPosition8===>>",result)
|
||||||
|
// let town = null;
|
||||||
|
// if (result instanceof Array) {
|
||||||
|
// town = result[0];
|
||||||
|
// } else
|
||||||
|
// town = result;
|
||||||
|
// console.log("Mise a jour getTownInformationNametown===>>", town);
|
||||||
|
// this.setState({town: town});
|
||||||
|
// })
|
||||||
|
// } else {
|
||||||
|
// console.log("debugTreatPosition10===>>")
|
||||||
|
// getDefaultTown().then(result => {
|
||||||
|
// getTownInformationName(result.default_locality).then((resultTowwn) => {
|
||||||
|
// let town = null;
|
||||||
|
// if (resultTowwn instanceof Array) {
|
||||||
|
// town = resultTowwn[0];
|
||||||
|
// } else
|
||||||
|
// town = resultTowwn;
|
||||||
|
// this.setState({town: town});
|
||||||
|
// });
|
||||||
|
// })
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// getListCountriesActive().then((cnt) => {
|
||||||
|
// this.setState({countries: cnt})
|
||||||
|
// console.debug(cnt, shortcountry);
|
||||||
|
// var found = false
|
||||||
|
// for (let i of cnt) {
|
||||||
|
// if (i.code_country === shortcountry) {
|
||||||
|
// found = true
|
||||||
|
// this.setState({indicatif: i.code_dial, country: i.name})
|
||||||
|
// this.getNetworks(i.code_dial);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// if (!found) {
|
||||||
|
// Alert.alert("Impossible de recupérer vos informations", "Nous n'avons pas pu recuperer les informations de votre pays veuillez contacter les administrateurs", [{text: "OK"}]);
|
||||||
|
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
|
||||||
|
|
||||||
|
// }
|
||||||
|
|
||||||
|
// }
|
||||||
|
// }).catch((e) => {
|
||||||
|
|
||||||
|
// });
|
||||||
|
// this.setState({myPosition: myPosition});
|
||||||
|
// if (this.mapRef !== undefined && this.mapRef !== null) {
|
||||||
|
// this.mapRef.animateToCoordinate({
|
||||||
|
// latitude: myPosition.latitude,
|
||||||
|
// longitude: myPosition.longitude
|
||||||
|
// }, 1000);
|
||||||
|
// this.mapRef.animateToRegion({
|
||||||
|
// latitude: myPosition.latitude,
|
||||||
|
// longitude: myPosition.longitude,
|
||||||
|
// latitudeDelta: 0.03,
|
||||||
|
// longitudeDelta: 0.01,
|
||||||
|
// }, 1000)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
// }
|
||||||
|
treatPosition = async (position) => {
|
||||||
const myPosition = position.coords;
|
const myPosition = position.coords;
|
||||||
|
if (isEqual(myPosition, this.state.myPosition)) return;
|
||||||
|
|
||||||
if (!isEqual(myPosition, myLastPosition)) {
|
try {
|
||||||
getPositionInformation(myPosition).then((response) => {
|
const { results = [] } = await getPositionInformation(myPosition);
|
||||||
if (response.results !== undefined) {
|
if (!results.length) return;
|
||||||
if (response.results.length > 0) {
|
|
||||||
let most = response.results[0]
|
|
||||||
let {address_components, formatted_address, place_id} = most
|
|
||||||
this.setState({address: address_components, textadress: formatted_address, place: place_id})
|
|
||||||
|
|
||||||
let results = response.results;
|
|
||||||
let shortcountry;
|
|
||||||
let mcountry;
|
|
||||||
for (let i = 0; i < results[0].address_components.length; i++) {
|
|
||||||
for (let j = 0; j < results[0].address_components[i].types.length; j++) {
|
|
||||||
if (results[0].address_components[i].types[j] === "country") {
|
|
||||||
mcountry = results[0].address_components[i];
|
|
||||||
shortcountry = mcountry.short_name;
|
|
||||||
this.setState({shortCountry: mcountry.short_name, longCountry: mcountry.long_name})
|
|
||||||
} else if (results[0].address_components[i].types[j] === "locality") {
|
|
||||||
const name = results[0].address_components[i].short_name;
|
|
||||||
this.setState({townName: name});
|
|
||||||
getTownInformationName(name).then((result) => {
|
|
||||||
let town = null;
|
|
||||||
if (result instanceof Array) {
|
|
||||||
town = result[0];
|
|
||||||
} else
|
|
||||||
town = result;
|
|
||||||
this.setState({town: town});
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
getListCountriesActive().then((cnt) => {
|
|
||||||
this.setState({countries: cnt})
|
|
||||||
console.debug(cnt, shortcountry);
|
|
||||||
var found = false
|
|
||||||
for (let i of cnt) {
|
|
||||||
if (i.code_country === shortcountry) {
|
|
||||||
found = true
|
|
||||||
this.setState({indicatif: i.code_dial, country: i.name})
|
|
||||||
this.getNetworks(i.code_dial);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!found) {
|
|
||||||
Alert.alert("Impossible de recupérer vos informations", "Nous n'avons pas pu recuperer les informations de votre pays veuillez contacter les administrateurs", [{text: "OK"}]);
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
|
const comps = results[0].address_components;
|
||||||
|
const country = comps.find(c => c.types.includes("country"));
|
||||||
|
const locality = comps.find(c => c.types.includes("locality"));
|
||||||
|
|
||||||
|
if (country) {
|
||||||
|
this.setState({ shortCountry: country.short_name,
|
||||||
|
longCountry : country.long_name });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let townName, townInfo;
|
||||||
|
|
||||||
|
if (locality) {
|
||||||
|
townName = locality.short_name;
|
||||||
|
townInfo = await getTownInformationName(townName);
|
||||||
|
} else {
|
||||||
|
const def = await getDefaultTown();
|
||||||
|
townName = def.default_locality;
|
||||||
|
townInfo = await getTownInformationName(townName);
|
||||||
}
|
}
|
||||||
}).catch((e) => {
|
|
||||||
this.showErrorDialog()
|
this.setState({
|
||||||
|
townName,
|
||||||
|
town: Array.isArray(townInfo) ? townInfo[0] : townInfo
|
||||||
});
|
});
|
||||||
this.setState({myPosition: myPosition});
|
|
||||||
if (this.mapRef !== undefined && this.mapRef !== null) {
|
|
||||||
this.mapRef.animateToCoordinate({
|
|
||||||
latitude: myPosition.latitude,
|
|
||||||
longitude: myPosition.longitude
|
|
||||||
}, 1000);
|
|
||||||
this.mapRef.animateToRegion({
|
|
||||||
latitude: myPosition.latitude,
|
|
||||||
longitude: myPosition.longitude,
|
|
||||||
latitudeDelta: 0.03,
|
|
||||||
longitudeDelta: 0.01,
|
|
||||||
}, 1000)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
// autres mises à jour (carte, myPosition, réseaux, …)
|
||||||
|
this.setState({ myPosition });
|
||||||
|
this.mapRef?.animateToCoordinate(myPosition, 1000);
|
||||||
|
this.mapRef?.animateToRegion({ ...myPosition,
|
||||||
|
latitudeDelta: 0.03, longitudeDelta: 0.01 }, 1000);
|
||||||
|
|
||||||
|
} catch (e) {
|
||||||
|
// gestion d'erreur
|
||||||
}
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
componentWillUnmount() {
|
componentWillUnmount() {
|
||||||
this.mounted = false;
|
this.mounted = false;
|
||||||
|
@ -387,10 +677,10 @@ export default class CreateUserStep2 extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
renderUserGeoAccount() {
|
renderUserGeoAccount() {
|
||||||
|
const { selectedCountry } = this.state;
|
||||||
return (
|
return (
|
||||||
<View style={styles.container}>
|
<View style={styles.container}>
|
||||||
{this.prepareModal()}
|
{/* {this.prepareModal()} */}
|
||||||
<View style={{flexDirection: 'row'}}>
|
<View style={{flexDirection: 'row'}}>
|
||||||
<Icon.Button name={"keyboard-backspace"}
|
<Icon.Button name={"keyboard-backspace"}
|
||||||
color={"white"}
|
color={"white"}
|
||||||
|
@ -412,7 +702,27 @@ export default class CreateUserStep2 extends Component {
|
||||||
paddingRight: 20,
|
paddingRight: 20,
|
||||||
backgroundColor: 'white'
|
backgroundColor: 'white'
|
||||||
}}>
|
}}>
|
||||||
<Dropdown
|
<Fumi
|
||||||
|
iconClass={FontAwesomeIcon}
|
||||||
|
label={I18n.t('COUNTRY_CHOICE')}
|
||||||
|
// value={this.state.countries}
|
||||||
|
value={selectedCountry ? `${selectedCountry.label}` : ''}
|
||||||
|
enabled={false}
|
||||||
|
editable={false}
|
||||||
|
onChangeText={(value, index, data) => {
|
||||||
|
const selectedCountry = this.state.countries[index];
|
||||||
|
this.setState({
|
||||||
|
countries: selectedCountry.countries,
|
||||||
|
indicatif: selectedCountry.code_dial,
|
||||||
|
network: null
|
||||||
|
});
|
||||||
|
this.getNetworks(selectedCountry.code_dial);
|
||||||
|
}}
|
||||||
|
|
||||||
|
/>
|
||||||
|
|
||||||
|
{console.log("town===>>",this.state.town)}
|
||||||
|
{/* <Dropdown
|
||||||
label={I18n.t('COUNTRY_CHOICE')}
|
label={I18n.t('COUNTRY_CHOICE')}
|
||||||
data={this.state.countries}
|
data={this.state.countries}
|
||||||
useNativeDriver={true}
|
useNativeDriver={true}
|
||||||
|
@ -430,7 +740,7 @@ export default class CreateUserStep2 extends Component {
|
||||||
labelExtractor={(value) => {
|
labelExtractor={(value) => {
|
||||||
return value.name
|
return value.name
|
||||||
}}
|
}}
|
||||||
/>
|
/> */}
|
||||||
</View>
|
</View>
|
||||||
<Animatable.View ref={(comp) => {
|
<Animatable.View ref={(comp) => {
|
||||||
this.numanim = comp
|
this.numanim = comp
|
||||||
|
@ -562,7 +872,7 @@ export default class CreateUserStep2 extends Component {
|
||||||
/>
|
/>
|
||||||
</View>}
|
</View>}
|
||||||
|
|
||||||
<Text
|
{/* <Text
|
||||||
style={{
|
style={{
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
marginTop: 10,
|
marginTop: 10,
|
||||||
|
@ -611,7 +921,8 @@ export default class CreateUserStep2 extends Component {
|
||||||
marginTop: 10, marginRight: responsiveWidth(6), color: 'white', fontWeight: 'bold'
|
marginTop: 10, marginRight: responsiveWidth(6), color: 'white', fontWeight: 'bold'
|
||||||
}}
|
}}
|
||||||
>{this.state.textadress !== undefined ? this.state.textadress : I18n.t('TAKE_MY_POSITION')}</Text>
|
>{this.state.textadress !== undefined ? this.state.textadress : I18n.t('TAKE_MY_POSITION')}</Text>
|
||||||
</TouchableOpacity>
|
</TouchableOpacity> */}
|
||||||
|
|
||||||
<Button style={styles.btnvalide} textStyle={styles.textbtnvalide}
|
<Button style={styles.btnvalide} textStyle={styles.textbtnvalide}
|
||||||
isLoading={this.state.isLoading}
|
isLoading={this.state.isLoading}
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
|
@ -622,7 +933,7 @@ export default class CreateUserStep2 extends Component {
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
<MaterialDialog
|
<MaterialDialog
|
||||||
title={'Selecionner un reseau'}
|
title={'Selectionner un reseau'}
|
||||||
items={LONG_LIST.map((row, index) => ({value: row, label: row}))}
|
items={LONG_LIST.map((row, index) => ({value: row, label: row}))}
|
||||||
visible={this.state.networksinglePickerVisible}
|
visible={this.state.networksinglePickerVisible}
|
||||||
selectedItem={this.state.singlePickerSelectedItem}
|
selectedItem={this.state.singlePickerSelectedItem}
|
||||||
|
@ -873,8 +1184,9 @@ export default class CreateUserStep2 extends Component {
|
||||||
data['category'] = user.category;
|
data['category'] = user.category;
|
||||||
|
|
||||||
data['active'] = '0';
|
data['active'] = '0';
|
||||||
|
console.log("data===>>",data);
|
||||||
createGeolocatedAccount(data).then((result) => {
|
createGeolocatedAccount(data).then((result) => {
|
||||||
console.log(result);
|
console.log("result===>>",result);
|
||||||
if (result.success !== undefined && result.success === 1) {
|
if (result.success !== undefined && result.success === 1) {
|
||||||
const message = result.category === 'super' ? I18n.t("HYPERVISOR_MUST_VALIDATE_SUPERVISOR")
|
const message = result.category === 'super' ? I18n.t("HYPERVISOR_MUST_VALIDATE_SUPERVISOR")
|
||||||
: I18n.t("ACCOUNT_SUCCESSFULL_CREATED")
|
: I18n.t("ACCOUNT_SUCCESSFULL_CREATED")
|
||||||
|
|
|
@ -29,6 +29,7 @@ import {readUser} from "../../../webservice/AuthApi";
|
||||||
import Spinner from "react-native-loading-spinner-overlay";
|
import Spinner from "react-native-loading-spinner-overlay";
|
||||||
import Geolocation from "react-native-geolocation-service";
|
import Geolocation from "react-native-geolocation-service";
|
||||||
import {callingCodes} from '@ideditor/country-coder';
|
import {callingCodes} from '@ideditor/country-coder';
|
||||||
|
import { ScreenComponent } from '../../../components/ScreenComponent';
|
||||||
|
|
||||||
let theme = require('./../../../utils/theme.json');
|
let theme = require('./../../../utils/theme.json');
|
||||||
|
|
||||||
|
@ -390,14 +391,18 @@ export class LoginUi extends Component {
|
||||||
render() {
|
render() {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
||||||
<Animated.View style={[style.container,
|
<Animated.View style={[style.container,
|
||||||
{backgroundColor: this.BackgroundColorConfig}]}>
|
{backgroundColor: this.BackgroundColorConfig}]}>
|
||||||
|
<ScreenComponent>
|
||||||
<StatusBar
|
<StatusBar
|
||||||
backgroundColor={theme.primaryDark}
|
backgroundColor={theme.primaryDark}
|
||||||
barStyle="light-content"
|
barStyle="light-content"
|
||||||
translucent={false}
|
translucent={false}
|
||||||
|
|
||||||
/><Spinner
|
/>
|
||||||
|
</ScreenComponent>
|
||||||
|
<Spinner
|
||||||
visible={this.state.loadingDialog}
|
visible={this.state.loadingDialog}
|
||||||
textContent={I18n.t("LOADING_PROGRESS")}
|
textContent={I18n.t("LOADING_PROGRESS")}
|
||||||
textStyle={{color: '#FFF'}}
|
textStyle={{color: '#FFF'}}
|
||||||
|
@ -516,6 +521,7 @@ export class LoginUi extends Component {
|
||||||
|
|
||||||
</Animated.View>
|
</Animated.View>
|
||||||
|
|
||||||
|
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -82,7 +82,7 @@ class AutreCarteN extends Component {
|
||||||
headerTintColor: 'white',
|
headerTintColor: 'white',
|
||||||
headerStyle: {
|
headerStyle: {
|
||||||
backgroundColor: Color.primaryColor,
|
backgroundColor: Color.primaryColor,
|
||||||
marginTop: 30,
|
marginTop: 0,
|
||||||
color: 'white',
|
color: 'white',
|
||||||
},
|
},
|
||||||
headerTitleStyle: {
|
headerTitleStyle: {
|
||||||
|
|
|
@ -34,7 +34,7 @@ class PaymentCard extends Component {
|
||||||
headerTintColor: 'white',
|
headerTintColor: 'white',
|
||||||
headerStyle: {
|
headerStyle: {
|
||||||
backgroundColor: Color.primaryColor,
|
backgroundColor: Color.primaryColor,
|
||||||
marginTop: 30,
|
marginTop: 0,
|
||||||
color: 'white'
|
color: 'white'
|
||||||
},
|
},
|
||||||
headerTitleStyle: {
|
headerTitleStyle: {
|
||||||
|
@ -121,7 +121,6 @@ class PaymentCard extends Component {
|
||||||
<TouchableOpacity style={styles.contain}
|
<TouchableOpacity style={styles.contain}
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
this.props.navigation.push(route.carteLierN, {
|
this.props.navigation.push(route.carteLierN, {
|
||||||
|
|
||||||
optionSelect: optionenvoieautrewalletNanoSanteScreen,
|
optionSelect: optionenvoieautrewalletNanoSanteScreen,
|
||||||
with_linked_card : true,
|
with_linked_card : true,
|
||||||
onGoBack: () => this.refresh(),
|
onGoBack: () => this.refresh(),
|
||||||
|
@ -324,7 +323,9 @@ const styles = StyleSheet.create({
|
||||||
flex: 1,
|
flex: 1,
|
||||||
},
|
},
|
||||||
contentTitle: {
|
contentTitle: {
|
||||||
paddingTop: 5,
|
display: 'flex',
|
||||||
|
marginTop: 22,
|
||||||
|
textAlign: 'center',
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,6 @@ import {useFormik} from 'formik';
|
||||||
import * as Yup from 'yup';
|
import * as Yup from 'yup';
|
||||||
import * as Utils from '../../../utils/UtilsFunction'
|
import * as Utils from '../../../utils/UtilsFunction'
|
||||||
import {IlinkEmitter} from '../../../utils/events';
|
import {IlinkEmitter} from '../../../utils/events';
|
||||||
import { optionenvoieautrewalletNanoSanteScreen} from '../../../utils/UtilsFunction'
|
|
||||||
import {Color} from "../../../config/Color";
|
import {Color} from "../../../config/Color";
|
||||||
import I18n from 'react-native-i18n';
|
import I18n from 'react-native-i18n';
|
||||||
import {Fumi} from 'react-native-textinput-effects';
|
import {Fumi} from 'react-native-textinput-effects';
|
||||||
|
@ -61,22 +60,7 @@ const navigatorStyle = {
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const navigationOptions = () => {
|
|
||||||
return {
|
|
||||||
drawerLabel: () => null,
|
|
||||||
headerTitle: I18n.t('PAIEMENT_FACTURE'),
|
|
||||||
headerTintColor: 'white',
|
|
||||||
headerStyle: {
|
|
||||||
backgroundColor: Color.primaryColor,
|
|
||||||
marginTop: 0,
|
|
||||||
color: 'white'
|
|
||||||
},
|
|
||||||
headerTitleStyle: {
|
|
||||||
color: "white"
|
|
||||||
},
|
|
||||||
title: I18n.t('PAIEMENT_FACTURE')
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
const CarteLierN = ({
|
const CarteLierN = ({
|
||||||
|
@ -93,7 +77,22 @@ const CarteLierN = ({
|
||||||
const [subscription, setSubscription] = useState(null);
|
const [subscription, setSubscription] = useState(null);
|
||||||
|
|
||||||
|
|
||||||
|
const navigationOptions = () => {
|
||||||
|
return {
|
||||||
|
drawerLabel: () => null,
|
||||||
|
headerTitle: I18n.t('PAIEMENT_FACTURE'),
|
||||||
|
headerTintColor: 'white',
|
||||||
|
headerStyle: {
|
||||||
|
backgroundColor: Color.primaryColor,
|
||||||
|
marginTop: 0,
|
||||||
|
color: 'white'
|
||||||
|
},
|
||||||
|
headerTitleStyle: {
|
||||||
|
color: "white"
|
||||||
|
},
|
||||||
|
title: I18n.t('PAIEMENT_FACTURE')
|
||||||
|
}
|
||||||
|
};
|
||||||
const dispatch = useDispatch();
|
const dispatch = useDispatch();
|
||||||
|
|
||||||
let dropDownAlertRef: any = null;
|
let dropDownAlertRef: any = null;
|
||||||
|
@ -242,8 +241,8 @@ const CarteLierN = ({
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ScreenComponent>
|
// <ScreenComponent>
|
||||||
<DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
// <DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
||||||
<KeyboardAvoidingView
|
<KeyboardAvoidingView
|
||||||
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
||||||
style={{flex: 1}}>
|
style={{flex: 1}}>
|
||||||
|
@ -358,7 +357,7 @@ const CarteLierN = ({
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
</ScreenComponent>
|
// </ScreenComponent>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -2371,6 +2371,6 @@ const styles = StyleSheet.create({
|
||||||
flex: 1,
|
flex: 1,
|
||||||
},
|
},
|
||||||
contentTitle: {
|
contentTitle: {
|
||||||
paddingTop: 5,
|
paddingTop: 15,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -18,11 +18,12 @@ import I18n from 'react-native-i18n'
|
||||||
import * as Utils from '../../utils/DeviceUtils';
|
import * as Utils from '../../utils/DeviceUtils';
|
||||||
import Icons from 'react-native-vector-icons/Ionicons'
|
import Icons from 'react-native-vector-icons/Ionicons'
|
||||||
import {Color} from '../../config/Color';
|
import {Color} from '../../config/Color';
|
||||||
|
import { ToastProvider, useToast } from 'react-native-toast-notifications';
|
||||||
import omit from 'lodash/omit';
|
import omit from 'lodash/omit';
|
||||||
import Tag from '../../components/Tag';
|
import Tag from '../../components/Tag';
|
||||||
import {IlinkEmitter} from "../../utils/events";
|
import {IlinkEmitter} from "../../utils/events";
|
||||||
import {Typography} from '../../config/typography';
|
import {Typography} from '../../config/typography';
|
||||||
import {responsiveWidth,} from 'react-native-responsive-dimensions';
|
import {responsiveHeight, responsiveWidth, responsiveFontSize} from 'react-native-responsive-dimensions';
|
||||||
import {
|
import {
|
||||||
getWalletDetailActivated,
|
getWalletDetailActivated,
|
||||||
passwordValidationAction,
|
passwordValidationAction,
|
||||||
|
@ -70,6 +71,8 @@ import {Fumi} from "react-native-textinput-effects";
|
||||||
import FontAwesomeIcon from "react-native-vector-icons/FontAwesome";
|
import FontAwesomeIcon from "react-native-vector-icons/FontAwesome";
|
||||||
import Button from "../../components/Button";
|
import Button from "../../components/Button";
|
||||||
import Entypo from "react-native-vector-icons/Entypo";
|
import Entypo from "react-native-vector-icons/Entypo";
|
||||||
|
import Clipboard from '@react-native-clipboard/clipboard';
|
||||||
|
import DropdownAlert from 'react-native-dropdownalert';
|
||||||
|
|
||||||
let moment = require('moment-timezone');
|
let moment = require('moment-timezone');
|
||||||
|
|
||||||
|
@ -79,6 +82,7 @@ let route = require('./../../route.json');
|
||||||
let slugify = require('slugify');
|
let slugify = require('slugify');
|
||||||
require('../../utils/Translations');
|
require('../../utils/Translations');
|
||||||
|
|
||||||
|
|
||||||
class WalletDetailUser extends Component {
|
class WalletDetailUser extends Component {
|
||||||
|
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
|
@ -98,9 +102,12 @@ class WalletDetailUser extends Component {
|
||||||
isIdentified: false,
|
isIdentified: false,
|
||||||
isIdentifiedValidated: false,
|
isIdentifiedValidated: false,
|
||||||
password: '',
|
password: '',
|
||||||
isLogged: false
|
isLogged: false,
|
||||||
};
|
isCopied: false,
|
||||||
|
|
||||||
|
};
|
||||||
|
this.copyToClipboard = this.copyToClipboard.bind(this);
|
||||||
|
// this.dropdownAlertRef = React.createRef();
|
||||||
slugify.extend({'+': 'plus'});
|
slugify.extend({'+': 'plus'});
|
||||||
|
|
||||||
this.scrollY = new Animated.Value(0);
|
this.scrollY = new Animated.Value(0);
|
||||||
|
@ -168,7 +175,6 @@ class WalletDetailUser extends Component {
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
getWalletDetail = () => {
|
getWalletDetail = () => {
|
||||||
readUser().then((user) => {
|
readUser().then((user) => {
|
||||||
if (user) {
|
if (user) {
|
||||||
|
@ -415,7 +421,35 @@ class WalletDetailUser extends Component {
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
renderAccountDetail = (wallet) => (
|
copyToClipboard = (wallet) => {
|
||||||
|
const textToCopy = `${wallet.user_code}`;
|
||||||
|
|
||||||
|
Clipboard.setString(textToCopy);
|
||||||
|
|
||||||
|
Clipboard.getString().then((copiedText) => {
|
||||||
|
console.log('Texte copié :', copiedText);
|
||||||
|
this.setState({ isCopied: true });
|
||||||
|
|
||||||
|
// this.dropdownAlertRef.current.alertWithType('success', 'Copié avec succès', copiedText);
|
||||||
|
|
||||||
|
|
||||||
|
showToast({
|
||||||
|
type: 'success', // ou 'warn', 'error', 'info'
|
||||||
|
text1: 'Code copier avec succès',
|
||||||
|
text2: copiedText,
|
||||||
|
visibilityTime: 2000,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
renderAccountDetail = (wallet) => {
|
||||||
|
|
||||||
|
|
||||||
|
return(
|
||||||
|
<>
|
||||||
|
<ToastProvider>
|
||||||
<View style={{ flexDirection: 'row', flex: 1, justifyContent: 'space-between' }}>
|
<View style={{ flexDirection: 'row', flex: 1, justifyContent: 'space-between' }}>
|
||||||
|
|
||||||
<View
|
<View
|
||||||
|
@ -430,8 +464,7 @@ class WalletDetailUser extends Component {
|
||||||
]}>
|
]}>
|
||||||
<Icons name='md-wallet'
|
<Icons name='md-wallet'
|
||||||
size={28}
|
size={28}
|
||||||
color={Color.whiteColor}
|
color={Color.whiteColor} />
|
||||||
/>
|
|
||||||
</View>
|
</View>
|
||||||
<View>
|
<View>
|
||||||
<Text style={[Typography.title3, Color.primaryColor, { marginBottom: 3 }]}>
|
<Text style={[Typography.title3, Color.primaryColor, { marginBottom: 3 }]}>
|
||||||
|
@ -440,9 +473,7 @@ class WalletDetailUser extends Component {
|
||||||
<Text
|
<Text
|
||||||
style={[Typography.body2]}>{`${thousands(wallet.balance, ' ')} ${wallet.currency_code}`}</Text>
|
style={[Typography.body2]}>{`${thousands(wallet.balance, ' ')} ${wallet.currency_code}`}</Text>
|
||||||
</View>
|
</View>
|
||||||
</View>
|
</View><View
|
||||||
|
|
||||||
<View
|
|
||||||
style={{
|
style={{
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
|
@ -454,22 +485,44 @@ class WalletDetailUser extends Component {
|
||||||
]}>
|
]}>
|
||||||
<Icons name='md-key'
|
<Icons name='md-key'
|
||||||
size={28}
|
size={28}
|
||||||
color={Color.whiteColor}
|
color={Color.whiteColor} />
|
||||||
/>
|
|
||||||
</View>
|
</View>
|
||||||
<View>
|
<View>
|
||||||
<Text style={[Typography.title3, Color.primaryColor, { marginBottom: 3 }]}>
|
<Text style={[Typography.title3, Color.primaryColor, { marginBottom: 3 }]}>
|
||||||
{I18n.t('NUMERO_COMPTE')}
|
{I18n.t('NUMERO_COMPTE')}
|
||||||
</Text>
|
</Text>
|
||||||
<Text style={[Typography.body2]}>{wallet.user_code}</Text>
|
<TouchableOpacity onPress={() => this.copyToClipboard(wallet)}>
|
||||||
|
<View style={{ flexDirection: 'row' }}>
|
||||||
|
<Animatable.Text
|
||||||
|
style={[Typography.body2, { color: this.state.isCopied ? 'green' : 'black' }]}
|
||||||
|
animation={this.state.isCopied ? 'fadeIn' : null}
|
||||||
|
>
|
||||||
|
{wallet.user_code}
|
||||||
|
</Animatable.Text>
|
||||||
|
{this.state.isCopied ? (
|
||||||
|
<Icons name='md-checkmark' size={16} color={Color.greenColor} style={{ marginLeft: 6 }} />
|
||||||
|
) : (
|
||||||
|
<Icons name='md-copy' size={16} color={Color.greenColor} style={{ marginLeft: 6 }} />
|
||||||
|
)}
|
||||||
|
|
||||||
|
|
||||||
</View>
|
</View>
|
||||||
|
</TouchableOpacity>
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
</View>
|
</View>
|
||||||
);
|
|
||||||
|
</View>
|
||||||
|
</ToastProvider>
|
||||||
|
{/* <DropdownAlert ref={this.dropdownAlertRef} /> */}
|
||||||
|
|
||||||
|
</>
|
||||||
|
)
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
renderDetailWallet = (wallet) => {
|
renderDetailWallet = (wallet) => {
|
||||||
const { width } = Dimensions.get('window');
|
// const { width } = Dimensions.get('window');
|
||||||
return (
|
return (
|
||||||
!isEmptyObject(wallet) ?
|
!isEmptyObject(wallet) ?
|
||||||
(<>
|
(<>
|
||||||
|
@ -479,7 +532,7 @@ class WalletDetailUser extends Component {
|
||||||
//</>style={styles.container}
|
//</>style={styles.container}
|
||||||
style={{
|
style={{
|
||||||
flex: 1,
|
flex: 1,
|
||||||
width: width >= 768 ? '50%' : '100%',
|
// width: width >= 768 ? '50%' : '100%',
|
||||||
backgroundColor: Color.containerBackgroundColor
|
backgroundColor: Color.containerBackgroundColor
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
@ -551,7 +604,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={styles.contentTitle}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('ENVOIE_ARGENT')}
|
{I18n.t('ENVOIE_ARGENT')}
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -589,7 +642,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={styles.contentTitle}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('RETRAIT_ARGENT')}
|
{I18n.t('RETRAIT_ARGENT')}
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -640,7 +693,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={{paddingTop: 5,}}>
|
<View style={styles.centerText}>
|
||||||
<Text
|
<Text
|
||||||
style={[Typography.headline, Typography.semibold]}>
|
style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('NANO_CREDIT')}
|
{I18n.t('NANO_CREDIT')}
|
||||||
|
@ -672,7 +725,7 @@ class WalletDetailUser extends Component {
|
||||||
style={styles.imageBanner}/>
|
style={styles.imageBanner}/>
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={{paddingTop: 20,}}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('NANO_SANTE')}
|
{I18n.t('NANO_SANTE')}
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -707,7 +760,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={styles.contentTitle}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('PAIEMENT_FACTURE')}
|
{I18n.t('PAIEMENT_FACTURE')}
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -752,7 +805,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={{paddingTop: 20,}}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
{I18n.t('CREATION_IDENTIFICATION_CLIENT')}
|
{I18n.t('CREATION_IDENTIFICATION_CLIENT')}
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -787,7 +840,7 @@ class WalletDetailUser extends Component {
|
||||||
|
|
||||||
<View style={[styles.content]}>
|
<View style={[styles.content]}>
|
||||||
|
|
||||||
<View style={styles.contentTitle}>
|
<View style={styles.centerText}>
|
||||||
<Text style={[Typography.headline, Typography.semibold]}>
|
<Text style={[Typography.headline, Typography.semibold]}>
|
||||||
Agency Banking
|
Agency Banking
|
||||||
</Text>
|
</Text>
|
||||||
|
@ -1233,6 +1286,9 @@ class WalletDetailUser extends Component {
|
||||||
console.warn("Wallet Detail user Props", this.props);
|
console.warn("Wallet Detail user Props", this.props);
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
<ToastProvider >
|
||||||
|
|
||||||
|
|
||||||
{this.state.displayModalHistory && this.renderModalHistoryDetail()}
|
{this.state.displayModalHistory && this.renderModalHistoryDetail()}
|
||||||
<StatusBar
|
<StatusBar
|
||||||
backgroundColor={Color.primaryDarkColor}
|
backgroundColor={Color.primaryDarkColor}
|
||||||
|
@ -1297,7 +1353,7 @@ class WalletDetailUser extends Component {
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
</ToastProvider>
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -1421,8 +1477,8 @@ const styles = StyleSheet.create({
|
||||||
borderBottomWidth: 0.5,
|
borderBottomWidth: 0.5,
|
||||||
},
|
},
|
||||||
circlePoint: {
|
circlePoint: {
|
||||||
width: 50,
|
width: responsiveWidth(10),
|
||||||
height: 50,
|
height: responsiveHeight(5),
|
||||||
borderRadius: 25,
|
borderRadius: 25,
|
||||||
marginRight: 5,
|
marginRight: 5,
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
|
@ -1431,7 +1487,7 @@ const styles = StyleSheet.create({
|
||||||
transactionContainer: {
|
transactionContainer: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
flex: 1,
|
flex: 1,
|
||||||
paddingTop: 10,
|
paddingTop: 20,
|
||||||
paddingLeft: 10,
|
paddingLeft: 10,
|
||||||
paddingRight: 10,
|
paddingRight: 10,
|
||||||
},
|
},
|
||||||
|
@ -1444,6 +1500,7 @@ const styles = StyleSheet.create({
|
||||||
borderColor: Color.borderColor,
|
borderColor: Color.borderColor,
|
||||||
borderWidth: 0.5,
|
borderWidth: 0.5,
|
||||||
shadowOffset: {width: 1.5, height: 1.5},
|
shadowOffset: {width: 1.5, height: 1.5},
|
||||||
|
height: responsiveHeight(10),
|
||||||
shadowOpacity: 1.0,
|
shadowOpacity: 1.0,
|
||||||
elevation: 5,
|
elevation: 5,
|
||||||
borderRadius: 10,
|
borderRadius: 10,
|
||||||
|
@ -1468,6 +1525,13 @@ const styles = StyleSheet.create({
|
||||||
flex: 1,
|
flex: 1,
|
||||||
},
|
},
|
||||||
contentTitle: {
|
contentTitle: {
|
||||||
paddingTop: 5,
|
textAlign: 'center',
|
||||||
|
},
|
||||||
|
centerText: {
|
||||||
|
display: 'flex',
|
||||||
|
marginTop: 22,
|
||||||
|
textAlign: 'center',
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -22,6 +22,7 @@ import {connect} from 'react-redux';
|
||||||
import {readUser} from '../../webservice/AuthApi';
|
import {readUser} from '../../webservice/AuthApi';
|
||||||
import {bindActionCreators} from 'redux';
|
import {bindActionCreators} from 'redux';
|
||||||
import {Typography} from '../../config/typography';
|
import {Typography} from '../../config/typography';
|
||||||
|
import { ScreenComponent } from '../../components/ScreenComponent';
|
||||||
|
|
||||||
const route = require('./../../route.json');
|
const route = require('./../../route.json');
|
||||||
let slugify = require('slugify');
|
let slugify = require('slugify');
|
||||||
|
@ -186,7 +187,7 @@ class WalletSelect extends Component {
|
||||||
<StatusBar
|
<StatusBar
|
||||||
backgroundColor={Color.primaryDarkColor}
|
backgroundColor={Color.primaryDarkColor}
|
||||||
barStyle="light-content"
|
barStyle="light-content"
|
||||||
translucent={false}
|
translucent={true}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Appbar.Header dark={true} style={{backgroundColor: Color.primaryColor}}>
|
<Appbar.Header dark={true} style={{backgroundColor: Color.primaryColor}}>
|
||||||
|
|
|
@ -25,7 +25,7 @@ import { optionenvoieautrewalletNanoSanteScreen} from '../../../utils/UtilsFunct
|
||||||
import {Color} from "../../../config/Color";
|
import {Color} from "../../../config/Color";
|
||||||
import I18n from 'react-native-i18n';
|
import I18n from 'react-native-i18n';
|
||||||
import {Fumi} from 'react-native-textinput-effects';
|
import {Fumi} from 'react-native-textinput-effects';
|
||||||
import {ScreenComponent} from "../../../components/ScreenComponent";
|
// import {ScreenComponent} from "../../../components/ScreenComponent";
|
||||||
import PasswordInput from '../../../components/PasswordInput';
|
import PasswordInput from '../../../components/PasswordInput';
|
||||||
import Button from "../../../components/Button";
|
import Button from "../../../components/Button";
|
||||||
import FontAwesome from "react-native-vector-icons/FontAwesome";
|
import FontAwesome from "react-native-vector-icons/FontAwesome";
|
||||||
|
@ -35,7 +35,7 @@ import {
|
||||||
fetchGetSubscriptionList,
|
fetchGetSubscriptionList,
|
||||||
fetchGetSubscriptionListReset
|
fetchGetSubscriptionListReset
|
||||||
} from "../../../redux/insurance/insurance.actions";
|
} from "../../../redux/insurance/insurance.actions";
|
||||||
import DropdownAlert from "react-native-dropdownalert";
|
// import DropdownAlert from "react-native-dropdownalert";
|
||||||
import {readUser} from "../../../webservice/AuthApi";
|
import {readUser} from "../../../webservice/AuthApi";
|
||||||
import * as Animatable from 'react-native-animatable';
|
import * as Animatable from 'react-native-animatable';
|
||||||
import FontAwesomeIcon from 'react-native-vector-icons/FontAwesome';
|
import FontAwesomeIcon from 'react-native-vector-icons/FontAwesome';
|
||||||
|
@ -388,8 +388,8 @@ const MobileMoneyNanoSante = ({
|
||||||
)
|
)
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ScreenComponent>
|
// <ScreenComponent>
|
||||||
<DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
// <DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
||||||
<KeyboardAvoidingView
|
<KeyboardAvoidingView
|
||||||
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
||||||
style={{flex: 1}}>
|
style={{flex: 1}}>
|
||||||
|
@ -492,7 +492,7 @@ const MobileMoneyNanoSante = ({
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
</ScreenComponent>
|
// </ScreenComponent>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,7 @@ import {
|
||||||
fetchGetSubscriptionList,
|
fetchGetSubscriptionList,
|
||||||
fetchGetSubscriptionListReset
|
fetchGetSubscriptionListReset
|
||||||
} from "../../../redux/insurance/insurance.actions";
|
} from "../../../redux/insurance/insurance.actions";
|
||||||
import DropdownAlert from "react-native-dropdownalert";
|
// import DropdownAlert from "react-native-dropdownalert";
|
||||||
import {readUser} from "../../../webservice/AuthApi";
|
import {readUser} from "../../../webservice/AuthApi";
|
||||||
import * as Animatable from 'react-native-animatable';
|
import * as Animatable from 'react-native-animatable';
|
||||||
import FontAwesomeIcon from 'react-native-vector-icons/FontAwesome';
|
import FontAwesomeIcon from 'react-native-vector-icons/FontAwesome';
|
||||||
|
@ -259,7 +259,7 @@ const WalletNanoSante = ({
|
||||||
|
|
||||||
|
|
||||||
const dispatch = useDispatch();
|
const dispatch = useDispatch();
|
||||||
let dropDownAlertRef: any = null;
|
// let dropDownAlertRef: any = null;
|
||||||
let subscriptionRef = null;
|
let subscriptionRef = null;
|
||||||
let amountPerMonthRef = null;
|
let amountPerMonthRef = null;
|
||||||
const [wallet] = useState(store.getState().walletDetailReducer.result.response);
|
const [wallet] = useState(store.getState().walletDetailReducer.result.response);
|
||||||
|
@ -522,8 +522,8 @@ const WalletNanoSante = ({
|
||||||
// )
|
// )
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ScreenComponent>
|
// <ScreenComponent>
|
||||||
<DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
// <DropdownAlert ref={ref => (dropDownAlertRef = ref)}/>
|
||||||
<KeyboardAvoidingView
|
<KeyboardAvoidingView
|
||||||
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
behavior={Platform.OS === 'android' ? 'height' : 'padding'}
|
||||||
style={{flex: 1}}>
|
style={{flex: 1}}>
|
||||||
|
@ -629,7 +629,7 @@ const WalletNanoSante = ({
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
</ScreenComponent>
|
// </ScreenComponent>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -22,6 +22,12 @@
|
||||||
"TAKE_MY_PLACE": "Take my position",
|
"TAKE_MY_PLACE": "Take my position",
|
||||||
"MAP": "The map",
|
"MAP": "The map",
|
||||||
"BSR": "Good evening",
|
"BSR": "Good evening",
|
||||||
|
"ZIP_CODE": "Postal Code",
|
||||||
|
"ETAT_STATE": "Etat or State",
|
||||||
|
"REATTACH__MY_CARD": "Rattach my Card",
|
||||||
|
"CARD_LINK": "Linked Card",
|
||||||
|
"OTHER_CARD": "Other Card",
|
||||||
|
"CHOUSE_PAYEMENT_MODE": "Chouse Payement Mode",
|
||||||
"ACCOUNT_CREATED_SUCCESS": "Account created successfully.\nYou will receive in a few minutes an email and an SMS with your informations.\nWe will redirect you to the login page",
|
"ACCOUNT_CREATED_SUCCESS": "Account created successfully.\nYou will receive in a few minutes an email and an SMS with your informations.\nWe will redirect you to the login page",
|
||||||
"OR_BIG": "OR",
|
"OR_BIG": "OR",
|
||||||
"FOR_NUMB": "For the ",
|
"FOR_NUMB": "For the ",
|
||||||
|
|
|
@ -678,7 +678,7 @@
|
||||||
"EXAMENS_SUCCESSFULLY_ADD": "Examen ajouté avec succès",
|
"EXAMENS_SUCCESSFULLY_ADD": "Examen ajouté avec succès",
|
||||||
"PRESCRIPTIONS_SUCCESSFULLY_ADD": "Prescription ajouté avec succès",
|
"PRESCRIPTIONS_SUCCESSFULLY_ADD": "Prescription ajouté avec succès",
|
||||||
"PRESCRIPTIONS_SUCCESSFULLY_MODIFY": "Prescription modifié avec succès",
|
"PRESCRIPTIONS_SUCCESSFULLY_MODIFY": "Prescription modifié avec succès",
|
||||||
"YOU_MUST_ADD_AT_LEAST_ONE_PRESTATION": "Vous devez ajouter au moins une prestation",
|
"YOU_MUST_ADD_AT_LEAST_ONE_PRESTATIONcode ": "Vous devez ajouter au moins une prestation",
|
||||||
"NO_DRUG_MATCH_YOU_SEARCH": "Aucun médicament ne correspond à votre recherche, voulez-vous en ajouter ?",
|
"NO_DRUG_MATCH_YOU_SEARCH": "Aucun médicament ne correspond à votre recherche, voulez-vous en ajouter ?",
|
||||||
"COMPRESSED": "Comprimé",
|
"COMPRESSED": "Comprimé",
|
||||||
"SYRUP": "Sirop",
|
"SYRUP": "Sirop",
|
||||||
|
|
|
@ -22,9 +22,10 @@ var serializeJSON = function (data) {
|
||||||
|
|
||||||
export const getCodeInformation = (code) => {
|
export const getCodeInformation = (code) => {
|
||||||
var data = {
|
var data = {
|
||||||
"tag": 'member', "type": "agen_info_code", "code": code,
|
"tag": 'member', "type": "agen_info_code", "code": "+237",
|
||||||
"lang": I18n.currentLocale()
|
"lang": I18n.currentLocale()
|
||||||
};
|
};
|
||||||
|
console.log("2===>>");
|
||||||
|
|
||||||
return queryData(data, memberActionUrl)
|
return queryData(data, memberActionUrl)
|
||||||
}
|
}
|
||||||
|
@ -41,8 +42,7 @@ function queryAuth(data) {
|
||||||
}
|
}
|
||||||
|
|
||||||
async function queryData(data, url) {
|
async function queryData(data, url) {
|
||||||
console.warn("REQUEST URL", url);
|
console.log("3===>>",url);
|
||||||
console.warn("REQUEST BODY", JSON.stringify(data));
|
|
||||||
data["lang"] = I18n.currentLocale();
|
data["lang"] = I18n.currentLocale();
|
||||||
data["isTest"] = isDebugMode
|
data["isTest"] = isDebugMode
|
||||||
/* await axios({
|
/* await axios({
|
||||||
|
@ -60,7 +60,7 @@ async function queryData(data, url) {
|
||||||
console.warn("SERVER RESPONSE ERROR", error);
|
console.warn("SERVER RESPONSE ERROR", error);
|
||||||
return {"error": "error", "error_msg": error}
|
return {"error": "error", "error_msg": error}
|
||||||
});*/
|
});*/
|
||||||
|
console.log("Ici data===>>", data)
|
||||||
let response = await fetch(url, {
|
let response = await fetch(url, {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
headers: {
|
headers: {
|
||||||
|
@ -78,6 +78,7 @@ async function queryData(data, url) {
|
||||||
console.warn("SERVER RESPONSE ERROR", responseText);
|
console.warn("SERVER RESPONSE ERROR", responseText);
|
||||||
return {"error": "error", "error_msg": responseText}
|
return {"error": "error", "error_msg": responseText}
|
||||||
}
|
}
|
||||||
|
console.log("responseJson===>> ", responseJson);
|
||||||
return responseJson;
|
return responseJson;
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,24 +1,11 @@
|
||||||
export const isDebugMode = false
|
export const isDebugMode = false
|
||||||
//base url test
|
|
||||||
//export const baseUrl = "https://ilink-app.com/mobilebackendbeta"
|
|
||||||
//base url production
|
|
||||||
//export const baseUrl = "https://ilink-app.com/mobilebackend";
|
|
||||||
//export const baseUrl = "https://test.ilink-app.com/mobilebackendtest";
|
|
||||||
//export const baseUrl = "http://test.ilink-app.com:8080/mobilebackendtest";
|
|
||||||
//const baseUrl = "https://ilink-app.com/mobilebackendtest2"
|
|
||||||
|
|
||||||
export const baseUrl = "https://test.ilink-app.com:8080/mobilebackend";
|
export const baseUrl = "https://test.ilink-app.com:8080/mobilebackend";
|
||||||
export const testBaseUrl = "https://test.ilink-app.com";
|
export const testBaseUrl = "https://test.ilink-app.com";
|
||||||
export const testBaseUrlWithPort = "https://test.ilink-app.com:8086";
|
export const testBaseUrlWithPort = "https://test.ilink-app.com:8086";
|
||||||
|
|
||||||
/*export const baseUrl = "https://ilink-app.com/mobilebackend";
|
|
||||||
export const testBaseUrl = "https://ilink-app.com:8080";*/
|
|
||||||
|
|
||||||
/* export const baseUrl = "https://preprod.ilink-app.com:8080/mobilebackend";
|
|
||||||
export const testBaseUrl = "https://preprod.ilink-app.com"; */
|
|
||||||
|
|
||||||
//base url agent test
|
|
||||||
//const baseUrl = "https://ilink-app.com/mobilebackendtest";
|
|
||||||
|
|
||||||
export const adhesionUrl = baseUrl + '/interacted/LoginAction.php';
|
export const adhesionUrl = baseUrl + '/interacted/LoginAction.php';
|
||||||
export const memberActionUrl = baseUrl + '/interacted/MembersAction.php';
|
export const memberActionUrl = baseUrl + '/interacted/MembersAction.php';
|
||||||
|
|
|
@ -5,7 +5,7 @@ import I18n from 'react-native-i18n'
|
||||||
import {readUser} from './AuthApi'
|
import {readUser} from './AuthApi'
|
||||||
import {isDebugMode, MARKER_URL} from "./IlinkConstants";
|
import {isDebugMode, MARKER_URL} from "./IlinkConstants";
|
||||||
|
|
||||||
let GEOCODDING_URL = "https://ilink-app.com:8080/geocode";
|
let GEOCODDING_URL = "https://test.ilink-app.com/geocode";
|
||||||
let API_KEY = "AIzaSyCQY0rwMM9Pn9XWt5F6YLhGoez_bU1IGtc"
|
let API_KEY = "AIzaSyCQY0rwMM9Pn9XWt5F6YLhGoez_bU1IGtc"
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
presets: [['module:metro-react-native-babel-preset', {
|
presets: [
|
||||||
unstable_disableES6Transforms: true
|
[
|
||||||
}]],
|
'module:metro-react-native-babel-preset',
|
||||||
|
{
|
||||||
|
unstable_disableES6Transforms: true,
|
||||||
|
},
|
||||||
|
],
|
||||||
|
],
|
||||||
};
|
};
|
||||||
|
|
|
@ -346,7 +346,6 @@ DEPENDENCIES:
|
||||||
- RNScreens (from `../node_modules/react-native-screens`)
|
- RNScreens (from `../node_modules/react-native-screens`)
|
||||||
- RNSVG (from `../node_modules/react-native-svg`)
|
- RNSVG (from `../node_modules/react-native-svg`)
|
||||||
- RNVectorIcons (from `../node_modules/react-native-vector-icons`)
|
- RNVectorIcons (from `../node_modules/react-native-vector-icons`)
|
||||||
- SajjadBlurOverlay (from `../node_modules/react-native-blur-overlay/ios`)
|
|
||||||
- Yoga (from `../node_modules/react-native/ReactCommon/yoga`)
|
- Yoga (from `../node_modules/react-native/ReactCommon/yoga`)
|
||||||
|
|
||||||
SPEC REPOS:
|
SPEC REPOS:
|
||||||
|
@ -443,8 +442,6 @@ EXTERNAL SOURCES:
|
||||||
:path: "../node_modules/react-native-svg"
|
:path: "../node_modules/react-native-svg"
|
||||||
RNVectorIcons:
|
RNVectorIcons:
|
||||||
:path: "../node_modules/react-native-vector-icons"
|
:path: "../node_modules/react-native-vector-icons"
|
||||||
SajjadBlurOverlay:
|
|
||||||
:path: "../node_modules/react-native-blur-overlay/ios"
|
|
||||||
Yoga:
|
Yoga:
|
||||||
:path: "../node_modules/react-native/ReactCommon/yoga"
|
:path: "../node_modules/react-native/ReactCommon/yoga"
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
29
package.json
29
package.json
|
@ -3,21 +3,23 @@
|
||||||
"version": "0.0.1",
|
"version": "0.0.1",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node node_modules/react-native/local-cli/cli.js start",
|
"start": "react-native start",
|
||||||
|
"android": "react-native run-android",
|
||||||
"test": "jest",
|
"test": "jest",
|
||||||
"postinstall": "node ./fix-android/android-release-fix.js",
|
"postinstall": "node ./fix-android/android-release-fix.js",
|
||||||
"release-build": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output ./android/app/src/main/assets/index.android.bundle --assets-dest ./android/app/build/intermediates/res/merged/release/ && cd ./android && gradlew clean && gradlew app:assembleRelease && cd .. && adb install ./android/app/build/outputs/apk/release/app-release.apk",
|
"release-build": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output ./android/app/src/main/assets/index.android.bundle --assets-dest ./android/app/build/intermediates/res/merged/release/ && cd ./android && gradlew clean && gradlew app:assembleRelease && cd .. && adb install ./android/app/build/outputs/apk/release/app-release.apk",
|
||||||
"debug-build": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output ./android/app/src/main/assets/index.android.bundle --assets-dest ./android/app/src/main/res/ && cd ./android && gradlew clean && gradlew app:assembleDebug && cd .. && adb install ./android/app/build/outputs/apk/debug/app-debug.apk",
|
"debug-build": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output ./android/app/src/main/assets/index.android.bundle --assets-dest ./android/app/src/main/res/ && cd ./android && ./gradlew clean && ./gradlew assembleDebug && cd .. && adb install ./android/app/build/outputs/apk/debug/app-debug.apk",
|
||||||
"start-emulator": "emulator -avd Nexus_5X_API_29 -dns-server 8.8.8.8",
|
"start-emulator": "emulator -avd Nexus_5X_API_29 -dns-server 8.8.8.8",
|
||||||
"start-emulator-pixel": "emulator -avd Pixel_2_API_29 -dns-server 8.8.8.8",
|
"start-emulator-pixel": "emulator -avd Pixel_2_API_29 -dns-server 8.8.8.8",
|
||||||
"run-debug": "cd android && gradlew clean && cd .. && react-native run-android",
|
"run-debug": "cd android && ./gradlew clean && cd .. && react-native run-android",
|
||||||
"run-release": "cd android && gradlew clean && cd .. && react-native run-android --variant=release"
|
"run-release": "cd android && gradlew clean && cd .. && react-native run-android --variant=release"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@expo/react-native-action-sheet": "^3.8.0",
|
"@expo/react-native-action-sheet": "^3.8.0",
|
||||||
"@ideditor/country-coder": "^4.0.0",
|
"@ideditor/country-coder": "^4.0.0",
|
||||||
|
"@react-native-clipboard/clipboard": "^1.12.1",
|
||||||
"@react-native-community/async-storage": "^1.9.0",
|
"@react-native-community/async-storage": "^1.9.0",
|
||||||
"@react-native-community/datetimepicker": "^3.5.2",
|
"@react-native-community/datetimepicker": "^2.4.0",
|
||||||
"@react-native-community/netinfo": "^6.0.2",
|
"@react-native-community/netinfo": "^6.0.2",
|
||||||
"@react-native-community/viewpager": "^3.3.0",
|
"@react-native-community/viewpager": "^3.3.0",
|
||||||
"@react-native/normalize-color": "^2.1.0",
|
"@react-native/normalize-color": "^2.1.0",
|
||||||
|
@ -36,7 +38,6 @@
|
||||||
"react-native-animatable": "^1.3.2",
|
"react-native-animatable": "^1.3.2",
|
||||||
"react-native-best-viewpager": "^1.0.4",
|
"react-native-best-viewpager": "^1.0.4",
|
||||||
"react-native-blob-util": "^0.14.0",
|
"react-native-blob-util": "^0.14.0",
|
||||||
"react-native-blur-overlay": "^1.0.6",
|
|
||||||
"react-native-calendario": "^0.2.10",
|
"react-native-calendario": "^0.2.10",
|
||||||
"react-native-camera": "^3.30.0",
|
"react-native-camera": "^3.30.0",
|
||||||
"react-native-cardview": "^2.0.2",
|
"react-native-cardview": "^2.0.2",
|
||||||
|
@ -49,21 +50,21 @@
|
||||||
"react-native-dropdownalert": "^4.3.0",
|
"react-native-dropdownalert": "^4.3.0",
|
||||||
"react-native-elements": "^1.1.0",
|
"react-native-elements": "^1.1.0",
|
||||||
"react-native-geolocation": "^1.0.0",
|
"react-native-geolocation": "^1.0.0",
|
||||||
"react-native-geolocation-service": "4.0.0",
|
"react-native-geolocation-service": "5.2.0",
|
||||||
"react-native-gesture-handler": "1.6.1",
|
"react-native-gesture-handler": "1.6.1",
|
||||||
"react-native-i18n": "^2.0.15",
|
"react-native-i18n": "^2.0.15",
|
||||||
"react-native-image-crop-picker": "^0.36.4",
|
"react-native-image-crop-picker": "^0.32.0",
|
||||||
"react-native-loader": "^1.2.1",
|
"react-native-loader": "^1.2.1",
|
||||||
"react-native-loading-spinner-overlay": "^1.0.1",
|
"react-native-loading-spinner-overlay": "^1.0.1",
|
||||||
"react-native-local-mongodb": "^2.2.9",
|
"react-native-local-mongodb": "^2.2.9",
|
||||||
"react-native-maps": "^1.4.0",
|
"react-native-maps": "^0.30.0",
|
||||||
"react-native-maps-directions": "^1.7.0",
|
"react-native-maps-directions": "^1.7.0",
|
||||||
"react-native-material-bottom-navigation": "^1.0.3",
|
"react-native-material-bottom-navigation": "^1.0.3",
|
||||||
"react-native-material-bottom-navigation-performance": "^0.7.8",
|
"react-native-material-bottom-navigation-performance": "^0.7.8",
|
||||||
"react-native-material-cards": "^1.0.9",
|
"react-native-material-cards": "^1.0.9",
|
||||||
"react-native-material-dialog": "^0.7.6",
|
"react-native-material-dialog": "^0.7.6",
|
||||||
"react-native-material-dropdown": "^0.11.1",
|
"react-native-material-dropdown": "^0.11.1",
|
||||||
"react-native-material-dropdown-v2": "^0.12.0",
|
"react-native-material-dropdown-v2": "^0.11.1",
|
||||||
"react-native-modal": "^12.1.0",
|
"react-native-modal": "^12.1.0",
|
||||||
"react-native-modal-datetime-picker": "^10.2.0",
|
"react-native-modal-datetime-picker": "^10.2.0",
|
||||||
"react-native-onesignal": "^3.9.0",
|
"react-native-onesignal": "^3.9.0",
|
||||||
|
@ -77,7 +78,7 @@
|
||||||
"react-native-range-datepicker": "^1.8.2",
|
"react-native-range-datepicker": "^1.8.2",
|
||||||
"react-native-reanimated": "^1.13.0",
|
"react-native-reanimated": "^1.13.0",
|
||||||
"react-native-responsive-dimensions": "^2.0.1",
|
"react-native-responsive-dimensions": "^2.0.1",
|
||||||
"react-native-root-toast": "^3.2.1",
|
"react-native-root-toast": "^3.6.0",
|
||||||
"react-native-safe-area-context": "0.7.3",
|
"react-native-safe-area-context": "0.7.3",
|
||||||
"react-native-screens": "^2.3.0",
|
"react-native-screens": "^2.3.0",
|
||||||
"react-native-simple-dialogs": "1.2.1",
|
"react-native-simple-dialogs": "1.2.1",
|
||||||
|
@ -89,8 +90,9 @@
|
||||||
"react-native-switch-selector": "^1.1.14",
|
"react-native-switch-selector": "^1.1.14",
|
||||||
"react-native-tab-view": "^2.14.0",
|
"react-native-tab-view": "^2.14.0",
|
||||||
"react-native-textinput-effects": "^0.5.1",
|
"react-native-textinput-effects": "^0.5.1",
|
||||||
"react-native-vector-icons": "^6.5.0",
|
"react-native-toast-notifications": "^3.4.0",
|
||||||
"react-native-webview": "^11.26.1",
|
"react-native-vector-icons": "6.6.0",
|
||||||
|
"react-native-webview": "^11.4.0",
|
||||||
"react-native-wizard": "^2.1.0",
|
"react-native-wizard": "^2.1.0",
|
||||||
"react-navigation": "3.13.0",
|
"react-navigation": "3.13.0",
|
||||||
"react-navigation-drawer": "^1.4.0",
|
"react-navigation-drawer": "^1.4.0",
|
||||||
|
@ -99,7 +101,7 @@
|
||||||
"react-navigation-tabs": "^2.11.2",
|
"react-navigation-tabs": "^2.11.2",
|
||||||
"react-navigation-transitions": "^1.0.12",
|
"react-navigation-transitions": "^1.0.12",
|
||||||
"react-redux": "^7.2.0",
|
"react-redux": "^7.2.0",
|
||||||
"realm": "^10.21.1",
|
"realm": "^10.10.0",
|
||||||
"reanimated-bottom-sheet": "^1.0.0-alpha.10",
|
"reanimated-bottom-sheet": "^1.0.0-alpha.10",
|
||||||
"redux": "^4.0.5",
|
"redux": "^4.0.5",
|
||||||
"redux-persist": "^6.0.0",
|
"redux-persist": "^6.0.0",
|
||||||
|
@ -118,6 +120,7 @@
|
||||||
"jest": "^26.6.3",
|
"jest": "^26.6.3",
|
||||||
"jetifier": "^1.6.5",
|
"jetifier": "^1.6.5",
|
||||||
"metro-react-native-babel-preset": "^0.66.0",
|
"metro-react-native-babel-preset": "^0.66.0",
|
||||||
|
"patch-package": "^8.0.0",
|
||||||
"react-native-codegen": "^0.0.7",
|
"react-native-codegen": "^0.0.7",
|
||||||
"react-test-renderer": "17.0.1",
|
"react-test-renderer": "17.0.1",
|
||||||
"redux-logger": "^3.0.6"
|
"redux-logger": "^3.0.6"
|
||||||
|
|
Loading…
Reference in New Issue