fix line indenting

This commit is contained in:
Uwe Steinmann 2022-05-09 15:26:45 +02:00
parent 92ce4ff1bc
commit 3388a14793

View File

@ -2324,6 +2324,22 @@ class RestapiController { /* {{{ */
return $response->withJson(array('success'=>true, 'message'=>'', 'data'=>''), 200); return $response->withJson(array('success'=>true, 'message'=>'', 'data'=>''), 200);
} /* }}} */ } /* }}} */
function getStatsTotal($request, $response) { /* {{{ */
$dms = $this->container->dms;
$userobj = $this->container->userobj;
$check = $this->checkIfAdmin($request, $response);
if($check !== true)
return $check;
$data = [];
foreach(array('docstotal', 'folderstotal', 'userstotal') as $type) {
$total = $dms->getStatisticalData($type);
$data[$type] = $total;
}
return $response->withJson(array('success'=>true, 'message'=>'', 'data'=>$data), 200);
} /* }}} */
} /* }}} */ } /* }}} */
class TestController { /* {{{ */ class TestController { /* {{{ */
@ -2512,6 +2528,7 @@ $app->put('/categories/{id}/name', \RestapiController::class.':changeCategoryNam
$app->get('/attributedefinitions', \RestapiController::class.':getAttributeDefinitions'); $app->get('/attributedefinitions', \RestapiController::class.':getAttributeDefinitions');
$app->put('/attributedefinitions/{id}/name', \RestapiController::class.':changeAttributeDefinitionName'); $app->put('/attributedefinitions/{id}/name', \RestapiController::class.':changeAttributeDefinitionName');
$app->get('/echo/{data}', \TestController::class.':echoData'); $app->get('/echo/{data}', \TestController::class.':echoData');
$app->get('/statstotal', \RestapiController::class.':getStatsTotal');
$app->run(); $app->run();
?> ?>