Guest User

Untitled

a guest
Dec 8th, 2018
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. class VisitorsController < ApplicationController
  2. include Databasedotcom::Rails::Controller
  3.  
  4. def create
  5. config = YAML.load_file(File.join(::Rails.root, 'config', 'databasedotcom.yml'))
  6. client = Databasedotcom::Client.new(config)
  7. client.authenticate :username => config[:username], :password => config[:password]
  8. client.materialize("Lead")
  9. end
Add Comment
Please, Sign In to add comment