代码之家  ›  专栏  ›  技术社区  ›  tesicg

如何向扩展剑道组合框的组合框添加新参数?

  •  1
  • tesicg  · 技术社区  · 5 年前

    (function () {
        "use strict";
        function comboBox() {
            comboBox.superclass.constructor.apply(this, arguments);
            this.params = $.extend(true, {
                suggest: true,
                highlightFirst: true,
                filter: "contains",
                minLength: 0,
                width: "auto"
            }, this.params);
    
            this.tControl = this.fn.kendoComboBox({
                change: $.proxy(this.onChange, this),
                minLength: this.params.minLength,
                filter: this.params.filter,
                suggest: this.params.suggest,
                highlightFirst: this.params.highlightFirst,
                dataSource: this.params.dataSource.data,
                dataTextField: this.params.dataTextField || "Text",
                dataValueField: this.params.dataValueField || "Value",
                template: this.params.template,
                clearButton: this.params.clearButton,
                width: this.params.width,
                readonly: ?
            }).data("kendoComboBox");
    
            this.tControl.list.width(this.params.width);
        }
    
        extend(comboBox, ui.WrappedControl);
    
        // ?
        comboBox.prototype.preventEnteringTextInVatType = function () {
            this.childs.vatType.tControl.input.attr("readonly", true);
        };
    
        ui.ComboBox = comboBox;
    })();
    

    我想连接“readonly”参数(有吗?现在)使用PreventEnteringDemivateType函数。怎么做?

    1 回复  |  直到 5 年前
        1
  •  1
  •   Carsten Franke    5 年前