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
bea3d563
Commit
bea3d563
authored
Sep 20, 2007
by
zYne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
--no commit message
--no commit message
parent
d4e3567a
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
8 deletions
+12
-8
Blog.php
models/Blog.php
+3
-2
BlogTag.php
models/BlogTag.php
+9
-6
No files found.
models/Blog.php
View file @
bea3d563
...
@@ -14,16 +14,17 @@ class Taggable extends Doctrine_Template
...
@@ -14,16 +14,17 @@ class Taggable extends Doctrine_Template
{
{
public
function
setUp
()
public
function
setUp
()
{
{
$this
->
hasMany
(
'[Component]Tag as Tag'
);
$this
->
hasMany
(
'[Component]Tag
Template
as Tag'
);
}
}
}
}
class
TagTemplate
extends
Doctrine_
Template
class
TagTemplate
extends
Doctrine_
Record
{
{
public
function
setTableDefinition
()
public
function
setTableDefinition
()
{
{
$this
->
hasColumn
(
'name'
,
'string'
,
100
);
$this
->
hasColumn
(
'name'
,
'string'
,
100
);
$this
->
hasColumn
(
'description'
,
'string'
);
$this
->
hasColumn
(
'description'
,
'string'
);
}
}
public
function
setUp
()
public
function
setUp
()
{
{
$this
->
hasOne
(
'[Component]'
,
array
(
'onDelete'
=>
'CASCADE'
));
$this
->
hasOne
(
'[Component]'
,
array
(
'onDelete'
=>
'CASCADE'
));
...
...
models/BlogTag.php
View file @
bea3d563
<?php
<?php
class
BlogTag
extends
Doctrine_Record
class
BlogTag
extends
Doctrine_Record
{
{
public
function
setUp
()
{
public
function
setTableDefinition
()
$this
->
hasMany
(
'Photo'
,
'Phototag.photo_id'
);
{
$this
->
hasColumn
(
'name'
,
'string'
,
100
);
$this
->
hasColumn
(
'description'
,
'string'
);
}
}
public
function
setTableDefinition
()
{
public
function
setUp
()
$this
->
hasColumn
(
'tag'
,
'string'
,
100
);
{
$this
->
hasOne
(
'Blog'
,
array
(
'onDelete'
=>
'CASCADE'
));
}
}
}
}
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