flectra/doc/howtos/backend/exercise-model

19 lines
634 B
Plaintext
Raw Normal View History

# HG changeset patch
# Parent e3bb12713a6d38c28f50d46e8c1bab74ac40c1be
Index: addons/openacademy/models.py
===================================================================
--- addons.orig/openacademy/models.py 2014-08-26 17:25:51.643783496 +0200
+++ addons/openacademy/models.py 2014-08-26 17:25:51.639783496 +0200
@@ -2,7 +2,8 @@
from odoo import models, fields, api
-# class openacademy(models.Model):
-# _name = 'openacademy.openacademy'
+class Course(models.Model):
+ _name = 'openacademy.course'
-# name = fields.Char()
+ name = fields.Char(string="Title", required=True)
+ description = fields.Text()