-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add
Retrieve a Users Locked Tasks
endpoint (#1139)
* add `Retrieve Users Locked Tasks` endpoint * format and remove unused code * fix imports * include challenge id in object * simplify parser and LockedTaskData object * add more descriptions and simplify queries and parses * fix descriptions * fix file name
- Loading branch information
1 parent
5949dc0
commit 9dc82e6
Showing
5 changed files
with
124 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (C) 2020 MapRoulette contributors (see CONTRIBUTORS.md). | ||
* Licensed under the Apache License, Version 2.0 (see LICENSE). | ||
*/ | ||
package org.maproulette.framework.model | ||
|
||
import org.joda.time.DateTime | ||
import play.api.libs.json.{Format, Json} | ||
import play.api.libs.json.JodaWrites._ | ||
import play.api.libs.json.JodaReads._ | ||
|
||
/** | ||
* Mapping of object structure for fetching task lock data | ||
*/ | ||
case class LockedTaskData( | ||
id: Long, | ||
parent: Long, | ||
parentName: String, | ||
/** | ||
* The time that the task was locked | ||
*/ | ||
startedAt: DateTime | ||
) | ||
|
||
// Define implicit Formats for LockedTaskData | ||
object LockedTaskData { | ||
implicit val lockedTaskDataFormat: Format[LockedTaskData] = Json.format[LockedTaskData] | ||
} |
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
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