Besoin des Technical features pour avoir accès au différents models du module
[OpenERP/semantics.git] / topic.py
1 #-*- coding: utf8 -*-
2 from openerp.osv import osv, fields
3
4
5 class Topic(osv.Model):
6
7     _name = "semantics.topic"
8
9     _inherit = "mail.thread"
10
11     _columns = {
12         "name": fields.char(string="Title", size=256, required=True),
13         "description": fields.text(string="Description"),
14     }
15
16     _sql_constraints = [
17         (
18             "name_different_from_description_constraint",
19             "CHECK(name <> description)",
20             "Fields name and description should be different",
21         ),
22     ]