Skip to content

Commit

Permalink
changed root directory
Browse files Browse the repository at this point in the history
  • Loading branch information
MUlt1mate committed Jan 6, 2016
1 parent 8fdc194 commit 9704ee3
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions examples/active_record/Controllers/BaseController.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class BaseController
public function __construct()
{
ActiveRecord\Config::initialize(function ($cfg) {
$cfg->set_model_directory('models');
$cfg->set_model_directory('../models');
$cfg->set_connections([
'development' => 'mysql://root:qwerty@localhost/crontab']);
});
Expand All @@ -19,10 +19,10 @@ public function __construct()
protected function renderView($view, $params, $template = true)
{
if ($template)
require_once 'views/template.php';
require_once '../views/template.php';
foreach ($params as $key => $value)
$$key = $value;
require_once "views/$view.php";
require_once "../views/$view.php";
}

}
2 changes: 1 addition & 1 deletion examples/active_record/views/tasks_list.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
</select>
</div>
<div class="form-group">
<input type="submit" value="Execute" class="btn btn-primary" id="execute_action">
<input type="submit" value="Apply" class="btn btn-primary" id="execute_action">
</div>
</form>
<form class="form-inline">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
require_once 'vendor/autoload.php';
require_once '../../vendor/autoload.php';
require_once '../vendor/autoload.php';
require_once '../../../vendor/autoload.php';
function __autoload($class_name)
{
if (file_exists('Controllers/' . $class_name . '.php'))
require_once 'Controllers/' . $class_name . '.php';
if (file_exists('../Controllers/' . $class_name . '.php'))
require_once '../Controllers/' . $class_name . '.php';
}

spl_autoload_register('__autoload');
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/TaskManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ public static function parseCrontab($cron, $task_class)
try {
CronExpression::factory($matches[2]);
} catch (\Exception $e) {
$r .= 'Time expression ' . $matches[2] . ' not valid';
$r[] = 'Time expression ' . $matches[2] . ' not valid';
$result[] = $r;
continue;
}
Expand Down

0 comments on commit 9704ee3

Please sign in to comment.