为旅拍 OTG 上传增加 client_photo_id,并按服务端已登记 ID 同步本地上传状态。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-07-16 19:13:19 +08:00
parent 3d5ad8a614
commit b019e1e494
11 changed files with 323 additions and 115 deletions

View File

@ -32,6 +32,9 @@ protocol TravelAlbumServing {
///
func uploadMaterial(_ request: TravelAlbumUploadMaterialRequest) async throws -> TravelAlbumMaterial
/// ID
func materialClientPhotoIds(userEquityTravelId: Int) async throws -> TravelAlbumMaterialClientPhotoIDsResponse
///
func deleteAlbum(id: Int) async throws
@ -115,6 +118,19 @@ final class TravelAlbumAPI: TravelAlbumServing {
try await client.send(APIRequest(method: .post, path: "\(basePath)/upload-material", body: request))
}
/// ID
func materialClientPhotoIds(userEquityTravelId: Int) async throws -> TravelAlbumMaterialClientPhotoIDsResponse {
try await client.send(
APIRequest(
method: .get,
path: "\(basePath)/material-client-photo-ids",
queryItems: [
URLQueryItem(name: "user_equity_travel_id", value: String(userEquityTravelId)),
]
)
)
}
///
func deleteAlbum(id: Int) async throws {
let _: EmptyPayload = try await client.send(