128 lines
5.0 KiB
Plaintext
128 lines
5.0 KiB
Plaintext
|
|
<button @onclick="()=>doSave()">Save</button>
|
|
|
|
<div class="d-flex justify-content-between my-2">
|
|
<div class="col-5 text-center fw-bold border border-secondary rounded d-flex justify-content-between">
|
|
<div>
|
|
@*@if (files2Chk != null && files2Chk.Count() > 0)
|
|
{
|
|
<button class="btn btn-info">Scan again</button>
|
|
}*@
|
|
</div>
|
|
<div>Candidate</div>
|
|
<div></div>
|
|
</div>
|
|
<div class="col-2 text-center"><button class="btn btn-dark" @onclick="()=>doScan()">Scan Dir New</button></div>
|
|
<div class="col-5 text-center fw-bold border border-secondary rounded d-flex justify-content-between">
|
|
<div></div>
|
|
<div>Current</div>
|
|
<div>
|
|
@*@if (files2Chk != null && files2Chk.Count() > 0)
|
|
{
|
|
<button class="btn btn-info">Scan again</button>
|
|
}*@
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@if (isLoading)
|
|
{
|
|
<ProgressDisplay Title="@titleMsg" CurrVal="@sendDataVal" MaxVal="@sendDataMaxVal" ExpTimeMSec="1000"></ProgressDisplay>
|
|
}
|
|
else if (files2Chk != null && files2Chk.Count() > 0)
|
|
{
|
|
<table class="table table-striped">
|
|
<thead>
|
|
<tr>
|
|
<th></th>
|
|
<th>Type</th>
|
|
<th>Template Folder</th>
|
|
<th>Template Name</th>
|
|
<th class="text-start">
|
|
<input class="form-check-input mt-0" type="checkbox" value="" aria-label="Select or Unselect all" @bind="@selUns">
|
|
</th>
|
|
<th>Type</th>
|
|
<th>Template Folder</th>
|
|
<th>Template Name</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach (var item in files2Chk)
|
|
{
|
|
<tr>
|
|
<td>
|
|
@if (item.Value.status == Core.Enum.fileStatus.mod)
|
|
{
|
|
<button class="btn btn-sm btn-info" data-bs-toggle="modal" data-bs-target="#fileDiffModal" @onclick="()=>showDiff(item)"><i class="fa-solid fa-magnifying-glass"></i></button>
|
|
}
|
|
else
|
|
{
|
|
<button class="btn btn-sm btn-secondary" disabled><i class="fa-solid fa-magnifying-glass"></i></button>
|
|
}
|
|
</td>
|
|
@if (item.Value.status == Core.Enum.fileStatus.add || item.Value.status == Core.Enum.fileStatus.mod)
|
|
{
|
|
<td>
|
|
@item.Key.Split("\\")[0]
|
|
</td>
|
|
<td>
|
|
@item.Key.Split("\\")[1]
|
|
</td>
|
|
<td>
|
|
@item.Key.Split("\\")[2]
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
}
|
|
<td class="text-start">
|
|
<button class="btn @btnCssClass(item.Value.status, item.Value.action)" @onclick="()=>changeDoAct(item)">@btnTxt(item.Value.status) <i class="@btnIcon(item.Value.status)"></i></button>
|
|
</td>
|
|
@if (item.Value.status == Core.Enum.fileStatus.rem || item.Value.status == Core.Enum.fileStatus.mod)
|
|
{
|
|
<td>
|
|
@item.Key.Split("\\")[0]
|
|
</td>
|
|
<td>
|
|
@item.Key.Split("\\")[1]
|
|
</td>
|
|
<td>
|
|
@item.Key.Split("\\")[2]
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
}
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
}
|
|
|
|
<!-- Modal -->
|
|
<div class="modal fade" id="fileDiffModal" tabindex="-1" aria-labelledby="fileDiffModalLabel" aria-hidden="true">
|
|
<div class="modal-dialog" style="min-width: 90%;">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<h1 class="modal-title fs-5" id="fileDiffModalLabel">Modal title</h1>
|
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
|
</div>
|
|
<div class="modal-body">
|
|
<DiffView oldText="@txt1" newText="@txt2"></DiffView>
|
|
</div>
|
|
<div class="modal-footer">
|
|
@if (actFile.Key != null)
|
|
{
|
|
<button class="btn @btnCssClass(actFile.Value.status, actFile.Value.action)" @onclick="()=>changeDoAct(actFile)">@btnTxt(actFile.Value.status) <i class="@btnIcon(actFile.Value.status)"></i></button>
|
|
}
|
|
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|