Add php files
This commit is contained in:
15
modules/EcmDocuments/AddRelation.php
Executable file
15
modules/EcmDocuments/AddRelation.php
Executable file
@@ -0,0 +1,15 @@
|
||||
<?
|
||||
$z="insert into ecmdocuments_".$_GET['relation']."(id,ecmdocument_id,".$_GET['parent_col'].",deleted) values('".create_guid()."','".$_GET['record']."','".$_GET['parent_id']."','0')";
|
||||
print $z;
|
||||
mysql_query($z);
|
||||
if($_GET['relation']=="correspondences" ||
|
||||
$_GET['relation']=="correspondenceouts" ||
|
||||
$_GET['relation']=="contracts" ||
|
||||
$_GET['relation']=="ecminvoices")
|
||||
{
|
||||
$z="update ".$_GET['relation']." set relation='1' where id='".$_GET['parent_id']."'";
|
||||
mysql_query($z);
|
||||
}
|
||||
|
||||
header("Location: index.php?module=EcmDocuments&action=DetailView&record=".$_GET['record']);
|
||||
?>
|
||||
Reference in New Issue
Block a user