<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Field; use ModStart\Core\Util\SerializeUtil; class Values extends AbstractField { protected $width = 300; protected $listable = false; protected function setup() { $this->addVariables(array('viewMode' => 'default', 'countFixed' => false)); } public function viewMode($Vceej) { $this->addVariables(array('viewMode' => $Vceej)); return $this; } public function countFixed($uQg0u) { $this->addVariables(array('countFixed' => $uQg0u)); return $this; } public function viewModeMini() { return $this->viewMode('mini'); } public function unserializeValue($cBDsM, AbstractField $Ldet7) { goto dpz09; gtwpw: $cBDsM = @json_decode($cBDsM, true); goto Y0_SO; Y0_SO: if (empty($cBDsM)) { $cBDsM = array(); } goto sgqHO; dpz09: if (null === $cBDsM) { return $cBDsM; } goto gtwpw; sgqHO: return $cBDsM; goto Q7KCY; Q7KCY: } public function serializeValue($cBDsM, $GMqtO) { return SerializeUtil::jsonEncode($cBDsM); } public function prepareInput($cBDsM, $GMqtO) { goto mXnRw; VZMdO: if (empty($cBDsM)) { $cBDsM = array(); } goto W6DJH; W6DJH: return $cBDsM; goto Tjpbs; mXnRw: $cBDsM = @json_decode($cBDsM, true); goto VZMdO; Tjpbs: } }