Add numerous new things
2 files changed, 9 insertions, 7 deletions
diff --git a/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListEditorPage.razor b/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListEditorPage.razor
index 5dfb2d6..d0f9b87 100644
--- a/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListEditorPage.razor
+++ b/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListEditorPage.razor
@@ -41,7 +41,8 @@ else
@policyEvent.content.ExpiryDateTime
</td>
<td>
- <button class="btn btn-danger" @* @onclick="async () => await RemovePolicyAsync(policyEvent)" *@>Remove</button>
+ <button class="btn" @* @onclick="async () => await RemovePolicyAsync(policyEvent)" *@>Edit</button>
+ @* <button class="btn btn-danger" $1$ @onclick="async () => await RemovePolicyAsync(policyEvent)" #1#>Remove</button> *@
</td>
</tr>
}
diff --git a/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListRoomList.razor b/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListRoomList.razor
index e9d1be4..f25fbae 100644
--- a/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListRoomList.razor
+++ b/MatrixRoomUtils.Web/Pages/PolicyList/PolicyListRoomList.razor
@@ -19,8 +19,13 @@ else
}
foreach (var s in PolicyRoomList)
{
- <a href="@(NavigationManager.Uri + "/" + s.RoomId.Replace('.', '~'))">[@s.Shortcode] @s.Name (@s.RoomId)</a>
- <br/>
+
+ <a style="color: unset; text-decoration: unset;" href="/PolicyListEditor/@s.RoomId.Replace('.','~')"><RoomListItem RoomId="@s.RoomId">
+ <br/>
+ <span>Shortcode: @s.Shortcode</span>
+ </RoomListItem></a>
+ @* <a href="@(NavigationManager.Uri + "/" + s.RoomId.Replace('.', '~'))">[@s.Shortcode] @s.Name (@s.RoomId)</a> *@
+ @* <br/> *@
}
}
@@ -74,15 +79,11 @@ else
{
try
{
- //TODO: refactor!!!!!
await semaphore.WaitAsync();
PolicyRoomInfo roomInfo = new()
{
RoomId = room
};
-
-
- // --- //
var r = await RuntimeCache.CurrentHomeServer.GetRoom(room);
var shortcodeState = await r.GetStateAsync("org.matrix.mjolnir.shortcode");
if(!shortcodeState.HasValue) return null;
|