Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
fix functional test, update documentations
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Eng committed Nov 26, 2015
1 parent 92bc299 commit 57e078e
Show file tree
Hide file tree
Showing 11 changed files with 48 additions and 9 deletions.
Binary file modified docs/images/language-add-member.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/language-cancel-request.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/language-leave-team.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/language-request-accept.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/language-request-decline.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/language-request-join-menu.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/language-request-join.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/language-request-tab.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 25 additions & 1 deletion docs/user-guide/languages/add-team-member.md
@@ -1,4 +1,28 @@
This is only available to language coordinator. To add team member:
This is only available to language coordinator.

## Action on request from user

While signed-in as language coordinator

1. Click on the request link sent in request email or
1. Go to language team page via `Languages` tab.
1. Click on `Requests` tab on the page to see all pending request from users.
<figure>
![language requests tab](/images/language-request-tab.png)
</figure>
1. To accept request, click on `Accept` button. You can add in more role for the user once request accepted.
<figure>
![language requests accept](/images/language-request-accept.png)
</figure>

1. To decline request, click on `Decline` button. Fill in the decline reason and click `Decline request` button.
<figure>
![language requests accept](/images/language-request-decline.png)
</figure>



## Manual search and add team member

While signed-in as language coordinator

Expand Down
18 changes: 14 additions & 4 deletions docs/user-guide/languages/language-team.md
Expand Up @@ -6,23 +6,33 @@ Translators can also join a [project team](/user-guide/projects/project-team/) s

------------

## Join a Language Team
## Request to join Language Team

While signed-in, translators can join a Language Team by completing the following:

1. Click `Languages` tab.
1. Click the language team you want to join.
1. Click on `More Action` menu on top right panel, select `Request to Join Team`.
1. Click on `Request To Join` button on the left side panel under language details.
<figure>
![Request to join menu](/images/language-request-join-menu.png)
</figure>
<br/>
1. In the dialog, select roles you wish to be added as, fill in some information for language team coordinator and click `Send`.
1. In the dialog, fill in some information of introduction and click `Send request`.
<figure>
![Request to join](/images/language-request-join.png)
</figure>
<br/>

## Cancel request to join Language Team

1. Click `Languages` tab.
1. Click the language team you want to cancel your request.
1. Click on `Cancel request` on the left side panel under language details.
<figure>
![cancel request](/images/language-cancel-request.png)
</figure>


------------

## Leaving a Language Team
Expand All @@ -31,7 +41,7 @@ While signed-in, translators can leave a Language Team by completing the followi

1. Click `Language` tab.
1. Click the language team you want to leave.
1. Click on `More Action` menu on top right panel, select `Leave Language Team`.
1. Click on `Leave Team` button on the left side panel under language details.

![Request to leave](/images/language-leave-team.png)

Expand Down
Expand Up @@ -178,13 +178,18 @@ private LanguagePage clickAddUserRoles(final String username, TeamPermission...
waitForAMoment().until(new Predicate<WebDriver>() {
@Override
public boolean apply(@Nullable WebDriver webDriver) {
WebElement input = getSearchedForUser(username)
WebElement inputDiv = getSearchedForUser(username)
.findElement(By.className("list--horizontal"))
.findElements(By.tagName("li"))
.get(permission.columnIndex)
.findElement(By.tagName("input"));
.findElement(By.className("form__checkbox"));
WebElement input =
inputDiv.findElement(By.tagName("input"));
Checkbox checkbox = Checkbox.of(input);
checkbox.check();
if (!checkbox.checked()) {
inputDiv.click();
waitForPageSilence();
}
return checkbox.checked();
}
});
Expand Down Expand Up @@ -226,7 +231,7 @@ public WebElement apply(WebDriver input) {

private String getListItemUsername(WebElement listItem) {
String fullname = listItem.findElements(
By.className("bx--inline-block"))
By.className("g__item"))
.get(0).getText();
return fullname.substring(fullname.indexOf('[') + 1, fullname.indexOf(']'));
}
Expand Down

0 comments on commit 57e078e

Please sign in to comment.