使用Kendo UI模板删除HTML属性

问题描述

我有一个kendo ui窗口小部件,它使用以下模板显示数据:

<script type="text/x-kendo-template" id="alert-details-template">
    <div class="row">
        <div class="col-12">
            <h3 class="text-center">#:AlertType#</h3>
            #=ModalMessageText#
            # if (DeliveryNoteUrl) { #
            <p><a href="#:DeliveryNoteUrl#" target="_blank" download>Download file</a></p>
            # } #
        </div>
    </div>
</script>

这很好。问题在于,在实际的窗口模式中,锚标签中除href和target之外的所有其他属性都将被删除。例如,上面的下载属性,id,样式,类均已从生成的模板中删除。奇怪的是,它只发生在锚标记上。这很奇怪,希望在那里的人能对此有所了解。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)