forked from saurabh/orbit4-5
14 lines
382 B
Ruby
14 lines
382 B
Ruby
|
class StoreApiController < ApplicationController
|
||
|
def confirmation
|
||
|
site_token = params[:site_token]
|
||
|
store_token = params[:store_token]
|
||
|
puts current_site.to_s
|
||
|
if current_site.uid.eql?(site_token)
|
||
|
current_site.store_token = store_token
|
||
|
current_site.save
|
||
|
render :json => {"success" => true}.to_json
|
||
|
else
|
||
|
render :json => {"success" => false}.to_json
|
||
|
end
|
||
|
end
|
||
|
end
|