From ef247b4e33c9b9d60037c4fd5b2cc48af8c295e6 Mon Sep 17 00:00:00 2001 From: Fabien Bourgeois Date: Fri, 29 Jul 2016 08:47:40 +0200 Subject: [PATCH] [ADD]Notes addons, first commit --- note_tags/__init__.py | 17 +++ note_tags/__init__.pyc | Bin 0 -> 135 bytes note_tags/__openerp__.py | 29 +++++ note_tags/note_tags_view.xml | 49 ++++++++ note_task/__init__.py | 19 +++ note_task/__init__.pyc | Bin 0 -> 182 bytes note_task/__openerp__.py | 30 +++++ note_task/models.py | 40 +++++++ note_task/note_task_view.xml | 111 ++++++++++++++++++ note_task/note_task_view_kanban.xml | 26 ++++ .../static/src/xml/note_task_view_kanban.xml | 27 +++++ 11 files changed, 348 insertions(+) create mode 100644 note_tags/__init__.py create mode 100644 note_tags/__init__.pyc create mode 100644 note_tags/__openerp__.py create mode 100644 note_tags/note_tags_view.xml create mode 100644 note_task/__init__.py create mode 100644 note_task/__init__.pyc create mode 100644 note_task/__openerp__.py create mode 100644 note_task/models.py create mode 100644 note_task/note_task_view.xml create mode 100644 note_task/note_task_view_kanban.xml create mode 100644 note_task/static/src/xml/note_task_view_kanban.xml diff --git a/note_tags/__init__.py b/note_tags/__init__.py new file mode 100644 index 0000000..daa4ccf --- /dev/null +++ b/note_tags/__init__.py @@ -0,0 +1,17 @@ +# -*- coding: utf-8 -*- + +# Author: Fabien Bourgeois. Copyright Yaltik +# Copyright (C) +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . diff --git a/note_tags/__init__.pyc b/note_tags/__init__.pyc new file mode 100644 index 0000000000000000000000000000000000000000..934af1e33b4ecc0f557d84d243b113c9dd3ed2c0 GIT binary patch literal 135 zcmZSn%*)jqH!m!i0SXv_v;zJ`6a3GC5h?9`tk9Zd6^~g@p=W7B^*FaHo5sJr8%i~Aft +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . + +{ + 'name': 'Note tags', + 'summary': 'Note tags management', + 'description': '', + 'version': '0.1', + 'category': 'Tools', + 'author': 'Fabien Bourgeois', + 'license': 'AGPL-3', + 'installable': True, + 'depends': ['note'], + 'data': ['note_tags_view.xml'] +} diff --git a/note_tags/note_tags_view.xml b/note_tags/note_tags_view.xml new file mode 100644 index 0000000..94d9c1f --- /dev/null +++ b/note_tags/note_tags_view.xml @@ -0,0 +1,49 @@ + + + + + + + + + Note Tags + note.tag + + + + + + + + + Note Tags + note.tag + form + tree,form + + + + + + + + diff --git a/note_task/__init__.py b/note_task/__init__.py new file mode 100644 index 0000000..e42a624 --- /dev/null +++ b/note_task/__init__.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- + +# Author: Fabien Bourgeois. Copyright Yaltik +# Copyright (C) +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . + +from . import models diff --git a/note_task/__init__.pyc b/note_task/__init__.pyc new file mode 100644 index 0000000000000000000000000000000000000000..2861c400920473177a26714e504d868797ac6b8d GIT binary patch literal 182 zcmZSn%*)l!GdC=m0ScIav;zlVzz!VP^*4^N`Ah6 qUVcexd`V()wtjqkW?p7Ve7s&kWeEpRlMT@P(wtN~VIaF0WGDat_#$@z literal 0 HcmV?d00001 diff --git a/note_task/__openerp__.py b/note_task/__openerp__.py new file mode 100644 index 0000000..97d403b --- /dev/null +++ b/note_task/__openerp__.py @@ -0,0 +1,30 @@ +# -*- coding: utf-8 -*- + +# Copyright 2016 Fabien Bourgeois +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . + +{ + 'name': 'Note task', + 'summary': 'Link a task to a note', + 'description': '', + 'version': '0.1', + 'category': 'Tools', + 'author': 'Fabien Bourgeois', + 'license': 'AGPL-3', + 'installable': True, + 'depends': ['note', 'project'], + 'data': ['note_task_view.xml'] + # 'qweb': [ 'static/src/xml/note_task_view_kanban.xml' ] +} diff --git a/note_task/models.py b/note_task/models.py new file mode 100644 index 0000000..674efed --- /dev/null +++ b/note_task/models.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- + +# Author: Fabien Bourgeois. Copyright Yaltik +# Copyright (C) +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . + +from openerp import fields, models + + +class NoteTask(models.Model): + + _inherit = 'note.note' + task_id = fields.Many2one('project.task', 'Linked Task') + + # @api.one + # def onclick_note_is_done(self): + # self.open = False + # self.date_done = fields.date.today() + # if self.task_id: + # print(self.task_id.stage_id.name) + # print('ok') + # return True + + +# class ProjectTask(models.Model): +# +# _inherit = 'project.task' +# note_ids = fields.One2many('note.note', 'task_id', 'Linked notes') diff --git a/note_task/note_task_view.xml b/note_task/note_task_view.xml new file mode 100644 index 0000000..1b1b2b5 --- /dev/null +++ b/note_task/note_task_view.xml @@ -0,0 +1,111 @@ + + + + + + + + + Note Task + note.note + +
+
+ +
+ + + + + + + + + +
+ + +
+
+
+
+ + + + + Note Task + note.note + + + + + + +

+ Linked Task : +

+
+
+
+ + + + +
+
diff --git a/note_task/note_task_view_kanban.xml b/note_task/note_task_view_kanban.xml new file mode 100644 index 0000000..e421d83 --- /dev/null +++ b/note_task/note_task_view_kanban.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + diff --git a/note_task/static/src/xml/note_task_view_kanban.xml b/note_task/static/src/xml/note_task_view_kanban.xml new file mode 100644 index 0000000..09e34b8 --- /dev/null +++ b/note_task/static/src/xml/note_task_view_kanban.xml @@ -0,0 +1,27 @@ + + + + + + + + lol + + + +