Implemented input disable on closed tickets for users

This commit is contained in:
Marcel Baumgartner 2024-01-08 08:32:39 +01:00
parent a2a9a6e21d
commit f17ff9246d

View file

@ -66,19 +66,31 @@
<div class="card-footer">
<div class="row">
<div class="input-group">
@if (HasStarted && TicketService.Chat.Ticket.Open)
{
<textarea @bind="MessageContent" class="form-control form-control-solid-bg rounded-end me-3" placeholder="Type a message" style="height: 1vh"></textarea>
<ChatFileSelect @ref="FileSelect"/>
<WButton OnClick="SendMessage" CssClasses="ms-2 btn btn-icon btn-bg-light btn-color-white">
<i class="bx bx-sm bx-send"></i>
</WButton>
}
else
{
<textarea @bind="MessageContent" class="form-control form-control-solid-bg rounded-end me-3 disabled" disabled="disabled" placeholder="Type a message" style="height: 1vh"></textarea>
<label class="btn btn-icon btn-bg-light btn-color-primary rounded-start rounded-end disabled" disabled="">
<i class="bx bx-sm bx-upload"></i>
</label>
<button class="ms-2 btn btn-icon btn-bg-light btn-color-white disabled" disabled="disabled">
<i class="bx bx-sm bx-send"></i>
</button>
}
</div>
</div>
</div>
@code
{
[CascadingParameter]
public TicketPopupMain TicketPopupMain { get; set; }
[CascadingParameter] public TicketPopupMain TicketPopupMain { get; set; }
private bool HasStarted = false;