Module: ODDB::State::Admin::Admin

Includes:
User
Defined in:
src/state/admin/admin.rb,
src/state/global_predefine.rb

Constant Summary

RESOLVE_STATES =
{
  [ :hospital ]                 =>  State::Hospitals::RootHospital,
  [ :registration ]             =>  State::Admin::Registration,
  [ :registration, :sequence ]  => State::Admin::Sequence,
  [ :registration,
    :sequence, :active_agent ] =>  State::Admin::ActiveAgent,
  [ :registration,
    :sequence, :package ]        =>  State::Admin::Package,
  [ :registration, :sequence,
    :package, :sl_entry ]        =>  State::Admin::SlEntry,
}

Constants included from User

RESOLVE_STATES

Instance Method Summary (collapse)

Methods included from User

#resolve_state, #user_navigation

Instance Method Details

- (Boolean) limited?

Returns:

  • (Boolean)


31
32
33
# File 'src/state/admin/admin.rb', line 31

def limited?
  false
end

- (Object) new_registration



34
35
36
37
38
39
40
41
42
43
44
# File 'src/state/admin/admin.rb', line 34

def new_registration
  pointer = Persistence::Pointer.new(:registration)
  item = Persistence::CreateItem.new(pointer)
  if(@model.is_a?(Company))
    item.carry(:company, @model)
    item.carry(:company_name, @model.name)
  end
  item.carry :sequences, {}
  item.carry :packages, []
  State::Admin::Registration.new(@session, item)
end

- (Object) zones



45
46
47
# File 'src/state/admin/admin.rb', line 45

def zones
  [:analysis, :doctors, :interactions, :drugs, :migel, :user, :hospitals, :companies]
end