Hi all,
This is just a query about what is the best way to store data temporary
without submitting it to a db. The reason for this it because i have
create app that take input data via a form and after i would like to
preview the data entered before putting it into the db. The only idea i
have had so far is the form gets submitted to db but has a boolean value
field that is set to false meaning it will not show up till the process
sets it to true then it will show up .
i.e form -------------------- preview ----------------------- payment
(Submitted But false) (View from db still false) (If ok set
to true else delete from db)

As anyone got any other suggestions on how this could be done.

Thanks

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Search Discussions

  • Scott Ribe at Apr 20, 2012 at 7:48 pm

    On Apr 20, 2012, at 12:53 PM, Paul Na wrote:

    As anyone got any other suggestions on how this could be done.
    I think you need to be more specific about what you mean by preview. When? By whom? For how long?

    Without knowing that, we can't tell whether or not it would be sufficient to simply stuff the data into the session...

    --
    Scott Ribe
    scott_ribe@elevated-dev.com
    http://www.elevated-dev.com/
    (303) 722-0567 voice




    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Colin Law at Apr 20, 2012 at 7:49 pm

    On 20 April 2012 19:53, Paul Na wrote:
    Hi all,
    This is just a query about what is the best way to store data temporary
    without submitting it to a db. The reason for this it because i have
    create app that take input data via a form and after i would like to
    preview the data entered before putting it into the db. The only idea i
    have had so far is the form gets submitted to db but has a boolean value
    field that is set to false meaning it will not show up till the process
    sets it to true then it will show up .
    i.e form -------------------- preview ----------------------- payment
    (Submitted But false)  (View from db still false)       (If ok set
    to true else delete from db)

    As anyone got any other suggestions on how this could be done.
    You could save the data in the session. This is the technique often
    used for shopping carts for example.

    Colin

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Paul Na at Apr 20, 2012 at 7:54 pm

    Colin Law wrote in post #1057623:
    On 20 April 2012 19:53, Paul Na wrote:
    to true else delete from db)

    As anyone got any other suggestions on how this could be done.
    You could save the data in the session. This is the technique often
    used for shopping carts for example.

    Colin
    Arh thanks Colin i forgot that.

    --
    Posted via http://www.ruby-forum.com/.

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedApr 20, '12 at 6:53p
activeApr 20, '12 at 7:54p
posts4
users3
websiterubyonrails.org
irc#RubyOnRails

3 users in discussion

Paul Na: 2 posts Scott Ribe: 1 post Colin Law: 1 post

People

Translate

site design / logo © 2021 Grokbase