Class: Marty::PromiseView
- Inherits:
-
Netzke::Tree::Base
- Object
- Netzke::Tree::Base
- Marty::PromiseView
show all
- Extended by:
- Permissions
- Defined in:
- app/components/marty/promise_view.rb
Constant Summary
Constants included
from Permissions
Marty::Permissions::ALL_ROLES, Marty::Permissions::REQ_ROLES
Instance Method Summary
collapse
can_perform_action?, can_perform_actions, current_user_roles, has_any_perm?, has_marty_permissions
Instance Method Details
#bbar ⇒ Object
38
39
40
|
# File 'app/components/marty/promise_view.rb', line 38
def bbar
[:clear, '->', :refresh, :download]
end
|
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
# File 'app/components/marty/promise_view.rb', line 12
def configure(config)
super
config.title = I18n.t("jobs.promise_view")
config.model = "Marty::VwPromise"
config.attributes = [
{name: :title, xtype: :treecolumn},
:user__login,
:job_id,
:start_dt,
:end_dt,
:status,
:cformat,
:error,
]
config.root_visible = false
config.paging = :none
config.bbar = bbar
config.read_only = true
config.permissions = { update: false,
create: false,
delete: false,
}
Marty::Promise.cleanup(false)
end
|
#get_records(params) ⇒ Object
66
67
68
69
|
# File 'app/components/marty/promise_view.rb', line 66
def get_records params
search_scope = config[:live_search_scope] || :live_search
Marty::VwPromise.children_for_id(params[:id], params[search_scope])
end
|