mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-13 13:11:31 +00:00
move block to parse categories after dms has been initialized
This commit is contained in:
parent
1a9265130b
commit
6c2a011a9a
|
@ -84,19 +84,6 @@ if(isset($options['k'])) {
|
||||||
$keywords = $options['k'];
|
$keywords = $options['k'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$categories = array();
|
|
||||||
if(isset($options['K'])) {
|
|
||||||
$categorynames = explode(',', $options['K']);
|
|
||||||
foreach($categorynames as $categoryname) {
|
|
||||||
$cat = $dms->getDocumentCategoryByName($categoryname);
|
|
||||||
if($cat) {
|
|
||||||
$categories[] = $cat->getID();
|
|
||||||
} else {
|
|
||||||
echo "Category '".$categoryname."' not found\n";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$sequence = 0;
|
$sequence = 0;
|
||||||
if(isset($options['s'])) {
|
if(isset($options['s'])) {
|
||||||
$sequence = $options['s'];
|
$sequence = $options['s'];
|
||||||
|
@ -143,6 +130,20 @@ if(!$dms->checkVersion()) {
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Parse categories */
|
||||||
|
$categories = array();
|
||||||
|
if(isset($options['K'])) {
|
||||||
|
$categorynames = explode(',', $options['K']);
|
||||||
|
foreach($categorynames as $categoryname) {
|
||||||
|
$cat = $dms->getDocumentCategoryByName($categoryname);
|
||||||
|
if($cat) {
|
||||||
|
$categories[] = $cat->getID();
|
||||||
|
} else {
|
||||||
|
echo "Category '".$categoryname."' not found\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Parse document attributes. */
|
/* Parse document attributes. */
|
||||||
$document_attributes = array();
|
$document_attributes = array();
|
||||||
if (isset($options['a'])) {
|
if (isset($options['a'])) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user