Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
W
WebBack
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
websystem
WebBack
Commits
ce8ae990
Commit
ce8ae990
authored
3 months ago
by
tpgus2603
Browse files
Options
Downloads
Patches
Plain Diff
refator: 프렌드 컨트롤러 수정(
#13
)
parent
892d17bb
No related branches found
Branches containing commit
No related tags found
2 merge requests
!31
Develop
,
!21
[#13] 미팅서비스 로직 및 테스트코드 수정
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
controllers/friendController.js
+2
-6
2 additions, 6 deletions
controllers/friendController.js
services/meetingService.js
+1
-2
1 addition, 2 deletions
services/meetingService.js
services/scheduleService.js
+1
-1
1 addition, 1 deletion
services/scheduleService.js
with
4 additions
and
9 deletions
controllers/friendController.js
+
2
−
6
View file @
ce8ae990
...
...
@@ -4,9 +4,6 @@ class friendController {
/**
* 친구 요청 보내기
* 클라이언트는 userId와 요청을 보낼 사용자의 email을 전송
* @param {Object} req - Express 요청 객체
* @param {Object} res - Express 응답 객체
* @param {Function} next - Express next 미들웨어 함수
*/
async
sendFriendRequest
(
req
,
res
,
next
)
{
const
{
userId
,
email
}
=
req
.
body
;
...
...
@@ -140,13 +137,12 @@ class friendController {
/**
* 친구 목록 조회
* GET /api/friend/all
* GET /api/friend/all
/:offset
*/
async
getFriendList
(
req
,
res
)
{
try
{
const
userId
=
req
.
user
.
id
;
const
friends
=
await
FriendService
.
getFriendList
(
userId
);
const
friends
=
await
FriendService
.
getFriendList
(
userId
,
20
,
req
.
param
);
return
res
.
status
(
200
).
json
({
success
:
true
,
data
:
friends
...
...
This diff is collapsed.
Click to expand it.
services/meetingService.js
+
1
−
2
View file @
ce8ae990
...
...
@@ -2,8 +2,7 @@
const
{
v4
:
uuidv4
}
=
require
(
'
uuid
'
);
const
{
Op
}
=
require
(
'
sequelize
'
);
const
{
Meeting
,
MeetingParticipant
,
User
,
Schedule
}
=
require
(
'
../models
'
);
// models/index.js를 통해 임포트
const
ChatRoom
=
require
(
'
../models/ChatRooms
'
);
const
{
Meeting
,
MeetingParticipant
,
User
,
Schedule
,
ChatRoom
}
=
require
(
'
../models
'
);
// models/index.js를 통해 임포트
const
chatController
=
require
(
'
../controllers/chatController
'
);
const
MeetingResponseDTO
=
require
(
'
../dtos/MeetingResponseDTO
'
);
const
MeetingDetailResponseDTO
=
require
(
'
../dtos/MeetingDetailResponseDTO
'
);
...
...
This diff is collapsed.
Click to expand it.
services/scheduleService.js
+
1
−
1
View file @
ce8ae990
// services/scheduleService.js
const
sequelize
=
require
(
'
../config/sequelize
'
);
const
{
Op
}
=
require
(
'
sequelize
'
);
const
Schedule
=
require
(
'
../models
/Schedule
'
);
const
{
Schedule
}
=
require
(
'
../models
'
);
const
ScheduleResponseDTO
=
require
(
'
../dtos/ScheduleResponseDTO
'
);
class
scheduleService
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment