mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-28 19:55:48 +03:00
отклонение запроса на Управление версиями
This commit is contained in:
@@ -149,16 +149,50 @@ void MultiThreadServer::slotDisconnectClient(QString peerAddress, QString peerPo
|
||||
|
||||
bool MultiThreadServer::slot_BlockAutorization(bool block, QString whoFullName, QString type)
|
||||
{
|
||||
bool res = true;
|
||||
bool res = false;
|
||||
bool blockRes = false;
|
||||
QString key = whoFullName + " [type:" + type + "]";
|
||||
QString strTypes = "";
|
||||
|
||||
if(block)
|
||||
{
|
||||
this->blockAutorization();
|
||||
blockersMap.insert(key, type);
|
||||
blockRes = true;
|
||||
if(whoFullName == "SERVER")
|
||||
{
|
||||
this->blockAutorization();
|
||||
blockersMap.insert(key, type);
|
||||
blockRes = true;
|
||||
res = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
bool flExist = false;
|
||||
|
||||
foreach(QString keyLocal, blockersMap.keys())
|
||||
{
|
||||
if(blockersMap[keyLocal] == type)
|
||||
{
|
||||
flExist = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(!flExist)
|
||||
{
|
||||
this->blockAutorization();
|
||||
blockersMap.insert(key, type);
|
||||
blockRes = true;
|
||||
res = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(!blockersMap.count())
|
||||
blockRes = false;
|
||||
else
|
||||
blockRes = true;
|
||||
|
||||
res = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -170,6 +204,8 @@ bool MultiThreadServer::slot_BlockAutorization(bool block, QString whoFullName,
|
||||
}
|
||||
else
|
||||
blockRes = true;
|
||||
|
||||
res = true;
|
||||
}
|
||||
|
||||
if(res)
|
||||
|
||||
Reference in New Issue
Block a user