// Jobs Database

// Locations
var SINGAPORE = 1;
var CHINA = 2;
var PENANG = 3;
var JOHORE = 4;

// Location Names
var LOCATION = new Array ();
LOCATION[SINGAPORE] = 'Singapore';
LOCATION[CHINA] = 'China';
LOCATION[PENANG] = 'Penang, Malaysia';
LOCATION[JOHORE] = 'Johore, Malaysia';

// State Variables
var CURRENT_LOC;
var CURRENT_LOC_NAME = 'Unknown Location';

var JOBS = new Array ();
var JOBDETAILS = new Array ();

JOBS[SINGAPORE] = new Array();
JOBDETAILS[SINGAPORE] = new Array();

JOBS[CHINA] = new Array ();
JOBDETAILS[CHINA] = new Array ();

JOBS[PENANG] = new Array ();
JOBDETAILS[PENANG] = new Array ();

JOBS[JOHORE] = new Array ();
JOBDETAILS[JOHORE] = new Array ();

JOBS[1][0] = 'Sales Engineer';
JOBDETAILS[1][0] = '<p>We are an independent manufacturer of fully tested wire & cable harness and other value added assemblies.</p>' + 
	'<p>We are looking for positive, aggressive and committed individuals to join our young and dynamic team of professionals.</p>' +
	'<p>The Job</p>' +
	'<ul><li>Develop sales strategies to service and manage existing accounts</li><li>Conceptualise and execute sales action plans to increase client base</li><li>Work with support team to deliver solutions and achieve high level of customer satisfaction</li></ul>' +
	'<p>The Person</p>' +
	'<ul><li>Applicants must possess a Diploma in Electrical/Electronics Engineering or Marketing</li><li>2 years working experience preferably in the electronics industry</li><li>Independent and customer service-oriented</li><li>Must possess a class 3 driving license</li></ul>';

JOBS[JOHORE][0] = 'KEY ACCOUNT MANAGER';
JOBS[JOHORE][1] = 'PRODUCTION SUPERVISOR';
JOBS[JOHORE][2] = 'QA ENGINEER';
JOBS[JOHORE][3] = 'HR ASSISTANT';
JOBS[JOHORE][4] = 'PRODUCTION CLERK';

JOBDETAILS[JOHORE][0] = '<ul><li>Diploma holder in electrical or equivalent with at least 3 years of working experience in electrical/electronics industry.</li><li>Able to develop company sales by promoting product and services.</li></ul>';
JOBDETAILS[JOHORE][1] = '<ul><li>STPM level with at least 1 to 2 years working experience in manufacturing environment.</li><li>Able to speak and write English.</li><li>Computer literate and good communication skills</li></ul>';
JOBDETAILS[JOHORE][2] = '<ul><li>Degree in Electrical/Mechanical Engineering with at least 1 year of relevant experience or Diploma holder in the same discipline with at least 3 years of relevant working experience.</li></ul>';
JOBDETAILS[JOHORE][3] = '<ul><li>Diploma holder with at least 1 year of related working experience in manufacturing environment.</li><li>Knowledge in Easypay will be an added advantage.</li></ul>';
JOBDETAILS[JOHORE][4] = '<ul><li>SPM or equivalent</li><li>Minimum 1 year of working experience in manufacturing environment</li><li>Computer literate</li></ul>';

function jobWindow(val)
{
	var str = 'loc=';
	CURRENT_LOC = val;
	
	if (val == 0) return;
	
	str += val;
	popJobWindow(str);
}

function printJobs (loc)
{
		var table = '<table width="100%" border="0" cellspacing="0" cellpadding="3">';

		if ( JOBS[loc].length <= 0 ) {
				table += '<tr><td>There are no job openings in this location at this moment.</td></tr>';
		} else {
				for (i=0; i<JOBS[loc].length; i++) {
					table += '<tr>';
					table += '<td> <i><b>' + JOBS[loc][i] + '</b></i> ' + JOBDETAILS[loc][i] + ' </td>';
					table += '<td valign="top"><a href="appform.html?job=' + JOBS[loc][i] + '"><img src="images/btn_apply.gif" border="0"></a></td>';
					table += '</tr>';
				}
		}
		
		table += '</table>';
		
		document.write (table);
}
