123456789101112131415161718192021222324 |
- # -*- encoding: utf-8 -*-
- from openerp import models, fields, api
- from datetime import datetime
- from pytz import timezone
- DATE_FORMAT = '%Y-%m-01 00:00:00'
- # import web_pdb; web_pdb.set_trace()
- class ChartList(models.Model):
- _name = 'chart.list'
- name = fields.Char('Chart Name', required=True)
- description = fields.Text('Description')
- class ResUsers(models.Model):
- _inherit = 'res.users'
- chart_ids = fields.Many2many('chart.list', 'chart_list_users_rel', 'id', 'cid', 'Charts')
- @api.model
- def get_user(self):
- return self.env.user.id
|