This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Started POST "/api/hosts" for 127.0.0.1 at 2012-05-24 16:42:26 +0800 | |
Processing by Api::HostsController#create as JSON | |
Parameters: {"subdomain"=>"oh", "domain"=>"aik.com", "service"=>"4", "domain_id"=>"aik.com", "host"=>{"domain"=>"aik.com", "subdomain"=>"oh", "service"=>"4"}} | |
User Load (0.3ms) SELECT `users`.* FROM `users` WHERE `users`.`id` = 3 LIMIT 1 | |
(0.1ms) BEGIN | |
Host Load (0.2ms) SELECT `hosts`.* FROM `hosts` WHERE `hosts`.`reference1` = 'aik.com' LIMIT 1 | |
CACHE (0.0ms) SELECT `hosts`.* FROM `hosts` WHERE `hosts`.`reference1` = 'aik.com' LIMIT 1 | |
CACHE (0.0ms) SELECT `hosts`.* FROM `hosts` WHERE `hosts`.`reference1` = 'aik.com' LIMIT 1 | |
CACHE (0.0ms) SELECT `hosts`.* FROM `hosts` WHERE `hosts`.`reference1` = 'aik.com' LIMIT 1 | |
oh.aik.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#in my controller | |
def update | |
user = current_user.update_attributes(params[:user]) | |
respond_with user | |
end | |
#in my backbone view | |
@model.url = '/api/users' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Dnscell.Collections.Domains extends Backbone.Collection | |
url: "/api/zones" | |
model: Dnscell.Models.Domain |
NewerOlder