tiseza_oss_live/Views/Welcome/Index.cshtml

241 lines
11 KiB
Plaintext

@{
ViewBag.Title = "Index";
Layout = "~/Views/Shared/_Layout.cshtml";
}
<link rel="stylesheet" type="text/css" href="~/Content/plugins/table/datatable/datatables.css">
<link rel="stylesheet" type="text/css" href="~/Content/plugins/table/datatable/custom_dt_html5.css">
<link rel="stylesheet" type="text/css" href="~/Content/plugins/table/datatable/dt-global_style.css">
<div class="col-lg-12 layout-spacing">
<div class="statbox widget box box-shadow">
<div class="widget-header">
<div class="row">
<div class="col-md-12 col-sm-12 col-12">
<br />
<h5 class="text-primary font-weight-bold"> &nbsp; COMPANY <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right"><line x1="5" y1="12" x2="19" y2="12"></line><polyline points="12 5 19 12 12 19"></polyline></svg> Company & Project Profiles </h5>
<hr class="text-primary /">
</div>
</div>
<div class="col-xl-12 col-lg-12 col-sm-12 layout-spacing">
<div class="widget-content widget-content-area br-6">
<h6 class="text-primary">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right-circle"><circle cx="12" cy="12" r="10"></circle><polyline points="12 16 16 12 12 8"></polyline><line x1="8" y1="12" x2="16" y2="12"></line></svg> &nbsp;Company Profiles
</h6>
<hr class="text-black/ ">
<div class="d-flex justify-content-end">
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</div>
<br />
@(Html.DevExtreme().DataGrid<OSS.Models.CompanyProfileExternal>
()
.DataSource(ds => ds.WebApi()
.RouteName("CompanyProfile")
.LoadAction("GetCompanyProfileByTIN")
.Key("CompanyTIN")
//.InsertAction("Post")
.LoadParams(new { Username = (Session["CompanyEmail"] as string ?? string.Empty) })
)
.RemoteOperations(true)
.AllowColumnResizing(true)
.ShowRowLines(true)
.Columns(columns =>
{
columns.AddFor(m => m.CompanyName).Visible(true).SortOrder(SortOrder.Desc);
columns.AddFor(m => m.IncorpCertNo).AllowEditing(false);
columns.AddFor(m => m.IncorpCertDate);
columns.AddFor(m => m.CompanyMobile);
columns.AddFor(m => m.CompanyEmail);
columns.AddFor(m => m.OperatingStatus).DataField("OperatingStatus").Caption("Operating Status").CellTemplate(@<text>
<% if(data.OperatingStatus=="Operating")
{%>
<a href="#"><div class="btn btn-outline-success">Operating</div></a>
<% }
%>
</text>);
}).SearchPanel(f => f.Visible(true)
.SearchVisibleColumnsOnly(true)
.HighlightSearchText(true)
).Paging(p => p.PageSize(10))
.HeaderFilter(f => f.Visible(true))
.SearchPanel(t => t.SearchVisibleColumnsOnly(true).Visible(true))
.Editing(e => e
.AllowAdding(true)
.AllowUpdating(true)
.AllowAdding(false).Mode(GridEditMode.Popup)
.Popup(p => p
.Title("Company Profile")
.ShowTitle(true)
.Width(800)
.Height(300)
.Position(pos => pos
.My(HorizontalAlignment.Center, VerticalAlignment.Center)
.At(HorizontalAlignment.Center, VerticalAlignment.Center)
.Of(new JS("window"))
)
)
.UseIcons(true)
.Form(f => f
.ID("GetControlNo")
.ColCount(2)
.Items(items =>
{
items.AddGroup()
.Items(groupItems =>
{
groupItems.AddSimpleFor(m => m.CompanyName);
groupItems.AddSimpleFor(m => m.CompanyType);
groupItems.AddSimpleFor(m => m.OperatingStatus);
});
items.AddGroup()
.Items(groupItems =>
{
groupItems.AddSimpleFor(m => m.IncorpCertNo);
groupItems.AddSimpleFor(m => m.IncorpCertDate);
});
})
)
)
)
</div>
</div>
<hr />
<div class="col-xl-12 col-lg-12 col-sm-12 layout-spacing">
<div class="widget-content widget-content-area br-6">
<h6 class="text-primary">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right-circle"><circle cx="12" cy="12" r="10"></circle><polyline points="12 16 16 12 12 8"></polyline><line x1="8" y1="12" x2="16" y2="12"></line></svg> &nbsp; Registered Projects
</h6>
<hr class="text-primary" />
@(Html.DevExtreme().DataGrid<OSS.Models.ApplicationManager>
()
.DataSource(ds => ds.WebApi()
.RouteName("CompanyProfile")
.LoadAction("GetApprovedProjectsByUser")
.Key("ProjectCode")
//.InsertAction("Post")
.LoadParams(new { Username = (Session["CompanyEmail"] as string ?? string.Empty) })
)
.RemoteOperations(true)
.AllowColumnResizing(true)
.ShowRowLines(true)
.Columns(columns =>
{
columns.AddFor(m => m.ProjectName).Visible(true).SortOrder(SortOrder.Desc);
columns.AddFor(m => m.ProjectCode).AllowEditing(false);
columns.AddFor(m => m.ServiceName);
columns.AddFor(m => m.Station);
columns.AddFor(m => m.EvaluationStatus).DataField("EvaluationStatus").Caption("Approved Status").CellTemplate(@<text>
<% if(data.EvaludationStatus=="Approved")
{%>
<a href="#"><div class="btn btn-outline-success">Apprved</div></a>
<% }
%>
</text>);
}).SearchPanel(f => f.Visible(true)
.SearchVisibleColumnsOnly(true)
.HighlightSearchText(true)
).Paging(p => p.PageSize(10))
.HeaderFilter(f => f.Visible(true))
.SearchPanel(t => t.SearchVisibleColumnsOnly(true).Visible(true))
.Editing(e => e
.AllowAdding(false)
.AllowUpdating(false)
.AllowAdding(false).Mode(GridEditMode.Popup)
.Popup(p => p
.Title("Company Profile")
.ShowTitle(true)
.Width(800)
.Height(300)
.Position(pos => pos
.My(HorizontalAlignment.Center, VerticalAlignment.Center)
.At(HorizontalAlignment.Center, VerticalAlignment.Center)
.Of(new JS("window"))
)
)
.UseIcons(true)
.Form(f => f
.ID("GetControlNo")
.ColCount(2)
.Items(items =>
{
items.AddGroup()
.Items(groupItems =>
{
groupItems.AddSimpleFor(m => m.CompanyName);
groupItems.AddSimpleFor(m => m.EvaluationStatus);
groupItems.AddSimpleFor(m => m.EvaluationStatus);
});
items.AddGroup()
.Items(groupItems =>
{
groupItems.AddSimpleFor(m => m.CompanyName);
groupItems.AddSimpleFor(m => m.EvaluationStatus);
});
})
)
)
)
</div>
</div>
</div>
</div>
</div>