Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
blog
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
la forge Heptapod sera en maintenance de 12h à 13h le mardi 01 avril 2025
Show more breadcrumbs
cubicweb
cubes
blog
Commits
99e3f9c4f822
Commit
99e3f9c4f822
authored
15 years ago
by
Sylvain Thénault
Browse files
Options
Downloads
Patches
Plain Diff
use RichString
parent
3dfd0d4f9513
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
schema.py
+7
-7
7 additions, 7 deletions
schema.py
with
7 additions
and
7 deletions
schema.py
+
7
−
7
View file @
99e3f9c4
from
yams.buildobjs
import
EntityType
,
String
,
SubjectRelation
from
cubicweb.schema
import
format_constraint
try
:
from
yams.buildobjs
import
RichString
except
ImportError
:
from
cubicweb.schema
import
RichString
class
Blog
(
EntityType
):
title
=
String
(
maxsize
=
50
,
required
=
True
)
...
...
@@ -3,11 +7,9 @@
class
Blog
(
EntityType
):
title
=
String
(
maxsize
=
50
,
required
=
True
)
description_format
=
String
(
meta
=
True
,
internationalizable
=
True
,
maxsize
=
50
,
default
=
'
text/rest
'
,
constraints
=
[
format_constraint
])
description
=
String
()
description
=
RichString
()
rss_url
=
String
(
maxsize
=
128
,
description
=
_
(
'
blog
\'
s rss url (useful for when using external site such as feedburner)
'
))
class
BlogEntry
(
EntityType
):
title
=
String
(
required
=
True
,
fulltextindexed
=
True
,
maxsize
=
256
)
...
...
@@ -9,9 +11,7 @@
rss_url
=
String
(
maxsize
=
128
,
description
=
_
(
'
blog
\'
s rss url (useful for when using external site such as feedburner)
'
))
class
BlogEntry
(
EntityType
):
title
=
String
(
required
=
True
,
fulltextindexed
=
True
,
maxsize
=
256
)
content_format
=
String
(
meta
=
True
,
internationalizable
=
True
,
maxsize
=
50
,
default
=
'
text/rest
'
,
constraints
=
[
format_constraint
])
content
=
String
(
required
=
True
,
fulltextindexed
=
True
)
content
=
RichString
(
required
=
True
,
fulltextindexed
=
True
)
entry_of
=
SubjectRelation
(
'
Blog
'
,
cardinality
=
'
**
'
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment