This topic is locked

How can I disable edit functions in SQL??

4/24/2008 2:20:23 AM
PHPRunner General questions
S
swanside author

Here is my sql query

SELECT

Order_Date,

File_No,

Job_No,

Customer_ID,

Order_Time,

Contract,

Order_Site_Address,

Job_Description,

VAT,

Invoice_Printed,

Invoice_Printing_Date,

Invoice_Tax_Date,

Payment_Received,

Job_Finished,

CustomerRef,

Customer_Name,

Payment_Due_date,

Payment_Date,

Locked,

Note

FROM job


If JOB-finished is checked, how can I disable the edit functions on this job so it can not be altered?
Thanks

Paul

J
Jane 4/24/2008

Hi,
you can do the following:

  1. edit link to edit page on the Visual Editor tab.

    here is a saple:
    {if $row.allowedit}<A class=tablelinks id=editlink{$row.1recno} href="TableName_edit.php?{$row.1editlink}">Edit</A>{/if}


2. add following code to the List page: After record processed event on the Events tab:

if ($data["Job_Finished"])

$row["allowedit"] = 0;

else

$row["allowedit"] = 1;

S
swanside author 4/24/2008

Thanks Jane.
Will try that
Paul.