<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Grid\Filter; use ModStart\Core\Util\SerializeUtil; class Between extends AbstractFilter { protected $view = null; public function formatId($t_tdX) { $yU7nJ = str_replace('.', '_', $t_tdX); return array('start' => "{$yU7nJ}_start", 'end' => "{$yU7nJ}_end"); } protected function formatName($t_tdX) { goto GTZ4U; W9Mx3: if (count($bBHtO) == 1) { $ZZMEd = $bBHtO[0]; } else { $ZZMEd = array_shift($bBHtO); foreach ($bBHtO as $t_tdX) { $ZZMEd .= "[{$t_tdX}]"; } } goto if71u; GTZ4U: $bBHtO = explode('.', $t_tdX); goto W9Mx3; if71u: return array('start' => "{$ZZMEd}[start]", 'end' => "{$ZZMEd}[end]"); goto Kd1fI; Kd1fI: } public function datetime($RKwZR = array()) { $this->view = 'admin::filter.betweenDatetime'; $this->prepareForDatetime($RKwZR); } protected function prepareForDatetime($RKwZR = array()) { goto QTINQ; QTINQ: $RKwZR['format'] = array_get($RKwZR, 'format', 'YYYY-MM-DD HH:mm:ss'); goto ETdqy; ADnMM: $E6N47 = SerializeUtil::jsonEncode($RKwZR); goto Ckf2p; ETdqy: $RKwZR['locale'] = array_get($RKwZR, 'locale', config('app.locale')); goto ADnMM; Ckf2p: $TSJK3 = SerializeUtil::jsonEncode($RKwZR + array('useCurrent' => false)); goto bhYIM; bhYIM: } public function render() { if (isset($this->view)) { return view($this->view, $this->variables()); } return parent::render(); } }