Skip to content

Commit 4cac40b

Browse files
committed
[WEB] develop 브랜치에 머지
2 parents c1d9d32 + e75271f commit 4cac40b

File tree

30 files changed

+69
-274
lines changed

30 files changed

+69
-274
lines changed

.github/workflows/web.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,5 @@ jobs:
3030
cd ../frontend
3131
npm install
3232
npm run build --if-present
33-
pm2 start npm --name "next" -- start
33+
pm2 start npm --name "next" -- start
34+

README.md

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ VIBE 서비스 사용과정에서 발생하는 이벤트를 수집하는 서비
2828
2929
<p align="center">
3030
<img width="350" alt="event" src="https://user-images.githubusercontent.com/60839959/102684638-c74b0780-421d-11eb-84fc-8f4f625a66e6.png">
31-
<img width="570" alt="스크린샷 2020-12-19 오후 5 27 57" src="https://user-images.githubusercontent.com/60839959/102684875-910e8780-421f-11eb-8b64-16f53d06c200.png">
31+
<img width="570" alt="스크린샷 2020-12-19 오후 5 27 57" src="https://user-images.githubusercontent.com/60839959/102684875-910e8780-421f-11eb-8b64-16f53d06c200.png">
3232
</p>
3333

3434
📕 ["이벤트 로그" 정의부터 구현까지](https://www.notion.so/9fca9884c5a144b6a8ade2611ae71f20?v=08ee6720efb043ddb19f7989a21f7adc&p=23cd57707992408db323aac536d239f9)
@@ -44,7 +44,7 @@ VIBE 서비스 사용과정에서 발생하는 이벤트를 수집하는 서비
4444
<p align="center"><img width="700" alt="기술 스택" src="https://user-images.githubusercontent.com/60839959/102687079-d470f200-422f-11eb-982d-0ee36795a17a.png"></p>
4545

4646
#### iOS 🍎
47-
<p align="center"><img width="350" alt="기술 스택" src="https://user-images.githubusercontent.com/60839959/102710138-9e954180-42f3-11eb-890c-751e5895ffab.png"></p>
47+
<p align="center"><img width="350" alt="기술 스택" src="https://user-images.githubusercontent.com/54564170/102690738-caa8b800-424a-11eb-81f5-96cd0ca4d309.png"></p>
4848

4949

5050
<br>
@@ -54,25 +54,17 @@ VIBE 서비스 사용과정에서 발생하는 이벤트를 수집하는 서비
5454
## 📹 서비스 데모 영상
5555
#### Web 🕸
5656

57-
[<img width="500" src="https://user-images.githubusercontent.com/60839959/102683358-bbf2de80-4213-11eb-87e0-c889f0afe61b.png"/>](https://www.youtube.com/watch?v=WWSpciYdGR4&feature=youtu.be)
57+
[<img width="500" src="https://user-images.githubusercontent.com/60839959/102683358-bbf2de80-4213-11eb-87e0-c889f0afe61b.png"/>](https://youtu.be/AqSunm6fDfc)
5858
> 클릭하시면 youtube로 이동합니다💨
5959
6060
#### iOS 🍎
6161

62-
[<img width="500" src="https://user-images.githubusercontent.com/54564170/102687174-9aecb680-4230-11eb-985a-ab967a08f06f.png"/>](https://www.youtube.com/watch?v=_10ZGYLncX0)
62+
[<img width="500" src="https://user-images.githubusercontent.com/54564170/102687174-9aecb680-4230-11eb-985a-ab967a08f06f.png"/>](https://youtu.be/dQiQtMR8pOM)
6363
> 클릭하시면 youtube로 이동합니다💨
6464
6565
<br>
6666
<br>
6767

68-
### Web 배포 주소
69-
http://115.85.181.152:3000/
70-
```
71-
네이버 로그인API 검수 문제로 로그인이 불가하여 주요서비스인 보관함 열람이 불가합니다😂
72-
전체 서비스 결과물은 데모영상을 활용해주시면 감사하겠습니다 🙏
73-
```
74-
75-
7668

7769
### Web 실행방법 🐈
7870
```
@@ -98,7 +90,7 @@ npm run start
9890

9991
## 🚢 사용자 이벤트 수집기 C팀 소개
10092

101-
<p align="center"><img width="650" alt="스크린샷 2020-12-19 오후 5 47 21" src="https://user-images.githubusercontent.com/60839959/102685197-49d5c600-4222-11eb-87e7-b3942e03a465.png"></p>
93+
<p align="center"><img width="650" alt="스크린샷 2020-12-19 오후 5 47 21" src="https://user-images.githubusercontent.com/60839959/102685197-49d5c600-4222-11eb-87e7-b3942e03a465.png"></p>
10294

10395
| 🕸 Web | 🕸 Web | 🕸 Web | 🍎 iOS | 🍎 iOS |
10496
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |

backend/src/route/auth/controller.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ import * as authService from '../../services/auth';
44

55
const getToken = (req: Request, res: Response): void => {
66
const token = authService.createToken(req.user as IJwtPayload);
7-
if (req.headers['user-agent']?.includes('iPhone')) {
7+
if (
8+
req.headers['user-agent']?.includes('iPhone') ||
9+
req.headers['user-agent']?.includes('iPad')
10+
) {
811
return res.redirect(`minivibe://token?${token}`); // 모바일
912
}
1013
res.cookie('token', token, { maxAge: 1000 * 60 * 60 * 24 * 1, httpOnly: false });
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { Request, Response } from 'express';
2+
import { IJwtPayload } from '../../middlewares/auth';
3+
import * as authService from '../../services/auth';
4+
5+
const getToken = (req: Request, res: Response): void => {
6+
// 모바일
7+
const token = authService.createToken(req.user as IJwtPayload);
8+
return res.redirect(`minivibe://token?${token}`);
9+
};
10+
11+
export { getToken };

backend/src/route/auth2/index.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import * as express from 'express';
2+
import * as passport from 'passport';
3+
import { getToken } from './controller';
4+
5+
const route = express.Router();
6+
7+
route.get('/login', passport.authenticate('naver', { session: false }));
8+
route.get('/login/callback', passport.authenticate('naver', { session: false }), getToken);
9+
10+
export default route;

backend/src/route/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import sampleRoute from './sample';
33
import userRoute from './users';
44
import logRoute from './log';
55
import authRoute from './auth';
6+
import auth2Route from './auth2';
67
import libraryRoute from './library';
78
import trackRoute from './track';
89
import albumRoute from './album';
@@ -17,6 +18,7 @@ route.use('/sample', sampleRoute);
1718
route.use('/user', userRoute);
1819
route.use('/log', tryAuthenticateWithJwt, logRoute);
1920
route.use('/auth', authRoute);
21+
route.use('/auth2', auth2Route);
2022
route.use('/library', authenticateWithJwt, libraryRoute);
2123
route.use('/track', trackRoute);
2224
route.use('/album', albumRoute);

event.sample.js

Lines changed: 0 additions & 67 deletions
This file was deleted.

frontend/next.config.js

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,9 @@ module.exports = withImages({
66
return [
77
{
88
source: '/',
9-
destination: '/today', // Matched parameters can be used in the destination
9+
destination: '/today',
1010
permanent: true,
1111
},
1212
]
1313
},
1414
})
15-
16-
// webpack 사용시
17-
// module.exports = withTypescript({
18-
// webpack(config, options) {
19-
// return config
20-
// }
21-
// })

frontend/pages/_app.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import App, { Container } from 'next/app';
1+
import App from 'next/app';
22
import React from 'react';
33
import theme from '@styles/themes';
44
import GlobalStyles from '@styles/global-styles';
@@ -14,7 +14,7 @@ class ReactApp extends App<any> {
1414
public render() {
1515
const { Component, pageProps } = this.props;
1616
return (
17-
<Container>
17+
<>
1818
<GlobalStyles />
1919
<ThemeProvider theme={theme}>
2020
<AuthProvider>
@@ -25,7 +25,7 @@ class ReactApp extends App<any> {
2525
</PlayProvider>
2626
</AuthProvider>
2727
</ThemeProvider>
28-
</Container>
28+
</>
2929
);
3030
}
3131
}

frontend/src/components/Common/Button/LargeButton.tsx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,6 @@ const LargeButton = ({ onClick, children, customType }: ILargeButtonProps) => {
5959
}
6060
};
6161

62-
// const iconStyle = {
63-
// marginRight: '4px',
64-
// position: 'relative',
65-
// bottom: '1px',
66-
// };
67-
6862
const CustomButton = styled.button<ILargeButtonProps>`
6963
display: flex;
7064
justify-content: center;

0 commit comments

Comments
 (0)