JobName | Queued | LineNo |
---|---|---|
@Html.DropDownListFor(x => x.JobName, new SelectList(Model.Jobs, "Value", "Text"), "Job", new { style = "width: 450px;" }) | @Html.DropDownListFor(x => x.QueuedBeamStatus, new SelectList(Model.Queues, "Value", "Text"), "Queue", new { style = "width: 450px;" }) | @Html.DropDownListFor(x => x.LineName, new SelectList(Model.Lines, "Value", "Text"), "Line", new { style = "width: 450px;" }) |
@Html.EJS().Grid("Grid").DataSource((IEnumerable<object>)ViewBag.datasource).Height("240").Columns(col =>
{=
col.Field("ShipCity").HeaderText("Ship City").CustomAttributes(new { @class = "orientationcss" }).Width("80").Add();
}).Created("setHeaderHeight").Render()
<script type="text/javascript">
function setHeaderHeight(args) {
var textWidth = document.querySelector(".orientationcss > div").scrollWidth; // obtain the width of the headerText content.
var headerCell = document.querySelectorAll(".e-headercell");
for (var i = 0; i < headerCell.length; i++) {
(headerCell.item(i)).style.height = textWidth + 'px'; // assign the obtained textWidth as the height of the headerCell.
}
}
</script>
<style>
.orientationcss .e-headercelldiv {
transform: rotate(90deg);
}
.e-grid .e-headercelldiv {
margin: 108px;
}
</style> |
|
|
<style>
.orientationcss .e-headercelldiv {
transform: rotate(90deg);
}
.orientationcss .e-headercelldiv {
text-align: center;
}
</style>
|
|