Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

approval system 1

Status
Not open for further replies.

derwent

Programmer
May 5, 2004
428
GB
I developed a cms for certain pages of our website, people log in, select the page to update then update the textareas (fed by MSSQL), press submit and the website is updated.

Some of the updates however are shocking so I need to put an approval system onto it.

Basically, when they press submit instead of the update automatically going into the DB and updating the website, and email is sent to whoever should approve it telling them that this is what they have changed, do you accept or reject it. If they accept then it is made live.

Question is, how do I go about doing this? I guess I would need a seperate table in my DB where the new text goes until it is approved then it goes into the main table?

 
yes you need a new table in the DB may be with the following fields...
Code:
Table Name: Approvals
ApprovalID | SubmitterName| SubmissionDate|SubmissionText|ApproverName|Status

When a new submission is submitted...just send an email to the person who is the ApproverName and you can either create a link that takes to the page where he/she can see the list of unapproved(Status being 1) or you can make them go the page directly and select their name to see their items...

to make it little clear you have to create a new page with a dropdown or a textbox where the approver can either select the name or enter the name and submit the information to the server and you can pull the unapproved items from the Approvals table...

the above is the process that happens when approver directly goes to the page instead of clicking the link in the email...

if the approver clicks the link the email you can get his/her information through querystring and pull the data accordingly without need to go the form page...

hope it makes sense...

-DNG
 
After reading about 10 times I think I have it:

1. user makes updates and presses submit
2. approvals table is populated, setting status to 1 (unapproved) and email is send to corresponding approver with link to a page showing new text entered
3. Approver can then edit this text and/or press submit to approve, sending this data to the main table, updating the website.

Is it possible to highlight exactly which part has been altered? Some pages have large paragraphs of text so the approver would have to read through it all and not necessarily notice the change. For example in this paragraph say I changed the word parapgraphs above (from chunks), the word paragraphs would be highlighted red.

Am I going a little complictaed with that?
 
sorry for not being clear enough...but i think you got the idea...

it is possible to highlight the differences in two texts but the process would be slow and not an easy task to do...

if this feature is not required then i would suggest you to keep the application simple...

-DNG
 
keep it simple stupid hehe

For the moment I will just do the basics but I would definately like to try comparing the entries and highlighting the changed parts.

Can you point me in the right direction?

Thanks for the help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top