- Fix aggiunta anta
- Modificata navigazione tra le tab
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Version>2.7.8.812</Version>
|
||||
<Version>2.7.8.817</Version>
|
||||
<Authors>Annamaria Sassi</Authors>
|
||||
<Company>Egalware</Company>
|
||||
<Description>Componente gestione JWD per LUX</Description>
|
||||
@@ -43,5 +43,23 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,254 +1,144 @@
|
||||
|
||||
<div class="row">
|
||||
<div class="@mainCss">
|
||||
<div class="card text-center table-svg">
|
||||
<div class="card-header" style="background-color: #d5f1f2;">
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<ul class="nav nav-tabs card-header-tabs">
|
||||
<li class="nav-item">
|
||||
@if (currStep == CompileStep.Template)
|
||||
{
|
||||
<a data-target="#Template" class="nav-link active fw-bold" aria-current="true" @onclick="() => AdvStep(CompileStep.Template)">Template</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<a data-target="#Template" class="nav-link text-secondary" @onclick="() => AdvStep(CompileStep.Template)">Template</a>
|
||||
}
|
||||
</li>
|
||||
@if (SelTemplateDTO != null)
|
||||
{
|
||||
<li class="nav-item">
|
||||
<a data-target="#Frame" class="@tabNavCss(CompileStep.Frame)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Frame)">Frame</a>
|
||||
</li>
|
||||
@if ( m_SplitList.Count > 0)
|
||||
@if (String.IsNullOrEmpty(m_CurrJwd) && m_CurrWindow == null)
|
||||
{
|
||||
<table class="table table-hover align-middle">
|
||||
<thead class="table-light fs-5">
|
||||
<tr>
|
||||
<th scope="col">#</th>
|
||||
<th scope="col" class="col-4">Image</th>
|
||||
<th scope="col" class="text-start">Description</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider fs-5">
|
||||
@foreach (var item in IN_TemplateDTOList)
|
||||
{
|
||||
string colorClass = "";
|
||||
@if (SelTemplateDTO != null && item.Index == SelTemplateDTO.Index)
|
||||
colorClass = "table-success";
|
||||
else
|
||||
colorClass = "";
|
||||
<tr style="height: 150px;" class="@colorClass" @onclick="() => DoSelect(item)">
|
||||
<td>@item.Index</td>
|
||||
<td><img class="img-fluid" width="100" src="@item.ImageUrl" /></td>
|
||||
<td class="text-start">@item.Description</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="@mainCss">
|
||||
<div class="card text-center table-svg">
|
||||
<div class="card-header" style="background-color: #d5f1f2;">
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<ul class="nav nav-tabs card-header-tabs">
|
||||
@* <li class="nav-item">
|
||||
@if (currStep == CompileStep.Template)
|
||||
{
|
||||
<a data-target="#Template" class="nav-link active fw-bold" aria-current="true" @onclick="() => AdvStep(CompileStep.Template)">Template</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<a data-target="#Template" class="nav-link text-secondary" @onclick="() => AdvStep(CompileStep.Template)">Template</a>
|
||||
}
|
||||
</li> *@
|
||||
@if (SelTemplateDTO != null)
|
||||
{
|
||||
<li class="nav-item">
|
||||
<a data-target="#Split" class="@tabNavCss(CompileStep.Split)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Split)">Split</a>
|
||||
<a data-target="#Frame" class="@tabNavCss(CompileStep.Frame)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Frame)">Frame</a>
|
||||
</li>
|
||||
}
|
||||
@if(m_SashList.Count > 0)
|
||||
{
|
||||
@if ( m_SplitList.Count > 0)
|
||||
{
|
||||
<li class="nav-item">
|
||||
<a data-target="#Split" class="@tabNavCss(CompileStep.Split)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Split)">Split</a>
|
||||
</li>
|
||||
}
|
||||
@if(m_SashList.Count > 0)
|
||||
{
|
||||
<li class="nav-item">
|
||||
<a data-target="#Sash" class="@tabNavCss(CompileStep.Sash)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Sash)">Sash</a>
|
||||
</li>
|
||||
}
|
||||
<li class="nav-item">
|
||||
<a data-target="#Sash" class="@tabNavCss(CompileStep.Sash)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Sash)">Sash</a>
|
||||
<a data-target="#Fill" class="@tabNavCss(CompileStep.Fill)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Fill)">Fill</a>
|
||||
</li>
|
||||
}
|
||||
<li class="nav-item">
|
||||
<a data-target="#Fill" class="@tabNavCss(CompileStep.Fill)" aria-current="true" @onclick="() => DoSelectAndPreview(CompileStep.Fill)">Fill</a>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
<div class="col-6 d-grid gap-2 d-md-flex justify-content-md-end">
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoSave">Save</button>
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoPreviewSvg">Preview Svg</button>
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoClose">Close</button>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="col-6 d-grid gap-2 d-md-flex justify-content-md-end">
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoSave">Save</button>
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoPreviewSvg">Preview Svg</button>
|
||||
<button class="btn btn-lg btn-primary btn-sm" @onclick="DoClose">Close</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body bg-transparent">
|
||||
<div class="alert alert-light text-center display-4">
|
||||
@if (currStep == CompileStep.Template)
|
||||
{
|
||||
<table class="table table-hover align-middle">
|
||||
<thead class="table-light fs-5">
|
||||
<tr>
|
||||
<th scope="col">#</th>
|
||||
<th scope="col" class="col-4">Image</th>
|
||||
<th scope="col" class="text-start">Description</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider fs-5">
|
||||
@foreach (var item in IN_TemplateDTOList)
|
||||
{
|
||||
string colorClass = "";
|
||||
@if (SelTemplateDTO != null && item.Index == SelTemplateDTO.Index)
|
||||
colorClass = "table-success";
|
||||
else
|
||||
colorClass = "";
|
||||
<tr style="height: 150px;" class="@colorClass" @onclick="() => DoSelect(item)">
|
||||
<td>@item.Index</td>
|
||||
<td><img class="img-fluid" width="100" src="@item.ImageUrl" /></td>
|
||||
<td class="text-start">@item.Description</td>
|
||||
<div class="card-body bg-transparent">
|
||||
<div class="alert alert-light text-center display-4">
|
||||
@* @if (currStep == CompileStep.Template)
|
||||
{
|
||||
<table class="table table-hover align-middle">
|
||||
<thead class="table-light fs-5">
|
||||
<tr>
|
||||
<th scope="col">#</th>
|
||||
<th scope="col" class="col-4">Image</th>
|
||||
<th scope="col" class="text-start">Description</th>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
@*<button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button> *@
|
||||
}
|
||||
else if (currStep == CompileStep.Frame)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="FrameShape">Shape</label>
|
||||
<select class="form-select" @bind="@m_Frame.SelShapeIndex">
|
||||
<option value="0">Rectangle</option>
|
||||
<option value="1">Right Chamfer</option>
|
||||
<option value="2">Left Chamfer</option>
|
||||
<option value="3">Double Chamfer</option>
|
||||
<option value="4">Arc</option>
|
||||
<option value="5">Arc Full</option>
|
||||
<option value="6">Double Arc</option>
|
||||
<option value="7">Triangle</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Dimension</h5>
|
||||
@foreach (FrameDimension dimension in m_Frame.DimensionList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="IndexDimFrame">@dimension.nIndex</span>
|
||||
<span class="input-group-text" id="NameDimFrame">@dimension.sName</span>
|
||||
<input type="number" class="form-control" aria-label="@dimension.dValue" @bind="@dimension.dValue">
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Joints frame</h5>
|
||||
@foreach (Joint joint in m_Frame.JointList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="IndexJoint">@joint.nIndex</label>
|
||||
<select class="form-select" @bind="@joint.SelJointTypeIndex">
|
||||
<option value="0">Angled</option>
|
||||
<option value="1">Full H</option>
|
||||
<option value="2">Full V</option>
|
||||
</select>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
@if (m_SashList.Count == 0)
|
||||
</thead>
|
||||
<tbody class="table-group-divider fs-5">
|
||||
@foreach (var item in IN_TemplateDTOList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Bottom rail</h5>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="BottomRailQty">Quantity</span>
|
||||
<input type="number" class="form-control" aria-label="BottomRailQty" @bind="@m_Frame.BottomRailQty">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
string colorClass = "";
|
||||
@if (SelTemplateDTO != null && item.Index == SelTemplateDTO.Index)
|
||||
colorClass = "table-success";
|
||||
else
|
||||
colorClass = "";
|
||||
<tr style="height: 150px;" class="@colorClass" @onclick="() => DoSelect(item)">
|
||||
<td>@item.Index</td>
|
||||
<td><img class="img-fluid" width="100" src="@item.ImageUrl" /></td>
|
||||
<td class="text-start">@item.Description</td>
|
||||
</tr>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (currStep == CompileStep.Split)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var item in SplitList)
|
||||
{
|
||||
</tbody>
|
||||
</table>
|
||||
} *@
|
||||
@if (currStep == CompileStep.Frame)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="FrameShape">Shape</label>
|
||||
<select class="form-select" @bind="@m_Frame.SelShapeIndex">
|
||||
<option value="0">Rectangle</option>
|
||||
<option value="1">Right Chamfer</option>
|
||||
<option value="2">Left Chamfer</option>
|
||||
<option value="3">Double Chamfer</option>
|
||||
<option value="4">Arc</option>
|
||||
<option value="5">Arc Full</option>
|
||||
<option value="6">Double Arc</option>
|
||||
<option value="7">Triangle</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="basic-addon1Split">Number</span>
|
||||
<input type="number" class="form-control" placeholder="0" aria-label="basic-addon1Split" @bind="@item.nSplitQty">
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="basic-addon2Split">Shape</label>
|
||||
<select class="form-select" @bind="@item.SelSplitShapeIndex">
|
||||
<option value="0">Vertical</option>
|
||||
<option value="1">Horizontal</option>
|
||||
<option value="2">Grid</option>
|
||||
<option value="3">Custom</option>
|
||||
</select>
|
||||
</div>
|
||||
@foreach (var dim in item.SplitPositionList)
|
||||
<h5 class="card-title">Dimension</h5>
|
||||
@foreach (FrameDimension dimension in m_Frame.DimensionList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="basic-addon3Split">Altezza area inferiore</span>
|
||||
<input type="number" class="form-control" aria-label="basic-addon2Split" @bind="@dim.dDimension">
|
||||
<span class="input-group-text" id="IndexDimFrame">@dimension.nIndex</span>
|
||||
<span class="input-group-text" id="NameDimFrame">@dimension.sName</span>
|
||||
<input type="number" class="form-control" aria-label="@dimension.dValue" @bind="@dimension.dValue">
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@* <button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (currStep == CompileStep.Sash)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var item in SashList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="NumberSash">Number</span>
|
||||
<input type="number" class="form-control" aria-label="NumberSash" @bind="@item.nSashQty">
|
||||
</div>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Orientation</h5>
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="OrientationSash">Tipology</label>
|
||||
<select class="form-select" @bind="@item.SelOrientationSashTypeIndex">
|
||||
<option value="0">Vertical</option>
|
||||
<option value="1">Horizontal</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@foreach (SashDimension sash in item.SashList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
@if(item.SashList.Count == 1)
|
||||
{
|
||||
<h5 class="card-title">Opening</h5>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h5 class="card-title">Sash opening @(item.SashList.IndexOf(sash) + 1)</h5>
|
||||
}
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="OpeningSash">Tipology</label>
|
||||
<select class="form-select" @bind="@sash.SelOpeningTypeIndex">
|
||||
<option value="0">A battente sinistra</option>
|
||||
<option value="1">A battente destra</option>
|
||||
<option value="2">Ad anta-ribalta sinistra</option>
|
||||
<option value="3">Ad anta-ribalta destra</option>
|
||||
<option value="4">5</option>
|
||||
<option value="5">7</option>
|
||||
<option value="6">8</option>
|
||||
<option value="7">9</option>
|
||||
<option value="8">10</option>
|
||||
<option value="9">11</option>
|
||||
<option value="10">12</option>
|
||||
<option value="11">13</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="Dimension">Dimension</span>
|
||||
<input type="number" class="form-control" aria-label="DimensionSash" @bind="@sash.dDimension">
|
||||
</div>
|
||||
<div class="d-flex justify-content-start fs-5 mb-2">
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" type="checkbox" name="Handle" id="Handle" @bind="@sash.bHasHandle">
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark" for="HandleSashLabel">Handle</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Sash joints</h5>
|
||||
@foreach (Joint joint in item.JointList)
|
||||
<h5 class="card-title">Joints frame</h5>
|
||||
@foreach (Joint joint in m_Frame.JointList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="IndexJoint">@joint.nIndex</label>
|
||||
@@ -261,60 +151,199 @@
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Bottom rail</h5>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="BottomRailQty">Quantity</span>
|
||||
<input type="number" class="form-control" aria-label="BottomRailQty" @bind="@item.SashBottomRailQty">
|
||||
@if (m_SashList.Count == 0)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Bottom rail</h5>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="BottomRailQty">Quantity</span>
|
||||
<input type="number" class="form-control" aria-label="BottomRailQty" @bind="@m_Frame.BottomRailQty">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
|
||||
@* <button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (currStep == CompileStep.Fill)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var Fill in FillList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
@if(FillList.Count == 1)
|
||||
{
|
||||
<h5 class="card-title">Fill</h5>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h5 class="card-title">Fill @(FillList.IndexOf(Fill) + 1)</h5>
|
||||
}
|
||||
<div class="input-group mb-2">
|
||||
<select class="form-select" @bind="@Fill.SelFillTypeIndex">
|
||||
<option value="0">Glass</option>
|
||||
<option value="1">Wood</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
else if (currStep == CompileStep.Split)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var item in SplitList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="basic-addon1Split">Number</span>
|
||||
<input type="number" class="form-control" placeholder="0" aria-label="basic-addon1Split" @bind="@item.nSplitQty">
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="basic-addon2Split">Shape</label>
|
||||
<select class="form-select" @bind="@item.SelSplitShapeIndex">
|
||||
<option value="0">Vertical</option>
|
||||
<option value="1">Horizontal</option>
|
||||
<option value="2">Grid</option>
|
||||
<option value="3">Custom</option>
|
||||
</select>
|
||||
</div>
|
||||
@foreach (var dim in item.SplitPositionList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="basic-addon3Split">Altezza area inferiore</span>
|
||||
<input type="number" class="form-control" aria-label="basic-addon2Split" @bind="@dim.dDimension">
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@* <button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (currStep == CompileStep.Sash)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var item in SashList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="NumberSash">Number</span>
|
||||
<input type="number" class="form-control" aria-label="NumberSash" @bind="@item.nSashQty">
|
||||
</div>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Orientation</h5>
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="OrientationSash">Tipology</label>
|
||||
<select class="form-select" @bind="@item.SelOrientationSashTypeIndex">
|
||||
<option value="0">Vertical</option>
|
||||
<option value="1">Horizontal</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@foreach (SashDimension sash in item.SashList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
@if(item.SashList.Count == 1)
|
||||
{
|
||||
<h5 class="card-title">Opening</h5>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h5 class="card-title">Sash opening @(item.SashList.IndexOf(sash) + 1)</h5>
|
||||
}
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="OpeningSash">Tipology</label>
|
||||
<select class="form-select" @bind="@sash.SelOpeningTypeIndex">
|
||||
<option value="0">A battente sinistra</option>
|
||||
<option value="1">A battente destra</option>
|
||||
<option value="2">Ad anta-ribalta sinistra</option>
|
||||
<option value="3">Ad anta-ribalta destra</option>
|
||||
<option value="4">5</option>
|
||||
<option value="5">7</option>
|
||||
<option value="6">8</option>
|
||||
<option value="7">9</option>
|
||||
<option value="8">10</option>
|
||||
<option value="9">11</option>
|
||||
<option value="10">12</option>
|
||||
<option value="11">13</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="Dimension">Dimension</span>
|
||||
<input type="number" class="form-control" aria-label="DimensionSash" @bind="@sash.dDimension">
|
||||
</div>
|
||||
<div class="d-flex justify-content-start fs-5 mb-2">
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" type="checkbox" name="Handle" id="Handle" @bind="@sash.bHasHandle">
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark" for="HandleSashLabel">Handle</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Sash joints</h5>
|
||||
@foreach (Joint joint in item.JointList)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text" for="IndexJoint">@joint.nIndex</label>
|
||||
<select class="form-select" @bind="@joint.SelJointTypeIndex">
|
||||
<option value="0">Angled</option>
|
||||
<option value="1">Full H</option>
|
||||
<option value="2">Full V</option>
|
||||
</select>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
<h5 class="card-title">Bottom rail</h5>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text" id="BottomRailQty">Quantity</span>
|
||||
<input type="number" class="form-control" aria-label="BottomRailQty" @bind="@item.SashBottomRailQty">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
|
||||
@* <button class="btn btn-sm btn-primary" title="Reset selezione" @onclick="DoReset"><i class="fa-solid fa-arrow-rotate-right"></i></button> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (currStep == CompileStep.Fill)
|
||||
{
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="alert alert-light text-start p-1 display-4 w-50">
|
||||
@foreach (var Fill in FillList)
|
||||
{
|
||||
<div class="border mb-2">
|
||||
<div class="card-body py-2">
|
||||
@if(FillList.Count == 1)
|
||||
{
|
||||
<h5 class="card-title">Fill</h5>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h5 class="card-title">Fill @(FillList.IndexOf(Fill) + 1)</h5>
|
||||
}
|
||||
<div class="input-group mb-2">
|
||||
<select class="form-select" @bind="@Fill.SelFillTypeIndex">
|
||||
<option value="0">Glass</option>
|
||||
<option value="1">Wood</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (SelTemplateDTO != null && currStep != CompileStep.Template)
|
||||
{
|
||||
<div class="col-6">
|
||||
@outSvg
|
||||
</div>
|
||||
@if (SelTemplateDTO != null && currStep != CompileStep.Template)
|
||||
{
|
||||
<div class="col-6">
|
||||
@outSvg
|
||||
</div>
|
||||
}
|
||||
}
|
||||
</div>
|
||||
|
||||
@@ -170,6 +170,7 @@ namespace WebWindowConfigurator
|
||||
protected async void DoSelect(TemplateSelectDTO newSel)
|
||||
{
|
||||
SelTemplateDTO = newSel;
|
||||
//DoSelectAndPreview(CompileStep.Frame);
|
||||
await EC_OnSelectedTemplate.InvokeAsync(newSel);
|
||||
}
|
||||
|
||||
@@ -226,7 +227,7 @@ namespace WebWindowConfigurator
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private CompileStep currStep = CompileStep.Template;
|
||||
private CompileStep currStep = CompileStep.Frame;
|
||||
|
||||
private List<Fill> m_FillList = new List<Fill>();
|
||||
|
||||
|
||||
+61
-125
@@ -594,8 +594,6 @@ namespace WebWindowConfigurator
|
||||
for (var SplitIndex = m_SashList.Count; SplitIndex <= value - 1; SplitIndex++)
|
||||
{
|
||||
SashList.Add(new SashDimension(dNewDimension, true, this));
|
||||
Fill f = (Fill)AreaList.Last();
|
||||
AreaList.Add(Fill.CreateFill(this, f.FillType));
|
||||
}
|
||||
}
|
||||
else if (value < m_SashList.Count)
|
||||
@@ -605,11 +603,71 @@ namespace WebWindowConfigurator
|
||||
{
|
||||
dLastDimension += m_SashList[SplitIndex].dDimension;
|
||||
SashList.RemoveAt(SplitIndex);
|
||||
AreaList.RemoveAt(SplitIndex);
|
||||
//AreaList.RemoveAt(SplitIndex);
|
||||
}
|
||||
dLastDimension += m_SashList[SashList.Count - 1].dDimension;
|
||||
SashList[SashList.Count - 1].SetDimension(dLastDimension);
|
||||
}
|
||||
if(m_SashList.Count == 1)
|
||||
{
|
||||
List<Area> ContentArea = new List<Area>();
|
||||
while(AreaList.Count > 0)
|
||||
{
|
||||
if(AreaList.Count == 1 & AreaList[0].AreaList.Count > 0)
|
||||
{
|
||||
foreach(Area selArea in AreaList[0].AreaList)
|
||||
{
|
||||
ContentArea.Add(selArea);
|
||||
}
|
||||
}
|
||||
AreaList.Remove(AreaList[AreaList.Count - 1]);
|
||||
}
|
||||
if(ContentArea.Count > 0)
|
||||
{
|
||||
AreaList = ContentArea;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
List<Area> ContentArea = new List<Area>();
|
||||
if (AreaList.Count == 1 & SashList.Count > AreaList.Count)
|
||||
{
|
||||
ContentArea.Add(AreaList.ElementAt(0));
|
||||
//foreach(Area selArea in AreaList)
|
||||
//{
|
||||
// ContentArea.Add(selArea);
|
||||
//}
|
||||
AreaList.Clear();
|
||||
}
|
||||
for (int SplitIndex = AreaList.Count; SplitIndex <= SashList.Count - 1; SplitIndex++)
|
||||
{
|
||||
AreaList.Add(Splitted.CreateSplitted(this));
|
||||
}
|
||||
int DimAreaList = AreaList.Count();
|
||||
for (int SplitIndex = SashList.Count; SplitIndex <= DimAreaList - 1; SplitIndex++)
|
||||
{
|
||||
AreaList.Remove(AreaList[AreaList.Count - 1]);
|
||||
}
|
||||
//if(ContentArea.Count > 0)
|
||||
//{
|
||||
// AreaList[0].AreaList = ContentArea;
|
||||
//}
|
||||
if (AreaList[AreaList.Count - 1].AreaList.Count == 0)
|
||||
{
|
||||
if (ContentArea.Count > 0)
|
||||
{
|
||||
foreach (Area SelArea in AreaList)
|
||||
{
|
||||
SelArea.AreaList = ContentArea;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
AreaList[AreaList.Count - 1] = AreaList[AreaList.Count - 2];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//RefreshHardwareList();
|
||||
RefreshHardwareOptionList();
|
||||
@@ -712,7 +770,6 @@ namespace WebWindowConfigurator
|
||||
set
|
||||
{
|
||||
m_bIsSashVertical = value;
|
||||
m_ParentWindow.OnUpdatePreview(m_ParentWindow.sSerialized());
|
||||
}
|
||||
}
|
||||
internal void SetIsSashVertical(bool IsSashVertical)
|
||||
@@ -984,72 +1041,6 @@ namespace WebWindowConfigurator
|
||||
return NewSash;
|
||||
}
|
||||
|
||||
//private string FindSashShape()
|
||||
//{
|
||||
// // Return "R"
|
||||
// // se non ancora creato, recupero area precedente
|
||||
// int nAreaId = m_nAreaId;
|
||||
// if (m_nAreaId == (int)GDB_ID.NULL)
|
||||
// nAreaId = ParentArea.nAreaId;
|
||||
// int nOutlineLayerId = EgtGetFirstNameInGroup(nAreaId, WIN_OUTLINE);
|
||||
// List<int> OutlineIdList = new List<int>();
|
||||
// int nOutlineId = EgtGetFirstInGroup(nOutlineLayerId);
|
||||
// while (nOutlineId != (int)GDB_ID.NULL)
|
||||
// {
|
||||
// OutlineIdList.Add(nOutlineId);
|
||||
// nOutlineId = EgtGetNext(nOutlineId);
|
||||
// }
|
||||
// int nTempLayerId = EgtCreateGroup(nAreaId);
|
||||
// int nCompoOutlineId = EgtCreateCurveCompo(nTempLayerId, OutlineIdList.ToArray(), false);
|
||||
// Point3d ptP;
|
||||
// Vector3d vtL1;
|
||||
// Vector3d vtL2;
|
||||
// Vector3d vtB1;
|
||||
// Vector3d vtB2;
|
||||
// Vector3d vtN;
|
||||
// double dRad;
|
||||
// bool bCCW;
|
||||
// if (EgtCurveIsARectangle(nCompoOutlineId, 0.001, ptP, vtL1, vtL2))
|
||||
// return "R";
|
||||
// else if (EgtCurveIsACircle(nCompoOutlineId, ptP, vtN, dRad, bCCW))
|
||||
// return "C";
|
||||
// else if (EgtCurveIsATrapezoid(nCompoOutlineId, ptP, vtB1, vtL1, vtB2))
|
||||
// return "T";
|
||||
// else
|
||||
// for (var nOutlineIndex = 0; nOutlineIndex <= OutlineIdList.Count - 1; nOutlineIndex++)
|
||||
// {
|
||||
// if (EgtGetType(OutlineIdList[nOutlineIndex]) == GDB_TY.CRV_ARC)
|
||||
// {
|
||||
// Vector3d vtStart;
|
||||
// EgtStartVector(OutlineIdList[nOutlineIndex], GDB_ID.ROOT, vtStart);
|
||||
// Vector3d vtEnd;
|
||||
// EgtEndVector(OutlineIdList[nOutlineIndex], GDB_ID.ROOT, vtEnd);
|
||||
// int nPrevOutlineId = nOutlineId > 0 ? OutlineIdList[nOutlineIndex - 1] : OutlineIdList[OutlineIdList.Count - 1];
|
||||
// int dPrevLen;
|
||||
// EgtCurveLength(nPrevOutlineId, dPrevLen);
|
||||
// Vector3d vtPrev;
|
||||
// EgtStartVector(nPrevOutlineId, vtPrev);
|
||||
// int nNextOutlineId = nOutlineId < OutlineIdList.Count - 1 ? OutlineIdList[nOutlineIndex + 1] : OutlineIdList[0];
|
||||
// int dNextLen;
|
||||
// EgtCurveLength(nNextOutlineId, dNextLen);
|
||||
// Vector3d vtNext;
|
||||
// EgtEndVector(nNextOutlineId, vtNext);
|
||||
// if (Math.Abs(dPrevLen - dNextLen) < 10 * EPS_SMALL)
|
||||
// {
|
||||
// if (AreSameVectorApprox(vtEnd, vtNext))
|
||||
// return "AS";
|
||||
// else
|
||||
// return "AR";
|
||||
// }
|
||||
// else if (AreSameVectorApprox(vtEnd, vtNext))
|
||||
// return "SS";
|
||||
// else
|
||||
// return "SR";
|
||||
// }
|
||||
// }
|
||||
// return "R";
|
||||
//}
|
||||
|
||||
internal OpeningTypes GetOpeningType(Openings OpeningType)
|
||||
{
|
||||
switch (OpeningType)
|
||||
@@ -1436,61 +1427,6 @@ namespace WebWindowConfigurator
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//private FillTypes m_FillType;
|
||||
//public FillTypes FillType
|
||||
//{
|
||||
// get
|
||||
// {
|
||||
// return m_FillType;
|
||||
// }
|
||||
// set
|
||||
// {
|
||||
// m_FillType = value;
|
||||
// }
|
||||
//}
|
||||
//internal void SetFillType(FillTypes FillType)
|
||||
//{
|
||||
// switch (FillType)
|
||||
// {
|
||||
// case FillTypes.GLASS:
|
||||
// {
|
||||
// bGlass_IsChecked = true;
|
||||
// break;
|
||||
// }
|
||||
|
||||
// case FillTypes.WOOD:
|
||||
// {
|
||||
// bWood_IsChecked = true;
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
// m_FillType = FillType;
|
||||
//}
|
||||
//private bool[] m_Fill_IsChecked = new[] { false, false };
|
||||
//public bool bGlass_IsChecked
|
||||
//{
|
||||
// get
|
||||
// {
|
||||
// return m_Fill_IsChecked[0];
|
||||
// }
|
||||
// set
|
||||
// {
|
||||
// m_Fill_IsChecked[0] = value;
|
||||
// }
|
||||
//}
|
||||
//public bool bWood_IsChecked
|
||||
//{
|
||||
// get
|
||||
// {
|
||||
// return m_Fill_IsChecked[1];
|
||||
// }
|
||||
// set
|
||||
// {
|
||||
// m_Fill_IsChecked[1] = value;
|
||||
// }
|
||||
//}
|
||||
|
||||
public Fill(Area ParentArea, Window ParentWindow) : base(ParentArea, ParentWindow)
|
||||
{
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user