projects
/
PHP_CodeDoc
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
73c0465
)
CodeDoc.php
author
Alan Knowles
<alan@roojs.com>
Fri, 14 Oct 2016 03:08:20 +0000
(11:08 +0800)
committer
Alan Knowles
<alan@roojs.com>
Fri, 14 Oct 2016 03:08:20 +0000
(11:08 +0800)
CodeDoc.php
patch
|
blob
|
history
diff --git
a/CodeDoc.php
b/CodeDoc.php
index
a4319d8
..
1bd72f3
100644
(file)
--- a/
CodeDoc.php
+++ b/
CodeDoc.php
@@
-387,17
+387,16
@@
class PHP_CodeDoc {
if (!isset(self::$options['targetJS'])) {
return;
}
if (!isset(self::$options['targetJS'])) {
return;
}
-
+ $cats = array();
foreach(self::$parser->classes as $k=>$cls) {
var_dump($cls->name);
$ar = $cls->toJs();
if (!$ar) {
continue;
}
foreach(self::$parser->classes as $k=>$cls) {
var_dump($cls->name);
$ar = $cls->toJs();
if (!$ar) {
continue;
}
- $cats = $ar[$cls->name];
- $file = self::$options['targetJS'].'/categories.bjs';
- file_put_contents($file, json_encode($cats ,JSON_PRETTY_PRINT));
-
+ foreach($ar[$cls->name] as $cat=>$catdata) {
+ $catdata[$cat] = isset($catdata[$cat]) ? array_merge($catdata[$cat], $catdata) : $catdata;
+ }
unset($ar[$cls->name]);
print_R($cats);
//print_R($cls); exit;
unset($ar[$cls->name]);
print_R($cats);
//print_R($cls); exit;
@@
-418,6
+417,9
@@
class PHP_CodeDoc {
}
}
+ $file = self::$options['targetJS'].'/categories.bjs';
+ file_put_contents($file, json_encode($cats ,JSON_PRETTY_PRINT));
+
}
}