Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class InterfaceController < ApplicationController
- def interface_defintion
- {
- "HL7" => {
- "Version_2_3" => Services::Interfaces::HL7::Version_2_3.new
- },
- "GDT" => {
- "Version_2_1" => Services::Interfaces::GDT::Version_2_1.new
- },
- # more interfaces...
- }
- end
- def import
- interface_version = @konfig_interface.version
- interface_typ = @konfig_interface.typ
- result = interface_definition[interface_typ][interface_version].export(@konfig_interface)
- # ... handle result and process post import steps (send mail, ...)
- end
- # other stuff...
- end
Add Comment
Please, Sign In to add comment