Admin System - Temp Tables? Advice?

2012-03-21 Thread Les Mizzell

I'm in the process of rewriting the admin system for an older website. 
On this version, client want to be able to edit/add/delete anything at 
will, and have it NOT got live until he's decided he's done with that 
part.

My current thought is to use a temp table(s) that:
a. when visiting an edit page - LOADS the live data into the temp table
b. all editing is done in the temp table
c. once he likes it, he can hit the publish button, and the temp data 
replaces whatever is currently in the live table.
d. after that transaction is completed, the temp table is emptied again

Seem like a plan? Is there a better way? How does everybody else handle 
this stuff?

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:350501
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


re: Admin System - Temp Tables? Advice?

2012-03-21 Thread Jason Fisher

Or have a 'versions' table attached to the 'page' table.  Versions can have 
status, with a maximum of 1 'published' for any given pageID, and versions 
can have publicationStart and publicationEnd dates.  Gives you the 
flexibility of rolling back to previous versions as well.  Just a thought.



From: Les Mizzell lesm...@bellsouth.net
Sent: Wednesday, March 21, 2012 12:22 PM
To: cf-talk cf-talk@houseoffusion.com
Subject: Admin System - Temp Tables? Advice?

I'm in the process of rewriting the admin system for an older website. 
On this version, client want to be able to edit/add/delete anything at 
will, and have it NOT got live until he's decided he's done with that 
part.

My current thought is to use a temp table(s) that:
a. when visiting an edit page - LOADS the live data into the temp table
b. all editing is done in the temp table
c. once he likes it, he can hit the publish button, and the temp data 
replaces whatever is currently in the live table.
d. after that transaction is completed, the temp table is emptied again

Seem like a plan? Is there a better way? How does everybody else handle 
this stuff?



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:350502
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Admin System - Temp Tables? Advice?

2012-03-21 Thread Gerald Guido

I have done this three ways. I had an edit table (like your temp table) and
that worked fairly well. I did versioning as Jason mentioned, that was a
bit of a PITA.   The other way was to use a preview page and I submitted
the form data to the preview page via AJAX and populated it that way. The
Ajax method worked best with simple pages i.e. not a lot of joins.

G!

On Wed, Mar 21, 2012 at 12:21 PM, Les Mizzell lesm...@bellsouth.net wrote:


 I'm in the process of rewriting the admin system for an older website.
 On this version, client want to be able to edit/add/delete anything at
 will, and have it NOT got live until he's decided he's done with that
 part.

 My current thought is to use a temp table(s) that:
 a. when visiting an edit page - LOADS the live data into the temp table
 b. all editing is done in the temp table
 c. once he likes it, he can hit the publish button, and the temp data
 replaces whatever is currently in the live table.
 d. after that transaction is completed, the temp table is emptied again

 Seem like a plan? Is there a better way? How does everybody else handle
 this stuff?

 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:350503
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Admin System - Temp Tables? Advice?

2012-03-21 Thread Dave Watts

 My current thought is to use a temp table(s) that:
 a. when visiting an edit page - LOADS the live data into the temp table
 b. all editing is done in the temp table
 c. once he likes it, he can hit the publish button, and the temp data
 replaces whatever is currently in the live table.
 d. after that transaction is completed, the temp table is emptied again

 Seem like a plan? Is there a better way? How does everybody else handle
 this stuff?

I would create an actual persistent table for this - if you literally
mean a temporary table, that table will only last while the database
session is active, and could go out of scope before the user has
completed his edits.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
http://training.figleaf.com/

Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on
GSA Schedule, and provides the highest caliber vendor-authorized
instruction at our training centers, online, or onsite.

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:350504
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Admin System - Temp Tables? Advice?

2012-03-21 Thread Claude Schnéegans

Most of the case, the user does not want a new item to be published bedore it 
is completed.
For existing items, only little adjustements are made and this may be done on 
line.

If it is your case, just add some Active logical field in the table and display 
the item only if the active flag is set.


~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:350506
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm