Giter VIP home page Giter VIP logo

angularjs_scaffold's People

Contributors

explainer avatar oripekelman avatar patcito avatar zequix avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

angularjs_scaffold's Issues

Missing description

I can follow the installation up to the point where the Posts scaffold is done. From that point, I cannot determine how the Post views should be invoked. I get nothing. Is it necessary to edit application.html.erb to add my own links in the menus? There is no joy here in Mudville.

rails g angularjs:install fails

~/c/angularjs_rails_resource ❯❯❯ rails -v

Rails 3.2.12

~/c/angularjs_rails_resource ❯❯❯ rails g angularjs:install

[WARNING] Could not load generator "generators/angularjs/install/install_generator". Error: uninitialized constant Angularjs::Rails::Generators.
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/angularjs_scaffold-0.0.24/lib/generators/angularjs/install/install_generator.rb:2:in `<module:Angularjs>'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/angularjs_scaffold-0.0.24/lib/generators/angularjs/install/install_generator.rb:1:in `<top (required)>'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:300:in `block (2 levels) in lookup'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:296:in `each'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:296:in `block in lookup'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:295:in `each'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:295:in `lookup'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:152:in `find_by_namespace'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/generators.rb:169:in `invoke'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/commands/generate.rb:12:in `<top (required)>'
/Users/et/.rvm/gems/ruby-1.9.3-p374/gems/railties-3.2.12/lib/rails/commands.rb:29:in `<top (required)>'
script/rails:6:in `require'
script/rails:6:in `<main>'
Could not find generator angularjs:install.

The scaffold generator works fine though.

Mismatched code with Delete buttons

In the Posts demo, only the delete button in edit.html actually works.
The one index.html has an 'Are you sure?' alert, but, apparently, the post.id is invalid at that point.
The delete button in show.html doesn't appear to be active at all.

Doesn't work with mongoid

/gems/angularjs_scaffold-0.0.19/lib/generators/angularjs/scaffold/scaffold_generator.rb:14:in init_vars': undefined methodcolumns' for Post:Class (NoMethodError)

Please reject my pull request

Hi Patrick,

I am a newbie with github pull requests, and I don't know how to dump my existing pull request in order to replace it with a new one, :-(

Would you reject my existing pull request? I will then issue a new pull, which adds, among other things, an option to select either CoffeeScript or javascript when installing the generator.

Because the file routes.coffee.erb (routes.js.erb) accumulates routing information with each scaffold command used, the choice of language must be viewed as an application-wide decision.

Question: New to rails less new to angular

So far it is going well, thanks for the work on this! Just wondering how to setup a "clean" url.
For example I did it that way for a home page.

pages/1 will show the Page model
/home will show pages/1 since I specified in the Rail routes.rb to
match '/home', to: 'pages#show', :id => '1'
But I also had to go into the angular pages_controller.js.coffee to make a controller for this
PagesHome = ($scope, $location, $routeParams, Page) ->
Page.get
id: 1
, (page) ->
@original = page
$scope.page = new Page(@original)
PagesHome.$inject = ['$scope', '$location', '$routeParams', 'Page'];

But to do this for the About page and the Contact page seem overkill. Is there a way to do this more dynamically.
Sorry if I am missing the obvious.
Al

Haml Support

ERB is a little smelly. Hows about some HAML support?

generator does not account for production mode js minification of the rails asset pipeline.

When deploying in production mode to heroku, for example, the implicit dependency injection logic of AngularJS gets disabled by the js minification and obfuscation associated with the rails asset pipeline.

It is necessary to use an explicit inject function to define controller parameters.

The temporary work around is to set:

config.assets.compress = false 

in

environments/production.rb

See http://docs.angularjs.org/tutorial/step_05, A Note on Minification, for more information.

Uncaught Error: No module: posts

Trying out the example, verbatim. Also tried laoding the gem from git, THis error is showing up in the browser insepctor console when I visit /posts/new

Eliminating default Views

Hi
I was playing around with angularjs_scaffold. Great stuff! Thanks. - It took me a long time to figure out the whole process of generating the view. Now I understand it and did some changes in my application, so I can remove all the views from Rails and use just your template views.

At the moment for two models my routes.rb looks like the following:

class JsonRouter
  def self.matches?(request)
    request.format == 'json'
  end
end

Trainingracoon::Application.routes.draw do
   root :to => 'welcome#index'

  constraints JsonRouter do
    resources :trainers
    resources :firms
  end

  get "/*other" => "welcome#index"

end

This routes all the html requests (when initial loading or reloading a page) to welcome#index and uses your layout. All other requests with json are routed correctly. In this case I could remove all the views, which makes the code more readable.

Maybe you like to put this into your library. Thanks anyway.
Daniel

Uncaught Error: No module: posts

This gem is not working with rails 5 getting error message in console "Uncaught Error: No module: posts"
for the example provide in read me file.

Is this gem still maintained?

Since it seems that the angularjs and bootstrap versions are not the newest.

Anyway, thanks for this amazing gem.

Cannot get id of post

Hi,

I created an angularjs_scaffold post as you instructed in announcement. I changed "protect_from_forgery with: :null_session" from exception. Now I can create posts.

But it seems that application cannot retrieve id of post. Now my show, edit and destroy paths are not working because of no id.

Please help me.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.