我在这里有功能,我想在 kendo 栏中调用它。函数正在检查是否点击了类。但是当我在 kendo 列中添加该类时,没有任何事情发生,我在这做什么?你能帮我在 kendo 栏中打电话给那个班级吗?
由于
<script>
$(function() {
$(".createInvoice").on('click', function(e) {
e.preventDefault();
debugger;
var self = $(this);
var createInvoiceW = $("#createInvoiceWindow");
var kwindow = createInvoiceW.data("kendoWindow");
kwindow.refresh({
url: "@Url.Action("CreateInvoicePopup", "Finances")/" + self.data('job-id')
});
kwindow.center();
kwindow.open();
});
});
</script>
<div id="createInvoiceWindow" class="kWindow"
data-title="false"
data-width="600"
@* data-height="700"*@
data-ajax="true"
data-visible="false"
data-url="@Url.Action("CreateInvoicePopup", "Finances")"></div>
剑道网格
<div id="jobs-grid"></div>@(Html.Kendo().Grid<Modus.Presentation.Models.Jobs.JobModel>()
.Name("#jobs-grid")
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action("List", "Jobs"))
)
.Columns(columns =>
{
columns.Bound(product => product.JobNumber).ClientTemplate("<a href='" +
"/#= Id #'" +
">Show Product Details</a>").HtmlAttributes(new { @class = "createInvoice" });
columns.Bound(product => product.Customer.Name).ClientTemplate("<a class='createInvoice'>hgg</a>");
columns.Bound(product => product.Customer.Name).HtmlAttributes(new { @class = "createInvoice" });
columns.Bound(p => p.JobNumber).Template(@<text>
@Html.ActionLink("", "", new { id = @item.Id , @class= "createInvoice" })>
</text>);
})
.Pageable()
)