mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-06-18 02:59:27 +00:00
check if attributes are posted
This commit is contained in:
parent
cb7ca87c6c
commit
9df1a1eb08
|
@ -168,6 +168,7 @@ if ($_FILES['userfile']['error'] == 0) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(isset($_POST["attributes"]) && $_POST["attributes"]) {
|
||||||
$attributes = $_POST["attributes"];
|
$attributes = $_POST["attributes"];
|
||||||
foreach($attributes as $attrdefid=>$attribute) {
|
foreach($attributes as $attrdefid=>$attribute) {
|
||||||
$attrdef = $dms->getAttributeDefinition($attrdefid);
|
$attrdef = $dms->getAttributeDefinition($attrdefid);
|
||||||
|
@ -179,6 +180,9 @@ if ($_FILES['userfile']['error'] == 0) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
$attributes = array();
|
||||||
|
}
|
||||||
|
|
||||||
$contentResult=$document->addContent($comment, $user, $userfiletmp, basename($userfilename), $fileType, $userfiletype, $reviewers, $approvers, $version=0, $attributes);
|
$contentResult=$document->addContent($comment, $user, $userfiletmp, basename($userfilename), $fileType, $userfiletype, $reviewers, $approvers, $version=0, $attributes);
|
||||||
if (is_bool($contentResult) && !$contentResult) {
|
if (is_bool($contentResult) && !$contentResult) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user