-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into feature/my-page-flow
- Loading branch information
Showing
19 changed files
with
433 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
Segno/Segno/Data/Network/Endpoints/DiaryPostEndpoint.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// | ||
// DiaryPostEndpoint.swift | ||
// Segno | ||
// | ||
// Created by TaehoYoo on 2022/11/27. | ||
// | ||
|
||
import Foundation | ||
|
||
enum DiaryPostEndpoint: Endpoint { | ||
case item(DiaryDetail) | ||
|
||
var baseURL: URL? { | ||
return URL(string: BaseURL.urlString) | ||
} | ||
|
||
var httpMethod: HTTPMethod { | ||
return .GET | ||
} | ||
|
||
var path: String { | ||
return "diary" | ||
} | ||
|
||
var parameters: HTTPRequestParameter? { | ||
switch self { | ||
case .item(let diary): | ||
return HTTPRequestParameter.body(diary) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// | ||
// ImageEndpoint.swift | ||
// Segno | ||
// | ||
// Created by TaehoYoo on 2022/11/27. | ||
// | ||
|
||
import Foundation | ||
|
||
enum ImageEndpoint: Endpoint { | ||
case item(Data) | ||
|
||
var baseURL: URL? { | ||
return URL(string: BaseURL.urlString) | ||
} | ||
|
||
var httpMethod: HTTPMethod { | ||
return .POST | ||
} | ||
|
||
var path: String { | ||
return "image" | ||
} | ||
|
||
var parameters: HTTPRequestParameter? { | ||
switch self { | ||
case .item(let image): | ||
return HTTPRequestParameter.data(image) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// | ||
// ImageDTO.swift | ||
// Segno | ||
// | ||
// Created by TaehoYoo on 2022/11/27. | ||
// | ||
|
||
struct ImageDTO: Decodable { | ||
let filename: String? | ||
} |
Oops, something went wrong.