preparing to push to heroku

This commit is contained in:
Jackk Goh
2018-03-23 09:55:42 +08:00
parent 6d879e9016
commit d1a0997c19
5856 changed files with 1 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
<?php
$records = array();
$records['nodes'] = array();
$id = isset($_REQUEST['id']) ? $_REQUEST['id'] : '0';
$level = 1;
if ($id != '0') {
$id = explode(':', $id);
$level = $id[1] + 1;
}
for($i = 1; $i < 6; $i++) {
$id_ = time() + rand(1000, 20000) . ':' . ($level);
$records['nodes'][] = array('id' => $id_, 'parent' => $id, 'name' => 'Node - ' . $level . ' - ' . $i, 'level' => $level, 'type' => 'folder');
}
echo json_encode($records);
?>