or
@(
Html.Kendo().RadialGauge()
.Name(
"patientDocumentMatchThresholdGauge"
)
.Pointer(pointer => pointer.Value((
double
)Model.PatientDocumentMatchThreshold * 100))
.Scale(scale => scale
.EndAngle(180)
.MajorUnit(10)
.Max(100)
.Min(0)
.MinorUnit(1)
.StartAngle(0)
.Ranges(ranges => {
ranges.Add().From(0).To(90).Color(
"#f00"
);
ranges.Add().From(90).To(95).Color(
"#ffa500"
);
ranges.Add().From(95).To(100).Color(
"#0c0"
);
}
)
)
)
01.
@(Html.Kendo().DropDownListFor(model => model.FixedMovementType)
02.
.OptionLabel(
"* Not Selected"
)
03.
.DataTextField(
"Name"
)
04.
.DataValueField(
"Id"
)
05.
.BindTo(Model.FixedMovementTypes))
06.
@Html.ValidationMessageFor(model => model.FixedMovementType,
""
,
new
{@
class
=
"alert-error"
})
07.
@(Html.Kendo().DropDownListFor(model => model.Location)
08.
.OptionLabel(
"* Not Selected"
)
09.
.DataTextField(
"Name"
)
10.
.DataValueField(
"Id"
)
11.
.DataSource(source => source.Read(read => read.Action(
"GetLocationsRead"
,
"FixedMovement"
).Data(
"FilterLocation"
)).ServerFiltering(
true
))
12.
.AutoBind(
false
)
13.
.CascadeFrom(
"FixedMovementType"
))
1.
{
2.
Id = 0,
3.
Name =
"Employment"
4.
},
5.
{
6.
Id = 1,
7.
Name =
"Store"
8.
}
Html.Kendo().Window()
.Name("createDocWin")
.Modal(true)
.Draggable(false)
.Height(300)
.Resizable(r => r.Enabled(false))
.Events(e => e.Error("errorCreatingDoc"))
<script>
jQuery(
function
(){jQuery(
"#createDocWin"
).kendoWindow({
"refresh"
:errorCreatingDoc,
"modal"
:
true
,
"iframe"
:
false
,
"draggable"
:
false
,
"title"
:
"Created Document"
,
"resizable"
:
false
,
"content"
:
null
,
"width"
:300,
"height"
:300,
"actions"
:[
"Close"
]});});
</script>
@(Html.Kendo().Grid<
MesFormations.Models.EmployeGridView
>()
.Name("grid")
.Columns(columns =>
{
columns.Bound(e => e.NomEmploye).Width(110);
columns.Bound(e => e.CourrielEmploye).Width(110);
columns.Bound(e => e.Telephone).Width(110);
columns.Bound(e => e.PosteTelephone);
})
.Sortable()
.Pageable()
.Scrollable()
.ClientDetailTemplateId("template")
.HtmlAttributes(new { style = "height:430px;" })
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(6)
.Read(read => read.Action("HierarchyBinding_Employees", "Employe"))
)
.Events(events => events.DataBound("dataBound"))
)
<
script
id
=
"template"
type
=
"text/kendo-tmpl"
>
@(Html.Kendo().Grid<
MesFormations.Models.FormationEmployeGridView
>()
.Name("grid_#=NoEmploye#")
.Columns(columns =>
{
columns.Bound(o => o.NoFormation).Width(70);
columns.Bound(o => o.DateFormation).Width(110);
columns.Bound(o => o.DateModification);
columns.Bound(o => o.Remarques).Width(200);
})
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(5)
.Read(read => read.Action("HierarchyBinding_Orders", "Employe", new { employeeID = "#=NoEmploye#" }))
)
.Pageable()
.Sortable()
.ToClientTemplate()
)
</
script
>
<
script
>
function dataBound() {
this.expandRow(this.tbody.find("tr.k-master-row").first());
}
</
script
>
public ActionResult HierarchyBinding_Employees([DataSourceRequest] DataSourceRequest request)
{
return Json(GetEmployees().ToDataSourceResult(request));
}
public ActionResult HierarchyBinding_Orders(int employeeID, [DataSourceRequest] DataSourceRequest request)
{
return Json(GetOrders()
.Where(order => order.NoEmploye == employeeID)
.ToDataSourceResult(request));
}
private static IEnumerable<
FormationEmployeGridView
> GetOrders()
{
var northwind = new FormationContext();
//var loadOptions = new DataLoadOptions();
//loadOptions.LoadWith<
Order
>(o => o.Customer);
//northwind.LoadOptions = loadOptions;
return northwind.FormationEmploye.Select(order => new FormationEmployeGridView
{
NoFormationEmploye = order.NoFormationEmploye,
NoEmploye = order.NoEmploye,
NoFormation = order.NoFormation,
DateFormation = order.DateFormation,
Remarques = order.Remarques,
DateModification = order.DateModification
});
}
private static IEnumerable<
EmployeGridView
> GetEmployees()
{
var northwind = new FormationContext();
return northwind.Employes.Select(employee => new EmployeGridView
{
NoEmploye = employee.NoEmploye,
PrenomEmploye = employee.PrenomEmploye,
NomEmploye = employee.NomEmploye,
CourrielEmploye = employee.CourrielEmploye,
Telephone = employee.Telephone,
PosteTelephone = employee.PosteTelephone
});
}
<
httpRuntime
targetFramework
=
"4.5"
encoderType
=
"System.Web.Security.AntiXss.AntiXssEncoder, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
/>