ooor 1.6.5 → 1.7.0
Sign up to get free protection for your applications and to get access to all the features.
- data/MIT-LICENSE +20 -0
- data/README.md +131 -88
- data/bin/ooor +4 -2
- data/lib/app/helpers/core_helpers.rb +137 -0
- data/lib/app/models/base64.rb +14 -25
- data/lib/app/models/common_service.rb +3 -15
- data/lib/app/models/db_service.rb +6 -17
- data/lib/app/models/ooor_client.rb +3 -15
- data/lib/app/models/open_object_resource.rb +40 -41
- data/lib/app/models/relation.rb +4 -16
- data/lib/app/models/serialization.rb +5 -0
- data/lib/app/models/type_casting.rb +8 -3
- data/lib/app/models/uml.rb +26 -35
- data/lib/app/ui/action_window.rb +13 -19
- data/lib/app/ui/client_base.rb +4 -21
- data/lib/app/ui/form_model.rb +4 -15
- data/lib/ooor.rb +50 -46
- data/spec/ooor_spec.rb +49 -29
- metadata +38 -37
- data/agpl-3.0-licence.txt +0 -661
- data/lib/app/ui/menu.rb +0 -34
data/lib/app/ui/menu.rb
DELETED
@@ -1,34 +0,0 @@
|
|
1
|
-
# OOOR: Open Object On Rails
|
2
|
-
# Copyright (C) 2009-2011 Akretion LTDA (<http://www.akretion.com>).
|
3
|
-
# Author: Raphaël Valyi
|
4
|
-
#
|
5
|
-
# This program is free software: you can redistribute it and/or modify
|
6
|
-
# it under the terms of the GNU Affero General Public License as
|
7
|
-
# published by the Free Software Foundation, either version 3 of the
|
8
|
-
# License, or (at your option) any later version.
|
9
|
-
#
|
10
|
-
# This program is distributed in the hope that it will be useful,
|
11
|
-
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
12
|
-
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
13
|
-
# GNU Affero General Public License for more details.
|
14
|
-
#
|
15
|
-
# You should have received a copy of the GNU Affero General Public License
|
16
|
-
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
17
|
-
|
18
|
-
require 'app/ui/action_window'
|
19
|
-
module Ooor
|
20
|
-
module MenuModule
|
21
|
-
|
22
|
-
attr_accessor :menu_action
|
23
|
-
|
24
|
-
def menu_action
|
25
|
-
#TODO put in cache eventually:
|
26
|
-
action_values = self.class.ooor.const_get('ir.values').rpc_execute('get', 'action', 'tree_but_open', [['ir.ui.menu', id]], false, self.class.ooor.global_context)[0][2]#get already exists
|
27
|
-
@menu_action = self.class.ooor.const_get('ir.actions.act_window').new(action_values, []) #TODO deal with action reference instead
|
28
|
-
end
|
29
|
-
|
30
|
-
def open(mode='tree', ids=nil)
|
31
|
-
menu_action.open(mode, ids)
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|