簡體   English   中英

如何使KendoUI編輯按鈕在Chrome中工作?

[英]How to make the KendoUI Edit button work in Chrome?

KendoUI的某些小部件似乎只能在Firefox中運行,而不能在Chrome中工作。 就像網格中的“編輯”命令按鈕一樣。

     { command: [ { name: "Edit" ,text:'', imageClass: "k-icon k-i-pencil", 
                               click: function(e) {
                                   //some code
                               }

單擊該功能在Chrome中根本不會調用,但在Firefox中會完美運行。

無論如何,我可以對其進行修復以使其在兩種瀏覽器中都能正常工作嗎?

像這樣綁定您的inline網格,

 $("#grid").kendoGrid({
                    dataSource: dataSource,
                    navigatable: true,
                    pageable: true,
                    height: 430,
                    groupable: {
                        messages: {
                            empty: "Drop columns here"
                        }
                    },
                    toolbar: ["create"],
                    columns: [
                                    "ProductName",

                                    {field: "UnitPrice", title: "Unit Price", width: 110 },
                                    { field: "UnitsInStock", title: "Units In Stock", width: 110 },
                                    { field: "Discontinued", width: 110 },
                                    { command: ["edit", "destroy"], title: " ", width: 190}],

                    editable: "inline"
                });

網格命令

{ command: ["edit", "destroy"], title: " ", width: 190}]它對chrome和FF均有效。

該演示似乎適用於所有瀏覽器:

http://demos.kendoui.c​​om/web/grid/custom-command.html

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM