kritbit

kritbit Git Source Tree


Root/web/application/migrations/2.php

<?php

use \vendor\DB\DB;

echo "Creating job table..." . PHP_EOL;
DB::query("CREATE TABLE jobs (
          id INTEGER PRIMARY KEY AUTOINCREMENT,
          jobName VARCHAR(255),
          runType VARCHAR(255),
          runScript TEXT,
          cron VARCHAR(255),
          failScript TEXT,
          last_run DATETIME,
          last_result INTEGER,
          api_key VARCHAR(255),
          view_private INTEGER,
          user_id INTEGER
);");

DB::query("INSERT INTO jobs VALUES (null, 'test', 1, 'TESTING', '*/5 * * *', 'TESTING', '2015-01-01', 0, '', 0, 1)");
DB::query("INSERT INTO jobs VALUES (null, 'test2', 1, 'TESTING', '*/5 * * *', 'TESTING', '2015-01-01', 0, '', 1, 1)");

Archive Download this file

Branches

Number of commits:
Page rendered in 0.06816s using 11 queries.