code: function() {
          var result = true;
          if (typeof this.options.onBeforeOpen == 'function') {
              result = this.options.onBeforeOpen();
              if (result === false) {
                  return;
              }
          }
  
          this.$container.show();
  
          var triggerPosition = this.$trigger.position(),
              containerLeft, containerTop;
          if (this.options.alignX === 'left') {
              containerLeft = triggerPosition.left + this.options.offsetX;
          } else if (this.options.alignX === 'right') {
              containerLeft = triggerPosition.left + this.$trigger.outerWidth() - this.$container.outerWidth() + this.options.offsetX;
          }
          if (this.options.alignY == 'bottom') {
              containerTop = triggerPosition.top + this.$trigger.outerHeight() + this.options.offsetY;
          } else if (this.options.alignY == 'top') {
              containerTop = triggerPosition.top - this.$container.outerHeight() + this.options.offsetY;
          }
  
          this.$container.css({
              left: containerLeft,
              top: containerTop,
              zIndex: this.options.zIndex || this.$trigger.css('zIndex')
          });
      }
docs: 打开下拉浮层