<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Widget; use ModStart\ModStart; class ButtonDialogRequest extends AbstractWidget { public static function getAssets() { return array('style' => '.ub-button-dialog-request{display:inline-block;}'); } public static function __callStatic($TUuqF, $MVaFK) { goto tidpF; a5QXT: throw new \Exception('ButtonDialogRequest error ' . join(',', $U0Xav) . ' '); goto bNcgx; tidpF: $U0Xav = array('muted', 'warning', 'danger', 'success', 'primary'); goto n9zQq; n9zQq: if (in_array($TUuqF, $U0Xav)) { goto wzf0a; DddyA: return $xU_gb->render(); goto ALBh4; Kdce1: $xU_gb->disabled(empty($MVaFK[2]) ? false : true); goto DddyA; Rmn7u: $xU_gb->url($MVaFK[1]); goto Kdce1; GiIny: $xU_gb->text($MVaFK[0]); goto Rmn7u; PMAOH: $xU_gb->type($TUuqF); goto GiIny; wzf0a: $xU_gb = new static(); goto PMAOH; ALBh4: } goto a5QXT; bNcgx: } public function render() { if ($this->disabled) { return '<a href="javascript:;" class="btn ub-button-dialog-request btn-' . $this->type . '">' . $this->text . '</a>'; } else { return '<a href="javascript:;" ' . ($this->confirm ? 'data-confirm="' . $this->confirm . '"' : '') . ' data-dialog-request="' . $this->url . '" class="btn ub-button-dialog-request btn-' . $this->type . '">' . $this->text . '</a>'; } } }