public function indexAction() { $params = TZ_Request::getParams('get'); $tag = ''; if (isset($params['tag'])) { $tag = $params['tag']; } $resultData = TZ_loader::service('Upgrade', 'Upgrade')->getUpgrade($tag); TZ_Request::success($resultData); }
public function getProUpgrade($name, $version = '') { if (!empty($name)) { $condition['tag:eq'] = $name; $condition['order'] = 'created_at desc'; if ($version) { $condition['version:eq'] = $version; } else { $condition['status:eq'] = 1; } } else { return false; } return TZ_loader::model('UpgradeApps')->select($condition, '*', 'ROW'); }
/** * Hello World! * * @return void */ public function indexAction() { $params = TZ_Request::getParams('get'); if (isset($params['session_id'])) { if (empty($params['session_id'])) { throw new Exception('无会话id.'); } $sessionId = TZ_Request::clean($params['session_id']); $uid = TZ_loader::service('SessionManager')->getUid($sessionId); if (!$uid) { throw new Exception('你还没有登录.'); } $userInfo = TZ_Loader::service('CallUser')->getUserInfo(array('friendlyName:eq' => $uid)); } elseif (isset($params['telephone'])) { if (empty($params['telephone'])) { throw new Exception('请输入手机号码.'); } $userInfo = TZ_Loader::service('CallUser')->getUserInfo(array('mobile:eq' => $params['telephone'])); } else { throw new Exception('请输入必要参数.'); } TZ_Request::success(array($userInfo)); }
public function getUserList() { //$condition['limit'] = "45,50"; $condition['id:eq'] = '0'; return TZ_loader::model('Open')->select($condition, 'uid,telephone', 'ALL'); }
public function indexAction() { TZ_loader::service('PayWork', 'Api')->setWork(); TZ_Request::success(); }