lib/magellan/cli/resources/project.rb in magellan-cli-0.10.0 vs lib/magellan/cli/resources/project.rb in magellan-cli-0.11.0

- old
+ new

@@ -15,11 +15,11 @@ desc "update ATTRIBUTES", I18n.t(:update, scope: [:resources, :common, :cmd], resource_name: resource_name) def update(attrs) s = load_selection!(self.class) attrs = JSON.parse(File.readable?(attrs) ? File.read(attrs) : attrs) - put_json("/admin/project/#{s['id']}/edit.json", {"project" => attrs}) + put_json("/admin/project/#{s['id']}/edit.js", {"project" => attrs}) end desc "create NAME", I18n.t(:create, scope: [:resources, :common, :cmd], resource_name: resource_name) def create(name) o = load_selection!(Organization) @@ -27,10 +27,10 @@ parameter_name => { "organization_id" => o["id"], "name" => name, } } - post_json("/admin/#{resource_key}/new.json", params) + post_json("/admin/#{resource_key}/new.js", params) select(name) end end end