YNICTE/BO/Views/cm/books.cshtml

62 lines
2.6 KiB
Plaintext

@model NP.Model.VMCM
<form id="mform" method="post" action="">
<section class="panel panel-default clearfix devsearch" data-cleartbody="tbody1">
@Html.Partial("./Partial/SearchCaption")
<div class="step-content">
<div class="step-pane active form-inline">
<div class="form-group">
@Html.Partial("./Partial/Text", Model.stringval, Helpers.DicText(new NP.Model.TextDic() { Name = "stringval", Value = Model.stringval, PH = "교재명을 입력하세요.", CssClass = "ff" }))
@Html.Partial("./Partial/Button", new NP.Model.Button() { Special = "search" })
</div>
</div>
</div>
</section>
<div class="tar buttonbox">
@Html.Partial("./Partial/pagerow", new ViewDataDictionary { { "tbodyid", "tbody1" }, { "searchmethod", "submit()" }, { "pagesize", Model.pagerowcount } })
<a href="#" onclick="javascript:reg(0);" class="btn btn-s-xs btn-info">등록</a>
</div>
<section class="panel panel-default">
<div class="table-responsive" id="excel1">
<table class="table table-striped b-t b-light">
<thead>
<tr>
<th width="20">No</th>
<th>교재명</th>
<th>단가</th>
<th>사용여부</th>
<th>등록일</th>
</tr>
</thead>
<tbody class="data" id="tbody1">
@foreach (var item in Model.Books)
{
<tr>
<td>@item.rnorvt</td>
<td class="text-left link"><a class="link" href="#" onclick="reg(@item.bkno)">@item.bkname</a></td>
<td class="text-right">@item.price.ToString("#,0") 원</td>
<td>@item.isuseyn</td>
<td>@item.cdtymd</td>
</tr>
}
</tbody>
</table>
</div>
@Html.Pager((int)Model.pagenum, 10, Model.pagerowcount, Model.pagetotalcount)
</section>
</form>
<form id="dform" method="post" action="/cm/bookreg">
@Html.Partial("./Partial/dform", Model, new ViewDataDictionary { { "preform", 1 } })
</form>
@section scripts{
<script>
$(document).ready(function () {
$("#stringval").on("change", function () {
submit();
});
});
function reg(no) {
setv("dform_intval", no);
$("#dform").submit();
}
</script>
}