-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from upwork/v1.2.3
v1.3.0
- Loading branch information
Showing
13 changed files
with
24 additions
and
183 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ant test |
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
Binary file not shown.
Binary file not shown.
Binary file not shown.
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 |
---|---|---|
|
@@ -28,7 +28,7 @@ | |
author = "Maksym Novozhylov <[email protected]>", | ||
date = "6/4/2014", | ||
currentRevision = 1, | ||
lastModified = "6/4/2014", | ||
lastModified = "24/5/2014", | ||
lastModifiedBy = "Maksym Novozhylov", | ||
reviewers = {"Yiota Tsakiri"} | ||
) | ||
|
@@ -43,56 +43,16 @@ public Snapshot(OAuthClient client) { | |
oClient.setEntryPoint(ENTRY_POINT); | ||
} | ||
|
||
/** | ||
* Get snapshot info | ||
* | ||
* @param company Company | ||
* @param username Username | ||
* @param ts Timestamp | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject get(String company, String username, String ts) throws JSONException { | ||
return oClient.get("/team/v1/snapshots/" + company + "/" + username + "/" + ts); | ||
} | ||
|
||
/** | ||
* Update snapshot | ||
* | ||
* @param company Company | ||
* @param username Username | ||
* @param ts Timestamp | ||
* @param params Parameters | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject update(String company, String username, String ts, HashMap<String, String> params) throws JSONException { | ||
return oClient.put("/team/v1/snapshots/" + company + "/" + username + "/" + ts, params); | ||
} | ||
|
||
/** | ||
* Delete snapshot | ||
* | ||
* @param company Company | ||
* @param username Username | ||
* @param ts Timestamp | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject delete(String company, String username, String ts) throws JSONException { | ||
return oClient.delete("/team/v1/snapshots/" + company + "/" + username + "/" + ts); | ||
} | ||
|
||
/** | ||
* Get snapshot info by specific contract | ||
* | ||
* @param contractId Contract ID | ||
* @param ts Timestamp | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject getByContract(String contractId, String ts) throws JSONException { | ||
return oClient.get("/team/v2/snapshots/contracts/" + contractId + "/" + ts); | ||
return oClient.get("/team/v3/snapshots/contracts/" + contractId + "/" + ts); | ||
} | ||
|
||
/** | ||
|
@@ -102,10 +62,10 @@ public JSONObject getByContract(String contractId, String ts) throws JSONExcepti | |
* @param ts Timestamp | ||
* @param params Parameters | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject updateByContract(String contractId, String ts, HashMap<String, String> params) throws JSONException { | ||
return oClient.put("/team/v2/snapshots/contracts/" + contractId + "/" + ts, params); | ||
return oClient.put("/team/v3/snapshots/contracts/" + contractId + "/" + ts, params); | ||
} | ||
|
||
/** | ||
|
@@ -114,10 +74,10 @@ public JSONObject updateByContract(String contractId, String ts, HashMap<String, | |
* @param contractId Contract ID | ||
* @param ts Timestamp | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject deleteByContract(String contractId, String ts) throws JSONException { | ||
return oClient.delete("/team/v2/snapshots/contracts/" + contractId + "/" + ts); | ||
return oClient.delete("/team/v3/snapshots/contracts/" + contractId + "/" + ts); | ||
} | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -28,7 +28,7 @@ | |
author = "Maksym Novozhylov <[email protected]>", | ||
date = "14/7/2015", | ||
currentRevision = 1, | ||
lastModified = "14/7/2015", | ||
lastModified = "24/5/2018", | ||
lastModifiedBy = "Maksym Novozhylov", | ||
reviewers = {"Yiota Tsakiri"} | ||
) | ||
|
@@ -54,7 +54,7 @@ public Workdays(OAuthClient client) { | |
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject getByCompany(String company, String fromDate, String tillDate, HashMap<String, String> params) throws JSONException { | ||
return oClient.get("/team/v2/workdays/companies/" + company + "/" + fromDate + "," + tillDate, params); | ||
return oClient.get("/team/v3/workdays/companies/" + company + "/" + fromDate + "," + tillDate, params); | ||
} | ||
|
||
/** | ||
|
@@ -68,7 +68,7 @@ public JSONObject getByCompany(String company, String fromDate, String tillDate, | |
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject getByContract(String contract, String fromDate, String tillDate, HashMap<String, String> params) throws JSONException { | ||
return oClient.get("/team/v2/workdays/contracts/" + contract + "/" + fromDate + "," + tillDate, params); | ||
return oClient.get("/team/v3/workdays/contracts/" + contract + "/" + fromDate + "," + tillDate, params); | ||
} | ||
|
||
} | ||
} |
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 |
---|---|---|
|
@@ -28,7 +28,7 @@ | |
author = "Maksym Novozhylov <[email protected]>", | ||
date = "6/3/2014", | ||
currentRevision = 1, | ||
lastModified = "6/3/2014", | ||
lastModified = "24/5/2018", | ||
lastModifiedBy = "Maksym Novozhylov", | ||
reviewers = {"Yiota Tsakiri"} | ||
) | ||
|
@@ -47,14 +47,13 @@ public Workdiary(OAuthClient client) { | |
* Get Workdiary | ||
* | ||
* @param company Company ID | ||
* @param username User ID | ||
* @param date Date | ||
* @param params (Optional) Parameters | ||
* @throws JSONException If error occurred | ||
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject get(String company, String username, String date, HashMap<String, String> params) throws JSONException { | ||
return oClient.get("/team/v1/workdiaries/" + company + "/" + username + "/" + date, params); | ||
public JSONObject get(String company, String date, HashMap<String, String> params) throws JSONException { | ||
return oClient.get("/team/v3/workdiaries/companies/" + company + "/" + date, params); | ||
} | ||
|
||
/** | ||
|
@@ -67,7 +66,7 @@ public JSONObject get(String company, String username, String date, HashMap<Stri | |
* @return {@link JSONObject} | ||
*/ | ||
public JSONObject getByContract(String contract, String date, HashMap<String, String> params) throws JSONException { | ||
return oClient.get("/team/v2/workdiaries/contracts/" + contract + "/" + date, params); | ||
return oClient.get("/team/v3/workdiaries/contracts/" + contract + "/" + date, params); | ||
} | ||
|
||
} |
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 was deleted.
Oops, something went wrong.
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