[Fix][UI Next][V1.0.0-Alpha] Fix the cannot update tenant individually on user info site. (#9237)
parent
3e82312713
commit
0d0674df1f
|
|
@ -101,7 +101,7 @@ public class FileManageE2ETest {
|
||||||
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
||||||
new By.ByClassName("name")));
|
new By.ByClassName("name")));
|
||||||
|
|
||||||
userPage.update(user, user, password, email, phone, tenant)
|
userPage.update(user, user, email, phone, tenant)
|
||||||
.goToNav(ResourcePage.class)
|
.goToNav(ResourcePage.class)
|
||||||
.goToTab(FileManagePage.class);
|
.goToTab(FileManagePage.class);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -102,7 +102,7 @@ public class FunctionManageE2ETest {
|
||||||
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
||||||
new By.ByClassName("name")));
|
new By.ByClassName("name")));
|
||||||
|
|
||||||
UdfManagePage udfManagePage = userPage.update(user, user, password, email, phone, tenant)
|
UdfManagePage udfManagePage = userPage.update(user, user, email, phone, tenant)
|
||||||
.goToNav(ResourcePage.class)
|
.goToNav(ResourcePage.class)
|
||||||
.goToTab(UdfManagePage.class)
|
.goToTab(UdfManagePage.class)
|
||||||
.uploadFile(testUploadUdfFilePath.toFile().getAbsolutePath());
|
.uploadFile(testUploadUdfFilePath.toFile().getAbsolutePath());
|
||||||
|
|
|
||||||
|
|
@ -97,7 +97,7 @@ public class UdfManageE2ETest {
|
||||||
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
||||||
new By.ByClassName("name")));
|
new By.ByClassName("name")));
|
||||||
|
|
||||||
userPage.update(user, user, password, email, phone, tenant)
|
userPage.update(user, user, email, phone, tenant)
|
||||||
.goToNav(ResourcePage.class)
|
.goToNav(ResourcePage.class)
|
||||||
.goToTab(UdfManagePage.class);
|
.goToTab(UdfManagePage.class);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -122,7 +122,7 @@ class UserE2ETest {
|
||||||
|
|
||||||
browser.navigate().refresh();
|
browser.navigate().refresh();
|
||||||
|
|
||||||
page.update(user, editUser, editPassword, editEmail, editPhone, tenant);
|
page.update(user, editUser, editEmail, editPhone, tenant);
|
||||||
|
|
||||||
await().untilAsserted(() -> {
|
await().untilAsserted(() -> {
|
||||||
browser.navigate().refresh();
|
browser.navigate().refresh();
|
||||||
|
|
|
||||||
|
|
@ -74,7 +74,7 @@ class WorkflowE2ETest {
|
||||||
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
new WebDriverWait(userPage.driver(), 20).until(ExpectedConditions.visibilityOfElementLocated(
|
||||||
new By.ByClassName("name")));
|
new By.ByClassName("name")));
|
||||||
|
|
||||||
userPage.update(user, user, password, email, phone, tenant)
|
userPage.update(user, user, email, phone, tenant)
|
||||||
.goToNav(ProjectPage.class)
|
.goToNav(ProjectPage.class)
|
||||||
.create(project)
|
.create(project)
|
||||||
;
|
;
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,7 @@ public final class UserPage extends NavBarPage implements SecurityPage.Tab {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public UserPage update(String user, String editUser, String editPassword, String editEmail, String editPhone,
|
public UserPage update(String user, String editUser, String editEmail, String editPhone,
|
||||||
String tenant) {
|
String tenant) {
|
||||||
userList().stream()
|
userList().stream()
|
||||||
.filter(it -> it.findElement(By.className("name")).getAttribute("innerHTML").contains(user))
|
.filter(it -> it.findElement(By.className("name")).getAttribute("innerHTML").contains(user))
|
||||||
|
|
@ -97,8 +97,6 @@ public final class UserPage extends NavBarPage implements SecurityPage.Tab {
|
||||||
editUserForm().inputUserName().sendKeys(Keys.BACK_SPACE);
|
editUserForm().inputUserName().sendKeys(Keys.BACK_SPACE);
|
||||||
editUserForm().inputUserName().sendKeys(editUser);
|
editUserForm().inputUserName().sendKeys(editUser);
|
||||||
|
|
||||||
editUserForm().inputUserPassword().sendKeys(editPassword);
|
|
||||||
|
|
||||||
createUserForm().btnSelectTenantDropdown().click();
|
createUserForm().btnSelectTenantDropdown().click();
|
||||||
|
|
||||||
new WebDriverWait(driver, 5).until(ExpectedConditions.visibilityOfElementLocated(new By.ByClassName(
|
new WebDriverWait(driver, 5).until(ExpectedConditions.visibilityOfElementLocated(new By.ByClassName(
|
||||||
|
|
|
||||||
|
|
@ -112,6 +112,8 @@ export const UserModal = defineComponent({
|
||||||
placeholder={t('security.user.username_tips')}
|
placeholder={t('security.user.username_tips')}
|
||||||
/>
|
/>
|
||||||
</NFormItem>
|
</NFormItem>
|
||||||
|
{
|
||||||
|
!this.currentRecord?.id && (
|
||||||
<NFormItem
|
<NFormItem
|
||||||
label={t('security.user.user_password')}
|
label={t('security.user.user_password')}
|
||||||
path='userPassword'
|
path='userPassword'
|
||||||
|
|
@ -123,6 +125,8 @@ export const UserModal = defineComponent({
|
||||||
placeholder={t('security.user.user_password_tips')}
|
placeholder={t('security.user.user_password_tips')}
|
||||||
/>
|
/>
|
||||||
</NFormItem>
|
</NFormItem>
|
||||||
|
)
|
||||||
|
}
|
||||||
{this.IS_ADMIN && (
|
{this.IS_ADMIN && (
|
||||||
<NFormItem label={t('security.user.tenant_code')} path='tenantId'>
|
<NFormItem label={t('security.user.tenant_code')} path='tenantId'>
|
||||||
<NSelect
|
<NSelect
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue