添加位置上报地图页和历史列表并对齐 Android
This commit is contained in:
@ -64,6 +64,36 @@ final class HomeAPI {
|
||||
)
|
||||
}
|
||||
|
||||
/// 拉取位置上报历史列表。
|
||||
func locationReportList(
|
||||
staffId: String,
|
||||
page: Int,
|
||||
pageSize: Int,
|
||||
type: Int,
|
||||
startDate: String?,
|
||||
endDate: String?
|
||||
) async throws -> LocationReportHistoryListResponse {
|
||||
var queryItems = [
|
||||
URLQueryItem(name: "staff_id", value: staffId),
|
||||
URLQueryItem(name: "page", value: String(page)),
|
||||
URLQueryItem(name: "page_size", value: String(pageSize)),
|
||||
URLQueryItem(name: "type", value: String(type)),
|
||||
]
|
||||
if let startDate, !startDate.isEmpty {
|
||||
queryItems.append(URLQueryItem(name: "start_date", value: startDate))
|
||||
}
|
||||
if let endDate, !endDate.isEmpty {
|
||||
queryItems.append(URLQueryItem(name: "end_date", value: endDate))
|
||||
}
|
||||
return try await client.send(
|
||||
APIRequest(
|
||||
method: .get,
|
||||
path: "/api/yf-handset-app/photog/loacation/list",
|
||||
queryItems: queryItems
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
/// 拉取待审核权限申请列表。
|
||||
func roleApplyPending() async throws -> [RoleApplyPendingResponse] {
|
||||
try await client.send(
|
||||
|
||||
Reference in New Issue
Block a user