mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-06 11:43:50 +00:00
Fix. Disable device provision. (#1700)
Close #1389 Rewrite code to write config file to file.
This commit is contained in:
committed by
FusionPBX
parent
11e51de389
commit
9fe937d4d6
@@ -3,6 +3,8 @@
|
||||
function device_by_mac($db, $mac) {
|
||||
$sql = 'SELECT * FROM v_devices ';
|
||||
$sql .= 'WHERE device_mac_address=:mac';
|
||||
$sql .= 'AND device_enabled = \'true\' ';
|
||||
|
||||
$prep = $db->prepare(check_sql($sql));
|
||||
if ($prep) {
|
||||
$prep->bindParam(':mac', $mac);
|
||||
@@ -21,6 +23,8 @@ function device_by_ext($db, $ext, $domain) {
|
||||
$sql .= 'where t2.user_id=:ext ';
|
||||
$sql .= 'and t3.domain_name=:domain ';
|
||||
$sql .= 'and t3.domain_enabled = \'true\' ';
|
||||
$sql .= 'and t1.device_enabled = \'true\' ';
|
||||
|
||||
$prep = $db->prepare(check_sql($sql));
|
||||
if ($prep) {
|
||||
$prep->bindParam(':ext', $ext);
|
||||
|
||||
Reference in New Issue
Block a user