if (typeof Durian == 'undefined') {
var Durian = {};
}
Durian.shop_good_list = Class({
init : function(option) {
jQuery.extend(this, {
container : null,
layer : null,
layerId : '__ui_shop_good_list_layer'
}, option || {});
this.container = $id(this.container) || document.body;
this.evtShowLayer = this.onShowLayer.bindForEvent(this);
this.evtHideLayer = this.onHideLayer.bindForEvent(this);
this.initLayer();
jQuery('.ui_shop_good_list')
.mouseenter(this.evtShowLayer)
.mouseleave(this.evtHideLayer)
;
},
initLayer : function() {
if (this.layer) {
return;
}
var div = document.createElement('div');
jQuery(div).hide();
document.body.appendChild(div);
jQuery(div).setClass('ui_user_box');
div.id = this.layerId;
this.layer = div;
},
onShowLayer : function(evt, obj) {
jQuery.eventStop(evt);
this.seq = obj.getAttribute('good_seq');
this.multi_seq = obj.getAttribute('multi_seq');
this.can_buy = obj.getAttribute('can_buy');
this.cate_code = jQuery.getQueryString('GC');
if (!this.seq) {
return;
}
if (this.multi_seq == null || this.multi_seq == undefined) this.multi_seq = '';
if (this.can_buy == null || this.can_buy == undefined) this.can_buy = '1';
this.getShopGoodList(this.seq, this.multi_seq, this.cate_code);
jQuery(this.layer).appendTo(obj).show();
},
onHideLayer : function(evt) {
jQuery(this.layer).hide();
},
getShopGoodList : function(seq, multi_seq, cate_code) {
result = "";
if(this.can_buy == '1') {
result += "";
result += "";
}
result += "";
this.layer.innerHTML = result;
},
nullFunc : function(evt) {
if (evt) {
jQuery.eventStop(evt);
}
}
});