Dashboard updated

This commit is contained in:
CPM
2025-08-20 11:21:36 +05:30
parent cd466a2af1
commit 85bb27408e
8 changed files with 66 additions and 33 deletions
@@ -263,7 +263,7 @@
buildSettings = { buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 6; CURRENT_PROJECT_VERSION = 7;
DEVELOPMENT_TEAM = JGDHGNH9XY; DEVELOPMENT_TEAM = JGDHGNH9XY;
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
INFOPLIST_FILE = PerformicsStoreDNA/Info.plist; INFOPLIST_FILE = PerformicsStoreDNA/Info.plist;
@@ -272,7 +272,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 1.6; MARKETING_VERSION = 1.7;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"$(inherited)", "$(inherited)",
"-ObjC", "-ObjC",
@@ -292,7 +292,7 @@
buildSettings = { buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 6; CURRENT_PROJECT_VERSION = 7;
DEVELOPMENT_TEAM = JGDHGNH9XY; DEVELOPMENT_TEAM = JGDHGNH9XY;
INFOPLIST_FILE = PerformicsStoreDNA/Info.plist; INFOPLIST_FILE = PerformicsStoreDNA/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 15.1; IPHONEOS_DEPLOYMENT_TARGET = 15.1;
@@ -300,7 +300,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 1.6; MARKETING_VERSION = 1.7;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"$(inherited)", "$(inherited)",
"-ObjC", "-ObjC",
Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

+1 -1
View File
@@ -31,7 +31,7 @@ export function ConfirmSaveAlert({
onYesCallBack = () => { }, onYesCallBack = () => { },
msg = 'Do you really want to save data?', msg = 'Do you really want to save data?',
yesText = 'Yes', yesText = 'Yes',
cancelText = 'NO', cancelText = 'No',
}) { }) {
return ( return (
<CustomModal <CustomModal
+19 -14
View File
@@ -1,5 +1,5 @@
import React from 'react'; import React from 'react';
import { View, Text, Modal, StyleSheet, TouchableOpacity, Image} from 'react-native'; import { View, Text, Modal, StyleSheet, TouchableOpacity, Image } from 'react-native';
import IMAGES from '../constants/Images'; import IMAGES from '../constants/Images';
const CustomModal = ({ const CustomModal = ({
@@ -18,17 +18,21 @@ const CustomModal = ({
<Modal visible={showModal} transparent animationType="fade"> <Modal visible={showModal} transparent animationType="fade">
<View style={styles.overlay}> <View style={styles.overlay}>
<View style={[styles.modalContainer, style]}> <View style={[styles.modalContainer, style]}>
{onClose && ( {/* {onClose && (
<TouchableOpacity onPress={onClose} style={styles.closeButton}> <TouchableOpacity onPress={onClose} style={styles.closeButton}>
<Image source={IMAGES.crossIcon} style={styles.iconStyle} /> <Image source={IMAGES.crossIcon} style={styles.iconStyle} />
</TouchableOpacity> </TouchableOpacity>
)} )} */}
{title && <Text style={[styles.title, titleStyle]}>{title}</Text>} {/* <TouchableOpacity onPress={onClose} style={styles.closeButton}>
{message && <Text style={[styles.message, messageStyle]}>{message}</Text>} <Image source={IMAGES.alert} style={styles.iconStyle} />
</TouchableOpacity> */}
<View style={{ marginTop: 10 }}>
{title && <Text style={[styles.title, titleStyle]}>{title}</Text>}
{message && <Text style={[styles.message, messageStyle]}>{message}</Text>}
</View>
<View style={{ marginVertical: 10 }}>{children}</View> <View style={{ marginVertical: 10 }}>{children}</View>
</View> </View>
</View> </View>
</Modal> </Modal>
@@ -50,7 +54,8 @@ const styles = StyleSheet.create({
borderRadius: 12, borderRadius: 12,
padding: 15, padding: 15,
alignItems: 'center', alignItems: 'center',
minHeight:200 minHeight: 180,
justifyContent: 'center'
}, },
title: { title: {
fontSize: 18, fontSize: 18,
@@ -64,17 +69,17 @@ const styles = StyleSheet.create({
textAlign: 'center', textAlign: 'center',
}, },
closeButton: { closeButton: {
alignSelf:'flex-end', alignSelf: 'center',
marginBottom:15 marginBottom: 15
}, },
closeText: { closeText: {
color: '#fff', color: '#fff',
fontWeight: 'bold', fontWeight: 'bold',
}, },
iconStyle:{ iconStyle: {
height:35, height: 50,
width:35, width: 50,
resizeMode:'contain', resizeMode: 'contain',
// tintColor:'red' // tintColor:'red'
} }
}); });
+2
View File
@@ -26,6 +26,8 @@ const IMAGES = {
AuthTopBGNew: require('../assets/Images/appLogoNew.png'), AuthTopBGNew: require('../assets/Images/appLogoNew.png'),
AuthBottomBG: require('../assets/Images/loginbottomBG.png'), AuthBottomBG: require('../assets/Images/loginbottomBG.png'),
dotsIcon: require('../assets/Icons/dots.png'), dotsIcon: require('../assets/Icons/dots.png'),
pending: require('../assets/Icons/wall-clock.png'),
alert: require('../assets/Icons/question-mark.png'),
}; };
+25 -7
View File
@@ -94,8 +94,8 @@ const Details = () => {
<Image source={IMAGES.backIcon} style={{ height: 20, width: 20, tintColor: '#fff' }} /> <Image source={IMAGES.backIcon} style={{ height: 20, width: 20, tintColor: '#fff' }} />
</TouchableOpacity> </TouchableOpacity>
<Text style={{ color: '#fff', fontSize: 20, fontWeight: 'bold' }}>Details</Text> <Text style={{ color: '#fff', fontSize: 20, fontWeight: 'bold' }}>Details</Text>
<View style={{ width: 25 }} /> <View style={{ width: 25 }} />
</View> </View>
<ScrollView style={{ padding: 20 }}> <ScrollView style={{ padding: 20 }}>
@@ -254,7 +254,8 @@ const Details = () => {
return ( return (
<View key={index} style={{ marginBottom: 30 }}> <View key={index} style={{ marginBottom: 30 }}>
<Text style={{ color: '#000', fontSize: 16, fontWeight: '600', marginBottom: 10 }}>
<Text style={{ marginTop: 10, color: '#000', fontSize: 16, fontWeight: '600', marginBottom: 10 }}>
{detail.GraphTitle} {detail.GraphTitle}
</Text> </Text>
@@ -289,6 +290,7 @@ const Details = () => {
borderColor: '#eee', borderColor: '#eee',
}}> }}>
<Text style={{ color: '#000', width: '80%' }}>{row[displayKey] || '--'}</Text> <Text style={{ color: '#000', width: '80%' }}>{row[displayKey] || '--'}</Text>
<TouchableOpacity disabled={isOSATab ? false : true} <TouchableOpacity disabled={isOSATab ? false : true}
onPress={() => { onPress={() => {
if (row[presentKey] == 100 || row[presentKey] == '100') { if (row[presentKey] == 100 || row[presentKey] == '100') {
@@ -340,8 +342,20 @@ const Details = () => {
</TouchableOpacity> </TouchableOpacity>
</View> </View>
<View style={{ borderTopLeftRadius: 10, borderTopRightRadius: 10, marginTop: 15, marginHorizontal: 15, backgroundColor: '#eee', padding: 10, borderWidth: 1, borderColor: 'gray' }}>
<Text style={{ color: '#000', fontSize: 16, fontWeight: '500' }}>{'Out of Stock SKUs:'}</Text>
</View>
{/* SKU List */} {/* SKU List */}
<ScrollView contentContainerStyle={{ padding: 15 }}> <ScrollView contentContainerStyle={{
marginHorizontal: 15,
borderBottomWidth: 0.5,
borderLeftWidth: 0.5,
borderRightWidth: 0.5,
borderColor: 'gray',
borderBottomEndRadius: 10,
borderBottomLeftRadius: 10,
}}>
{/* <Text style={{ color: '#000', fontSize: 16, fontWeight: 'bold', marginBottom: 5 }}>OOS SKU details</Text> */} {/* <Text style={{ color: '#000', fontSize: 16, fontWeight: 'bold', marginBottom: 5 }}>OOS SKU details</Text> */}
{selectedCategoryData.map((item, idx) => ( {selectedCategoryData.map((item, idx) => (
<View <View
@@ -353,11 +367,15 @@ const Details = () => {
paddingVertical: 8, paddingVertical: 8,
borderBottomWidth: idx === selectedCategoryData.length - 1 ? 0 : 1, borderBottomWidth: idx === selectedCategoryData.length - 1 ? 0 : 1,
borderColor: '#eee', borderColor: '#eee',
}} }}
> >
<Text style={{ color: '#000', width: '80%' }}> <View style={{ flexDirection: 'row' }}>
{item.Product_MasterProduct_Name} <Text style={{ color: '#000', marginLeft: 10 }}>{idx + 1}. </Text>
</Text> <Text style={{ color: '#000', }}>
{item.Product_MasterProduct_Name}
</Text>
</View>
{/* <Text style={{ color: '#000', width: '20%', textAlign: 'center' }}> {/* <Text style={{ color: '#000', width: '20%', textAlign: 'center' }}>
{item['#_of_OOS_SKU_for_all_visits']} {item['#_of_OOS_SKU_for_all_visits']}
</Text> */} </Text> */}
+15 -7
View File
@@ -563,6 +563,10 @@ const Dashboard = (props) => {
const barData = values.map((v, idx) => { const barData = values.map((v, idx) => {
const value = parseFloat(Object.values(v).find(val => typeof val === 'number').toFixed(1)); const value = parseFloat(Object.values(v).find(val => typeof val === 'number').toFixed(1));
// console.log('valuevaluevalue--->', value);
return { return {
value, value,
label: v.CalendarYear_Month, label: v.CalendarYear_Month,
@@ -571,6 +575,7 @@ const Dashboard = (props) => {
<Text style={{ color: '#000', fontSize: 12, fontWeight: '500', marginBottom: 5 }}>{value}%</Text> <Text style={{ color: '#000', fontSize: 12, fontWeight: '500', marginBottom: 5 }}>{value}%</Text>
) )
}; };
}); });
const visibleBars = barData.length; const visibleBars = barData.length;
@@ -708,7 +713,7 @@ const Dashboard = (props) => {
}); });
// console.log('mainTabIndex----->',mainTabIndex); // console.log('mainTabIndex----->',mainTabIndex);
return ( return (
<SafeAreaView style={{ flex: 1, backgroundColor: GlobalTheme.colors.primary }}> <SafeAreaView style={{ flex: 1, backgroundColor: GlobalTheme.colors.primary }}>
@@ -769,16 +774,19 @@ const Dashboard = (props) => {
disabled={store?.UPLOAD_STATUS == 'U' ? true : false} disabled={store?.UPLOAD_STATUS == 'U' ? true : false}
onPress={() => onSelectStore(store)} onPress={() => onSelectStore(store)}
key={store.StoreId} style={styles.storeCard}> key={store.StoreId} style={styles.storeCard}>
<View style={[styles.row, { margin: 0 }]}> <View style={[styles.row, { margin: 0, width: "100%" }]}>
<Text style={styles.cardTextBold}>{store.StoreName}</Text> <View style={{ width: "70%" }}>
<Text style={styles.cardTextBold}>{store.StoreName}</Text>
</View>
{store?.UPLOAD_STATUS === 'U' ? {store?.UPLOAD_STATUS === 'U' ?
<Image source={IMAGES.greenTick} style={{ height: 20, width: 20 }} /> <Image source={IMAGES.greenTick} style={{ height: 20, width: 20 }} />
: :
<View style={{ flexDirection: 'row', alignItems: 'center' }}> <View style={{ width: "30%", flexDirection: 'row', alignItems: 'center' }}>
<View style={{ backgroundColor: '#FFF8CD', padding: 5, paddingHorizontal: 7, borderRadius: 15 }}> <View style={{ flexDirection: 'row', backgroundColor: '#ffefd5', padding: 5, paddingHorizontal: 10, borderRadius: 15 }}>
<Text style={{ color: 'orange', fontSize: 13, fontWeight: '500' }}>Pending</Text> <Text style={{ color: 'orange', fontSize: 12, fontWeight: '500' }}>Feedback Pending</Text>
{/* <Image source={IMAGES.pending} style={{ marginLeft: 5, height: 18, width: 18, tintColor: 'orange' }} /> */}
</View> </View>
<Image source={IMAGES.rightArrowIcon} style={{ marginLeft: 10, height: 20, width: 20, resizeMode: 'contain', tintColor: '#97ADD6' }} /> <Image source={IMAGES.rightArrowIcon} style={{ marginLeft: -2, height: 20, width: 20, resizeMode: 'contain', tintColor: '#97ADD6' }} />
</View> </View>
} }
</View> </View>