| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- @using GreenTree.Nachtragsmanagement.Web.Extensions
- @using GreenTree.Nachtragsmanagement.Core.Domain.Deviation
- @model GreenTree.Nachtragsmanagement.Web.Models.Deviation.DeviationDataModel
- @Html.DevExpress().PopupControl(s =>
- {
- s.Name = "devDisturbanceValuePopup";
- s.HeaderText = "Kategorie zuweisen";
- s.Modal = true;
- s.Width = new Unit(350, UnitType.Pixel);
- s.CloseAction = CloseAction.CloseButton;
- s.PopupHorizontalAlign = PopupHorizontalAlign.WindowCenter;
- s.PopupVerticalAlign = PopupVerticalAlign.TopSides;
- s.PopupVerticalOffset = 40;
- s.AllowDragging = true;
- s.AllowResize = false;
- s.ShowFooter = false;
- s.SetContent(() =>
- {
- ViewContext.Writer.Write("<div class='editFormWrapper'>");
- {
- ViewContext.Writer.Write(Html.CustomLabelFor(m => m.DisturbanceEntities, "Kategorie:"));
- Html.DevExpress().DropDownEdit(t =>
- {
- t.Name = "devDropDownListAllDisturbances";
- t.Width = new Unit(100, UnitType.Percentage);
- t.Text = ((ICollection<Disturbance>)ViewData["AllDisturbances"]).ToArray()[0].Description;
- t.SetDropDownWindowTemplateContent(l =>
- {
- Html.DevExpress().ListBox(lb =>
- {
- lb.Name = "devListBoxAllDisturbances";
- lb.Width = new Unit(100, UnitType.Percentage);
- lb.Properties.TextField = "Description";
- lb.Properties.ValueField = "Id";
- lb.Properties.ValueType = typeof(int);
- lb.Properties.SelectionMode = ListEditSelectionMode.Single;
- lb.SelectedIndex = 0;
- lb.Properties.ClientSideEvents.SelectedIndexChanged = "function (s, e) { devDropDownListAllDisturbances.SetText(s.GetSelectedItem().text); devDropDownListAllDisturbances.HideDropDown(); }";
- lb.ControlStyle.Border.BorderStyle = BorderStyle.None;
- }).BindList(ViewData["AllDisturbances"]).Render();
- });
- }).Render();
- ViewContext.Writer.Write(Html.CustomLabelFor(m => m.DisturbanceEntities, "Wert:"));
- Html.DevExpress().SpinEdit(t =>
- {
- t.Name = "devSpinEditDisturbanceValue";
- t.Number = 0;
- t.Properties.MinValue = 0;
- t.Properties.MaxValue = decimal.MaxValue;
- t.Properties.NumberType = SpinEditNumberType.Float;
- t.Properties.DisplayFormatString = "c2";
- }).Render();
- }
- ViewContext.Writer.Write("</div>");
- Html.RenderPartial(
- "~/Views/Shared/_PopupButtonPanel.cshtml",
- new GreenTree.Nachtragsmanagement.Web.Models.Global.PopupModel
- {
- PopupName = "devDisturbanceValuePopup",
- AcceptFunction = "function (s, e) { addDisturbanceValue(); }"
- }
- );
- });
- s.Styles.Content.Paddings.Padding = new Unit(0);
- s.Styles.ModalBackground.Opacity = 0;
- }).GetHtml()
|