
/** **************************************************************** */
/*                                                                 */
/* Copyright (c) 2005-2008 Jasob.com */
/*                                                                 */
/* This obfuscated code was created by Jasob 3.1 Trial Version. */
/* The code may be used for evaluation purposes only. */
/* To obtain full rights to the obfuscated code you have to */
/* purchase the license key (http://www.jasob.com/Purchase.html). */
/*                                                                 */
/** **************************************************************** */

function generalStore() {
	this.createStore = function(url, data) {
		this.store = new Ext.data.JsonStore({
			url : url,
			root : 'data',
			fields : data
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getTopUsers() {
	this.createStore = function(ammount) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/ranking.php?page=getTopMembers&ammount=' + ammount,
			root : 'data',
			fields : ['userID', 'userName', 'userUrl', 'userLvl',
					'userAboutMe', 'verhicleName', 'verhicleID', 'verhicleUrl',
					{
						name : 'userRankPoints',
						type : 'int'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getForSaleCompanyStore() {
	this.creatStore = function(companyID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/buy.php?companyID=' + companyID
					+ '&page=showForSaleVerhicles',
			root : 'images',
			fields : ['name', 'url', 'ID', 'acceleration', 'price', 'topSpeed',
					'handling', 'class', 'verhicleType', 'minimumLevel', {
						name : 'size',
						type : 'float'
					}, {
						name : 'lastmod',
						type : 'date',
						dateFormat : 'timestamp'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getForSaleUserVerhicles() {
	this.creatStore = function(verhicleType) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/buy.php?verhicleType=' + verhicleType
					+ '&page=buyFromUsers',
			root : 'data',
			fields : ['userName', 'userID', 'name', 'url', 'ID',
					'acceleration', 'price', 'topSpeed', 'handling', 'class',
					'verhicleType', 'minimumLevel', {
						name : 'size',
						type : 'float'
					}, {
						name : 'lastmod',
						type : 'date',
						dateFormat : 'timestamp'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getForSaleVerhiclePartsStore() {
	this.createStore = function(companyID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/parts.php?companyID=' + companyID
					+ '&page=buyParts',
			root : 'data',
			fields : ['name', 'url', 'ID', 'acceleration', 'price', 'topSpeed',
					'handling', 'class', 'verhicleType', 'type']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getVerhiclePartsStore() {
	this.createStore = function(verhicleID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/parts.php?verhicleID=' + verhicleID
					+ '&page=showVerhicleParts',
			root : 'data',
			fields : ['name', 'url', 'ID', 'acceleration', 'price', 'topSpeed',
					'handling', 'class', 'verhicleType', 'type']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getMyPersonalMessagesStore() {
	this.createStore = function() {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/messages.php?page=getMyPersonalMessages',
			root : 'data',
			fields : ['pmID', 'senderID', 'senderName', 'senderUrl',
					'messageSubject', 'messageText', 'messageRead', 'sendDate',
					'senderCurrentVerhicleName', 'senderCurrentVerhicleUrl']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getWebsiteMembers() {
	this.createStore = function() {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/user.php?page=getWebsiteMembers',
			root : 'data',
			fields : ['userID', 'userName', {
				name : 'userLvl',
				type : 'int'
			}, 'userUrl', 'userAboutMe', 'verhicleName', 'verhicleID',
					'verhicleUrl']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getMyAvaibleParts() {
	this.createStore = function(verhiclePartType) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/parts.php?page=showMyParts&verhiclePartType='
					+ verhiclePartType,
			root : 'data',
			fields : ['name', 'url', 'ID', 'acceleration', 'price', 'topSpeed',
					'handling', 'class', 'verhicleType', 'type', 'usedBy']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getForSaleHousesStore() {
	this.creatStore = function(companyID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/buy.php?companyID=' + companyID
					+ '&page=showForSaleHouses',
			root : 'images',
			fields : ['ID', 'name', 'company_ID', 'price', 'storage', 'url',
					'min_level', {
						name : 'size',
						type : 'float'
					}, {
						name : 'lastmod',
						type : 'date',
						dateFormat : 'timestamp'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getMyHousesStore() {
	this.createStore = function() {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/user.php?page=showMyHouses',
			root : 'images',
			fields : ['ID', 'name', 'company_ID', 'value', 'storage', 'url',
					'min_level', {
						name : 'size',
						type : 'float'
					}, {
						name : 'lastmod',
						type : 'date',
						dateFormat : 'timestamp'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getMyRacesStore() {
	this.createStore = function() {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/racing.php?page=showMyRaces',
			root : 'data',
			fields : ['ID', 'raceName', 'turnover', 'class', 'status',
					'statusNumber', 'statusInName', 'slots', 'catogorie',
					'raceType', 'raceLaps']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getMyProfileInfoStore() {
	this.createStore = function(userID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/user.php?page=showMyProfileInfo&userID=' + userID,
			root : 'data',
			fields : [{
				name : 'Sport auto',
				mapping : 'userSportCarsExperiance'
			}, {
				name : 'Sport Motor',
				mapping : 'userSportBikesExperiance'
			}, {
				name : 'Persoonlijke link kliks',
				mapping : 'personalLinkClick'
			}, {
				name : 'Aantal keer goldmember',
				mapping : 'goldMemberAmmount'
			}, {
				name : 'Onderdelen gemaakt',
				mapping : 'userPartBuild'
			}, {
				name : 'Voertuigen gemaakt',
				mapping : 'userVerhicleBuild'
			}, {
				name : 'Aantal Auto Sport Races',
				mapping : 'userTotalCarSportRaces'
			}, {
				name : 'Aantal Motor Sport Races',
				mapping : 'userTotalBikeSportRaces'
			}, {
				name : 'Aantal Auto Straat Races',
				mapping : 'userTotalCarStreetRaces'
			}, {
				name : 'Aantal Motor Straat Races',
				mapping : 'userTotalBikeStreetRaces'
			}, {
				name : 'Aantal voertuigen',
				mapping : 'verhicleAmmount'
			}, {
				name : 'Aantal Onderdelen',
				mapping : 'partAmmount'
			}, {
				name : 'Aantal classe 1 voertuigen',
				mapping : 'class1Verhicles'
			}, {
				name : 'Aantal classe 2 voertuigen',
				mapping : 'class2Verhicles'
			}, {
				name : 'Aantal classe 3 voertuigen',
				mapping : 'class3Verhicles'
			}, {
				name : 'Aantal classe 4 voertuigen',
				mapping : 'class4Verhicles'
			}, {
				name : 'Aantal classe 5 voertuigen',
				mapping : 'class5Verhicles'
			}, {
				name : 'Naam',
				mapping : 'userName'
			}, {
				name : 'Gold',
				mapping : 'userGold'
			}, {
				name : 'Geld €',
				mapping : 'userMoney'
			}, {
				name : 'Reactie',
				mapping : 'userResponse'
			}, {
				name : 'Ervaring',
				mapping : 'userExperiance'
			}, {
				name : 'Conditie',
				mapping : 'userCondition'
			}, {
				name : 'Level',
				mapping : 'userLvl'
			}, {
				name : 'Circuit 1ste',
				mapping : 'userCircuitWins'
			}, {
				name : 'Circuit 2de',
				mapping : 'userCircuit2nd'
			}, {
				name : 'Circuit 3de',
				mapping : 'userCircuit3th'
			}, {
				name : 'Sprint 1ste',
				mapping : 'userSprintWins'
			}, {
				name : 'Sprint 2de',
				mapping : 'userSprint2nd'
			}, {
				name : 'Sprint 3de',
				mapping : 'userSprint3th'
			}, {
				name : 'Drift 1ste',
				mapping : 'userDriftWins'
			}, {
				name : 'Drift 2de',
				mapping : 'userDrift2nd'
			}, {
				name : 'Drift 3de',
				mapping : 'userDrift3th'
			}, {
				name : 'Lange Aftand 1ste',
				mapping : 'userLongDistanceWins'
			}, {
				name : 'Lange Aftand 2de',
				mapping : 'userLongDistance2nd'
			}, {
				name : 'Lange Aftand 3de',
				mapping : 'userLongDistance3th'
			}, {
				name : 'Totaal Races',
				mapping : 'userTotalRaces'
			}, {
				name : 'Forum Berichten',
				mapping : 'userForumPosts'
			}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function getRacersInfoStore(raceID) {
	this.createStore = function() {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/racing.php?page=getRacerInfo&raceID=' + raceID,
			root : 'data',
			fields : ['racerID', 'racerName', 'racerAvater', 'racerAboutMe',
					'verhicleName', 'verhiclePhoto', 'raceName', 'maxLaps']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function showCompanyStore() {
	this.creatStore = function(type) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/company.php?page=' + type,
			root : 'images',
			fields : ['name', 'url', 'ID', 'respectPoints', 'value',
					'turnover', 'level', 'ownerID', 'ownerName', 'ownerPhoto',
					'bannerImage', 'bannerImageRedirectUrl', 'type', 'storage',
					{
						name : 'size',
						type : 'float'
					}, {
						name : 'lastmod',
						type : 'date',
						dateFormat : 'timestamp'
					}]
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function showRaceResultStore() {
	this.creatStore = function(raceID, raceLap) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/racing.php?page=showRaceResult&raceID=' + raceID
					+ '&raceLap=' + raceLap,
			root : 'data',
			fields : ['lapID', 'raceID', 'raceLaps', 'circuitID', 'racerID',
					'racerName', 'racerLapTime', 'raceLapTimeFormated',
					'totalTime', 'totalTimeFormated', 'lapComment',
					'racerAvater', 'racerVerhiclePhoto', 'racerVerhicleName',
					'racerAboutMe', 'racerPosition']
		});
		this.store.setDefaultSort('totalTimeFormated', 'asc');
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
};
function raceInfoStore() {
	this.creatStore = function(raceID) {
		this.store = new Ext.data.JsonStore({
			url : '/paginas/racing.php?page=showRaceInfo&raceID=' + raceID,
			root : 'races',
			fields : ['', '', '', '', '', '', '', '', '']
		});
	};
	this.getMyStore = function() {
		return this.store;
	};
	this.reloadMyStore = function() {
		this.store.load();
	};
	this.countRecords = function() {
		return this.store.getTotalCount();
	};
	return this.store;
}