<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Grid\Filter; class Between extends AbstractFilter { protected $view = null; public function formatId($mSZnY) { $PMDE9 = str_replace('.', '_', $mSZnY); return array('start' => "{$PMDE9}_start", 'end' => "{$PMDE9}_end"); } protected function formatName($mSZnY) { goto wsaY1; S8GtP: return array('start' => "{$c6VKG}[start]", 'end' => "{$c6VKG}[end]"); goto MC0sK; wsaY1: $ebHxk = explode('.', $mSZnY); goto fPJjz; fPJjz: if (count($ebHxk) == 1) { $c6VKG = $ebHxk[0]; } else { $c6VKG = array_shift($ebHxk); foreach ($ebHxk as $mSZnY) { $c6VKG .= "[{$mSZnY}]"; } } goto S8GtP; MC0sK: } public function datetime($Tpa5t = array()) { $this->view = 'admin::filter.betweenDatetime'; $this->prepareForDatetime($Tpa5t); } protected function prepareForDatetime($Tpa5t = array()) { goto O3BWx; O3BWx: $Tpa5t['format'] = array_get($Tpa5t, 'format', 'YYYY-MM-DD HH:mm:ss'); goto Wp7tC; SZH2T: $HGknj = json_encode($Tpa5t); goto V33Z_; V33Z_: $tClyV = json_encode($Tpa5t + array('useCurrent' => false)); goto DAG_J; Wp7tC: $Tpa5t['locale'] = array_get($Tpa5t, 'locale', config('app.locale')); goto SZH2T; DAG_J: } public function render() { if (isset($this->view)) { return view($this->view, $this->variables()); } return parent::render(); } }