Commit 7a5629c1 by tungnq

TODO: Đã dựng xong màn hình danh sách đánh giá giảng dạy

parent dea62512
...@@ -10,6 +10,8 @@ import ClassActivity from '../screens/academic_advisor'; ...@@ -10,6 +10,8 @@ import ClassActivity from '../screens/academic_advisor';
import ListStudentClass from '../screens/academic_advisor/list_student'; import ListStudentClass from '../screens/academic_advisor/list_student';
import DetailStudent from '../screens/academic_advisor/list_student/detail'; import DetailStudent from '../screens/academic_advisor/list_student/detail';
import SubTeacherView from '../screens/sub_teacher'; import SubTeacherView from '../screens/sub_teacher';
import ListFeedBack from '../screens/feedback';
import DetailFeedBack from '../screens/feedback/detail';
const Stack = createStackNavigator(); const Stack = createStackNavigator();
function MyStack(props) { function MyStack(props) {
...@@ -28,6 +30,8 @@ function MyStack(props) { ...@@ -28,6 +30,8 @@ function MyStack(props) {
<Stack.Screen name={ScreenName.LISTSTUDENTCLASS} component={ListStudentClass} /> <Stack.Screen name={ScreenName.LISTSTUDENTCLASS} component={ListStudentClass} />
<Stack.Screen name={ScreenName.DETAILSTUDENT} component={DetailStudent} /> <Stack.Screen name={ScreenName.DETAILSTUDENT} component={DetailStudent} />
<Stack.Screen name={ScreenName.SUBTEACHER} component={SubTeacherView} /> <Stack.Screen name={ScreenName.SUBTEACHER} component={SubTeacherView} />
<Stack.Screen name={ScreenName.LISTFEEDBACK} component={ListFeedBack}/>
<Stack.Screen name={ScreenName.DETAILFEEDACK} component={DetailFeedBack}/>
</Stack.Navigator> </Stack.Navigator>
); );
} }
......
import React from 'react';
import {Text, View, StyleSheet} from 'react-native';
import DetailFeedBackView from './view';
const DetailFeedBack = (props) => {
return (
<DetailFeedBackView />
);
};
export default DetailFeedBack;
import React from 'react';
import {Text, View, TouchableOpacity, StyleSheet} from 'react-native';
const DetailFeedBackView = (props) => {
const { } = props;
return (
<View
style={{
flex: 1,
justifyContent: 'center',
alignItems: 'center',
}}>
<TouchableOpacity>
<Text>DetailFeedBack</Text>
</TouchableOpacity>
</View>
);
};
export default DetailFeedBackView;
const styles = StyleSheet.create({})
\ No newline at end of file
import React from 'react';
import {Text, View, StyleSheet} from 'react-native';
import FeedBackView from './view';
const FeedBack = (props) => {
const [dataList, setDataList] = React.useState([
{
"classCode": "ATTT2024.1",
"evaluationOpenDate": "15/07/2025",
"gpa": 4.0
},
{
"classCode": "IS2024.IP57.1",
"evaluationOpenDate": "15/07/2025",
"gpa": 3.0
},
{
"classCode": "BGF197.47.1",
"evaluationOpenDate": "15/07/2025",
"gpa": 3.5
},
{
"classCode": "CS301.12.3",
"evaluationOpenDate": "15/07/2025",
"gpa": 2.8
},
{
"classCode": "MA205.C33.2",
"evaluationOpenDate": "15/07/2025",
"gpa": 3.7
}
]);
return (
<FeedBackView dataList={dataList} setDataList={setDataList}/>
);
};
export default FeedBack;
import { StyleSheet, Text, View } from 'react-native'
import R from '../../assets/R'
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor:R.colors.white,
},
card:{
borderRadius:10,
padding:5,
marginTop:15,
marginBottom:15,
marginHorizontal:15,
alignItems:'center',
justifyContent:'center',
backgroundColor:R.colors.white,
shadowColor:R.colors.black,
shadowOffset:{width:0.5,height:2},
shadowOpacity:Platform.OS === 'ios' ? 0.25 : 1,
shadowRadius:5,
elevation:Platform.OS === 'ios' ? 1 : 2,
},
btnCard:{
borderRadius:10,
borderWidth:1,
padding:5,
width:'100%',
alignItems:'center',
justifyContent:'center',
borderColor:R.colors.grayBorderInputTextHeader,
},
text:{
fontSize:R.sizes.sm,
color:R.colors.black,
fontFamily:R.fonts.fontRegular,
fontWeight:'400',
},
containerCard:{
padding:10,
borderRadius:10,
marginBottom:15,
backgroundColor:R.colors.white,
shadowColor:R.colors.black,
shadowOffset:{width:0,height:2},
shadowOpacity:Platform.OS === 'ios' ? 0.25 : 1,
shadowRadius:1,
elevation:Platform.OS === 'ios' ? 1 : 2,
marginHorizontal:15,
flexDirection:'row',
alignItems:'center',
justifyContent:'space-between',
},
containerText:{
alignItems:'center',
justifyContent:'center',
},
btnRight:{
}
})
export default styles;
\ No newline at end of file
import React from 'react';
import {Text, View, TouchableOpacity, StyleSheet, FlatList, Image} from 'react-native';
import styles from './style';
import Header from '../../components/Header/Header';
import R from '../../assets/R';
const FeedBackView = props => {
const {dataList, setDataList} = props;
const renderItem = ({item})=>{
return(
<TouchableOpacity style={styles.containerCard}>
<View>
<View>
<Text style={[styles.text,{fontWeight:'600', fontFamily:R.fonts.fontMedium, color:R.colors.blue}]}>Lp: {item.classCode}</Text>
</View>
<View >
<Text style={styles.text}>M đánh giá t: {item.evaluationOpenDate}</Text>
</View>
</View>
<View>
<Text style={[styles.text]}>GPA: {item.gpa}</Text>
</View>
<View style={styles.btnRight}>
<Image
source={R.images.icNext}
style={{width:20,height:20}}
resizeMode='contain'
tintColor={R.colors.black}
/>
</View>
</TouchableOpacity>
)
}
return (
<View style={styles.container}>
<Header title={'Đánh giá giảng dạy'} isBack />
<View style={styles.body}>
<View style={styles.card}>
<TouchableOpacity style={styles.btnCard}>
<Text style={styles.text}>Hc k 2, Năm 2025</Text>
</TouchableOpacity>
</View>
<FlatList
data={dataList || []}
renderItem={renderItem}
showsVerticalScrollIndicator={false}
vertical
keyExtractor={(item, index) => `${index}`}
/>
</View>
</View>
);
};
export default FeedBackView;
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