|
|
@ -22,23 +22,6 @@ BI.DownListCombo = BI.inherit(BI.Widget, { |
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.DownListCombo.superclass._init.apply(this, arguments); |
|
|
|
BI.DownListCombo.superclass._init.apply(this, arguments); |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
this.popupview = BI.createWidget({ |
|
|
|
|
|
|
|
type: "bi.down_list_popup", |
|
|
|
|
|
|
|
items: o.items, |
|
|
|
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
|
|
|
value: o.value |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.popupview.on(BI.DownListPopup.EVENT_CHANGE, function (value) { |
|
|
|
|
|
|
|
self.fireEvent(BI.DownListCombo.EVENT_CHANGE, value); |
|
|
|
|
|
|
|
self.downlistcombo.hideView(); |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.popupview.on(BI.DownListPopup.EVENT_SON_VALUE_CHANGE, function (value, fatherValue) { |
|
|
|
|
|
|
|
self.fireEvent(BI.DownListCombo.EVENT_SON_VALUE_CHANGE, value, fatherValue); |
|
|
|
|
|
|
|
self.downlistcombo.hideView(); |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.downlistcombo = BI.createWidget({ |
|
|
|
this.downlistcombo = BI.createWidget({ |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
@ -58,7 +41,28 @@ BI.DownListCombo = BI.inherit(BI.Widget, { |
|
|
|
height: o.height |
|
|
|
height: o.height |
|
|
|
}), |
|
|
|
}), |
|
|
|
popup: { |
|
|
|
popup: { |
|
|
|
el: this.popupview, |
|
|
|
el: { |
|
|
|
|
|
|
|
type: "bi.down_list_popup", |
|
|
|
|
|
|
|
ref: function (ref) { |
|
|
|
|
|
|
|
self.popupView = ref; |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
items: o.items, |
|
|
|
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
|
|
|
value: o.value, |
|
|
|
|
|
|
|
listeners: [{ |
|
|
|
|
|
|
|
eventName: BI.DownListPopup.EVENT_CHANGE, |
|
|
|
|
|
|
|
action: function (value) { |
|
|
|
|
|
|
|
self.fireEvent(BI.DownListCombo.EVENT_CHANGE, value); |
|
|
|
|
|
|
|
self.downlistcombo.hideView(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}, { |
|
|
|
|
|
|
|
eventName: BI.DownListPopup.EVENT_SON_VALUE_CHANGE, |
|
|
|
|
|
|
|
action: function (value, fatherValue) { |
|
|
|
|
|
|
|
self.fireEvent(BI.DownListCombo.EVENT_SON_VALUE_CHANGE, value, fatherValue); |
|
|
|
|
|
|
|
self.downlistcombo.hideView(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}] |
|
|
|
|
|
|
|
}, |
|
|
|
stopPropagation: o.stopPropagation, |
|
|
|
stopPropagation: o.stopPropagation, |
|
|
|
maxHeight: o.maxHeight, |
|
|
|
maxHeight: o.maxHeight, |
|
|
|
minWidth: o.minWidth |
|
|
|
minWidth: o.minWidth |
|
|
|