Correction des bugs
This commit is contained in:
parent
38868291b8
commit
1755385e39
File diff suppressed because one or more lines are too long
|
@ -65,6 +65,13 @@ import chunk from "lodash/chunk";
|
|||
import _ from "lodash";
|
||||
import FontAwesome from "react-native-vector-icons/FontAwesome";
|
||||
import FontAwesome5 from "react-native-vector-icons/FontAwesome5";
|
||||
import {
|
||||
fetchGetConsultationReset,
|
||||
fetchGetDrugAppareilReset, fetchGetNetworkActsReset, fetchGetProviderClassReset,
|
||||
fetchGetSubscriptionListReset, fetchGetUserByIdQRCodeReset,
|
||||
fetchGetUserByNameOrNumberReset
|
||||
} from "../../redux/insurance/insurance.actions";
|
||||
import {facturerSoinReset} from "../../webservice/NanoCreditApi";
|
||||
|
||||
let moment = require('moment-timezone');
|
||||
const thousands = require('thousands');
|
||||
|
@ -113,6 +120,14 @@ class WalletDetail extends Component {
|
|||
this.props.getWalletTransactionHistoryReset();
|
||||
this.props.depositActionReset();
|
||||
this.props.resetWalletListDetailReducer();
|
||||
this.props.fetchGetSubscriptionListReset();
|
||||
this.props.fetchGetDrugAppareilReset();
|
||||
this.props.fetchGetUserByNameOrNumberReset();
|
||||
this.props.fetchGetUserByIdQRCodeReset();
|
||||
this.props.fetchGetProviderClassReset();
|
||||
this.props.fetchGetConsultationReset();
|
||||
this.props.fetchGetNetworkActsReset();
|
||||
this.props.facturerSoinReset();
|
||||
|
||||
this.currentLocale = I18n.locale.includes("fr") ? "fr" : "en-gb";
|
||||
moment.locale(this.currentLocale);
|
||||
|
@ -155,6 +170,14 @@ class WalletDetail extends Component {
|
|||
this.willFocus = this.props.navigation.addListener(
|
||||
'willFocus',
|
||||
payload => {
|
||||
this.props.fetchGetSubscriptionListReset();
|
||||
this.props.fetchGetDrugAppareilReset();
|
||||
this.props.fetchGetUserByNameOrNumberReset();
|
||||
this.props.fetchGetUserByIdQRCodeReset();
|
||||
this.props.fetchGetProviderClassReset();
|
||||
this.props.fetchGetConsultationReset();
|
||||
this.props.fetchGetNetworkActsReset();
|
||||
this.props.facturerSoinReset();
|
||||
const {result} = this.props;
|
||||
console.warn("will focus detail");
|
||||
this.getWalletDetail();
|
||||
|
@ -1307,7 +1330,9 @@ class WalletDetail extends Component {
|
|||
)
|
||||
}
|
||||
|
||||
renderItem = (options, isOneElement, index) => (
|
||||
renderItem = (options, isOneElement, index) => {
|
||||
console.log("OPTIONS", options);
|
||||
return (
|
||||
isOneElement ?
|
||||
<>
|
||||
<View key={index} style={[styles.containerTouch]}>
|
||||
|
@ -1318,10 +1343,18 @@ class WalletDetail extends Component {
|
|||
}}
|
||||
activeOpacity={0.9}>
|
||||
|
||||
{
|
||||
options.hasOwnProperty('iconType') ?
|
||||
<FontAwesome5 name={options.icon}
|
||||
color={Color.primaryColor}
|
||||
size={24}
|
||||
style={styles.imageBanner}/>
|
||||
: <Icon name={options.icon}
|
||||
color={Color.primaryColor}
|
||||
size={24}
|
||||
style={styles.imageBanner}/>
|
||||
|
||||
}
|
||||
|
||||
<View style={[styles.content]}>
|
||||
|
||||
|
@ -1346,10 +1379,18 @@ class WalletDetail extends Component {
|
|||
}}
|
||||
activeOpacity={0.9}>
|
||||
|
||||
{
|
||||
options.hasOwnProperty('iconType') ?
|
||||
<FontAwesome5 name={options.icon}
|
||||
color={Color.primaryColor}
|
||||
size={24}
|
||||
style={styles.imageBanner}/>
|
||||
: <Icon name={options.icon}
|
||||
color={Color.primaryColor}
|
||||
size={24}
|
||||
style={styles.imageBanner}/>
|
||||
|
||||
}
|
||||
|
||||
|
||||
<View style={[styles.content]}>
|
||||
|
@ -1368,7 +1409,8 @@ class WalletDetail extends Component {
|
|||
</View>
|
||||
</>
|
||||
|
||||
);
|
||||
)
|
||||
};
|
||||
|
||||
renderDetailWallet = (wallet) => {
|
||||
return (
|
||||
|
@ -2006,7 +2048,17 @@ const mapDispatchToProps = dispatch => bindActionCreators({
|
|||
getWalletTransactionHistoryReset,
|
||||
depositActionReset,
|
||||
getHyperSuperTransactionHistoryAction,
|
||||
getHyperSuperTransactionHistoryReset
|
||||
getHyperSuperTransactionHistoryReset,
|
||||
|
||||
fetchGetSubscriptionListReset,
|
||||
fetchGetDrugAppareilReset,
|
||||
fetchGetUserByNameOrNumberReset,
|
||||
fetchGetUserByIdQRCodeReset,
|
||||
fetchGetProviderClassReset,
|
||||
fetchGetConsultationReset,
|
||||
fetchGetNetworkActsReset,
|
||||
facturerSoinReset,
|
||||
|
||||
}, dispatch);
|
||||
|
||||
export default connect(mapStateToProps, mapDispatchToProps)(WalletDetail);
|
||||
|
|
|
@ -322,7 +322,9 @@ class WalletOptionSelect extends Component {
|
|||
|
||||
}
|
||||
|
||||
renderItem = (options, isOneElement, index) => (
|
||||
renderItem = (options, isOneElement, index) => {
|
||||
console.log("OPTIONS", options);
|
||||
return (
|
||||
isOneElement ?
|
||||
<>
|
||||
<View key={index} style={[styles.containerTouch]}>
|
||||
|
@ -333,11 +335,6 @@ class WalletOptionSelect extends Component {
|
|||
}}
|
||||
activeOpacity={0.9}>
|
||||
|
||||
<Icon name={options.icon}
|
||||
color={Color.primaryColor}
|
||||
size={30}
|
||||
style={styles.imageBanner}/>
|
||||
|
||||
{
|
||||
options.hasOwnProperty('iconType') ?
|
||||
<FontAwesome5 name={options.icon}
|
||||
|
@ -421,7 +418,8 @@ class WalletOptionSelect extends Component {
|
|||
</View>
|
||||
</>
|
||||
|
||||
);
|
||||
)
|
||||
};
|
||||
|
||||
updateLangue() {
|
||||
this.props.navigation.setParams({name: I18n.t('WALLET')})
|
||||
|
|
|
@ -455,7 +455,38 @@ const ModifierFeuilleSoinScreen = ({
|
|||
}
|
||||
}, [getUserByNameOrNumber]);
|
||||
|
||||
useEffect(() => {
|
||||
if (checkInsuranceCoverageAmount.result !== null) {
|
||||
if (checkInsuranceCoverageAmount.result.response !== null) {
|
||||
if(consultation.performances.length >= 1) {
|
||||
setModalPrestation(false);
|
||||
Utils.displayToast(I18n.t('PRESTATION_SUCCESSFULLY_ADD'));
|
||||
}
|
||||
dispatch(fetchCheckInsuranceCoverageAmountReset());
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (checkInsuranceCoverageAmount.error) {
|
||||
Alert.alert(
|
||||
I18n.t("ERROR_LABLE"),
|
||||
Utils.getErrorMsg(checkInsuranceCoverageAmount),
|
||||
[
|
||||
{
|
||||
text: I18n.t("OK"), onPress: () => {
|
||||
if(consultation.performances.length >= 1) {
|
||||
setConsultation({...consultation, performances: [...consultationClone.performances]});
|
||||
setModalPrestation(false);
|
||||
}
|
||||
dispatch(fetchCheckInsuranceCoverageAmountReset());
|
||||
}
|
||||
}
|
||||
],
|
||||
{ cancelable: false }
|
||||
);
|
||||
}
|
||||
}, [checkInsuranceCoverageAmount]);
|
||||
|
||||
|
||||
useEffect(() => {
|
||||
|
@ -2450,7 +2481,8 @@ const ModifierFeuilleSoinScreen = ({
|
|||
pregnancy_end_at: values.pregnancy_end_at,
|
||||
performances: consultation.performances,
|
||||
prescriptions: consultation.prescriptions,
|
||||
exams: consultation.exams
|
||||
exams: consultation.exams,
|
||||
tmp_sheet_id: Date.now()
|
||||
});
|
||||
},
|
||||
});
|
||||
|
|
|
@ -1577,7 +1577,8 @@ const SaisirFeuilleSoinScreen = ({
|
|||
pregnancy_end_at: values.pregnancy_end_at,
|
||||
performances: prestations,
|
||||
prescriptions: prescriptions,
|
||||
exams: examens
|
||||
exams: examens,
|
||||
tmp_sheet_id: Date.now()
|
||||
})
|
||||
}
|
||||
},
|
||||
|
|
|
@ -674,7 +674,14 @@ export const optionNanoSanteAgentScreen = {
|
|||
icon: 'history',
|
||||
title: 'HISTORY',
|
||||
iconType:"FontAwesome5"
|
||||
},
|
||||
{
|
||||
screen: route.createIdentification,
|
||||
icon: 'user',
|
||||
iconType:"FontAwesome5",
|
||||
title: 'CREATION_IDENTIFICATION_DESCRIPTION_SUBSCREEN',
|
||||
}
|
||||
|
||||
]
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue