Exemplo n.º 1
0
 public function _init()
 {
     $this->playerType = array(1 => '用户ID', 2 => '用户账号', 3 => '用户呢称 ');
     $this->_assign['playerType'] = $this->playerType;
     $this->_assign['items'] = $this->partner('Item', 'main', null, 'MasterTools');
     $this->_assign['URL_itemUpdate'] = Tools::url('MasterTools', 'Item', array('timeout' => '1', 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
 }
Exemplo n.º 2
0
 function actionIndex()
 {
     $this->_modelLostPassword = $this->_getGlobalData('Model_LostPassword', 'object');
     $status = $this->_modelLostPassword->getStatus();
     $this->_view->assign('statusSelect', $status);
     $status[''] = Tools::getLang('ALL', 'Common');
     $gameTypes = $this->_getGlobalData('game_type');
     $gameTypes = Model::getTtwoArrConvertOneArr($gameTypes, 'Id', 'name');
     $serverList = $this->_getGlobalData('gameser_list');
     $serverList = Model::getTtwoArrConvertOneArr($serverList, 'Id', 'server_name');
     $this->_utilMsg->createNavBar();
     $where = array();
     if ($this->_isPost()) {
         $selected['status'] = $_POST['status'];
         if (intval($_POST['status']) > 0) {
             $where['status'] = $_POST['status'];
         }
     }
     $order = 'status asc,Id desc';
     $dataList = $this->_modelLostPassword->getOrder($where, 1, $order);
     $this->_loadCore('Help_Page');
     $currUrl = Tools::url(CONTROL, 'EventList', $selected);
     $helpPage = new Help_Page(array('total' => $this->_modelLostPassword->getCount($where), 'perpage' => PAGE_SIZE, 'url' => $currUrl));
     $this->_view->assign('pageBox', $helpPage->show());
     $this->_view->assign('gameTypes', $gameTypes);
     $this->_view->assign('serverList', $serverList);
     $this->_view->assign('chargeType', $this->_modelLostPassword->getChargeType());
     $this->_view->assign('status', $this->_modelLostPassword->getStatus());
     $this->_view->assign('status', $status);
     $this->_view->assign('dataList', $dataList);
     $this->_view->assign('selected', $selected);
     $this->_view->display();
 }
Exemplo n.º 3
0
 public function main($UrlAppend = NULL, $get = NULL, $post = NULL)
 {
     if (!$_REQUEST['server_id']) {
         return $this->_assign;
     }
     if ($_REQUEST["sbm"] == "") {
         return $this->_assign;
     }
     $getData = $this->_gameObject->getGetData($get);
     if ($_GET["WorldID"] != "") {
         $WorldID = $_GET["WorldID"];
     }
     $postData = array('PlayerID' => trim($_GET['PlayerID']), 'AccountName' => trim($_GET['AccountName']), 'AccountID' => trim($_GET['AccountID']), 'WorldID' => trim($WorldID), 'PlayerName' => urlencode(trim($_GET['PlayerName'])), 'Page' => max(0, intval($_GET['page'] - 1)));
     $getData = array_merge($getData, $postData);
     $account = $this->getResult($UrlAppend, $getData);
     if ($account['Result'] === 0) {
         $status = 1;
         if ($account['PlayerList']) {
             $this->_loadCore('Help_Page');
             //载入分页工具
             $helpPage = new Help_Page(array('total' => $account['Count'], 'perpage' => PAGE_SIZE));
             $this->_assign['data'] = $account;
             $this->_assign['dataList'] = $account['PlayerList'];
             $this->_assign['pageBox'] = $helpPage->show();
         }
     } else {
         $this->_assign['connectError'] = 'Error Message:' . $data['info'];
         $info = $data['info'];
     }
     $this->_assign['ajax'] = Tools::url(CONTROL, 'PlayerRoleList', array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
     return $this->_assign;
 }
Exemplo n.º 4
0
 public function main($UrlAppend = NULL, $get = NULL, $post = NULL)
 {
     if ($this->_isPost()) {
         $cause .= "全服发送邮件<br>";
         $getData = $this->_gameObject->getGetData($get);
         $r = "";
         $cause .= "内容:" . trim($_POST['content']) . "<br>";
         $cause .= "标题:" . trim($_POST['title']) . "<br>";
         foreach ($_POST["server_ids"] as $v) {
             $postData = array('WorldID' => intval($this->_serverList[$v]["ordinal"]), 'IsAllPlayer' => intval(1), 'Title' => trim($_POST['title']), 'Content' => trim($_POST['content']));
             $SendData["data"] = json_encode($postData);
             $applyData = array('type' => 51, 'server_id' => $v, 'operator_id' => $this->_serverList[$v]['operator_id'], 'game_type' => $this->_serverList[$v]['game_type_id'], 'list_type' => 1, 'apply_info' => str_replace(array("\r\n", "\n"), '', $cause), 'send_type' => 1, 'send_data' => array('url_append' => $UrlAppend, 'post_data' => $SendData, 'get_data' => $getData, 'call' => array('cal_local_object' => 'Game_' . $this->_gameObject->_gameId, 'cal_local_method' => 'ApplySend', 'params' => array('data' => $SendData, "server_id" => $v, "UrlAppend" => $UrlAppend))), 'receiver_object' => array($serverId => ''), 'player_type' => 0, 'player_info' => 0);
             $modelApply = $this->_getGlobalData('Model_Apply', 'object');
             if ($modelApply->AddApply($applyData)) {
                 $r .= "[" . $this->_serverList[$v]["server_name"] . "]提交成功<br>";
             } else {
                 $r .= "[" . $this->_serverList[$v]["server_name"] . "]提交失败<br>";
             }
         }
         $URL_CsIndex = Tools::url('Apply', 'CsIndex');
         $URL_CsAll = Tools::url('Apply', 'CsAll');
         $showMsg = '申请成功,等待审核...<br>';
         $showMsg .= "<a href='{$URL_CsIndex}'>客服审核列表</a><br>";
         $showMsg .= "<a href='{$URL_CsAll}'>客服审核列表(全部)</a>";
         $this->jump($r . $showMsg, 1, 1, false);
     }
     $this->_assign['tplServerSelect'] = 'BaseZp/MultiServerSelect.html';
     return $this->_assign;
 }
Exemplo n.º 5
0
 /**
  * 职位设置
  */
 public function actionSetup()
 {
     $this->_modelUser = $this->_getGlobalData('Model_User', 'object');
     $this->_setupFilePath = CACHE_DIR . '/program/position.cache.php';
     if (file_exists($this->_setupFilePath)) {
         $dataList = $this->_getGlobalData('program/position');
         foreach ($dataList as $key => &$list) {
             $list['url_del'] = Tools::url(CONTROL, 'SetupDel', array('zp' => 'Program', 'Id' => $key));
         }
     } else {
         $dataList = null;
     }
     if ($dataList !== null) {
         $users = $this->_modelUser->findByDepartment(self::DEPARTMENT_IT);
         foreach ($users as $user) {
             if (!$user['position_id']) {
                 continue;
             }
             if (array_key_exists($user['position_id'], $dataList)) {
                 if (!is_array($dataList[$user['position_id']]['users'])) {
                     $dataList[$user['position_id']]['users'] = array();
                 }
                 array_push($dataList[$user['position_id']]['users'], $user);
             }
         }
     }
     $this->_view->assign('dataList', $dataList);
     $this->_utilMsg->createPackageNavBar();
     $this->_view->display();
 }
Exemplo n.º 6
0
 private function _getCardlist($UrlAppend = null, $get = null, $post = null)
 {
     $postData = $this->getPostData($post);
     $get = $this->_gameObject->getGetData($get);
     $data = $this->getResult($UrlAppend, $get, $postData);
     if ($data['status'] == 1) {
         $list = $data['data']['list'];
         if (is_array($list)) {
             foreach ($list as &$sub) {
                 $sub['URL_itemCardFailure'] = Tools::url(CONTROL, ACTION, array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'cardId' => $sub['cardId'], 'do' => 'failure'));
                 $sub['goods'] = $this->_getGoodsInfo($sub['goods']);
                 $sub['type'] = $this->cardType[$sub['type']];
             }
             $this->_assign['dataList'] = $list;
             $total = intval($data['data']['total']);
             $this->_loadCore('Help_Page');
             //载入分页工具
             $helpPage = new Help_Page(array('total' => $total, 'perpage' => PAGE_SIZE));
             $this->_assign['pageBox'] = $helpPage->show();
         }
     } else {
         $this->_assign['connectError'] = 'Error Info:' . $data['info'];
         return $this->_assign;
     }
     return $this->_assign;
 }
Exemplo n.º 7
0
 private function _add()
 {
     $typeArr = $this->_f("logType_" . $this->_gameObject->_gameId);
     $typeArr[$_POST["type_id"]] = array("cn" => $_POST["chinese"], "en" => $_POST["english"]);
     $this->_f("logType_" . $this->_gameObject->_gameId, $typeArr);
     $this->jump('操作成功', 1, Tools::url(CONTROL, 'LogType', array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId)));
 }
Exemplo n.º 8
0
 public function _allnoticeIndex()
 {
     $this->_assign['ajax'] = Tools::url(CONTROL, ACTION, array('zp' => PACKAGE, 'doaction' => 'ajax', '__game_id' => $this->_gameObject->_gameId));
     //		$this->_assign['del']				=	Tools::url(CONTROL,ACTION,array('zp'=>PACKAGE,'doaction'=>'del','__game_id'=>$this->_gameObject->_gameId));
     $this->_assign['tplServerSelect'] = "ActionGame_OperatorTools/AllNotice/ServerSelect.html";
     return $this->_assign;
 }
Exemplo n.º 9
0
 public function main($UrlAppend = null, $get = null, $post = null)
 {
     $serverId = $_REQUEST['server_id'];
     if (!$serverId) {
         return $this->_assign;
     }
     if ($this->_isPost()) {
         $postData = $this->getPostData($post);
         $getData = $this->_gameObject->getGetData($get);
         $apply_info = "申请原因:<br>{$_POST['cause']}<p>";
         //1的类型是奖励发送
         $apply_info .= '<div style="padding:3px; margin:3px; border:1px dashed #000">';
         $apply_info .= $this->goodsDis;
         $apply_info .= '<br>用户类型:' . $this->playerType[$_POST['playerType']];
         $apply_info .= '<br>用户:' . $_POST['player'];
         $apply_info .= '</div>';
         $gameser_list = $this->_getGlobalData('server/server_list_' . $_REQUEST['__game_id']);
         $applyData = array('type' => 50, 'server_id' => $_REQUEST['server_id'], 'operator_id' => $gameser_list[$_REQUEST['server_id']]['operator_id'], 'game_type' => $gameser_list[$_REQUEST['server_id']]['game_type_id'], 'list_type' => 1, 'apply_info' => $apply_info, 'send_type' => 2, 'send_data' => array('url_append' => $UrlAppend, 'post_data' => $postData, 'get_data' => $getData), 'receiver_object' => array($serverId => ''), 'player_type' => $_POST['playerType'], 'player_info' => $_POST['player']);
         $_modelApply = $this->_getGlobalData('Model_Apply', 'object');
         $applyInfo = $_modelApply->AddApply($applyData);
         // 				print_r($applyData);exit;
         // 				var_dump($applyInfo);exit;
         if (true === $applyInfo) {
             $URL_CsIndex = Tools::url('Apply', 'CsIndex');
             $URL_CsAll = Tools::url('Apply', 'CsAll');
             $showMsg = '申请成功,等待审核...<br>';
             $showMsg .= "<a href='{$URL_CsIndex}'>客服审核列表</a><br>";
             $showMsg .= "<a href='{$URL_CsAll}'>客服审核列表(全部)</a>";
             $this->jump($showMsg, 1, 1, false);
         } else {
             $this->jump($applyInfo['info'], -1);
         }
     }
     return $this->_assign;
 }
Exemplo n.º 10
0
 public function add($postArr)
 {
     if (empty($postArr['title'])) {
         return array('status' => -1, 'msg' => '请填写标题', 'href' => 1);
     }
     if (empty($postArr['description'])) {
         return array('status' => -1, 'msg' => '请填写描述', 'href' => 1);
     }
     if (empty($postArr['start_time'])) {
         return array('status' => -1, 'msg' => '请选择开始时间', 'href' => 1);
     }
     if (empty($postArr['end_time'])) {
         return array('status' => -1, 'msg' => '请选择结束时间', 'href' => 1);
     }
     $this->_utilRbac = $this->_getGlobalData('Util_Rbac', 'object');
     $userClass = $this->_utilRbac->getUserClass();
     $addArr = array();
     $addArr['title'] = $postArr['title'];
     $addArr['description'] = $postArr['description'];
     $addArr['start_time'] = strtotime($postArr['start_time']);
     $addArr['end_time'] = strtotime($postArr['end_time']);
     $addArr['create_time'] = CURRENT_TIME;
     $addArr['status'] = $postArr['status'];
     $addArr['user_id'] = $userClass['_id'];
     if (parent::add($addArr)) {
         return array('status' => 1, 'msg' => false, 'href' => Tools::url('Askform', 'Askform'));
     } else {
         return array('status' => -2, 'msg' => '添加问卷失败', 'href' => 1);
     }
 }
Exemplo n.º 11
0
 public function main($UrlAppend = NULL, $get = NULL, $post = NULL)
 {
     if (!$_REQUEST['server_id']) {
         return $this->_assign;
     }
     $this->_assign['server_id'] = $_REQUEST['server_id'];
     $postData = $this->getPostData($post);
     // 			print_r($postData);
     $getData = $this->_gameObject->getGetData($get);
     $data = $this->getResult($UrlAppend, $getData, $postData);
     // 			print_r($data);
     // 			exit;
     if ($data['status'] == 1 && is_array($data['data']['list'])) {
         $list = $data['data']['list'];
         //  				print_r($list);exit;
         foreach ($list as &$sub) {
             $sub['del_url'] = Tools::url(CONTROL, 'RewardTriggerDel', array('id' => $sub['id'], 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'doaction' => 'delById'));
             $sub['del_urlByTitle'] = Tools::url(CONTROL, 'RewardTriggerDel', array('title' => $sub['title'], 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'doaction' => 'delByTitle'));
             foreach ($sub['award'] as $k => $v) {
                 $award .= $v['cname'] . '(' . $v['num'] . ') ';
             }
             $sub['award'] = $award;
             $award = '';
         }
         $this->_assign['dataList'] = $list;
         // 				$this->_loadCore('Help_Page');//载入分页工具
         // 				$helpPage=new Help_Page(array('total'=>intval($data['data']['total']),'perpage'=>PAGE_SIZE));
         // 				$this->_assign['pageBox'] = $helpPage->show();
     }
     return $this->_assign;
 }
Exemplo n.º 12
0
 /**
  * 生成导航条
  * @param string $control 控制器
  * @param string $action 动作
  */
 public function createNavBar($control = CONTROL, $action = ACTION)
 {
     $this->_createView();
     $menuIndex = $this->_getGlobalData('menuIndex');
     $curValue = "{$control}_{$action}";
     #------生成2,3级导航条------#
     $curAction = $menuIndex[$curValue];
     if ($curAction['super_action']) {
         $lv3 = "<a href='javascript:void(0)'>{$curAction['name']}</a>";
         $superName = $menuIndex[$curAction['super_action']]['name'];
         $superValue = $menuIndex[$curAction['super_action']]['value'];
         $superAction = explode('_', $superValue);
         $superUrl = Tools::url($superAction[0], $superAction[1]);
         $lv2 = "<a href='{$superUrl}'>{$superName}</a>";
         $mainId = $menuIndex[$superValue]['parent_id'];
         foreach ($menuIndex as $value) {
             if ($value['Id'] == $mainId) {
                 $lv1 = $value['name'];
             }
         }
     } else {
         $lv2 = "<a href='" . Tools::url($control, $action) . "'>{$curAction['name']}</a>";
         $mainId = $menuIndex[$curValue]['parent_id'];
         foreach ($menuIndex as $value) {
             if ($value['Id'] == $mainId) {
                 $lv1 = $value['name'];
             }
         }
     }
     #------生成2,3级导航条------#
     $this->_view->set_tpl(array('navBar' => 'Default/NavigationBar.html'));
     $navBar = array('lv1' => $lv1, 'lv2' => $lv2, 'lv3' => $lv3);
     $this->_view->assign('nav', $navBar);
 }
Exemplo n.º 13
0
 public function _init()
 {
     $this->_assign[self::ITEM_TYPE] = Tools::gameConfig(self::ITEM_TYPE, $this->_gameObject->_gameId);
     //itemTypes
     $this->_assign[self::BIND_TYPE] = Tools::gameConfig(self::BIND_TYPE, $this->_gameObject->_gameId);
     //bindType
     $this->_assign[self::GOLD_TYPE] = Tools::gameConfig(self::GOLD_TYPE, $this->_gameObject->_gameId);
     //goldType
     $this->_assign[self::KEY_TYPE] = Tools::gameConfig(self::KEY_TYPE, $this->_gameObject->_gameId);
     //keyType
     $this->_assign[self::ITEM_PACKAGE_TYPE] = Tools::gameConfig(self::ITEM_PACKAGE_TYPE, $this->_gameObject->_gameId);
     //keyType
     $this->_assign[self::EXCHANGE_TYPE] = Tools::gameConfig(self::EXCHANGE_TYPE, $this->_gameObject->_gameId);
     //keyType
     $this->_assign['itemReceiveConditions'] = $this->partner('ItemReceiveCondition');
     //礼包领取的条件
     $this->_assign['items'] = $this->partner('Item');
     $this->_assign['selected'][self::BIND_TYPE] = 2;
     //0:不绑定,1:绑定服,2:绑定玩家
     $this->_assign['selected'][self::GOLD_TYPE] = 2;
     //1:系统元宝,2:GM元宝
     $this->_assign['selected'][self::KEY_TYPE] = 1;
     //1:36位,2 10位
     $this->_assign['selected'][self::ITEM_PACKAGE_TYPE] = 100;
     //100:标准礼包,200: 共享礼包
     $this->_assign['selected'][self::EXCHANGE_TYPE] = 2;
     //1:补偿金币卡,2: 智能金币卡
     $this->_assign['URL_itemReceiveConditions'] = Tools::url(CONTROL, 'ItemReceiveCondition', array('timeout' => '1', 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
     $this->_assign['URL_itemUpdate'] = Tools::url(CONTROL, 'Item', array('timeout' => '1', 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
     $this->_assign['URL_itemCard'] = Tools::url(CONTROL, 'ItemCard', array('submit' => 1, 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
     $this->_assign['URL_playerLookup'] = Tools::url(CONTROL, 'PlayerLookup', array('sbm' => 1, 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
 }
Exemplo n.º 14
0
 public function edit($postArr)
 {
     if (empty($postArr['Id'])) {
         return array('msg' => '参数错误', 'status' => -1, 'href' => 2);
     }
     if (empty($postArr['name'])) {
         return array('msg' => '项目名称不能为空', 'status' => -1, 'href' => 2);
     }
     if (empty($postArr['principal_user_id'])) {
         return array('msg' => '请选择项目负责人', 'status' => -1, 'href' => 2);
     }
     if (empty($postArr['detail'])) {
         $postArr['detail'] = '暂无内容';
     }
     $updateArr = array('name' => $postArr['name'], 'principal_user_id' => $postArr['principal_user_id'], 'detail' => $postArr['detail']);
     $this->update($updateArr, "Id={$postArr['Id']}");
     $this->_modelUser = $this->_getGlobalData('Model_User', 'object');
     $this->_modelUser->execute("update {$this->_modelUser->tName()} set project_id=0 where project_id = {$postArr['Id']}");
     if (count($postArr['user_id'])) {
         $this->_modelUser->execute("update {$this->_modelUser->tName()} set project_id={$postArr['Id']} where Id in (" . implode(',', $postArr['user_id']) . ")");
     }
     $this->_modelUser->createCache();
     $this->createCache();
     return array('msg' => '项目修改成功', 'status' => 1, 'href' => Tools::url('ProgramProject', 'Index', array('zp' => 'Program')));
 }
Exemplo n.º 15
0
 public function edit($postArr)
 {
     $postArr['Id'] = intval($postArr['Id']);
     if (!$postArr['Id']) {
         return array('msg' => '参数错误', 'status' => '-1', 'href' => 2);
     }
     if (!$postArr['game_type_id']) {
         return array('msg' => '请选择游戏', 'status' => '-1', 'href' => 2);
     }
     if (!$postArr['type']) {
         return array('msg' => '请选类型', 'status' => '-1', 'href' => 2);
     }
     if (!$postArr['progress']) {
         return array('msg' => '请选择进展', 'status' => '-1', 'href' => 2);
     }
     if (!$postArr['title']) {
         return array('msg' => '请输入标题', 'status' => '-1', 'href' => 2);
     }
     if (!$postArr['content']) {
         return array('msg' => '请输入内容', 'status' => '-1', 'href' => 2);
     }
     $this->_utilRbac = $this->_getGlobalData('Util_Rbac', 'object');
     $userClass = $this->_utilRbac->getUserClass();
     $updateArr = array('game_type_id' => intval($postArr['game_type_id']), 'type' => intval($postArr['type']), 'progress' => intval($postArr['progress']), 'title' => $postArr['title'], 'content' => $postArr['content'], 'edit_time' => CURRENT_TIME, 'user_id' => $userClass['_id']);
     $this->update($updateArr, "Id={$postArr['Id']}");
     return array('msg' => '编辑成功', 'status' => '1', 'href' => Tools::url('Worker', 'Index', array('zp' => 'LianYun')));
 }
Exemplo n.º 16
0
 public function _init()
 {
     $query = array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'playerType' => 0);
     $ShortcutUrl = array('SendMail' => Tools::url(CONTROL, 'SendMail', $query), 'AddTitleOrGag' => Tools::url(CONTROL, 'AddTitleOrGag', $query));
     $this->_assign['ShortcutUrl'] = $ShortcutUrl;
     $this->_assign['userType'] = array(0 => '玩家ID', 1 => '玩家账号', 2 => '玩家昵称');
 }
Exemplo n.º 17
0
 public function edit($postArr)
 {
     if (empty($postArr['Id'])) {
         return array('status' => -1, 'msg' => '请选择要编辑的投票配置', 'href' => 1);
     }
     if (empty($postArr['conf_name'])) {
         return array('status' => -1, 'msg' => '请填定配置名称', 'href' => 1);
     }
     if (empty($postArr['description'])) {
         return array('status' => -1, 'msg' => '请填定说明', 'href' => 1);
     }
     if (!count($postArr['option'])) {
         return array('status' => -1, 'msg' => '至少要有一个投票选项', 'href' => 1);
     }
     if (!count($postArr['user'])) {
         return array('status' => -1, 'msg' => '至少要有一个投票用户', 'href' => 1);
     }
     $updateArr = array();
     $updateArr['conf_name'] = $postArr['conf_name'];
     $updateArr['description'] = $postArr['description'];
     $updateArr['is_open'] = $postArr['is_open'];
     $updateArr['content'] = serialize($postArr['option']);
     $updateArr['vote_user'] = serialize($postArr['user']);
     if ($this->update($updateArr, "Id={$postArr['Id']}")) {
         return array('status' => 1, 'msg' => "编辑 [{$postArr['conf_name']}] 配置成功", 'href' => Tools::url(CONTROL, ACTION, array('doaction' => 'conf')));
     } else {
         return array('status' => -1, 'msg' => '编辑配置失败', 'href' => 1);
     }
 }
Exemplo n.º 18
0
 public function _allnoticeIndex()
 {
     $senddata = array('game_type' => $this->_gameObject->_gameId, 'page' => $_GET['page'] ? $_GET['page'] : '1', 'zp' => PACKAGE);
     if ($this->_isPost()) {
         if ($_POST['start_time']) {
             $senddata['start_time'] = $_POST['start_time'];
         }
         if ($_POST['end_time']) {
             $senddata['end_time'] = $_POST['end_time'];
         }
         if ($_POST['content']) {
             $senddata['content'] = $_POST['content'];
         }
     }
     $model = $this->_getGlobalData('Model_Notice', 'object');
     $data = $model->getNoticelist($senddata);
     if ($data['dataList']) {
         foreach ($data['dataList'] as &$value) {
             $value['url_edit'] = Tools::url(CONTROL, 'NoticeEdit', array('zp' => PACKAGE, 'server_id' => $value['server_main_id'], 'id' => $value['main_id'], '__game_id' => $value['game_type']));
         }
         $this->_assign['datalist'] = $data['dataList'];
         $this->_assign['pageBox'] = $data['pageBox'];
     }
     $this->_assign['post'] = $_POST;
     $this->_assign['ajax'] = Tools::url(CONTROL, ACTION, array('zp' => PACKAGE, 'doaction' => 'ajax', '__game_id' => $this->_gameObject->_gameId));
     $this->_assign['del'] = Tools::url(CONTROL, ACTION, array('zp' => PACKAGE, 'doaction' => 'del', '__game_id' => $this->_gameObject->_gameId));
     $this->_assign['tplServerSelect'] = "ActionGame_OperatorTools/AllNotice/ServerSelect.html";
     return $this->_assign;
 }
Exemplo n.º 19
0
 private function _createUrl()
 {
     $this->_url['ProgramStats_MonthAssignMarks'] = Tools::url(CONTROL, 'MonthAssignMarks', array('zp' => 'Program'));
     $this->_url['Program_EditMonthMarks'] = Tools::url(CONTROL, 'EditMonthMarks', array('zp' => 'Program'));
     $this->_url['ProgramStats_QuarterAssignMarks'] = Tools::url(CONTROL, 'QuarterAssignMarks', array('zp' => 'Program'));
     $this->_url['Program_EditQuarterMarks'] = Tools::url(CONTROL, 'EditQuarterMarks', array('zp' => 'Program'));
     $this->_view->assign('url', $this->_url);
 }
Exemplo n.º 20
0
 private function _createUrl()
 {
     $this->_url['Stats_Detail'] = Tools::url(CONTROL, 'Detail');
     $this->_url['Stats_Index'] = Tools::url(CONTROL, 'Index');
     $this->_url['Stats_Operator'] = Tools::url(CONTROL, 'Operator');
     $this->_url['Stats_OperatorDay'] = Tools::url(CONTROL, 'OperatorDay');
     $this->_view->assign('url', $this->_url);
 }
Exemplo n.º 21
0
 protected function _createUrl()
 {
     $this->_url['OperatorTools_Libao_serverSync'] = Tools::url('OperatorTools', 'ItemCardSync', array('zp' => self::PACKAGE, 'doaction' => 'serverSync', '__game_id' => $_REQUEST['__game_id']));
     $this->_url['OperatorTools_Notice_serverSync'] = Tools::url('OperatorTools', 'NoticeSync', array('zp' => self::PACKAGE, 'doaction' => 'serverSync', '__game_id' => $_REQUEST['__game_id']));
     $this->_url['OperatorTools_Activities_serverSync'] = Tools::url('OperatorTools', 'ActivitiesSync', array('zp' => self::PACKAGE, 'doaction' => 'serverSync', '__game_id' => $_REQUEST['__game_id']));
     $this->_url['OperatorTools_ShopProduce_serverSync'] = Tools::url('OperatorTools', 'ShopProduceSync', array('zp' => self::PACKAGE, 'doaction' => 'serverSync', '__game_id' => $_REQUEST['__game_id']));
     $this->_view->assign('url', $this->_url);
 }
Exemplo n.º 22
0
 public function __construct()
 {
     $this->args = func_get_args();
     $this->view = new View($this->layout, get_class($this));
     if (is_null($this->noAuth) && empty(Registry::get('user'))) {
         $_SESSION['from_url'] = Tools::url($_SERVER['REQUEST_URI']);
         $_SESSION['redirect_message'] = json_encode(['type' => 'info', 'message' => 'Вы не авторизованы в системе!<br>Пожалуйста, нажмите на кнопку &quot;Войти в систему&quot;']);
         Tools::redirect();
     }
 }
Exemplo n.º 23
0
 public function main($UrlAppend = null, $get = null, $post = null)
 {
     if (!$_REQUEST['submit']) {
         return $this->_assign;
     }
     $postData = $this->getPostData($post);
     $getData = $this->_gameObject->getGetData($get);
     unset($getData['serverId']);
     //这个接口不用serverId这个参数
     $data = $this->getResult($UrlAppend, $getData, $postData);
     // 		print_r($data);
     // 		print_r($postData);
     // 		print_r($getData);
     if (!($data && $data['status'] == 1)) {
         $this->_assign['connectError'] = 'Error Info:' . $data['info'];
         return $this->_assign;
     }
     $itemsCon = array();
     if (is_array($tmpData = $data['data']) && is_array($tmpData = $tmpData['list'])) {
         foreach ($tmpData as &$sub) {
             //$sub['type'] = '';
             $sub['URL_itemCardAppendApply'] = Tools::url(CONTROL, 'ItemCardAppendApply', array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'classId' => $sub['id'], 'bindType' => $sub['bindType'], 'type' => $sub['type']));
             $sub['URL_batchList'] = Tools::url(CONTROL, 'ItemCardShowBatch', array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'classId' => $sub['id']));
             $sub['URL_ItemPackageEdit'] = Tools::url(CONTROL, 'ItemPackageEdit', array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'classId' => $sub['id'], 'submit' => 1));
             $sub['bindType'] = $this->_assign[self::BIND_TYPE][$sub['bindType']];
             $sub['goldType'] = $this->_assign[self::GOLD_TYPE][$sub['goldType']];
             // 				$sub['goods'] = json_decode($sub['goods'],true);
             if (is_array($sub['goods'])) {
                 foreach ($sub['goods'] as $item) {
                     $itemsCon[$item['goodsId']] = '';
                 }
             }
         }
         $itemsCon = $this->_getItemsName($itemsCon);
         foreach ($tmpData as &$sub) {
             $sub['itemInfo'] = '';
             if (is_array($sub['goods'])) {
                 foreach ($sub['goods'] as $item) {
                     $sub['itemInfo'] .= $itemsCon[$item['goodsId']] . "(<font color='#FF0000'>{$item['num']}</font>),";
                 }
             }
         }
         $this->_assign['dataList'] = $tmpData;
         if ($data['data']['total']) {
             $total = intval($data['data']['total']);
             $this->_loadCore('Help_Page');
             //载入分页工具
             $helpPage = new Help_Page(array('total' => $total, 'perpage' => PAGE_SIZE));
             $this->_assign['pageBox'] = $helpPage->show();
         }
     } else {
         $this->_assign['connectError'] = 'Error Info:返回数据结构有误';
     }
     return $this->_assign;
 }
Exemplo n.º 24
0
 public function add($postArr)
 {
     $this->_utilRbac = $this->_getGlobalData('Util_Rbac', 'object');
     $userClass = $this->_utilRbac->getUserClass();
     $addArr = array('user_id' => $userClass['_id'], 'create_time' => CURRENT_TIME, 'content' => $postArr['content']);
     if (parent::add($addArr)) {
         return array('status' => 1, 'msg' => false, 'href' => Tools::url(CONTROL, 'BugBack'));
     } else {
         return array('status' => -2, 'msg' => '添加bug失败', 'href' => Tools::url(CONTROL, 'BugBack'));
     }
 }
Exemplo n.º 25
0
 private function _urlstate($val = '')
 {
     $query = array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']);
     if ($val == "Mutil") {
         $query['WorldID'] = 0;
     } else {
         $serverList = $this->_getGlobalData('server/server_list_' . $this->_gameObject->_gameId);
         $query['WorldID'] = $serverList[$_REQUEST['server_id']]['ordinal'];
     }
     return Tools::url(CONTROL, 'ServerState', $query);
 }
Exemplo n.º 26
0
 public function _init()
 {
     $serverList = $this->_getGlobalData('server/server_list_18');
     $dataInfo = $serverList[$_REQUEST['server_id']]["data_url"];
     $dataInfo = explode(";", $dataInfo);
     $this->operator_id = $serverList[$_REQUEST['server_id']]["operator_id"];
     $this->dataIp = $dataInfo[0];
     $this->dataBase = $dataInfo[1];
     $this->_jdbc = "jdbc:mysql://s82.app24599.qqopenapp.com:8010/" . $dataInfo[1] . "?characterEncoding=utf8&connectTimeout=30000&extrakey=kkyt678&extra=" . $dataInfo[0] . "&tgw=tgw_l7_forward";
     $query = array('zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id'], 'playerType' => 1);
     $ShortcutUrl = array('SendMail' => Tools::url(CONTROL, 'SendMail', $query), 'SilenceAdd' => Tools::url(CONTROL, 'SilenceAdd', $query), 'LockAccountAdd' => Tools::url(CONTROL, 'LockAccountAdd', $query), 'PointDel' => Tools::url(CONTROL, 'PointDel', $query));
     $this->_assign['ShortcutUrl'] = $ShortcutUrl;
 }
 /**
  * 显示已经点配菜列表
  */
 public function SelectedRemarkAction()
 {
     $listArr = $_SESSION['currentItem'];
     $remarkArr = $_SESSION['menu'][$listArr['site_no']][$listArr['item_no']]['remark'];
     if ($remarkArr) {
         foreach ($remarkArr as &$list) {
             $list['actionLang'] = $this->_uMsg->remarkOption[$list['action_lv']];
         }
     }
     $this->_view->assign('body_page', 'Remark/SelectedRemark.html');
     $this->_view->assign('remarkList', $remarkArr);
     $this->_view->assign('delRemarkURL', Tools::url('Remark', 'DelRemark'));
     $this->_view->display('Default/SystemView.html');
 }
Exemplo n.º 28
0
 public function main($UrlAppend = null, $get = null, $post = null)
 {
     if ($_REQUEST['server_id']) {
         //如果选择了服务器将显示
         if ($this->_isPost() && $_POST['submit']) {
             //提交表单
             $serverId = $_POST['server_id'];
             $getData = array();
             $getData['playerType'] = $_POST['ReceiveType'];
             $getData['playerIds'] = base64_encode(str_replace(',', ',', $_POST['UserIds']));
             $getData['num'] = intval($_POST['ingotNum']);
             $getData['title'] = base64_encode(trim($_POST['MsgTitle']));
             $getData['content'] = base64_encode(trim($_POST['MsgContent']));
             $utilRbac = $this->_getGlobalData('Util_Rbac', 'object');
             $userClass = $utilRbac->getUserClass();
             if ($userClass['_departmentId'] == 1 && in_array('kf_xz', $userClass['_roles'])) {
                 if ($getData['num'] > 20000) {
                     $this->jump('元宝不能过20000', -1);
                 }
             }
             $receiveType = array(1 => '用户ID', 2 => '用户名', 3 => '用户昵称');
             $apply_info = "申请原因:<br>{$_POST['cause']}<p>";
             //1的类型是奖励发送
             $apply_info .= '<div style="padding:3px; margin:3px; border:1px dashed #000">';
             $apply_info .= '元宝:' . $_POST['ingotNum'];
             $apply_info .= '<br>用户类型:' . $receiveType[$_POST['ReceiveType']];
             $apply_info .= '<br>用户:' . $_POST['UserIds'];
             $apply_info .= '</div>';
             $gameser_list = $this->_getGlobalData('server/server_list_' . $_REQUEST['__game_id']);
             $applyData = array('type' => 45, 'server_id' => $_REQUEST['server_id'], 'operator_id' => $gameser_list[$_REQUEST['server_id']]['operator_id'], 'game_type' => $gameser_list[$_REQUEST['server_id']]['game_type_id'], 'list_type' => 1, 'apply_info' => $apply_info, 'send_type' => 2, 'send_data' => array('url_append' => $UrlAppend, 'post_data' => array(), 'get_data' => $this->_getData($getData)), 'receiver_object' => array($serverId => ''), 'player_type' => $_POST['ReceiveType'], 'player_info' => $_POST['UserIds']);
             $_modelApply = $this->_getGlobalData('Model_Apply', 'object');
             // 				print_r($applyData);exit;
             $applyInfo = $_modelApply->AddApply($applyData);
             // 				print_r($applyInfo);exit;
             if (true === $applyInfo) {
                 $URL_CsIndex = Tools::url('Apply', 'CsIndex');
                 $URL_CsAll = Tools::url('Apply', 'CsAll');
                 $showMsg = '申请成功,等待审核...<br>';
                 $showMsg .= "<a href='{$URL_CsIndex}'>客服审核列表</a><br>";
                 $showMsg .= "<a href='{$URL_CsAll}'>客服审核列表(全部)</a>";
                 $this->jump($showMsg, 1, 1, false);
             } else {
                 $this->jump($applyInfo['info'], -1);
             }
         }
     }
     return $this->_assign;
 }
Exemplo n.º 29
0
 public function runGlobal()
 {
     $curAction = CONTROL . '_' . ACTION;
     switch ($this->_utilRbac->checkAct($curAction)) {
         case 1:
             //已经登录,通过
             return true;
         case -1:
             //没有权限
             $this->_utilMsg->showMsg('您没有权限', -1);
             break;
         case -2:
             //未登录
             $this->_utilMsg->showMsg('您还未登录', -2, Tools::url('Index', 'Login'));
     }
 }
Exemplo n.º 30
0
 public function _init()
 {
     $this->_playerType = Tools::gameConfig('userType', $this->_gameObject->_gameId);
     $this->_cardType = Tools::gameConfig('cardType', $this->_gameObject->_gameId);
     $this->_assign['playerType'] = $this->_playerType;
     /*客服现在全服功能  */
     $utilRbac = $this->_getGlobalData('Util_Rbac', 'object');
     $userClass = $utilRbac->getUserClass();
     if ($userClass['_departmentId'] == 1 && in_array('kf_xz', $userClass['_roles'])) {
         unset($this->_cardType[3], $this->_cardType[4]);
     }
     /*客服现在全服功能  */
     $this->_assign['cardType'] = $this->_cardType;
     $this->_assign['items'] = $this->partner('Item');
     $this->_assign['URL_itemUpdate'] = Tools::url(CONTROL, 'Item', array('timeout' => '1', 'zp' => PACKAGE, '__game_id' => $this->_gameObject->_gameId, 'server_id' => $_REQUEST['server_id']));
 }