Skip to content

Commit

Permalink
최종 apk (#49)
Browse files Browse the repository at this point in the history
  • Loading branch information
seonggwon98 committed Apr 8, 2024
1 parent 9d31d76 commit 4e7cb33
Show file tree
Hide file tree
Showing 15 changed files with 3,699 additions and 196 deletions.
3,577 changes: 3,577 additions & 0 deletions app/frontend/android/app/src/main/assets/index.android.bundle

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package com.ssafy.conting

import expo.modules.ReactActivityDelegateWrapper
import android.os.Bundle
import android.view.WindowManager
import com.facebook.react.ReactActivity
import com.facebook.react.ReactActivityDelegate
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.fabricEnabled
Expand All @@ -22,8 +20,4 @@ class MainActivity : ReactActivity() {
*/
override fun createReactActivityDelegate(): ReactActivityDelegate =
ReactActivityDelegateWrapper(this, BuildConfig.IS_NEW_ARCHITECTURE_ENABLED, DefaultReactActivityDelegate(this, mainComponentName, fabricEnabled))
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
window.setFlags(WindowManager.LayoutParams.FLAG_SECURE, WindowManager.LayoutParams.FLAG_SECURE)
}
}
2 changes: 1 addition & 1 deletion app/frontend/src/components/card/TicketEntryCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export default function TicketEntryCard(props: TicketEntryCardProps) {
<Animated.View style={[styles.ticketContainer, animatedCard]}>
<TouchableOpacity
style={{width: cardWidth, height: cardHeight}}
activeOpacity={0.8}
activeOpacity={1}
onPress={backHandler}>
{!isBack ? (
<TicketFront
Expand Down
17 changes: 8 additions & 9 deletions app/frontend/src/components/card/TicketQrCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@ type TicketCardProps = {
};

export default function TicketQrCard(props: TicketCardProps) {
console.log('ticket qr : ', props);
const [isPass, setIspass] = useState(false);
const [isQR, setIsQR] = useState(false);
const [qrURL, setQrURL] = useState('');
const [timeLeft, setTimeLeft] = useState(30);

Expand All @@ -50,11 +48,6 @@ export default function TicketQrCard(props: TicketCardProps) {
return () => clearInterval(interval);
}, [isPass, timeLeft]);

useEffect(() => {
if (isPass) {
setIsQR(false);
}
}, [isPass]);
// 입장권 터치시 지문 인식하는 과정
const handlePass = async () => {
// 키가 존재하는지 확인
Expand All @@ -67,6 +60,9 @@ export default function TicketQrCard(props: TicketCardProps) {
// 지문 인식을 하는데 새로운 지문을 등록했을 경우 키 삭제 후 새로운 키 발급
const {result, key, msg} = await biometricsAuth();
console.log(key);
if (key === null || key === undefined) {
return;
}
if (msg === '지문 재등록 필요') {
alertAndLog(
'',
Expand All @@ -89,6 +85,7 @@ export default function TicketQrCard(props: TicketCardProps) {
healthCheck(res.uuid);
} catch (error) {
alertAndLog('', error);
console.log(error);
}
}
}
Expand All @@ -105,15 +102,17 @@ export default function TicketQrCard(props: TicketCardProps) {
alertAndLog('', error);
clearInterval(healthcheck);
setIspass(false);
case 'QR 코드가 유효하지 않습니다.':
case 'QR 코드가 만료되었습니다..':
alertAndLog('', error);
clearInterval(healthcheck);
setIspass(false);
default:
console.log(error);
clearInterval(healthcheck);
setIspass(false);
}
}
}, 2000);
}, 2300);

// 30초 후 자동으로 반복 종료
setTimeout(() => {
Expand Down
3 changes: 3 additions & 0 deletions app/frontend/src/components/list/BannerList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ export default function BannerList({banners}: BannerListProps) {
height={heightPercent(200)}
autoPlay={true}
autoPlayInterval={2000}
panGestureHandlerProps={{
activeOffsetX: [-10, 10],
}}
/>
</View>
);
Expand Down
62 changes: 48 additions & 14 deletions app/frontend/src/components/list/EventList.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
import {StyleSheet, Text, View, Image, ColorValue} from 'react-native';
import {
StyleSheet,
Text,
View,
Image,
ColorValue,
Dimensions,
} from 'react-native';
import {BlueButton} from '../button/Button';
import {fontPercent, heightPercent} from '../../config/Dimensions';
import {widthPercent} from './../../config/Dimensions';
Expand All @@ -18,14 +25,16 @@ import moment from 'moment';
import {useNavigation} from '@react-navigation/native';
import {SlideModal} from '../modal/Modal.tsx';
import SelectNftScreen from '../../screens/mainScreen/eventScreen/SelectNftScreen.tsx';
import Carousel from 'react-native-reanimated-carousel';

export default function EventList(props: {events: Array<any>}) {
const [timer, setTimer] = useState('');
const [startTime, setStartTime] = useState('');
const [endTime, setEndTime] = useState('');
const [currentIndex, setCurrentIndex] = useState(0);
const [selectNftModalVisible, setSelectNftModalVisible] = useState(false);

const navigation = useNavigation();

useEffect(() => {
const interval = setInterval(() => {
const now = moment();
Expand Down Expand Up @@ -54,11 +63,24 @@ export default function EventList(props: {events: Array<any>}) {
return () => clearInterval(interval);
}, [startTime, endTime]);

const renderItem = item => {
setStartTime(item.start_at);
setEndTime(item.end_at);
useEffect(() => {
console.log(props.events);
const setTime = () => {
setStartTime(props.events[currentIndex].start_at);
setEndTime(props.events[currentIndex].end_at);
};
if (props.events.length) {
setTime();
}
}, [props.events, currentIndex]);

const renderItem = ({item}) => {
return (
<View>
<View
style={{
width: '100%',
height: '100%',
}}>
<View style={styles.cardContainer}>
<View
style={{
Expand All @@ -68,7 +90,7 @@ export default function EventList(props: {events: Array<any>}) {
<Image
style={{
width: '100%',
height: '100%',
height: heightPercent(300),
borderRadius: widthPercent(10),
resizeMode: 'stretch',
}}
Expand Down Expand Up @@ -119,6 +141,7 @@ export default function EventList(props: {events: Array<any>}) {
</View>
);
};

return (
<View style={styles.container}>
<View style={styles.titleContainer}>
Expand Down Expand Up @@ -147,12 +170,23 @@ export default function EventList(props: {events: Array<any>}) {
{/*end_at: new Date(endTimestamp).toISOString(),*/}
{/*doItPress: props.doItPress,*/}
<View style={{flex: 4}}>
<FlatList
<Carousel
data={props.events}
decelerationRate="fast"
horizontal
renderItem={({item, index}) => renderItem(item)}
showsHorizontalScrollIndicator={false}
renderItem={renderItem}
width={Dimensions.get('screen').width * 0.9}
defaultIndex={0}
mode="parallax"
onSnapToItem={index => {
setCurrentIndex(index);
}}
modeConfig={{
parallaxScrollingScale: 0.8,
parallaxScrollingOffset: 50,
parallaxAdjacentItemScale: 0.8,
}}
panGestureHandlerProps={{
activeOffsetX: [-30, 30],
}}
/>
</View>
</View>
Expand All @@ -170,17 +204,17 @@ const styles = StyleSheet.create({
padding: widthPercent(10),
},
titleContainer: {
flex: 1,
flex: 0.5,
flexDirection: 'row',
justifyContent: 'space-between',
alignItems: 'center',
marginBottom: heightPercent(10),
},
timeContainer: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
width: '100%',
flex: 0.5,
borderRadius: widthPercent(10),
backgroundColor: 'rgba(242,242,242,0.8)',
},
Expand Down
3 changes: 3 additions & 0 deletions app/frontend/src/components/list/PopularConcertList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,9 @@ export default function PopularConcertList({
}}
defaultIndex={0}
mode="parallax"
panGestureHandlerProps={{
activeOffsetX: [-30, 30],
}}
/>
);
}
4 changes: 0 additions & 4 deletions app/frontend/src/components/nft/NftSelectCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,6 @@ export default function NftSelectCard(props: NftBackProps) {
<Text style={F_SIZE_Y_TEXT}>NFT 주소</Text>
<Text style={F_SIZE_TEXT}>{props.ticketAddress.toBase58()}</Text>
</View>
<View style={styles.content}>
<Text style={F_SIZE_Y_TEXT}>가수 명</Text>
<Text style={F_SIZE_TEXT}>{props.accountData.data.name}</Text>
</View>
<View style={styles.content}>
<Text style={F_SIZE_Y_TEXT}>거래시 수수료</Text>
<Text style={F_SIZE_TEXT}>
Expand Down
Loading

0 comments on commit 4e7cb33

Please sign in to comment.