Good to hear that Jim, are you by any chance using the current <http://www.web2py.com/books/default/chapter/29/04/the-core?search=current.request#Sharing-the-global-scope-with-modules-using-the-current-object> object in your class to control state? - is this even advisable by the core devs?
On Wednesday, June 29, 2016 at 1:39:59 PM UTC-7, Jim S wrote: > > That is exactly what I'm doing with a new application we rolled out > earlier this month. Controller instantiates the object, does the necessary > processing and then returns the object to the view. Works well for me. > I'm doing some tricky (well, tricky for me) things to pass the object > around between pages, but it is all working quite well. > > -Jim > > > On Wednesday, June 29, 2016 at 3:03:45 PM UTC-5, Julio F. Schwarzbeck > wrote: >> >> Hi again Folks, >> >> I just wanted to get your take on an approach that has not been suggested >> for this question, even though the question, in one form another, has been >> asked previously. >> >> I have more than one application, or potentially one or more applications >> + some services that roughly has the same information requirements. >> >> Both my mobile app and my desktop app (no bootstrap here, as both are >> first-class apps) call the same controller, I know I can change the view >> name dynamically and still call the same controller, but what if I add a >> service endpoint, for example, that ultimately calls the "default/index" >> controller, but with no view, and so on.. >> >> So the solution that I'd like you guys to comment on is the following.. >> >> Creating a class (or first class functions) as a *Module*, and put all >> the business logic in that module(s), and now we can have as many >> controllers as we need (if needed) and they all call the same business >> logic module but represent the data in different ways (JSON, XML, etc). >> >> So the question is, do you see a problem offsetting "controller" code to >> a module instead, and having the controller (or multiple different >> controllers or applications) call the business rule in the module? - This >> could potentially eliminate the need to change views or other "trickery" to >> technically execute the same code for a specific controller.. >> >> Thanks! >> >> --sb >> >> >> >> >> -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.