Build Online fix operation schedule

After I move to operation from engineer, company has a shift schedule in paper, print small size put in wallet, during the time see doctor need to open schedule to find the best day which not working for the appointment , the paper easy to broken and I need to print it every years, our shift is schedule is change, so you can’t remember it, and in the end of the year, if I want to plan next year vacation I find out the next year schedule to do, it is not that convenience , all the operator need to print one

I were having an idea to build a online shift schedule, everyone can look it, and chance year automatically, the first version of shift schedule use JavaScript build, only one schedule, can’t be change, our cycle is 35 days, so each month can hold within one row, The schedule like below:

The major function this schedule can provide:

  • Manual change each year; the schedule is automatically change
  • Holiday is highlight(red color), for the operators, they like the holiday just in their shift, triple time!
  • Today is automatic in yellow color,
  • Hidden another team schedule to click my team,
  • Chick operation schedule to display all team schedule

As I previous blog descript, the hosting company provide different plan, basic plan is only play $9 dollar per month,   so I pay $9 for this schedule online, the operators really like it.

The Codes highlight:

Only need JavaScript for run this schedule, not requests establish database

  • Build function for display current day
  • Build a function for display holiday
  • Build a function to remove the pass year and storage the holiday for your country
  • At major function to find relationship to dynamic display dates when the years change

Now Successfully to display our shift schedule online, and test it is working very well, all operator like it. It can use more than 40 years, open my cell phone can check it anytime .

If you shift cycle is bigger than 32 days which can hold one month in one row, you can do it, pay less than 10 dollar per month to apply a domain name, then download from my online store, fix_shift_online_shchedule

After you download codes, change the name to index.php and upload to your base domain to you URL.

One example codes: display current day:

function currentday(o,hd1){

var i1=1;

for (i1;i1<=35;i1++) {

var op2=o+i1;

document.getElementById(op2).style.color = “black”;}

var i1=1;

for (i1;i1<=35;i1++) {

var op3=o+i1;

var h1=document.getElementById(op3).innerHTML;

var h2 =parseInt(h1)

if (h2==hd1){

document.getElementById(op3).style.background = “yellow”;

}}}

Leave a Comment

Your email address will not be published. Required fields are marked *