The Wiki is still in development, please bare with us while we add and update content.

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
schedman:main [2017/08/27 09:26]
textstorm [Create]
schedman:main [2017/08/27 09:41]
textstorm [Schedule Example]
Line 84: Line 84:
  
 {{:​schedman:​basic.png?​100|}} {{:​schedman:​basic.png?​100|}}
 +
 +----
 +
 ==== Advanced ==== ==== Advanced ====
  
Line 89: Line 92:
  
 {{:​schedman:​advanced.png?​100|}} {{:​schedman:​advanced.png?​100|}}
 +
 +----
 +
 ==== Modify ==== ==== Modify ====
  
Line 94: Line 100:
  
 {{:​schedman:​modifyhighlight.png?​100|}} {{:​schedman:​modifyhighlight.png?​100|}}
 +
 +----
 +
 === Advanced Runtime Options === === Advanced Runtime Options ===
  
Line 103: Line 112:
  
 {{:​schedman:​advancedmatrix.png?​100|}} {{:​schedman:​advancedmatrix.png?​100|}}
 +
 +----
 +
 ==== Create ==== ==== Create ====
  
Line 108: Line 120:
  
 {{:​schedman:​create.png?​100|}} {{:​schedman:​create.png?​100|}}
 +
 +----
 +
 ==== Logs ==== ==== Logs ====
  
Line 131: Line 146:
 if($caller) { if($caller) {
  
-    ///you can use $id to get the SchedRef of your script, useful for logging purposes +    ///you can use $this->​schedRef ​to get the SchedRef of your script, useful for logging purposes 
-    echo $id;+    echo $this->​schedRef;
  
     ///​$this->​date is the datetimestamp last known by SchedMan, you can update this using the method below. Useful for logging.     ///​$this->​date is the datetimestamp last known by SchedMan, you can update this using the method below. Useful for logging.
Line 141: Line 156:
  
     ///generate a log you can see in the database for your script     ///generate a log you can see in the database for your script
-    $this->​GenerateLog($id, "​Script Began Running at: $this->​date",​ -1);+    $this->​GenerateLog($this->​schedRef, "​Script Began Running at: $this->​date",​ -1);
  
     ///you can reference $this->​db for your database connection if SchedMan is configured on the correct database for this script     ///you can reference $this->​db for your database connection if SchedMan is configured on the correct database for this script
Line 147: Line 162:
  
     ///need to set the job as failed if a try/catch goes wrong or validates incorrectly?​     ///need to set the job as failed if a try/catch goes wrong or validates incorrectly?​
-    $this->​setJobAsInError($id, "The job failed as we could not change x to 1");+    $this->​setJobAsInError("​The job failed as we could not change x to 1")
 +     
 +    //tell SchedMan how many rows your job affected 
 +    $this->​rowsAffected = 1;
  
 } }
 </​file>​ </​file>​

QR Code
QR Code schedman:main (generated for current page)