public function showAllTrunksIpAccessList($trunkId)
 {
     $ossbss = new Ossbss();
     $inputs['sipTrunkId'] = $trunkId;
     $result = $ossbss->getInfo("trunks.allTrunksIpList", $inputs, $trunkId);
     $result = unsetParam($result, 'msg', 'paging', 'flag');
     return json_encode($result);
 }
 public function showList()
 {
     $ossbss = new Ossbss();
     $start = $_GET['start'];
     $length = $_GET['length'];
     $inputs['offset'] = 0;
     $inputs['limit'] = 10;
     $result = $ossbss->getInfo('clientApps.showList', $inputs);
     $result = unsetParam($result, "msg");
     return json_encode($result);
 }
 public function index(Request $request)
 {
     $a = $request->only('page');
     if ($a['page'] == null) {
         $page = 1;
     } else {
         $inputs = $request->only('page');
         //只获取页码数
         $page = $inputs['page'];
     }
     $offset = ($page - 1) * $this->_perNums;
     $data['offset'] = $offset;
     $data['limit'] = $this->_perNums;
     $ossbss = new Ossbss();
     $res = $ossbss->getInfo("numbers.showList", $data);
     $res['data'] = isset($res['data']) ? $res['data'] : array();
     return view('test/testing', array("active" => "menu_number , menu_number_listing", "pagetitle" => "Numbers Listing", 'listDatas' => $res['data']));
 }
 public function removeApp(Request $request, $id)
 {
     $inputs['id'] = $id;
     $params[0] = $id;
     $ossbss = new Ossbss();
     $result = $ossbss->deleteInfo('serverApps.removeApp', $inputs, $params);
     return json_encode($result);
 }
 public function deleteAssignedNum(Request $request)
 {
     $inputs = $request->except('_token');
     $numbers = $inputs['number'];
     $data = array();
     foreach ($numbers as $num) {
         $data['number'] = $num;
         $data['sip_trunk_id'] = "";
         $data['voice_bind_type'] = "";
         $data['message_bind_type'] = "";
         $data['developer_id'] = Session::get('account_sid');
         Log::info($data);
         $params['number'] = $num;
         $ossbss = new Ossbss();
         $result = $ossbss->putInfo("numbers.doReleased", $data, $params);
         return json_encode($result);
     }
 }