mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-09 06:55:47 +01:00
Move advanced button to new column
This commit is contained in:
@@ -3,6 +3,9 @@
|
|||||||
"submit-button": {
|
"submit-button": {
|
||||||
"label": "Set permissions"
|
"label": "Set permissions"
|
||||||
},
|
},
|
||||||
|
"advanced-button": {
|
||||||
|
"label": "Advanced"
|
||||||
|
},
|
||||||
"set-permissions-successful": "Permissions set successfully"
|
"set-permissions-successful": "Permissions set successfully"
|
||||||
},
|
},
|
||||||
"advanced": {
|
"advanced": {
|
||||||
|
|||||||
@@ -148,6 +148,7 @@ class Permissions extends React.Component<Props> {
|
|||||||
</th>
|
</th>
|
||||||
<th>{t("permission.type")}</th>
|
<th>{t("permission.type")}</th>
|
||||||
<th />
|
<th />
|
||||||
|
<th />
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
|||||||
@@ -91,12 +91,19 @@ class SinglePermission extends React.Component<Props, State> {
|
|||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { role, permission, showAdvancedDialog } = this.state;
|
const { role, permission, showAdvancedDialog } = this.state;
|
||||||
const { availablePermissions, loading, namespace, repoName } = this.props;
|
const {
|
||||||
|
t,
|
||||||
|
availablePermissions,
|
||||||
|
loading,
|
||||||
|
namespace,
|
||||||
|
repoName
|
||||||
|
} = this.props;
|
||||||
const availableRoleNames = availablePermissions.availableRoles.map(
|
const availableRoleNames = availablePermissions.availableRoles.map(
|
||||||
r => r.name
|
r => r.name
|
||||||
);
|
);
|
||||||
const typeSelector =
|
const typeSelector =
|
||||||
this.props.permission._links && this.props.permission._links.update ? (
|
this.props.permission._links && this.props.permission._links.update ? (
|
||||||
|
<>
|
||||||
<td>
|
<td>
|
||||||
<TypeSelector
|
<TypeSelector
|
||||||
handleTypeChange={this.handleTypeChange}
|
handleTypeChange={this.handleTypeChange}
|
||||||
@@ -104,13 +111,19 @@ class SinglePermission extends React.Component<Props, State> {
|
|||||||
type={role}
|
type={role}
|
||||||
loading={loading}
|
loading={loading}
|
||||||
/>
|
/>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
<Button
|
<Button
|
||||||
label={"..."}
|
label={t("form.advanced-button.label")}
|
||||||
action={this.handleDetailedPermissionsPressed}
|
action={this.handleDetailedPermissionsPressed}
|
||||||
/>
|
/>
|
||||||
</td>
|
</td>
|
||||||
|
</>
|
||||||
) : (
|
) : (
|
||||||
|
<>
|
||||||
<td>{role}</td>
|
<td>{role}</td>
|
||||||
|
<td />
|
||||||
|
</>
|
||||||
);
|
);
|
||||||
|
|
||||||
const advancedDialg = showAdvancedDialog ? (
|
const advancedDialg = showAdvancedDialog ? (
|
||||||
|
|||||||
Reference in New Issue
Block a user