Chore: Verschiebe Git-Repository in das Hauptverzeichnis und richte .gitignore ein
This commit is contained in:
commit
96d0545193
502 files changed
+176027
No files matched your search
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
namespace HermannTelser\Gutachten\DB\Select;
|
||||
|
||||
use HermannTelser\Gutachten\DB\DbFunction;
|
||||
use TYPO3\CMS\Core\Utility\GeneralUtility;
|
||||
|
||||
/***
|
||||
*
|
||||
* This file is part of the "NuhOdds Comparatore" Extension for TYPO3 CMS.
|
||||
*
|
||||
* For the full copyright and license information, please read the
|
||||
* LICENSE.txt file that was distributed with this source code.
|
||||
*
|
||||
* (c) 2019 Hermann Telser <hermann.telser@gmail.com>
|
||||
*
|
||||
***/
|
||||
|
||||
class ProjekteSetActive
|
||||
{
|
||||
public static function set()
|
||||
{
|
||||
$projectid = GeneralUtility::_GP('id');
|
||||
$userid = $GLOBALS['TSFE']->fe_user->user['uid'];
|
||||
|
||||
$has = DbFunction::has('tx_gutachten_freigabe', ['AND' => ['userid' => $userid, 'projektid' => $projectid]]);
|
||||
|
||||
if (!$has) {
|
||||
$value_array = [];
|
||||
$value_array['userid'] = $userid;
|
||||
$value_array['projektid'] = $projectid;
|
||||
|
||||
DbFunction::secureInsert('tx_gutachten_freigabe', $value_array);
|
||||
|
||||
echo 1;
|
||||
} else {
|
||||
$active = DbFunction::delete('tx_gutachten_freigabe', ['AND' => ['userid' => $userid, 'projektid' => $projectid]]);
|
||||
|
||||
echo 0;
|
||||
}
|
||||
|
||||
exit;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user