本文整理匯總了PHP中DatabaseManager::insertValue方法的典型用法代碼示例。如果您正苦於以下問題:PHP DatabaseManager::insertValue方法的具體用法?PHP DatabaseManager::insertValue怎麽用?PHP DatabaseManager::insertValue使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類DatabaseManager
的用法示例。
在下文中一共展示了DatabaseManager::insertValue方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: addAction
public function addAction($pActionNotification, $pUser, $forceReload = true)
{
if ($pActionNotification instanceof ActionNotification) {
require_once dirname(__FILE__) . '/DatabaseManager.php';
$databaseManager = new DatabaseManager();
$databaseManager->openTable('notifications', json_decode(DatabaseManager::$table5));
$action = $pActionNotification->getAction();
$timestamp = $pActionNotification->getMaxTimestamp();
$readed = $pActionNotification->getReaded();
if (!empty($pActionNotification->getAdressed())) {
$insert['text'] = array("value" => $pActionNotification->getAdressed());
} else {
$insert['text'] = array("value" => '');
}
$insert['title'] = array("value" => '');
$insert['action'] = array("value" => $action);
$insert['user'] = array("value" => $pUser);
$insert['timestamp'] = array("value" => $timestamp, "type" => "integer");
$insert['type'] = array("value" => 1);
$insert['readed'] = array("value" => $readed);
$insert['icon'] = array("value" => "", "type" => "text");
$databaseManager->insertValue($insert);
if ($forceReload) {
$this->forceReload();
}
}
}
示例2: addJwtSignature
public function addJwtSignature($signature, $name = 'Endgerät', $userid)
{
$databaseAuthtokens = new DatabaseManager();
$json = json_decode(DatabaseManager::$table11);
$databaseAuthtokens->openTable("jwt", $json);
$arrayToken['user'] = array('operator' => '=', 'value' => $userid, 'type' => 'i');
$arrayToken['signature'] = array('operator' => '=', 'value' => $signature, 'type' => 's');
$arrayToken['name'] = array('operator' => '=', 'value' => $name, 'type' => 's');
$resultToken1 = $databaseAuthtokens->insertValue($arrayToken);
return $resultToken1;
}