Update ivr_menu.php
IVR Menu - Add temporary permissions for adding or editing the dialplan.
This commit is contained in:
parent
a537084752
commit
f6efae3830
|
|
@ -450,6 +450,13 @@ include "root.php";
|
||||||
//echo "</pre>\n";
|
//echo "</pre>\n";
|
||||||
//exit;
|
//exit;
|
||||||
|
|
||||||
|
//add the dialplan permission
|
||||||
|
$p = new permissions;
|
||||||
|
$p->add("dialplan_add", 'temp');
|
||||||
|
$p->add("dialplan_detail_add", 'temp');
|
||||||
|
$p->add("dialplan_edit", 'temp');
|
||||||
|
$p->add("dialplan_detail_edit", 'temp');
|
||||||
|
|
||||||
//save the dialplan
|
//save the dialplan
|
||||||
$orm = new orm;
|
$orm = new orm;
|
||||||
$orm->name('dialplans');
|
$orm->name('dialplans');
|
||||||
|
|
@ -465,6 +472,12 @@ include "root.php";
|
||||||
//echo "</pre>\n";
|
//echo "</pre>\n";
|
||||||
//exit;
|
//exit;
|
||||||
|
|
||||||
|
//remove the temporary permission
|
||||||
|
$p->delete("dialplan_add", 'temp');
|
||||||
|
$p->delete("dialplan_detail_add", 'temp');
|
||||||
|
$p->delete("dialplan_edit", 'temp');
|
||||||
|
$p->delete("dialplan_detail_edit", 'temp');
|
||||||
|
|
||||||
//synchronize the xml config
|
//synchronize the xml config
|
||||||
save_dialplan_xml();
|
save_dialplan_xml();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue