<?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')); } public function viewMode($RynTC) { $this->addVariables(array('viewMode' => $RynTC)); return $this; } public function viewModeMini() { return $this->viewMode('mini'); } public function unserializeValue($Mczr_, AbstractField $rZfgs) { goto bRNRm; jswU6: if (empty($Mczr_)) { $Mczr_ = array(); } goto Rec9S; Rec9S: return $Mczr_; goto FxDo_; bRNRm: if (null === $Mczr_) { return $Mczr_; } goto Vz8F_; Vz8F_: $Mczr_ = @json_decode($Mczr_, true); goto jswU6; FxDo_: } public function serializeValue($Mczr_, $vn_cr) { return SerializeUtil::jsonEncode($Mczr_); } public function prepareInput($Mczr_, $vn_cr) { goto apnEW; gHtsK: if (empty($Mczr_)) { $Mczr_ = array(); } goto Blv3v; apnEW: $Mczr_ = @json_decode($Mczr_, true); goto gHtsK; Blv3v: return $Mczr_; goto qnmgx; qnmgx: } }