"dev_buttons",label=>"Buttons Configuration"), array("name"=>"button",label=>"Buttons ",help=>"help.") ); //$buttons_type= array("empty","line","service","feature","speeddial"); // "feature","service" -- Add leter ! $buttons_type= array("empty","line","silent","monitor","speeddial","feature","adv.line"); $feature_list= array('parkinglot'=>'Park Slots','monitor'=> "Record Calls",'devstate'=> "Change Status"); $lines_list = $this->dbinterface->get_db_SccpTableData('SccpExtension'); //$hint_list = $this->dbinterface->get_db_SccpTableData('SccpExtension'); $hint_list = $this->get_hint_info(true,array('context'=>'park-hints')) ; // print_r($hint_list); $line_id =0; $max_buttons =56; $show_buttons =1; //print_r($hint_list); if (!empty($_REQUEST['id'])) { $dev_id = $_REQUEST['id']; $db_buttons = $this->dbinterface->get_db_SccpTableData('get_sccpdevice_buttons', array("id" => $dev_id)); $db_device = $this->dbinterface->get_db_SccpTableData('get_sccpdevice_byid', array("id" => $dev_id)); $max_buttons = $db_device['buttons']; if (!empty($db_device['addon_buttons'])){ $max_buttons += $db_device['addon_buttons']; } $show_buttons = $max_buttons; } if (!empty($_REQUEST['new_id'])) { $val = $_REQUEST['type']; $dev_schema = $this-> getSccp_model_information('byid', false, "all", array('model' =>$val)); // $db_device = $this->dbinterface->get_db_SccpTableData('get_sccpdevice_byid', array("id" => $val)); $max_buttons = $dev_schema[0]['buttons']; if (!empty($_REQUEST['addon'])) { $val = $_REQUEST['addon']; $dev_schema = $this-> getSccp_model_information('byid', false, "all", array('model' =>$val)); $max_buttons += $dev_schema[0]['buttons']; } $show_buttons = $max_buttons; } if (!empty($_REQUEST['ru_id'])) { $dev_id = $_REQUEST['ru_id']; $db_buttons = $this->dbinterface->get_db_SccpTableData('get_sccpdevice_buttons', array("id" => $dev_id)); $show_buttons = $max_buttons; } ?>