mirror of
https://github.com/Mibew/mibew.git
synced 2025-05-12 23:03:08 +03:00
Remove functions definition from operator/opgroups.php
This commit is contained in:
parent
c6b03cfe55
commit
41f1e0a3bc
@ -874,4 +874,20 @@ function check_password_hash($login, $password, $hash)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function update_operator_groups($operatorid, $newvalue)
|
||||||
|
{
|
||||||
|
$db = Database::getInstance();
|
||||||
|
$db->query(
|
||||||
|
"delete from {chatgroupoperator} where operatorid = ?",
|
||||||
|
array($operatorid)
|
||||||
|
);
|
||||||
|
|
||||||
|
foreach ($newvalue as $groupid) {
|
||||||
|
$db->query(
|
||||||
|
"insert into {chatgroupoperator} (groupid, operatorid) values (?,?)",
|
||||||
|
array($groupid, $operatorid)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
?>
|
?>
|
@ -16,7 +16,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// Import namespaces and classes of the core
|
// Import namespaces and classes of the core
|
||||||
use Mibew\Database;
|
|
||||||
use Mibew\Style\PageStyle;
|
use Mibew\Style\PageStyle;
|
||||||
|
|
||||||
// Initialize libraries
|
// Initialize libraries
|
||||||
@ -27,22 +26,6 @@ require_once(MIBEW_FS_ROOT.'/libs/operator_settings.php');
|
|||||||
$operator = check_login();
|
$operator = check_login();
|
||||||
csrfchecktoken();
|
csrfchecktoken();
|
||||||
|
|
||||||
function update_operator_groups($operatorid, $newvalue)
|
|
||||||
{
|
|
||||||
$db = Database::getInstance();
|
|
||||||
$db->query(
|
|
||||||
"delete from {chatgroupoperator} where operatorid = ?",
|
|
||||||
array($operatorid)
|
|
||||||
);
|
|
||||||
|
|
||||||
foreach ($newvalue as $groupid) {
|
|
||||||
$db->query(
|
|
||||||
"insert into {chatgroupoperator} (groupid, operatorid) values (?,?)",
|
|
||||||
array($groupid, $operatorid)
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$operator_in_isolation = in_isolation($operator);
|
$operator_in_isolation = in_isolation($operator);
|
||||||
|
|
||||||
$opId = verifyparam("op", "/^\d{1,9}$/");
|
$opId = verifyparam("op", "/^\d{1,9}$/");
|
||||||
|
Loading…
Reference in New Issue
Block a user