Fix various issues with buttons
Add choice of default line on add device Partially fix buttoncount (will not work if default device is selected) Correct database save logic for buttons - triggers should be OK but more verification needed Fix various save issues where defaults not correctly set Delete default buttons when deleting line to avoid orphans
This commit is contained in:
parent
80cf629c0f
commit
26f750296a
|
@ -383,6 +383,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
|
||||
function getPhoneButtons($get_settings, $ref_id = '', $ref_type = 'sccpdevice') {
|
||||
// get Model Buttons info
|
||||
dbug($get_settings);
|
||||
$res = array();
|
||||
$def_feature = array('parkinglot' => array('name' => 'P.slot', 'value' => 'default'),
|
||||
'devstate' => array('name' => 'Coffee', 'value' => 'coffee'),
|
||||
|
@ -489,10 +490,11 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
break;
|
||||
}
|
||||
if (!empty($btn_t)) {
|
||||
$res[] = array('ref' => $ref_id, 'reftype' => $ref_type, 'instance' => (string) ($it + 1), 'type' => $btn_t, 'name' => $btn_n, 'options' => $btn_opt);
|
||||
$res[] = array('ref' => $ref_id, 'reftype' => $ref_type, 'instance' => (string) ($it + 1), 'buttontype' => $btn_t, 'name' => $btn_n, 'options' => $btn_opt);
|
||||
}
|
||||
}
|
||||
}
|
||||
dbug($res);
|
||||
return $res;
|
||||
}
|
||||
|
||||
|
@ -796,7 +798,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
if (empty($button_list)) {
|
||||
return array('Response' => ' 0 buttons found ', 'data' => '');
|
||||
}
|
||||
$copy_fld = array('ref', 'reftype', 'instance', 'buttontype');
|
||||
$copy_fld = array('ref', 'reftype', 'instance', 'buttontype', 'options');
|
||||
$extList = $extList = $this->dbinterface->get_db_SccpTableByID("SccpExtension", array(), 'name');
|
||||
foreach ($button_list as $value) {
|
||||
$btn_opt = explode(',', $value['options']);
|
||||
|
@ -1068,9 +1070,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
}
|
||||
|
||||
function getSccpModelInformation($get = "all", $validate = false, $format_list = "all", $filter = array()) {
|
||||
// $file_ext = array('.loads', '.LOADS', '.sbn', '.SBN', '.bin', '.BIN','.zup','.ZUP');
|
||||
$file_ext = array('.loads', '.sbn', '.bin', '.zup');
|
||||
// $dir = $this->sccppath["tftp_path"];
|
||||
$dir = $this->sccppath['tftp_firmware_path'];
|
||||
$dir_tepl = $this->sccppath['tftp_templates_path'];
|
||||
|
||||
|
|
|
@ -296,6 +296,7 @@ $(document).ready(function () {
|
|||
}
|
||||
|
||||
var btn_add = $('#sccp_hw_addon').find(':selected').data('val');
|
||||
$('#buttonscount').attr('value',btn_dev + btn_add);
|
||||
$('.line_button').each(function () {
|
||||
if ($(this).data('id') < btn_dev + btn_add) {
|
||||
$(this).removeClass('hidden');
|
||||
|
@ -307,6 +308,12 @@ $(document).ready(function () {
|
|||
|
||||
});
|
||||
|
||||
$('.lineSelect').change(function (e) {
|
||||
var type_id = $('#sccp_hw_defaultLine').find(':selected').data('id');
|
||||
$("select.lineid_0 option:selected").prop("selected",false);
|
||||
$("select.lineid_0 option[value=" + type_id + "]").prop("selected",true);
|
||||
});
|
||||
|
||||
$('.sccp_button_hide').each(function () {
|
||||
// On page create !!
|
||||
var dev_id = $(this).data('vhide');
|
||||
|
|
|
@ -1263,7 +1263,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<name>type</name>
|
||||
<default>7911</default>
|
||||
<select name="model" dataid="dns" dataval="buttons">model</select>
|
||||
<class>hw_select sccp-custom</class>
|
||||
<class>hw_select form-control</class>
|
||||
<help>The type of phone: 7911, 7940, 7960, etc. Important note: the 'G' models are handled as the base model (e.g., 7962G is handled as 7962). In the Display mode, this field is read-only because the MAC address and the model number are a pair.</help>
|
||||
</item>
|
||||
<item type="SDE" id="3" seq="99">
|
||||
|
@ -1271,7 +1271,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<name>addon</name>
|
||||
<default>NONE</default>
|
||||
<select name="model" dataval="buttons">description</select>
|
||||
<class>hw_select sccp-custom</class>
|
||||
<class>hw_select form-control</class>
|
||||
<help>Addon: Addons are model specific and only work with certain base phones. This phone model is identified as being a phone that does not accept sidecars. Update devmodel if this is not correct.</help>
|
||||
</item>
|
||||
</page_group>
|
||||
|
@ -1322,6 +1322,14 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
</input>
|
||||
<help>The information in the upper right corner of the device screen. Only English letters and digits !</help>
|
||||
</item>
|
||||
<item type="SDML" id="1" seq="100">
|
||||
<label>Default Line</label>
|
||||
<name>defaultLine</name>
|
||||
<default></default>
|
||||
<select name="name" addlabel='label' dataid="name" dataval="label">model</select>
|
||||
<class>lineSelect form-control</class>
|
||||
<help>Select the default line for this device</help>
|
||||
</item>
|
||||
<item type="SLK" id="2" seq="99">
|
||||
<label>Soft Keyset</label>
|
||||
<name>softkeyset</name>
|
||||
|
@ -1894,7 +1902,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<name>type</name>
|
||||
<default>7911</default>
|
||||
<select name="model" dataid="dns" dataval="buttons">model</select>
|
||||
<class>hw_select sccp-custom</class>
|
||||
<class>form-control hw_select</class>
|
||||
<help>The type of phone: 7911, 7940, 7960, etc. Important note: the 'G' models are handled as the base model (e.g., 7962G is handled as 7962). In the Display mode, this field is read-only because the MAC address and the model number are a pair.</help>
|
||||
</item>
|
||||
<item type="SDE" id="3" seq="99">
|
||||
|
@ -1902,7 +1910,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<name>addon</name>
|
||||
<default>NONE</default>
|
||||
<select name="model" dataval="buttons">model</select>
|
||||
<class>hw_select sccp-custom</class>
|
||||
<class>hw_select form-control</class>
|
||||
<help>Addon: Addons are model specific and only work with certain base phones. This phone model is identified as being a phone that does not accept sidecars. Update devmodel if this is not correct.</help>
|
||||
</item>
|
||||
</page_group>
|
||||
|
|
|
@ -182,9 +182,12 @@ class Sccp extends \FreePBX\modules\Core\Driver {
|
|||
}
|
||||
|
||||
public function delDevice($id) {
|
||||
//Required by FreePBX
|
||||
$sql = "DELETE FROM sccpline WHERE name = ?";
|
||||
$sth = $this->database->prepare($sql);
|
||||
//Required by FreePBX.
|
||||
// Delete associated default line buttons or will leave orphans
|
||||
$sth = $this->database->prepare("DELETE FROM sccpbuttonconfig WHERE ref = ? AND instance = 1 AND buttontype = 'line'");
|
||||
$sth->execute(array($id));
|
||||
|
||||
$sth = $this->database->prepare("DELETE FROM sccpline WHERE name = ?");
|
||||
$sth->execute(array($id));
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -49,6 +49,7 @@ class dbinterface
|
|||
// $stmt is a single row fetch, $stmts is a fetchAll while stmtU is fetchAll UNIQUE
|
||||
$stmt = '';
|
||||
$stmts = '';
|
||||
$stmtU = '';
|
||||
if ($dataid == '') {
|
||||
return false;
|
||||
}
|
||||
|
@ -60,7 +61,7 @@ class dbinterface
|
|||
break;
|
||||
case 'SccpExtension':
|
||||
if (empty($data['name'])) {
|
||||
$stmts = $this->db->prepare('SELECT * FROM sccpline ORDER BY name');
|
||||
$stmtU = $this->db->prepare('SELECT name, sccpline.* FROM sccpline ORDER BY name');
|
||||
} else {
|
||||
$stmts = $this->db->prepare('SELECT * FROM sccpline WHERE name = :name');
|
||||
$stmts->bindParam(':name', $data['name'],\PDO::PARAM_STR);
|
||||
|
@ -111,15 +112,6 @@ class dbinterface
|
|||
$stmts = $this->db->prepare("SELECT {$fld} FROM sccpdeviceconfig ORDER BY name");
|
||||
}
|
||||
break;
|
||||
case 'HWSipDevice':
|
||||
$raw_settings = $this->getDb_model_info($get = "sipphones", $format_list = "model");
|
||||
break;
|
||||
case 'HWDevice':
|
||||
$raw_settings = $this->getDb_model_info($get = "ciscophones", $format_list = "model");
|
||||
break;
|
||||
case 'HWextension':
|
||||
$raw_settings = $this->getDb_model_info($get = "extension", $format_list = "model");
|
||||
break;
|
||||
case 'get_columns_sccpdevice':
|
||||
$stmts = $this->db->prepare('DESCRIBE sccpdevice');
|
||||
break;
|
||||
|
@ -140,6 +132,13 @@ class dbinterface
|
|||
$stmt = $this->db->prepare('SELECT * FROM sccpuser WHERE name = :name');
|
||||
$stmt->bindParam(':name', $data['id'],\PDO::PARAM_STR);
|
||||
break;
|
||||
case 'getAssignedExtensions':
|
||||
// all extensions that are designed as default lines
|
||||
$stmtU = $this->db->prepare("SELECT DISTINCT name, name FROM sccpbuttonconfig WHERE buttontype = 'line' AND instance =1");
|
||||
break;
|
||||
case 'getDefaultLine':
|
||||
$stmt = $this->db->prepare("SELECT name FROM sccpbuttonconfig WHERE ref = '{$data['id']}' and instance =1 and buttontype = 'line'");
|
||||
break;
|
||||
case 'get_sccpdevice_buttons':
|
||||
$sql = '';
|
||||
if (!empty($data['buttontype'])) {
|
||||
|
@ -162,7 +161,7 @@ class dbinterface
|
|||
$raw_settings = array();
|
||||
}
|
||||
break;
|
||||
// No default case so will give exception of $raw_settings undefined if there
|
||||
// No default case so will give exception of $raw_settings undefined if the
|
||||
// dataid is not in the switch.
|
||||
}
|
||||
if (!empty($stmt)) {
|
||||
|
@ -323,29 +322,51 @@ class dbinterface
|
|||
break;
|
||||
case 'replace':
|
||||
foreach ($save_value as $button_array) {
|
||||
$stmt = $this->db->prepare('UPDATE sccpbuttonconfig SET name =:name WHERE ref = :ref AND reftype =:reftype AND instance = :instance AND buttontype = :buttontype');
|
||||
$stmt = $this->db->prepare('UPDATE sccpbuttonconfig SET name =:name WHERE ref = :ref AND reftype =:reftype AND instance = :instance AND buttontype = :buttontype AND options = :options');
|
||||
$stmt->bindParam(':ref', $button_array['ref'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':reftype', $button_array['reftype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':instance', $button_array['instance'],\PDO::PARAM_INT);
|
||||
$stmt->bindParam(':buttontype', $button_array['type'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':buttontype', $button_array['buttontype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':name', $button_array['name'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':options', $button_array['options'],\PDO::PARAM_STR);
|
||||
$result= $stmt->execute();
|
||||
}
|
||||
break;
|
||||
case 'add':
|
||||
foreach ($save_value as $button_array) {
|
||||
$stmt = $this->db->prepare("INSERT INTO sccpbuttonconfig SET ref = :ref, reftype = :reftype, instance = :instance, buttontype = :buttontype, name = :name, options = :options
|
||||
ON DUPLICATE KEY UPDATE ref = :refU, reftype = :reftypeU, instance = :instanceU, buttontype = :buttontypeU, name = :nameU, options = :optionsU");
|
||||
$stmt->bindParam(':ref', $button_array['ref'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':reftype', $button_array['reftype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':instance', $button_array['instance'],\PDO::PARAM_INT);
|
||||
$stmt->bindParam(':buttontype', $button_array['buttontype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':name', $button_array['name'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':options', $button_array['options'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':refU', $button_array['ref'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':reftypeU', $button_array['reftype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':instanceU', $button_array['instance'],\PDO::PARAM_INT);
|
||||
$stmt->bindParam(':buttontypeU', $button_array['buttontype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':nameU', $button_array['name'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':optionsU', $button_array['options'],\PDO::PARAM_STR);
|
||||
$result = $stmt->execute();
|
||||
}
|
||||
break;
|
||||
/*
|
||||
case 'add':
|
||||
foreach ($save_value as $button_array) {
|
||||
$stmt = $this->db->prepare('INSERT INTO sccpbuttonconfig (ref, reftype, instance, buttontype, name, options) VALUES (:ref, :reftype, :instance, :buttontype, :name, :options)');
|
||||
$stmt->bindParam(':ref', $button_array['ref'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':reftype', $button_array['reftype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':instance', $button_array['instance'],\PDO::PARAM_INT);
|
||||
$stmt->bindParam(':buttontype', $button_array['type'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':buttontype', $button_array['buttontype'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':name', $button_array['name'],\PDO::PARAM_STR);
|
||||
$stmt->bindParam(':options', $button_array['options'],\PDO::PARAM_STR);
|
||||
$result = $stmt->execute();
|
||||
}
|
||||
break;
|
||||
*/
|
||||
case 'clear';
|
||||
// Clear is equivalent of delete + insert.
|
||||
// Clear is equivalent of delete + insert. Mode is used in order to activate trigger.
|
||||
$this->write('sccpbuttons', '', $mode = 'delete','', $hwid);
|
||||
$this->write('sccpbuttons', $save_value, $mode = 'add','', $hwid);
|
||||
break;
|
||||
|
|
|
@ -537,6 +537,7 @@ class formcreate
|
|||
$select_opt[$key]= $key;
|
||||
}
|
||||
}
|
||||
|
||||
case 'SLM':
|
||||
if (function_exists('music_list')) {
|
||||
$moh_list = music_list();
|
||||
|
@ -741,15 +742,23 @@ class formcreate
|
|||
}
|
||||
switch ($child['type']) {
|
||||
case 'SDM':
|
||||
$model_list = \FreePBX::Sccp_manager()->dbinterface->getSccpDeviceTableData("HWDevice");
|
||||
$model_list = \FreePBX::Sccp_manager()->dbinterface->getDb_model_info('ciscophones', 'model');
|
||||
$select_opt= $model_list;
|
||||
break;
|
||||
case 'SDMS':
|
||||
$model_list = \FreePBX::Sccp_manager()->dbinterface->getSccpDeviceTableData("HWSipDevice");
|
||||
$model_list = \FreePBX::Sccp_manager()->dbinterface->getDb_model_info('sipphones', 'model');
|
||||
$select_opt= $model_list;
|
||||
break;
|
||||
case 'SDML':
|
||||
$assignedExts = \FreePBX::Sccp_manager()->dbinterface->getSccpDeviceTableData('getAssignedExtensions');
|
||||
$select_opt = \FreePBX::Sccp_manager()->dbinterface->getSccpDeviceTableData('SccpExtension');
|
||||
foreach ($assignedExts as $name => $nameArr ) {
|
||||
$select_opt[$name]['label'] .= " - in use";
|
||||
}
|
||||
$child->default = $fvalues['defaultLine'];
|
||||
break;
|
||||
case 'SDE':
|
||||
$extension_list = \FreePBX::Sccp_manager()->dbinterface->getSccpDeviceTableData("HWextension");
|
||||
$extension_list = \FreePBX::Sccp_manager()->dbinterface->getDb_model_info('extension', 'model');
|
||||
$extension_list[]=array( 'model' => 'NONE', 'vendor' => 'CISCO', 'dns' => '0');
|
||||
foreach ($extension_list as &$data) {
|
||||
$d_name = explode(';', $data['model']);
|
||||
|
@ -771,7 +780,6 @@ class formcreate
|
|||
?>
|
||||
<div class="element-container">
|
||||
<div class="row"> <div class="form-group">
|
||||
|
||||
<div class="col-md-3">
|
||||
<label class="control-label" for="<?php echo $res_id; ?>"><?php echo _($child->label);?></label>
|
||||
<i class="fa fa-question-circle fpbx-help-icon" data-for="<?php echo $res_id; ?>"></i>
|
||||
|
@ -786,7 +794,7 @@ class formcreate
|
|||
echo '>';
|
||||
|
||||
$fld = (string)$child->select['name'];
|
||||
$flv = (string)$child->select;
|
||||
$flv = (string)$child->select['name'];
|
||||
$flv2 = (string)$child->select['addlabel'];
|
||||
$flk = (string)$child->select['dataid'];
|
||||
$flkv = (string)$child->select['dataval'];
|
||||
|
@ -797,7 +805,6 @@ class formcreate
|
|||
$key = $fvalues[$res_n]['data'];
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($select_opt as $data) {
|
||||
echo '<option value="' . $data[$fld] . '"';
|
||||
if ($key == $data[$fld]) {
|
||||
|
|
|
@ -703,7 +703,7 @@ trait ajaxHelper {
|
|||
$db_field = $this->dbinterface->getSccpDeviceTableData("get_columns_sccpdevice");
|
||||
$hw_id = (empty($get_settings['sccp_deviceid'])) ? 'new' : $get_settings['sccp_deviceid'];
|
||||
$hw_type = (empty($get_settings['sccp_device_typeid'])) ? 'sccpdevice' : $get_settings['sccp_device_typeid'];
|
||||
$update_hw = ($hw_id == 'new') ? 'add' : 'clear'; // Possible values are delete, replace, add, clear.
|
||||
$update_hw = ($hw_id == 'new') ? 'add' : 'clear'; // Clear is delete + add
|
||||
$hw_prefix = 'SEP';
|
||||
if (!empty($get_settings[$hdr_prefix . 'type'])) {
|
||||
$value = $get_settings[$hdr_prefix . 'type'];
|
||||
|
@ -806,7 +806,7 @@ trait ajaxHelper {
|
|||
}
|
||||
// Save this device.
|
||||
$this->dbinterface->write('sccpdevice', $save_settings, 'replace');
|
||||
// Retrieve the phone buttons and write back to
|
||||
// Retrieve the phone buttons from $_REQUEST ($get_settings) and write back to
|
||||
// update sccpdeviceconfig via Trigger
|
||||
$save_buttons = $this->getPhoneButtons($get_settings, $name_dev, $hw_type);
|
||||
$this->dbinterface->write('sccpbuttons', $save_buttons, $update_hw, '', $name_dev);
|
||||
|
|
|
@ -98,6 +98,8 @@ if (!empty($_REQUEST['id'])) {
|
|||
continue;
|
||||
}
|
||||
$def_val[$key] = array("keyword" => $key, "data" => $val, "seq" => "99");
|
||||
// Need to assign defaultLine as not set in the db.
|
||||
$def_val['defaultLine'] = $this->dbinterface->getSccpDeviceTableData('getDefaultLine', array('id' => $dev_id))['name'];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -20,12 +20,18 @@ $feature_list= array('parkinglot'=>'Park Slots','monitor'=> "Record Calls",'dev
|
|||
*/
|
||||
|
||||
$lines_list = $this->dbinterface->getSccpDeviceTableData('SccpExtension');
|
||||
//$hint_list = $this->dbinterface->getSccpDeviceTableData('SccpExtension');
|
||||
$hint_list = $this->getHintInformation(true, array('context'=>'park-hints')) ;
|
||||
|
||||
|
||||
/* REQUEST for new device
|
||||
[display] => sccp_phone
|
||||
[tech_hardware] => cisco
|
||||
[extdisplay] =>
|
||||
*/
|
||||
|
||||
// print_r($hint_list);
|
||||
$line_id =0;
|
||||
$max_buttons =56;
|
||||
$max_buttons =56; //Don't know hardware type so et a maximum. On save, this is set to actual max buttons
|
||||
$show_buttons =1;
|
||||
//print_r($hint_list);
|
||||
if (!empty($_REQUEST['id'])) {
|
||||
|
@ -61,7 +67,7 @@ if (!empty($_REQUEST['ru_id'])) {
|
|||
<form autocomplete="off" name="frm_editbuttons" id="frm_editbuttons" class="fpbx-submit" action="" method="post" data-id="hw_edit">
|
||||
<input type="hidden" name="category" value="frm_editbuttons">
|
||||
<input type="hidden" name="Submit" value="Submit">
|
||||
<input type="hidden" name="buttonscount" value="<?php echo $max_buttons?>">
|
||||
<input type="hidden" name="buttonscount" id="buttonscount" value="<?php echo $max_buttons?>">
|
||||
<div class="section-title" data-for="<?php echo $forminfo[0]['name'];?>">
|
||||
<h3><i class="fa fa-minus"></i><?php echo _($forminfo[0]['label']) ?></h3>
|
||||
</div>
|
||||
|
@ -90,7 +96,7 @@ if (!empty($_REQUEST['ru_id'])) {
|
|||
|
||||
</div></div>
|
||||
<?php
|
||||
for ($line_id = 0; $line_id <=$max_buttons; $line_id ++) {
|
||||
for ($line_id = 0; $line_id <$max_buttons; $line_id ++) {
|
||||
$show_form_mode = '';
|
||||
$defaul_tv = (empty($db_buttons[$line_id])) ? "empty": $db_buttons[$line_id]['buttontype'];
|
||||
$defaul_btn = (empty($db_buttons[$line_id])) ? "": $db_buttons[$line_id]['name'];
|
||||
|
@ -154,7 +160,7 @@ if (!empty($_REQUEST['ru_id'])) {
|
|||
<div class="col-sm-5">
|
||||
<div class="col-xs-3">
|
||||
<!-- Line Type Select -->
|
||||
<select class="form-control buttontype" data-id="<?php echo $line_id;?>" name="<?php echo $forminfo[1]['name'].$line_id.'_type';?>" >
|
||||
<select class="form-control buttontype" data-id="<?php echo $line_id;?>" name="<?php echo $forminfo[1]['name'].$line_id.'_type';?>">
|
||||
<?php
|
||||
if ($line_id == 0) {
|
||||
echo '<option value="line" selected >DEF LINE</option>';
|
||||
|
@ -178,7 +184,7 @@ if (!empty($_REQUEST['ru_id'])) {
|
|||
?>
|
||||
</select>
|
||||
<!-- if Line Type = line Show SCCP Num -->
|
||||
<select data-type='line' class ="form-control lineid_<?php echo $line_id.(($show_form_mode=='line' || $show_form_mode=='adv.line')?'':' hidden');?>" name="<?php echo $forminfo[1]['name'].$line_id.'_line';?>" >
|
||||
<select data-type='line' class ="form-control lineid_<?php echo $line_id.(($show_form_mode=='line' || $show_form_mode=='adv.line')?'':' hidden');?>" name="<?php echo $forminfo[1]['name'].$line_id.'_line';?>">
|
||||
<?php
|
||||
foreach ($lines_list as $data) {
|
||||
$select = (($data['name']==$defaul_btn)?"selected":"");
|
||||
|
|
|
@ -90,6 +90,7 @@ foreach ($items as $child) {
|
|||
break;
|
||||
case 'SDM':
|
||||
case 'SDMS':
|
||||
case 'SDML':
|
||||
case 'SDE':
|
||||
case 'SDD':
|
||||
\FreePbx::sccp_manager()->formcreate->addElementSD($child, $fvalues, $sccp_defaults,$npref);
|
||||
|
|
Loading…
Reference in a new issue