1

剣道コントロールを持つasp.net Webアプリケーションがあります。私は3つのパネルバーアイテムを持つKendoPanelを追加しました..

ボタン クリック イベントで、PanelBar の 2 番目の項目のヘッダー テキストを変更したい..

どうすればこれを達成できますか?

ありがとう

4

1 に答える 1

1

これがパネル バーの定義であると仮定します。

var panelbar = $("#panelbar").kendoPanelBar({
     ...
}).data("kendoPanelBar");

そして、これはあなたのボタンハンドラです:

$("#change_2").on("click", function() {
    // Get reference to the second "li" and then to the header
    var li = panelbar.wrapper.find("> li:nth(1) span.k-link.k-header");
    // Replace the content by "Title"
    li.contents().first().replaceWith("Title");
});

ここで見ることができます:http://dojo.telerik.com/@OnaBai/Uzugu

于 2014-12-26T00:46:12.547 に答える