Commit 6c30002e authored by danushka9999's avatar danushka9999

crop plan response finalization

parent 292f0939
import React from 'react'; import React from 'react';
import { View, Text, FlatList, Image, StyleSheet } from 'react-native'; import { View, Text, FlatList, Image, StyleSheet } from 'react-native';
import cropImages from '../common/Images';
const CropRotationResponse = ({ route }) => { const CropRotationResponse = ({ route }) => {
const { response } = route.params; const { response } = route.params;
...@@ -14,10 +15,11 @@ const CropRotationResponse = ({ route }) => { ...@@ -14,10 +15,11 @@ const CropRotationResponse = ({ route }) => {
<View style={styles.cropItem}> <View style={styles.cropItem}>
<Image <Image
style={styles.cropImage} style={styles.cropImage}
source={{ uri: `https://example.com/api/crop-images/${item.cropName}` }} source={cropImages[item.cropName]}
/> />
<Text style={styles.cropName}>{item.cropName}</Text> <Text style={styles.cropName}>{item.cropName}</Text>
<Text style={styles.year}>{item.year}</Text> <Text style={styles.year}>{item.year}</Text>
<Text style={styles.year}>{item.Sequence}</Text>
</View> </View>
)} )}
/> />
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment