Skip to content

Commit cc73abc

Browse files
Merge pull request #51 from TaskFlow-CLAP/CLAP-68
CLAP-68 기간별 작업 요청량 조회
2 parents 6e0c88a + df80537 commit cc73abc

38 files changed

+693
-107
lines changed

.github/image/Sihun23.jpeg

108 KB
Loading

.github/image/hyoseong.jpg

193 KB
Loading

.github/image/jaehak.jpg

131 KB
Loading

.github/image/jaehak.jpg.jpg

131 KB
Loading

.github/image/joowojr.JPG

693 KB
Loading

.github/image/tf-architecture.png

320 KB
Loading

.github/image/tf-erd.png

720 KB
Loading

README.md

Lines changed: 181 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,181 @@
1-
# TaskFlow-Server
1+
<div align="center">
2+
3+
# TaskFlow Server
4+
5+
[<img src="https://img.shields.io/badge/프로젝트 기간-2025.01.06~2025.02.20-green?style=flat&logo=&logoColor=white" />]()
6+
7+
</div>
8+
9+
## 🔎 TaskFlow
10+
11+
12+
## 💁‍♂️ Team Member
13+
| 서주원 (PL) | 나은비(BE) | 박재학(BE) | 양시훈(BE) | 이규동(BE) | 최효성(BE & INFRA) |
14+
|:---------:|:--------:|:--------:|:--------:|:--------:|:--------:|
15+
| <img src="https://github.com/TaskFlow-CLAP/TaskFlow-Server/blob/develop/.github/image/joowojr.JPG" width="150px" > | <img src="https://github.com/user-attachments/assets/5c59f742-8f2b-4472-bff4-d8dff350481b" width="150px"> | <img src="https://github.com/TaskFlow-CLAP/TaskFlow-Server/blob/develop/.github/image/jaehak.jpg" width="150px" > | <img src="https://github.com/TaskFlow-CLAP/TaskFlow-Server/blob/develop/.github/image/Sihun23.jpeg" width="150px" > | ![](사진) | <img src="https://github.com/TaskFlow-CLAP/TaskFlow-Server/blob/develop/.github/image/hyoseong.jpg" width="150px" > |
16+
| [Github](https://github.com/joowojr) | [Github](https://github.com/nano-mm) | [Github](https://github.com/parkjaehak) | [Github](https://github.com/Sihun23) | [Github](https://github.com/starboxxxx) | [Github](https://github.com/hyoseong-Choi) |
17+
18+
## ⚒️ Stack
19+
20+
21+
### Back-end
22+
<img src="https://img.shields.io/badge/Framework-555555?style=for-the-badge">![SpringBoot](https://img.shields.io/badge/springboot-%236DB33F.svg?style=for-the-badge&logo=springboot&logoColor=white)![spring_data_JPA](https://img.shields.io/badge/spring_data_JPA-%236DB33F?style=for-the-badge&logo=databricks&logoColor=white)![spring_security](https://img.shields.io/badge/spring_security-%236DB33F.svg?style=for-the-badge&logo=springsecurity&logoColor=white)
23+
24+
<img src="https://img.shields.io/badge/build-555555?style=for-the-badge">![Gradle](https://img.shields.io/badge/Gradle-02303A.svg?style=for-the-badge&logo=Gradle&logoColor=white)
25+
26+
<img src="https://img.shields.io/badge/Test-555555?style=for-the-badge">![junit5](https://img.shields.io/badge/junit5-25A162?style=for-the-badge&logo=junit5&logoColor=white)
27+
28+
<img src="https://img.shields.io/badge/Security-555555?style=for-the-badge">![JWT](https://img.shields.io/badge/json%20web%20tokens-323330?style=for-the-badge&logo=json-web-tokens&logoColor=pink)
29+
30+
31+
### DB
32+
<img src="https://img.shields.io/badge/DB Migration-555555?style=for-the-badge">![Flyway](https://img.shields.io/badge/Flyway-F7B500?style=for-the-badge&logo=flyway&logoColor=white)
33+
34+
### Infra
35+
<img src="https://img.shields.io/badge/CI/CD-555555?style=for-the-badge">![Docker](https://img.shields.io/badge/docker-%230db7ed.svg?style=for-the-badge&logo=docker&logoColor=white)![GitHub Actions](https://img.shields.io/badge/github%20actions-%232671E5.svg?style=for-the-badge&logo=githubactions&logoColor=white)
36+
37+
### Database
38+
<img src="https://img.shields.io/badge/Database-555555?style=for-the-badge">![MySQL](https://img.shields.io/badge/mysql-4479A1.svg?style=for-the-badge&logo=mysql&logoColor=white)![Redis](https://img.shields.io/badge/redis-%23DD0031.svg?style=for-the-badge&logo=redis&logoColor=white)![Elastic Search](https://img.shields.io/badge/Elastic_Search-005571?style=for-the-badge&logo=elasticsearch&logoColor=white)
39+
40+
## 🏗️ Architecture
41+
Coming Soon...
42+
43+
## 📍ERD
44+
![taskflow-erd.png](/.github/image/tf-erd.png)
45+
46+
47+
## Task Flow 아키텍쳐
48+
![taskflow-architecture.png](/.github/image/tf-architecture.png)
49+
50+
### 🔴 Domain
51+
52+
- 애플리케이션의 **핵심 비즈니스 로직**을 구현하는 계층입니다.
53+
- 모델과 비즈니스 규칙을 정의하여, 애플리케이션의 주요 기능을 수행하며 외부와 의존성이 없습니다.
54+
55+
---
56+
57+
### 🟢Application
58+
59+
- 비지니스 로직 **액션**을 담당하는 서비스 계층입니다.
60+
61+
<aside>
62+
➡️ Inbound Port
63+
64+
- 외부에서 입력을 받는 인커밍 역할 **Usecase**를 담당합니다.
65+
- Inbound adapter로 부터 입력받습니다.
66+
- 입력 유효성 검증을 하지 않고 그 책임은 오직 웹 계층에서 진행합니다.
67+
</aside>
68+
69+
<aside>
70+
➡️ Outbound Port
71+
72+
- adapter의 outbound로 가는 포트의 엳할을 합니다
73+
- Port 인터페이스를 통해 영속성 계층과 의존성 역전을 통해서 데이터를 저장, 조회, 목록조회 등 역할을 수행합니다.
74+
</aside>
75+
76+
---
77+
78+
### 🔵 Adapter
79+
80+
- 외부 요청을 내부로 전달하는 Inbound 어댑터와 내부 요청을 외부로 전달하는 Outbound 어댑터로 나뉩니다.
81+
- 애플리케이션의 핵심 로직과 외부 시스템 간의 통신을 중개하는 역할을 합니다.
82+
83+
<aside>
84+
➡️ Inbound Port
85+
86+
- **Web**
87+
- 사용자 인터페이스 또는 REST API를 처리하는 컨트롤러
88+
- 입력 유효성 검증을 진행
89+
</aside>
90+
91+
<aside>
92+
◀️ Outbound Port
93+
94+
- **Persistence**
95+
- 데이터베이스와의 상호작용을 위한 orm 데이터베이스 매핑 및 repository
96+
- **Api**
97+
- 외부 서비스와의 통신을 위한 클라이언트
98+
99+
- **Infrastructure**
100+
- 데이터베이스, 외부 API, 파일 시스템 등 외부 세계와의 연결을 처리
101+
- 다른 레이어에 대해 의존하지 않습니다.
102+
</aside>
103+
104+
105+
106+
## 🗂️ Package
107+
108+
```
109+
├── 💽 TaskflowApplication
110+
├── 🗂️adapter
111+
│   ├── 🗂️inbound
112+
│   │   └── 📂web
113+
│   │   ├── admin
114+
│   │   ├── auth
115+
│   │   └── dto
116+
│   │  
117+
│   └── 🗂️outbound
118+
│   ├── 📂api
119+
│   ├── 📂infrastructure
120+
│   └── 📂️security
121+
│   └── 📂persistense
122+
│   ├── entity
123+
│   │   ├── common
124+
│   │   ├── log
125+
│   │   ├── member
126+
│   │   ├── notification
127+
│   │   └── task
128+
│   ├── mapper
129+
│   │   └── common
130+
│   └── repository
131+
│   ├── log
132+
│   ├── member
133+
│   ├── notification
134+
│   └── task
135+
├── 🗂️application
136+
│   ├── 🗂️mapper
137+
│   └── 🗂️port
138+
│   ├── 📂inbound
139+
│   └── 📂outbound
140+
├── 🗂️common
141+
│   └── 🗂️annotation
142+
│   ├── 🗂️exception
143+
│   └── 🗂️response
144+
├── 🗂️config
145+
├── 🗂️domain
146+
│   ├── 🗂️model
147+
│      ├── 📂common
148+
│      ├── 📂log
149+
│      ├── 📂member
150+
│      ├── 📂notification
151+
│      └── 📂task
152+
└── 🗂️exception
153+
```
154+
155+
## 📜 Covention
156+
### Code Convetion
157+
158+
| Type | Naming Convention |
159+
|:----:|:---------------:|
160+
| Class | PascalCase |
161+
| Function | camelCase |
162+
| Variable | camelCase |
163+
| DB Table | snake_case |
164+
| ENUM, Constant | PascalCase |
165+
166+
### Prefix
167+
| Prefix | Description |
168+
|:------:|:----------:|
169+
| `feat` | 새로운 기능 구현 |
170+
| `fix` | 버그 수정 |
171+
| `refactor` | 코드 리팩토링 |
172+
| `chore` | 프로젝트 설정 수정 |
173+
| `docs` | 문서 수정 |
174+
| `infra` | 인프라 관련 작업 |
175+
| `hotfix` | 긴급 수정 작업 |
176+
177+
### Branch Naming
178+
<Jira_Issue_Number>
179+
180+
### Commit Message
181+
<Jira_Issue_Number> [Prefix] : <Description>

src/main/java/clap/server/adapter/inbound/web/dto/admin/RegisterMemberRequest.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,7 @@ public record RegisterMemberRequest(
1818
@NotNull
1919
MemberRole role,
2020
@NotBlank
21-
String departmentRole,
22-
@NotNull
23-
Long adminId
21+
String departmentRole
2422
) {
2523
}
2624

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
package clap.server.adapter.inbound.web.statistics;
2+
3+
import clap.server.application.port.inbound.statistics.CategoryTaskRequestUsecase;
4+
import clap.server.application.port.inbound.statistics.PeriodTaskProcessUsecase;
5+
import clap.server.application.port.inbound.statistics.PeriodTaskRequestUsecase;
6+
import clap.server.application.port.inbound.statistics.SubCategoryTaskRequestUsecase;
7+
import clap.server.common.annotation.architecture.WebAdapter;
8+
import lombok.RequiredArgsConstructor;
9+
import org.springframework.web.bind.annotation.GetMapping;
10+
import org.springframework.web.bind.annotation.RequestParam;
11+
12+
import java.util.Map;
13+
14+
@WebAdapter
15+
@RequiredArgsConstructor
16+
public class StatisticsFindController {
17+
private final PeriodTaskRequestUsecase periodTaskRequestUsecase;
18+
private final PeriodTaskProcessUsecase periodTaskProcessUsecase;
19+
private final CategoryTaskRequestUsecase categoryTaskRequestUsecase;
20+
private final SubCategoryTaskRequestUsecase subCategoryTaskRequestUsecase;
21+
// private final ManagerTaskProcessUsecase managerTaskProcessUsecase;
22+
23+
@GetMapping(value = "/task/statistics/task-requests-by-period")
24+
public Map<String, Long> aggregatePeriodTaskRequest(@RequestParam String period) {
25+
return periodTaskRequestUsecase.periodTaskRequestAggregate(period);
26+
}
27+
28+
@GetMapping("/task/statistics/task-processed-by-period")
29+
public Map<String, Long> aggregatePeriodTaskProcess(@RequestParam String period) {
30+
return periodTaskProcessUsecase.periodTaskProcessAggregate(period);
31+
}
32+
@GetMapping("/task/statistics/task-requests-by-category")
33+
public Map<String, Long> aggregateCategoryTaskRequest(@RequestParam String period) {
34+
return categoryTaskRequestUsecase.categoryTaskRequestAggregate(period);
35+
}
36+
37+
@GetMapping("/task/statistics/task-requests-by-subcategory")
38+
public Map<String, Long> aggregateSubCategoryTaskRequest(@RequestParam String period, @RequestParam String mainCategory) {
39+
return subCategoryTaskRequestUsecase.subCategoryTaskRequestAggregate(period, mainCategory);
40+
}
41+
// @GetMapping("/task/statistics/tasks-processed-by-manager")
42+
}

0 commit comments

Comments
 (0)