Skip to content

Commit

Permalink
Staging (#24) (#25) (#26)
Browse files Browse the repository at this point in the history
* 테스트

* 두번 테스트

* 로그인 수정 및 강의계획서 추가 (#23)

* 테스트

* 두번 테스트

* 교수계획서 백단 추가

* 홈화면그림자

* 그림자재수정

* 콘솔 제거

* 그림자 추가

* 강의 계획 추가

* 콘솔 제거

* 그림자

* 일부수정
  • Loading branch information
aerain authored Aug 25, 2019
1 parent 73f6dcf commit edba21a
Show file tree
Hide file tree
Showing 17 changed files with 450 additions and 96 deletions.
22 changes: 15 additions & 7 deletions components/drawer/home/card/BusTime.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useState, useEffect } from 'react'
import { View, Text, StyleSheet } from 'react-native'
import { View, Text, StyleSheet, Platform } from 'react-native'
import Picker from 'react-native-picker-select';
import BusTb from '../../../../jsons/busschedule.json';
import BusA from '../../../../tool/busA';
Expand Down Expand Up @@ -58,21 +58,29 @@ const BusTime = () => {

const pickerSelectStyles = StyleSheet.create({
inputIOS: {
fontSize: 16,
paddingVertical: 12,
fontSize: 14,
paddingVertical: 4,
paddingHorizontal: 10,
color: '#ffffff',
paddingRight: 24, // to ensure the text is never behind the icon
},
inputAndroid: {
fontSize: 16,
paddingHorizontal: 10,
paddingVertical: 8,
fontSize: 14,
paddingHorizontal: 12,
color: '#ffffff',
paddingRight: 24, // to ensure the text is never behind the icon
},
inputAndroidContainer: {
height: null,
},
// headlessAndroidPicker: {
// height: null,
// },
headlessAndroidContainer: {
height: '100%'
},
iconContainer: {
top: 10,
top: Platform.select({ios: 0, android: 10})
},
});

Expand Down
4 changes: 2 additions & 2 deletions components/drawer/jnuservice/dreamy/DreamyHome.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ const DreamyHome = ({navigation, isFocused}) => {
<DreamyCard title="내 평점 확인" onPress={() => afterLogin(() => navigation.navigate("Credit"))}>
<Text>전체 성적을 조회하실 수 있습니다.</Text>
</DreamyCard>
{/* {isLogin && */}
{isLogin &&
<FlatList
ListHeaderComponent={MenuHeader}
numColumns={numColumns}
Expand All @@ -84,7 +84,7 @@ const DreamyHome = ({navigation, isFocused}) => {
renderItem={MenuItem}
contentContainerStyle={styles.totalMenuContainer}
/>
{/* } */}
}
</ScrollView>
)
}
Expand Down
39 changes: 19 additions & 20 deletions components/drawer/jnuservice/dreamy/LecturePlan.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,15 @@ import colorPalette from '../../../styles/colorPalette';
import Picker from 'react-native-picker-select';
import semesterData from '../../../../jsons/semesterMap';
import Icon from 'react-native-vector-icons/Ionicons';
import elevationShadowStyle from '../../../../tool/elevationShadow';

const LecturePlan = ({navigation}) => {
const date = new Date();
const [year, setYear] = useState(date.getFullYear().toString());
const [semester, setSemester] = useState([21, 10, 10, 10, 10, 10, 11, 20, 20, 20, 20, 20][date.getMonth()]);
const [classCode, setClassCode] = useState('');
const [professorName, setProfessorName] = useState('');
const [lectureName, setLectureName] = useState('보안시스템개론');
const [lectureName, setLectureName] = useState('');
const [data, setData] = useState([]);
const [isLoading, setLoading] = useState(false);

Expand All @@ -27,10 +28,6 @@ const LecturePlan = ({navigation}) => {
await setLoading(false);
}

useEffect(() => {
getData()
} ,[]);

const LectureItem = ({item: {classCode, credit, professorName, takeName, lectureCode, lectureName, time}}) => (
<TouchableOpacity style={styles.lecture} onPress={() => navigation.navigate("LecturePlanDetail", { year, semester, classCode, lectureCode })}>
<View style={styles.lectureHeader}>
Expand Down Expand Up @@ -74,27 +71,28 @@ const LecturePlan = ({navigation}) => {
Icon={() => (<Icon name="md-arrow-dropdown" size={24} color={colorPalette.mainColor} style={{marginRight: 5}} />)}
/>
</View>
{
isLoading ? (
<View style={{alignItems: 'center', paddingTop:20, flex:1}}>
<ActivityIndicator size='large' color={colorPalette.mainColor}/>
</View>
) : (<ScrollView>
<View style={styles.searchHeader}>
<Input label="수강반번호" value={classCode} onChangeText={classCode => setClassCode(classCode)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Input label="교수이름" value={professorName} onChangeText={professorName => setProfessorName(professorName)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Input label="강의명" value={lectureName} onChangeText={lectureName => setLectureName(lectureName)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Button title="조회" type="solid" color={colorPalette.mainColor} buttonStyle={{backgroundColor: colorPalette.mainColor, margin: 8}} onPress={getData}/>
<ScrollView>
<View style={styles.searchHeader}>
<Input label="수강반번호" value={classCode} onChangeText={classCode => setClassCode(classCode)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Input label="교수이름" value={professorName} onChangeText={professorName => setProfessorName(professorName)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Input label="강의명" value={lectureName} onChangeText={lectureName => setLectureName(lectureName)} labelStyle={styles.label} containerStyle={styles.searchContainer} inputStyle={styles.searchInput}/>
<Button title="조회" type="solid" color={colorPalette.mainColor} buttonStyle={{backgroundColor: colorPalette.mainColor, margin: 8}} onPress={getData}/>
</View>
{
isLoading ? (
<View style={{alignItems: 'center', paddingTop:20, flex:1}}>
<ActivityIndicator size='large' color={colorPalette.mainColor}/>
</View>
) : (
<FlatList
data={data}
renderItem = {LectureItem}
keyExtractor={item => item.classCode}
nestedScrollEnabled={true}
/>
</ScrollView>
)
}
)
}
</ScrollView>
</Fragment>

)
Expand Down Expand Up @@ -131,6 +129,7 @@ const styles = StyleSheet.create({
borderWidth: 0.5,
backgroundColor: colorPalette.cardBackgroundColor,
padding: 16,
...elevationShadowStyle(5),
},
lectureHeader: {
paddingBottom: 8,
Expand Down Expand Up @@ -169,8 +168,8 @@ const styles = StyleSheet.create({
backgroundColor: colorPalette.cardBackgroundColor,
borderColor: colorPalette.cardBorderColor,
borderWidth: 0.5,
overflow: 'hidden',
marginVertical: 4,
...elevationShadowStyle(5),
}
});

Expand Down
Loading

0 comments on commit edba21a

Please sign in to comment.