Login   Register  
PHP Classes
elePHPant
Icontem

File: trgrs_Appointments.js

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Michael J. Fuhrman  >  Appointment Calendar  >  trgrs_Appointments.js  >  Download  
File: trgrs_Appointments.js
Role: Auxiliary data
Content type: text/plain
Description: JavaScript functions that determine what should be done when a link is selected
Class: Appointment Calendar
Manage scheduled appointments
Author: By
Last change:
Date: 4 years ago
Size: 1,687 bytes
 

Contents

Class file image Download
/*	=======================================
	Copyright 1998 - 2010 - E Net Arch
	This program is distributed under the terms of the GNU 
	General Public License (or the Lesser GPL).
	======================================= */

var ENetArch = 
{
	Appointments :
	{
		nFolderID : 0, 
		nPos : 0, 
		onCheckID : function (me) { this.nPos = me.value; },
		List : function () { location="List.php?nFolderID=" + this.nFolderID + "&"; } ,
		New : function () { location="New.php?nFolderID=" + this.nFolderID + "&"; } ,
		View : function () { location="View.php?nFolderID=" + this.nFolderID + "&nPos=" + this.nPos + "&"; } ,
		Edit : function () { location="Edit.php?nFolderID=" + this.nFolderID + "&nPos=" + this.nPos + "&"; } ,
		Delete : function () { location="Delete.php?nFolderID=" + this.nFolderID + "&nPos=" + this.nPos + "&"; } ,
		Times : { nTime : { onChange : function () {} } } , 
		Lengths : { nLength : { onChange : function () {} } } , 
		AddNew : function (me) 
		{ 
			me.method="post"; 
			me.action="add.php?nFolderID=" + this.nFolderID + "&"; 
			me.submit; 
		} , 
		Update : function (me) 
		{ 
			me.method="post"; 
			me.action="update.php?nFolderID=" + this.nFolderID + "&nPos=" + this.nPos + "&"; 
			me.submit; 
		} , 
	},
	
	Calendar :
	{
		dSelected : function (thsDate)
		{ 
			var nPos = ENetArch.Appointments.nPos;
			if (nPos != 0)
			{
				location="Move.php?nFolderID=" + ENetArch.Appointments.nFolderID + "&" +
					"nPos=" + nPos + "&" + "dTarget=" + thsDate + "&";
			}
			else
			{
				location="List.php?nFolderID=" + ENetArch.Appointments.nFolderID + "&" +
					"dTarget=" + thsDate + "&";
			}
		}
	}
}