projects
/
Pman.Core
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add support for aching all of the translations
[Pman.Core]
/
RooPostTrait.php
diff --git
a/RooPostTrait.php
b/RooPostTrait.php
index
f48c96d
..
456aa7a
100644
(file)
--- a/
RooPostTrait.php
+++ b/
RooPostTrait.php
@@
-170,7
+170,8
@@
trait Pman_Core_RooPostTrait {
$affects = array();
$affects = array();
- $all_links = $GLOBALS['_DB_DATAOBJECT']['LINKS'][$x->_database];
+ $all_links = $x->databaseLinks();
+
foreach($all_links as $tbl => $links) {
foreach($links as $col => $totbl_col) {
$to = explode(':', $totbl_col);
foreach($all_links as $tbl => $links) {
foreach($links as $col => $totbl_col) {
$to = explode(':', $totbl_col);
@@
-282,7
+283,7
@@
trait Pman_Core_RooPostTrait {
}
}
- $this->
add
DeleteEvent($x);
+ $this->
log
DeleteEvent($x);
$xx->delete();
$xx->delete();
@@
-299,7
+300,7
@@
trait Pman_Core_RooPostTrait {
}
}
- function
add
DeleteEvent($object)
+ function
log
DeleteEvent($object)
{
DB_DataObject::Factory('Events')->logDeletedRecord($object);
{
DB_DataObject::Factory('Events')->logDeletedRecord($object);
@@
-395,7
+396,7
@@
trait Pman_Core_RooPostTrait {
{
$this->permitError = true; // allow it to fail without dieing
{
$this->permitError = true; // allow it to fail without dieing
- $lock = DB_DataObjecT::factory('
C
ore_locking');
+ $lock = DB_DataObjecT::factory('
c
ore_locking');
$this->permitError = false;
if (is_a($lock,'DB_DataObject') && $this->authUser) {
$this->permitError = false;
if (is_a($lock,'DB_DataObject') && $this->authUser) {
@@
-434,7
+435,7
@@
trait Pman_Core_RooPostTrait {
// edit it anyways...
// can we find the user's lock.
// edit it anyways...
// can we find the user's lock.
- $lock = DB_DataObjecT::factory('
C
ore_locking');
+ $lock = DB_DataObjecT::factory('
c
ore_locking');
$lock->on_id = $x->{$this->key};
$lock->on_table= strtolower($x->tableName());
$lock->person_id = $this->authUser->id;
$lock->on_id = $x->{$this->key};
$lock->on_table= strtolower($x->tableName());
$lock->person_id = $this->authUser->id;
@@
-449,7
+450,7
@@
trait Pman_Core_RooPostTrait {
$x->modified_by != $this->authUser->id
)
{
$x->modified_by != $this->authUser->id
)
{
- $p = DB_DataObject::factory('
P
erson');
+ $p = DB_DataObject::factory('
core_p
erson');
$p->get($x->modified_by);
$this->jerr($p->name . " saved the record since you started editing,\nDo you really want to update it?", array('needs_confirm' => true));
$p->get($x->modified_by);
$this->jerr($p->name . " saved the record since you started editing,\nDo you really want to update it?", array('needs_confirm' => true));