Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
e21562b0
Commit
e21562b0
authored
Sep 05, 2006
by
amadeus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed Record::hasRelation() to call Table::hasRelation() instead of old Table::hasForeignkey()
parent
946e3f1c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
Record.php
Doctrine/Record.php
+5
-5
No files found.
Doctrine/Record.php
View file @
e21562b0
...
@@ -470,7 +470,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
...
@@ -470,7 +470,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
if
(
!
$this
->
data
)
if
(
!
$this
->
data
)
throw
new
Doctrine_Record_Exception
(
'Failed to refresh. Record does not exist anymore'
);
throw
new
Doctrine_Record_Exception
(
'Failed to refresh. Record does not exist anymore'
);
$this
->
data
=
array_change_key_case
(
$this
->
data
,
CASE_LOWER
);
$this
->
data
=
array_change_key_case
(
$this
->
data
,
CASE_LOWER
);
$this
->
modified
=
array
();
$this
->
modified
=
array
();
...
@@ -600,7 +600,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
...
@@ -600,7 +600,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
* rawSet
* rawSet
* doctrine uses this function internally, not recommended for developers
* doctrine uses this function internally, not recommended for developers
*
*
* rawSet() works in very same same way as set() with an exception that
* rawSet() works in very same same way as set() with an exception that
* 1. it cannot be used for setting references
* 1. it cannot be used for setting references
* 2. it cannot load uninitialized fields
* 2. it cannot load uninitialized fields
*
*
...
@@ -812,7 +812,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
...
@@ -812,7 +812,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
if
(
$this
->
data
[
$v
]
instanceof
Doctrine_Record
)
if
(
$this
->
data
[
$v
]
instanceof
Doctrine_Record
)
$this
->
data
[
$v
]
=
$this
->
data
[
$v
]
->
getIncremented
();
$this
->
data
[
$v
]
=
$this
->
data
[
$v
]
->
getIncremented
();
if
(
$this
->
data
[
$v
]
===
self
::
$null
)
if
(
$this
->
data
[
$v
]
===
self
::
$null
)
$a
[
$v
]
=
null
;
$a
[
$v
]
=
null
;
else
else
...
@@ -849,7 +849,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
...
@@ -849,7 +849,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
* @return boolean
* @return boolean
*/
*/
public
function
exists
()
{
public
function
exists
()
{
return
(
$this
->
state
!==
Doctrine_Record
::
STATE_TCLEAN
&&
return
(
$this
->
state
!==
Doctrine_Record
::
STATE_TCLEAN
&&
$this
->
state
!==
Doctrine_Record
::
STATE_TDIRTY
);
$this
->
state
!==
Doctrine_Record
::
STATE_TDIRTY
);
}
}
/**
/**
...
@@ -860,7 +860,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
...
@@ -860,7 +860,7 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite
public
function
hasRelation
(
$name
)
{
public
function
hasRelation
(
$name
)
{
if
(
isset
(
$this
->
data
[
$name
])
||
isset
(
$this
->
id
[
$name
]))
if
(
isset
(
$this
->
data
[
$name
])
||
isset
(
$this
->
id
[
$name
]))
return
true
;
return
true
;
return
$this
->
table
->
has
ForeignKey
(
$name
);
return
$this
->
table
->
has
Relation
(
$name
);
}
}
/**
/**
* getIterator
* getIterator
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment