schinery / bootstrap-on

Admin generators for Padrino (< 0.10.7) with Twitter Bootstrap integration
MIT License
0 stars 1 forks source link

Wrong instructions for non-activerecord usage #2

Open ronnqvist opened 12 years ago

ronnqvist commented 12 years ago

When generating an admin page (padrino g bs_admin_page) in an app using mognoid I get this instruction: 2) Run 'padrino rake ar:migrate'

For MongoDB ORM:s you don't need migrations at all and in case of other than ActiveRecord SQL ORM:s you need another migration command.

futurechimp commented 12 years ago

Hi Simon,

Stu's the primary author of this, but he's off on vacation so I'll try and jump in here.

I think that the library has never been designed to work with anything other than ActiveRecord - it'll probably work with other ORMs but I don't think Stu's ever tried it with them (I know I haven't).

Does it actually work other than for the instruction at the end of the generation process? If so, that's quite cool actually, and we can probably detect what ORM is in use somehow and fix up that message. However, I don't want to give people the impression that this thing will work for all ORMs without some extra work, as it may make people annoyed if all cases are not supported properly.

futurechimp commented 12 years ago

Oh, wait a moment, maybe this will in fact work for all ORMs. I was thinking of another generator library we've made that kicks out a fully-tested scaffold which is targeted at AR only. I guess we should look at this - I'm in the middle of site deployment right now so it may not happen today.

ronnqvist commented 12 years ago

The only thing (apart from everything being unstyled) is that the _sidebar.haml partial seems to be missing, when I removed all includes to that it worked using mongoid.

The reason I assumed it would work with mongoid is that it provided that alternative when I (by mistake) generated an ORM-less padrino app and tried:

$ padrino g bs_admin <= At the moment, Padrino only supports mini_record or datamapper or activerecord or mongomapper or mongoid or couchrest or sequel. Sorry!

schinery commented 12 years ago

Hi Simon,

I removed the sidebar partial in the .erb templates purely as in nearly all the projects I've done I end up removing it. I'd made (a very slow) start to the other templates by removing the sidebar partial but forgot to the remove the reference to the sidebar. Have just done a commit to remove those references.

Hopefully at some point I'll get around the formatting the other templates. If you use the .haml ones would you be interested in formatting the templates and then sending them over in a pull request?

ronnqvist commented 12 years ago

Hi!

Yes, I'd love to help you out with that. I've actually modified the templates that the bootstrap-on generator made to have working templates in a bootstrapish way, at this point it's all a part of an app I'm making for a customer... but I tried to do the basic enchancements as separate commits in my repo, so that I can easily spot the changes to contribute back to the project later on (in a couple of weeks or so).

cheers, Simon

On 02.10.2012 12:31, Stuart Chinery wrote:

Hi Simon,

I removed the sidebar partial in the .erb templates purely as in nearly all the projects I've done I end up removing it. I'd made (a very slow) start to the other templates by removing the sidebar partial but forgot to the remove the reference to the sidebar. Have just done a commit to remove those references.

Hopefully at some point I'll get around the formatting the other templates. If you use the .haml ones would you be interested in formatting the templates and then sending them over in a pull request?

— Reply to this email directly or view it on GitHub https://github.com/sleepingstu/bootstrap-on/issues/2#issuecomment-9065071.

schinery commented 12 years ago

OK that sounds awesome. I'll look out for the pull request.

ronnqvist commented 11 years ago

Hi!

I happened to find some (slightly outdated) code that might be of interest to you. I'm pretty much ready with my own implementation though and will contribute that once I get it more or less extracted from the client-project that I'm working on.

https://github.com/padrino/padrino-framework/tree/bootstrap ...in other words, a bootstrap branch of the padrino project. Unless they've intended to make bootstrap the standard admin UI it's not the best place for that piece of code though. Haven't tested it, but I think it might deserve our attention and is better served as a part of the bootstrap-on gem.

cheers, Simon

On 02.10.2012 15:58, Stuart Chinery wrote:

OK that sounds awesome. I'll look out for the pull request.

— Reply to this email directly or view it on GitHub https://github.com/sleepingstu/bootstrap-on/issues/2#issuecomment-9069828.

schinery commented 11 years ago

Hi Simon,

Your right, it looks like they are going to have the Padrino admin bootstrap enabled as of the next release as all of those changes are also now in the Master branch. I think most of the bootstrap integration came from this version - https://github.com/WaYdotNET/padrino-framework.

I guess this will make this project redundant when the new Padrino gem comes out, but that isn't such a bad thing as they look like they have really gone to town with the integration.

Stu

ronnqvist commented 11 years ago

Ok, maybe we'll just make the gem some kind of a backport of the new admin generator? And instead try to contribute actual bootstrap integration efforts to the framework core.

cheers, Simon

Stuart Chinery notifications@github.com skrev:

Hi Simon,

Your right, it looks like they are going to have the Padrino admin bootstrap enabled as of the next release as all of those changes are also now in the Master branch. I think most of the bootstrap integration came from this version - https://github.com/WaYdotNET/padrino-framework.

I guess this will make this project redundant when the new Padrino gem comes out, but that isn't such a bad thing as they look like they have really gone to town with the integration.

Stu


Reply to this email directly or view it on GitHub: https://github.com/sleepingstu/bootstrap-on/issues/2#issuecomment-9778214