|
5 | 5 |
|
6 | 6 | @if (ShowPageSizeInput) |
7 | 7 | { |
8 | | - <PageSizeComponent PageSizeCallback="UpdatePageSize"></PageSizeComponent> |
| 8 | + <PageSizeComponent PageSizeCallback="UpdatePageSize"></PageSizeComponent> |
9 | 9 | } |
10 | 10 | <Table class="table table-bordered th-bg-secondary sticky-header show-scrollbar table-responsive" TableItem="ModellingConnection" |
11 | 11 | Items="Connections" PageSize="PageSize" ColumnReorder="true" TableRowClass="@(con => getTableRowClass(con))" |
12 | 12 | SelectedItems="SelectedConns" RowClickAction="@(conn => ToggleSelection(conn))"> |
13 | 13 | @if (!Readonly && !SelectInterfaceView && AppHandler != null) |
14 | 14 | { |
15 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("actions"))" Field="(x => x.Id)" Sortable="false" Filterable="false"> |
16 | | - <Template> |
17 | | - <div class="btn-group"> |
18 | | - <button type="button" class="btn btn-sm btn-primary" @onclick="async () => |
| 15 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("actions"))" Field="(x => x.Id)" Sortable="false" Filterable="false"> |
| 16 | + <Template> |
| 17 | + <div class="btn-group"> |
| 18 | + <button type="button" class="btn btn-sm btn-primary" @onclick="async () => |
19 | 19 | { await AppHandler.ShowDetails(context); await AppHandlerChanged.InvokeAsync(AppHandler); }"> |
20 | 20 | @(AppHandler.DisplayButton("details", Icons.Display)) |
21 | | - </button> |
| 21 | + </button> |
22 | 22 | @if (AppActive) |
23 | 23 | { |
24 | 24 | @if (!context.GetBoolProperty(ConState.InterfaceRejected.ToString()) && !context.GetBoolProperty(ConState.Rejected.ToString())) |
25 | 25 | { |
26 | | - <button type="button" class="btn btn-sm btn-warning" @onclick="async () => |
| 26 | + <button type="button" class="btn btn-sm btn-warning" @onclick="async () => |
27 | 27 | { await AppHandler.EditConn(context); await AppHandlerChanged.InvokeAsync(AppHandler); }"> |
28 | 28 | @(AppHandler.DisplayButton("edit", Icons.Edit)) |
29 | | - </button> |
| 29 | + </button> |
30 | 30 | } |
31 | | - <button type="button" class="btn btn-sm btn-danger" @onclick="async () => |
| 31 | + <button type="button" class="btn btn-sm btn-danger" @onclick="async () => |
32 | 32 | { await AppHandler.RequestDeleteConnection(context); await AppHandlerChanged.InvokeAsync(AppHandler); }"> |
33 | 33 | @(AppHandler.DisplayButton("delete", Icons.Delete)) |
34 | | - </button> |
| 34 | + </button> |
35 | 35 | } |
36 | | - </div> |
37 | | - </Template> |
38 | | - </Column> |
| 36 | + </div> |
| 37 | + </Template> |
| 38 | + </Column> |
39 | 39 | } |
40 | 40 | @if (ShowSelectionColumn) |
41 | 41 | { |
42 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("select"))" Sortable="false" Filterable="false"> |
43 | | - <Template> |
| 42 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("select"))" Sortable="false" Filterable="false"> |
| 43 | + <Template> |
44 | 44 | @if (SelectionType == SelectionType.Single) |
45 | 45 | { |
46 | | - <input type="radio" checked="@(SelectedConns.Contains(context))" /> |
| 46 | + <input type="radio" checked="@(SelectedConns.Contains(context))" /> |
47 | 47 | } |
48 | 48 | else if (SelectionType == SelectionType.Multiple) |
49 | 49 | { |
50 | | - <input type="checkbox" checked="@(SelectedConns.Contains(context))" /> |
| 50 | + <input type="checkbox" checked="@(SelectedConns.Contains(context))" /> |
51 | 51 | } |
52 | | - </Template> |
53 | | - </Column> |
| 52 | + </Template> |
| 53 | + </Column> |
54 | 54 | } |
55 | 55 | <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("id"))" Field="@(x => x.Id)" Sortable="true" Filterable="true" /> |
56 | 56 | @if (!SelectInterfaceView) |
57 | 57 | { |
58 | 58 | @if (Connections.Count > 0 && Connections.First().IsInterface) |
59 | 59 | { |
60 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("published"))" Field="@(x => x.IsPublished)" Sortable="true" Filterable="true"> |
61 | | - <Template> |
62 | | - @(context.IsPublished.ShowAsHtml()) |
63 | | - </Template> |
64 | | - </Column> |
65 | | - } |
66 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("state"))" Field="@(x => x.Id)" Sortable="true" Filterable="false"> |
| 60 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("published"))" Field="@(x => x.IsPublished)" Sortable="true" Filterable="true"> |
67 | 61 | <Template> |
68 | | - @((MarkupString)DisplayState(context)) |
| 62 | + @(context.IsPublished.ShowAsHtml()) |
69 | 63 | </Template> |
70 | 64 | </Column> |
| 65 | + } |
| 66 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("state"))" Field="@(x => x.Id)" Sortable="true" Filterable="false"> |
| 67 | + <Template> |
| 68 | + @((MarkupString)DisplayState(context)) |
| 69 | + </Template> |
| 70 | + </Column> |
71 | 71 | } |
72 | 72 | @if (ShowAppName) |
73 | 73 | { |
74 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("owner"))" Field="@(x => x.App.Name)" Sortable="true" Filterable="true"> |
75 | | - <Template> |
| 74 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("owner"))" Field="@(x => x.App.Name)" Sortable="true" Filterable="true"> |
| 75 | + <Template> |
76 | 76 | @(context.App?.DisplayWithoutAppId(userConfig.GetText("common_service"))) |
77 | | - </Template> |
78 | | - </Column> |
79 | | - <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("ext_app_id"))" Field="@(x => x.App.ExtAppId)" Sortable="true" Filterable="true"> |
80 | | - <Template> |
| 77 | + </Template> |
| 78 | + </Column> |
| 79 | + <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("ext_app_id"))" Field="@(x => x.App.ExtAppId)" Sortable="true" Filterable="true"> |
| 80 | + <Template> |
81 | 81 | @(context.App?.ExtAppId) |
82 | | - </Template> |
83 | | - </Column> |
| 82 | + </Template> |
| 83 | + </Column> |
84 | 84 | } |
85 | 85 | <Column TableItem="ModellingConnection" Title="@(userConfig.GetText("name"))" Field="@(x => x.Name)" Sortable="true" Filterable="true"> |
86 | 86 | <Template> |
@@ -161,7 +161,7 @@ SelectedItems="SelectedConns" RowClickAction="@(conn => ToggleSelection(conn))"> |
161 | 161 |
|
162 | 162 | [Parameter] |
163 | 163 | public EventCallback<int> PageSizeCallback { get; set; } |
164 | | - |
| 164 | + |
165 | 165 | [Parameter] |
166 | 166 | public bool ShowPageSizeInput { get; set; } = false; |
167 | 167 |
|
@@ -234,6 +234,9 @@ SelectedItems="SelectedConns" RowClickAction="@(conn => ToggleSelection(conn))"> |
234 | 234 | case nameof(ConState.DeletedObjects): |
235 | 235 | relevantProps.Add($"<span class=\"text-warning\" data-toggle=\"tooltip\" title=\"{(connection.IsInterface ? userConfig.PureLine("C9016") : userConfig.PureLine("C9014"))}\">!</span>"); |
236 | 236 | break; |
| 237 | + case nameof(ConState.EmptySvcGrps): |
| 238 | + relevantProps.Add($"<span class=\"text-warning\" data-toggle=\"tooltip\" title=\"{( connection.IsInterface ? userConfig.PureLine("C9019") : userConfig.PureLine("C9018") )}\">!</span>"); |
| 239 | + break; |
237 | 240 | default: |
238 | 241 | break; |
239 | 242 | } |
|
0 commit comments