本文整理汇总了PHP中ADODB_Active_Record::Save方法的典型用法代码示例。如果您正苦于以下问题:PHP ADODB_Active_Record::Save方法的具体用法?PHP ADODB_Active_Record::Save怎么用?PHP ADODB_Active_Record::Save使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ADODB_Active_Record
的用法示例。
在下文中一共展示了ADODB_Active_Record::Save方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Save
public function Save()
{
parent::Save();
if ($this->supporting_docs_links != null) {
$this->supporting_docs_links->Save();
}
}
示例2: importAdditionalData
protected function importAdditionalData($b, $blockNode)
{
if (isset($blockNode->data)) {
foreach ($blockNode->data as $data) {
if ($data['table'] != $this->getBlockTypeDatabaseTable()) {
$table = (string) $data['table'];
if (isset($data->record)) {
foreach ($data->record as $record) {
$aar = new ADODB_Active_Record($table);
$aar->bID = $b->getBlockID();
foreach ($record->children() as $node) {
$nodeName = $node->getName();
$aar->{$nodeName} = (string) $node;
}
if ($table == 'btFormQuestions') {
$db = Loader::db();
$aar->questionSetId = $db->GetOne('select questionSetId from btForm where bID = ?', array($b->getBlockID()));
$aar->qID = null;
}
$aar->Save();
}
}
}
}
}
}
示例3: Save
function Save()
{
// Agregar el generador a la llave primaria en insercion
// el generador debe llamarse GEN_(Campo PK)
if (App::$base->driver == 'firebird') {
$ids = $this->DB()->MetaPrimaryKeys($this->_table);
// PK
$id = count($ids) > 0 ? $ids[0] : '';
if (!$this->_saved && $id != '') {
$id = strtolower($id);
$gen = 'GEN_' . strtoupper($id);
$this->{$id} = $this->DB()->GenID($gen);
}
}
if (App::$base->driver == 'postgres' || App::$base->driver == 'postgres8') {
$ids = $this->DB()->MetaPrimaryKeys($this->_table);
// PK
$id = count($ids) > 0 ? $ids[0] : '';
if (!$this->_saved && $id != '') {
$gen = $this->_table . '_' . $id . '_seq';
//formato: tbl_nombretabla_id_campoid_seq
$gen = strtolower($gen);
$this->{$id} = $this->DB()->GenID($gen);
}
}
parent::Save();
return $this;
}
示例4: Save
public function Save()
{
$saveType = $this->getSaveType();
parent::Save();
if ($this->supporting_docs_meta != null) {
$this->supporting_docs_meta->Save();
Log::saveLogDetails($this->_table, $this->doc_id, $saveType);
}
}
示例5: Save
public function Save()
{
if ($this->entity_name != null && $this->entity_id != null) {
echo 'management:Save - no entity_name or entity_id defined';
return false;
} else {
parent::Save();
}
}
示例6: Save
public function Save()
{
if ($this->clari_notes_record_number != null) {
$this->Load("clari_notes_record_number = '{$this->clari_notes_record_number}'");
} else {
$this->clari_notes_record_number = shn_create_uuid('clari_notes');
parent::Save();
}
}
示例7: importAdditionalData
protected function importAdditionalData($b, $blockNode)
{
if (isset($blockNode->data)) {
foreach ($blockNode->data as $data) {
if (strtoupper($data['table']) != strtoupper($this->getBlockTypeDatabaseTable())) {
$table = (string) $data['table'];
if (isset($data->record)) {
foreach ($data->record as $record) {
$aar = new ADODB_Active_Record($table);
$aar->bID = $b->getBlockID();
foreach ($record->children() as $node) {
$nodeName = $node->getName();
$aar->{$nodeName} = ContentImporter::getValue((string) $node);
}
$aar->Save();
}
}
}
}
}
}
示例8: Save
public function Save()
{
parent::Save();
}
示例9: Save
public function Save()
{
$saveType = $this->getSaveType();
parent::Save();
Log::saveLogDetails($this->_table, $this->doc_id, $saveType);
}
示例10: Save
public function Save()
{
$ok = parent::Save();
if (!$ok) {
$err = $this->ErrorMsg();
throw new DbException($err);
}
}
示例11: Save
public function Save()
{
$ok = parent::Save();
if (!$ok) {
$err = $this->ErrorMsg();
echo $err;
//throw new ADODB_Exception();// Exception($err); // should remove exception and add error handling routines
}
//Save UserProfile
if ($this->user_profile != null) {
$this->user_profile->username = $this->username;
$ok = $this->user_profile->Save();
if (!$ok) {
$err = $this->ErrorMsg();
echo $err;
//throw new ADODB_Exception();// Exception($err); // should remove exception and add error handling routines
}
}
//Save UserCodes
if ($this->user_code != null) {
$this->user_code->username = $this->username;
$ok = $this->user_code->Save();
if (!$ok) {
$err = $this->ErrorMsg();
echo $err;
//throw new ADODB_Exception();// Exception($err); // should remove exception and add error handling routines
}
}
if ($err == null) {
return true;
}
}