OpenSportz Help
 

Index

General
Introduction
General
Hardware and Software
Site Configuration
Server Installation
Kiosk Installation
IPSEC VPN Setup

Database
Accounts
Account History
Bank Statement Import
Bookings
Door Control
Lights On / Off
User Details
Card Details
Door Access Info
New Bookings
User Group Charges
Zero Account Balances
Special Card Types
Contact List

Reports
Court Usage
Door Access
Financial Report
Transaction Report
Trial Balance Report
Incorrect Balance Report
Invoicing
User Group Report
User Details Report

Setup
Account Types
Address Types
Court Hire Rates
Contact Types
Court Setup
Device Setup
Device Firmware Upgrade
Group Flag Types
Kiosk Information
User Group Types
Note Types
Play/Access Time Setup
Sport Setup
Transaction Types

Maintenance
Audit Log
Backup
Import Data
System Status
Server Status
OpenSportz Status

What is OpenSportz ?
 
top

OpenSportz is an open source sports facility managment system designed to make the daily operation of the facility easier.

OpenSportz curently provides the following features:

  • User/player database recording names, addresses, contact details, etc.
  • Comprehensive accounting facilities including multiple account types, transaction types, journal entries and reports.
  • Proximity security cards assigned to each member/player. Magnetic stripe and smart cards can also be interfaced to the system.
  • Lighting control of court and non-court lighting, linked to the security card, including time-of-day and day-of-week charging.
  • Door access via security card.
  • Comprehensive reporting facilities.

By using OpenSportz, your facility will increase security, reduce fraud and theft, and free up your committee/volunteers to promote your sport/club rather than being tied down in daily administration.

 
Hardware and Software Requirements
 
top

OpenSportz is currently being developed on the following platform:

  • 2GHz CPU with 1GB RAM
  • openSUSE Linux 10.3
  • Apache 2.2.4
  • MySQL 5.0.45
  • PHP 5.2.4

That said, pretty much any computer capable of running Linux with MySQL (v3.x, 4.x or 5.x) and PHP (v4.x or 5.x) should work with the possibility of some minor language compatibility issues.

 
openSUSE Server Installation
 
top

Here's a typical server setup for running and ZoneMinder with 4 or more cameras. Your server MUST have an internet connection to complete the installation.

Hardware. Here's our typical (high end) server hardware spec.

  • Intel Core2 Quad CPU
  • 4GB DDR3 SDRAM
  • 2x 250GB SATAII hard drives, RAID1 (for OS and apps)
  • 2x 1TB SATAII hard drives, RAID1 (for video files)
  • 4 port video capture card

OpenSUSE 10.3. Boot from the openSUSE 10.3 CDROM and choose Install. Then choose New Installation. Follow the default options until you get to Partitioning, Software Packages and Boot Loader options. See below for what to do next.

Partitioning the hard drives. We will use RAID1 (Mirrored) drives, so setup the 2x 250GB drives as 248GB (mount point /) with type Linux RAID (0xFD) and 2GB for Linux swap (not mirrored). Note that the swap partition must not be the first partition on the disk.

Setup the 2x 1TB drives as Linux RAID for the entire drive (mount point /srv/www/htdocs/zm). Next create the RAID partitions, set our 248GB / partition as type EXT3 and the 1TB /srv/www/htdocs/zm partition as type XFS.

Boot Loader. Since we are using RAID1 and only a single OS we need to install the Boot Loader (Grub) into the Master Boot Record (otherwise the install tries to put it on one of the raid partitions and you wont be able to boot). So ensure you check "Boot from Master Boot Record" and uncheck "Custom Boot Record", then under Boot Loader Options check "Write Generic Boot Code to MBR".

Software Packages. Select the following additional software package groups: File Server, Web Server, C++ Development, Kernel Sources.

Reboot the server now and finished the standard install questions (root password, release notes, etc.

OS Update. Using Yast select the following online community repositories: OpenSUSE update, NVIDIA and packman. Now perform a software update to get all the lates OS patches and kernel updates. This will take some time.

NVidia Driver. Assuming you have installed an NVidia graphics card you should install the NVidia driver matching your card, typically x11-video-nvidiaG01. Run "sax2 -r" for X.Org configuration.

ZoneMinder software requirements. See this link for additional software required before installing ZoneMinder. My experience has shown it is better to compile ffmpeg from source otherwise the ZoneMinder configure step fails to find the required libraries (see ffmpeg download) (Note, ZoneMinder build fine using the ffmpeg from rpm or yast on openSuse 11.2 and 11.4). Once installed you need to manually copy the boot script from scripts/zm to /etc/init.d/zm, then edit it to remove the 'functions' include and change 'success' to 'echo success' and 'failure' to 'echo failure'. Also create the following symbolic links:

  • ln -s /etc/init.d/zm /usr/sbin/rczm
  • ln -s /etc/init.d/zm /etc/init.d/rc3.d/S119zm
  • ln -s /etc/init.d/zm /etc/init.d/rc3.d/K11zm
  • ln -s /etc/init.d/zm /etc/init.d/rc5.d/S11zm
  • ln -s /etc/init.d/zm /etc/init.d/rc5.d/K11zm
An example ZoneMinder startup script for openSuse 10.3 is included in the OpenSportz scripts directory. OpenSuse yast install packages can now be found for openSuse 11.1 onwards here.

Here is a typical ZoneMinder configure command: ./configure --with-webdir=/srv/www/htdocs/zm --with-cgidir=/srv/www/cgi-bin --with-webuser=wwwrun --with-webgroup=www ZM_SSL_LIB=openssl ZM_DB_PASS=xxxxxx. If you need to install additional perl modules you can use the following command as root perl -MCPAN -e 'install foo::blah'

Kernel Shared Memory. ZoneMinder makes use of a lot of shared memory so we must adjust the kernel shmall and shmmax parameters in the /etc/sysctl file. Set 'kernel.shmmall=2048000' (this means a max of 2048000 pages of shared memory, or 8GB) and 'kernel.shmmax=4194304000' (this means a max of 4GBytes of shared memory per request).

The OpenSportz osz-ethernet.php script can check the status of the ZoneMinder database if you issue the following mysql grant command: grant all on zm.* to openuser@'localhost' identified by '*******', where 'openuser' and the '******' password comes from your site_config.php file. If the ZoneMinder database is found to be corrupted an auto-repair will be attempted and an email will be sent to the SECURITY_EMAIL_ADDRESS in the site_config.php file.

OpenSportz software requirements. Using the Yast Software Update install the following php5 modules: php5-bz2, php5-gd, php5-mysql, php5-pcntl, php5-sockets and php5-zlib. The Apache web server and MySQL database will have already been installed during the base install.

NUT UPS software. If you are using a UPS (and you should be !) install NUT. Example NUT configuration files are included in the OpenSportz scripts directory (/srv/www/htdocs/opensportz/scripts).

Checking your RAID disk status: Check your raid disks are ok by using the mdadm command as root: mdadm --misc --detail /dev/md0

Securing SSH for remote access. SSH is a secure shell protocol which can make remote access and configuration of your server easy. But you must take care to make ssh secure, so here are the first few steps:

  • On the server configure sshd to only allow public key access by the following changes to /etc/ssh/sshd_config:
    • PermitRootLogin no
    • PasswordAuthentication no
    • ChallengeResponseAuthentication no
  • On your remote machine(s) create a private/public dsa key by the command. Ensure you secure your private key with a pass phrase.
    • On linux: ssh-keygen -t dsa (creates private key file id_dsa and public key file id_dsa.pub).
    • On Windows: use putty: generatekey.exe (save your private and public key files to the hard drive).
  • Now copy the *.pub public key files (NOT the private key files) to the OpenSportz server. If you do not have console access you will need to use a USB flash disk to transfer the files:
    • Add the public key contents to the opensportz users home directory /home/opensportz/.ssh/authorized_keys with the command cat /media/disk/my_public_key.pub >> /home/opensportz/.ssh/authorized_keys
    • If the public key was generated on a Windows machine you should edit the authorized_keys file to remove any newlines or comments as each public key should be on a single line.
  • Change the permissions of the authoized_keys file to 0600 by the command chmod 600 /home/opensportz/.ssh/authoriized_keys
  • Now you can login to the server by ssh without having to use a password (you will need to type in your private key pass phrase - but this is not sent across the internet)
    • On linux: ssh opensportz@www.xxx.yyy.zzz
    • On Windows: use Putty: make sure you point the putty connection to your saved private key on disk.
  • If you loose or regenerate your private/public keys on the remote machine your ssh access will cease. Same thing if you forget your private key pass phrase.

Remote Administration. Command line remote administration is easliy done using SSH after you have preloaded your public keys as described above. You can even run remote GUI applications if your client machine is running an X Server. Simply run 'ssh -X opensportz@myclub.co.nz' to enable the X extensions and forward the GUI to your desktop. If you get the error message 'Cannot connect to X server' then check the following settings on the server:

  • Ensure your client machine's firewall is set to allow access to the X Display manager.
  • Ensure your client machine's X display permissions allow connections from the server, try 'xhost +' to allow connections from anyone (but note that this is rather insecure).
  • Once you login with 'ssh -X ....' check your DISPLAY environment variable is set, it should be something like 'localhost:10.0'.
  • In the sshd configuration /etc/ssh/sshd_config ensure 'X11Forwarding yes' is set.

How to clone a hard drive. If you want to copy the Kiosk PC hard drive to make another bookings kiosk here is a simple procedure to clone the hard drive. This procedure works even if the hard drives are different sizes.

  • Install the new drive and boot up the existing kiosk PC.
  • Use Yast - System - Partitioner to create 2 partitions on the new drive (/dev/sdb). Create a root (/) partition with most of the drive space and create a swap partition using the remaining space (approx 2GB). Mount the new drive at /new-disk so we can copy the files across.
  • Copy existing files to the new disk with the command cp -ax / /new-disk. This will take a few minutes to complete, then make a few extra commands:
    • Create missing /dev/ directory: mkdir -p /new-disk/dev/pts.
    • Remove mounting of the new disk: vi /etc/fstab to remove references to /dev/sdb.
    • Change new disk mounting: vi /new-disk/etc/fstab to change /dev/disk/by-id... to /dev/sda.
  • Check new disk grub boot menu information: vi /new-disk/boot/grub/menu.lst to ensure it references hd0 and /dev/sda.
  • Make the new disk bootable: fdisk /dev/sdb a 1 w.
  • Install Grub: grub-install --root-directory=/new-disk /dev/sdb. TODO: this command does not seem to work - you need to boot the first time onto the openSUSE 10.3 cdrom and do an upgrade installing no packages and get the cdrom to install the boot loader.
  • Fix the ethernet persistent MAC address settings: vi /new-disk/etc/udev/rules.d/70-persistent-net.rules to remove the eth0 lines since the new PC will have a different MAC address.
  • Boot the new machine with our cloned hard drive. If the motherboard video (or add in video card) use a different driver you will need to run sax2 -r to get the correct video driver installed. The manually re-add the elo driver section into /etc/X11/xorg.conf using /etc/X11/xorg.conf.opensportz as an example. Do not use Sax to install a touch screen as it does not work with the elo driver compiled from source.
  • Fixup the network settings with Yast - Network Devices - Network Card. Delete the existing eth0 entry and then re-add the eth0 entry. If you use a static IP address make sure if it unique, otherwise use DHCP.
  • Change the hostname if you are uptting this machine on the same network as your existing kiosk PC.
  • All done - it should be working

 
openSUSE Kiosk Installation
 
top

Here's a typical kiosk setup for running . Your kiosk PC MUST have an internet connection to complete the installation.

Hardware. Here's our typical kiosk hardware spec.

  • Intel Celeron 1.8GHz CPU
  • 1GB DDR2 SDRAM
  • 1x 160GB SATAII hard drive
  • Motherboard with onboard video and network

Software.

  • Install openSUSE 10.3 operating system. Boot from the openSUSE installation CDROM, accept all the default settings, come back in an hour or so (depends on your internet download speed). You currently cannot install openSUSE 11.2 since the ELO touch screen driver is not compatible with kernel version 2.6.31.
  • Install the following additional software packages:
    • cifs
    • gcc and gcc++ compiler
    • make
    • kernel source files
    • php5
  • Network configuration and services
    • Set a static IP address, e.g. 192.168.1.80 (Yast - Network Devices - Network Settings - Overview)
    • Set a sensible hostname, domain and DNS for the PC, e.g. kiosk, myclub.co.nz (Yast - Network Devices - Network Settings - Hostname/DNS
    • Set the default router to your OpenSportz server, e.g. 192.168.1.1 (Yast - Network Devices - Network Settings - Routing)
    • Set NTP to start automatically at boot time so the PC clock keeps the correct time (Yast - Network Services - NTP)
    • Set the firewall to allow ssh access (Yast - Security and Users - Firewall)
    • Set System Services to start sshd a boot time (Yast - System - System Services (Runlevel))
  • Mount the OpenSportz directory on the server using cifs.
    • You must be root to run the following commands
    • Edit /etc/fstab: //192.168.1.1/opensportz /srv/www/htdocs/opensportz cifs auto,gid=users,file_mode=0660,dir_mode=0660,iocharset=utf8 ,domain=YOURDOMAIN,credentials=/etc/winpassword 0 0
    • Create /etc/winpassword: username=opensportz password=xxxxxxx. File permissions must be 0600 root:root
    • Create the directory /srv/www/htdocs/opensportz and set the permissions to 0755 opensportz:users
    • Reboot or run mount -a to mount the file system
  • Configure the screen saver of your choice with no password and set the screen power management to 0 minutes for suspend and power off timing.
  • Install the ELO touch screen driver
    • Compile the ELO driver from source
    • Edit the /etc/X11/xorg/conf file
  • Make Konqueror the default web browser - (Configure Desktop - Default Applocations - Web Browser - konqueror)
  • Set the task bar to auto hide (Right click on task bar - Configure Panel - Auto Hide)
  • Run the opensportz-kiosk.sh script from /etc/inittab
    • Create the /home/opensportz/opensportz.conf file (copy the default file from the web server, normally /srv/www/htdocs/opensport/opensportz.conf)
    • Create the logging directory /var/log/opensportz with permissions 0666 opensportz:users
    • Ensure the serial port permissions are correct (0666), add /etc/udev/rules.d/10-local.rules containing KERNEL=="ttyS0" MODE="0666"
    • Edit /etc/inittab to add the line: oz:35:respawn:/srv/www/htdocs/opensportz/scripts/opensportz-kiosk.sh 1 1 0 0 0 0
  • Using the kiosk with a mouse or trackball. In this case we need to disable the middle and right mouse buttons to stop users breaking out of the Konqueror browser full screen mode. We do this by addind the line Option "ButtonMapping" "1 1 1" to the /etc/X11/xorg.conf file in the mouse Input Device section(s).

 
IPSEC VPN Setup
 
top

Install the novell-ipsec-tools package from 'Yast - Software Management'. This installs the racoon daemon and associated tools. Set the racoon daemon to run at boot time from 'Yast - System Services (Runlevel)'.

The racoon configuration files are in /etc/racoon and certificate files are in /etc/ssl. An example racoon.conf file is included with OpenSportz in 'scripts/racoon.conf.sample'.

Make some changes to the openssl setup so we can generate certificates (you need to be logged in as 'root' for all the openssl and racoon commands):

  • cd /etc/ssl
  • vi openssl.conf - change CA_default dir from './demoCA' to '.'
  • mkdir newcerts
  • vi serial - insert 01
  • touch index.txt

Creating the certificate files with openssl:

  • Run the following commands from the /etc/ssl directory.
  • Create a root certificate: 'openssl req -new -x509 -keyout ./caprivkey.pem -out ./cacert.pem -days 3650'. Generating the certificate requires a pass phrase - do not loose this and keep it safe !.
  • Create the certificate request: 'openssl req -new -nodes -keyout ./privkey.pem -out ./req.pem'.
  • Sign the certificate request: 'openssl ca -out ./cert.pem -keyfile ./caprivkey.pem -cert ./cacert.pem -days 3650 -infiles ./req.pem'.
The 'roadwarrior' clients need the cacert.pem from step 1 above. The racoon daemon setup needs the privkey.pem from step 1 and the signed certificate request from step 3 - the location of these files is set in the racoon.conf file.

Restart the racoon daemon by 'rcracoon restart'.

Configure the openSUSE firewall to allow IPSEC. Configure your ADSL modem to allow IPSEC pass through, you may also need to specifically allow UDP on ports 500 and 4500 and TCP on port 50 to the server.

Client VPN setup. Use Shrewsoft's VPN client - it works on Windows XP and Linux clients and it's free. Download it from www.shrewsoft.com. Use a USB key to transfer the cacert.pem file created above - do NOT email the cacert.pem file about for security reasons.

Setup your VPN clients as follows:
vpn-accessmanager
vpn-general vpn-client vpn-nameresolution
vpn-authentication-local vpn-authentication-remote vpn-authentication-credentials
vpn-phase1 vpn-phase2 vpn-policy

 
General
 
top

Automatic Logout. After 5 minutes of inactivity you will be automatically returned to the home page of the portal and any changes will not be saved. This is to ensure someone does not lock out another user. The timeout period is configurable. The automatic logout does not apply, however, if you are entering details of a new player or a new receipt.

Securlty Levels. The following security access levels are used to restrict users from accessing certain database information.

  • Guest access. Most users get this access level, it only allows them to access the court bookings via the internet and update their own contact details.
  • Committee access. Your committee members normally get this class of access, it allows access to all user information, bookings and they can receipt money.
  • Accounts access. All the access of 'User' and can process user group charges, import bank statements, modify/delete accounts records and bulk email invoices.
  • System Administrator access. Unrestricted access to all database information including deleting user records. Only a user with 'Admin' access can set a security access level of 'User', 'Accounts' or 'Admin'. Access to the 'Setup' and 'Maintenance' menus is also restricted to users with 'Admin' access. For security, whenever a new user is allocated the 'Admin' security level, an email will be sent to all other 'admin' level users.

 
Site Configuration
 
top

The site_config.php file is where you personalise OpenSportz to your particular club. A sample config file is provided as site_config_sample.php for you to copy and edit when you first install OpenSportz.

When you upgrade OpenSportz your site_config.php file will remain unchanged with any new settings appearing in site_config_sample.php. You must manually add any new settings into your site_config.php file.

The following settings are contained in the site_config.php file:

  • WEBSITE_DOMAIN_NAME: Enter the domain name of your web server, e.g. http://www.mysportsclub.org.nz. This setting is used for security to redirect web browsers to the main page if they try to access pages directly.
  • DB_HOST_NAME: The server host name which runs the MySQL database, normally you would not need to change this from the default 'localhost';
  • DB_USER_NAME: The MySQL database username, normally you would not change this from the default 'openuser'.
  • DB_PASSWORD: This is the MySQL database password - for security reasons you should change this from the default value when OpenSportz is first installed. At this time you should also edit the tables.sql script and include the same modified password there when the initial tables are created.
  • DB_DATABASE_NAME: The name of the OpenSportz MySQL database, normally you would not nede to change this setting from the default 'opensportz'.
  • OSZ_BACKUP_PATH: This is the directory on the server where the daily backup files will be copied to. The backups are initiated by the script './scripts/backup-all.sh' which is called at 2:00am by ./scripts/opensportz.sh
  • OSZ_BACKUP_EMAIL: This is a comma separated list of email addresses which will be emailed the MySQL database backup file each morning at 2:00am.
  • FACILITY_NAME: The name of your sports club, this will appear on any printed reports and as the web page title.
  • FACILITY_ADDRESS1: The first line of your clubs address.
  • FACILITY_ADDRESS2: The second line of your clubs address.
  • FACILITY_ADDRESS3: The third line of your clubs address.
  • FACILITY_GSTNUMBER: Your clubs GST number which is printed/displayed on all invoices.
  • FACILITY_PAYMENTTERMS: The payment terms to be printed/displayed on all invoices.
  • FACILITY_BANKACCOUNTNAME: Your clubs bank account name printed/displayed on all invoices.
  • FACILITY_BANKACCOUNTNUM: Your clubs bank account number printed/displayed on all invoices.
  • FACILITY_EMAIL_ADDRESS: A general enquiries email address for your club shown on the home page.
  • FACILITY_ACCOUNTS_EMAIL: An accounts email address for your club, this is used as the 'Reply-To' address on emailed invoices.
  • FACILITY_ADMIN_NAME: This is the name shown in the 'From' field of emailed invoices.
  • FACILITY_IMAGE_1: This is the first image of your club displayed on the home page.
  • FACILITY_IMAGE_2: This is the second image of your club displayed on the home page.
  • INVOICE_IMAGE_1: This is your clubs logo which is displayed/printed on invoices. The image size should be less than approximately 18KB to ensure loading emailed invoices are not too slow for people using dialup internet. The image dimensions should be 564 wide by 129 high, or a ratio of approximately 4.3:1.
  • SECURITY_EMAIL_ADDRESS: This email address will be sent emails in response to failed login attempts and other security related issues. The default address is 'security@opensportz.org'.
  • BOOKING_KEEP_TIME: This is the number of minutes (default = 10) to keep a manual lights on booking if the player does not turn up to swipe their card to say they have arrived. After this time the booking is cancelled freeing up the court for someone else to play.
  • BOOKING_EARLY_TURNON_TIME: This is the number of minutes early (default = 10) a player can swipe to say they have arrived for their booking. After they have swiped the lights will turn on automatically when the booking start time arrives.
  • BOOKING_MAX_DAYS_AHEAD: The limits the number of days (default = 18) ahead a player can book a court.
  • BOOKING_DOOR_UNLOCK_ANY_CARD: Allow any card swipe to keep the door unlocked for a booking (default=true), or require the booking owner to swipe (false). The booking must be set for "Door unlock on first swipe".
  • BOOKINGS_ALLOW_TYPE_CHANGE: Bookings via kiosk or web allow all users to change auto/manual lights on status (= true), or only users with committee logon or 'Manager Card' status can change the booking type (= false).
  • DEFAULT_DOOR_OPEN_DURATION: The booking door open default duration: (-1 = entire duration, 30= minutes).
  • ACCOUNT_RECORD_DELETE_ALLOWED: This accounting option controls whether receipt records can be deleted permanently from the database or are only journalled out (default = false).
  • NON_COURT_LIGHTS_TIMER: The 'Non Court Lights' feature allows the court lighting control unit to also turn on and off hallway/foyer/etc lighting so that players can see what they are doing when packing up after their game ends (default = 30 minutes).
  • NON_COURT_LIGHTS_OFF_IF_COURT_ON: The 'Non Court Lights' should be off any court lights are on (default = true).
  • INVOICE_FORMAT: This setting defines the order of fields in an invoice (default = 0). 0 = date, amount, initials, type, rcptnum, details; 1 = date, amount, details, initials, type, rcptnum.
  • DEFAULT_VISITOR_CHARGE: For players who require two cards to operate the lights, this value is the default visitor charge in dollars per hour (default = $1.00 per hour) which is charged to the player, in addition to half the normal court hire charge, when they select the Visitor option when turning on the court lights.
  • DEFAULT_PRACTICE_CHARGE: For players who require two cards to operate the lights, this value is the default practice charge in dollars per hour (default = $1.00 per hour) which is charged to the player, in addition to half the normal court hire charge, when they select the Practice option when turning on the court lights.
  • DEFAULT_VISITOR_CHARGE_FREE: For players who require two cards to operate the lights where their normal court hire charge is zero, this value is the default visitor charge in dollars per hour (default = $3.00 per hour) which is charged to the player when they select the Visitor option when turning on the court lights.
  • VISITOR_PRACTICE_PAY_HALF: For players who require two cards to operate the lights, this value sets whether they pay the full court hire cost (default = true) or only half the cost (plus any special visitor/practice charges).
  • SHOW_TEST_CARD_BUTTONS: This setting should be disabled (default = false) for normal operation. It is used to simulate kiosk bookings card swipes for testing purposes only.
  • KIOSK_SCREEN_RESOLUTION: This settings is used to default the screen resolution of the kiosk bookings monitor (default = SVGA) and is used to position and size the touch screen buttons for easy operation. The valid options are VGS (640x480), SVGA (800x600) or XVGA (1024x768).
  • SPECIAL_CARD_TYPE_T_HOURS: This setting controls how many hours (default = 0) after a Special Type T card is first swiped for door access before the card is disabled. A setting of 0 means the card is immediately disabled after its first use.
  • DEBT_LIMIT_1-4: These 4 dollar values set the amounts that each player can overspend, or go into debt, on their court hire account. Normally values such as $0.00, $200.00, $1500.00 and $9999.00 are used.
  • PASSWORDS_REQUIRE_SYMBOLS: When passwords are changed by users do they require symbol characters in addition to letters and numbers (default = true).
  • SHOW_IMPORTED_CARD_NUMBER: Should the user details screen show the users imported card number, e.g. from the old Sport Manager system. Defaults to false.
  • CONTACT_LIST_REQUIRE_CONTACT: If true, names displayed on the contact list will only appear if they have a publicly visible contact method (e.g. phone, email, etc). If false, names will appear if they have a Grade or contact method. The default is true.
  • CONTACT_LIST_SHOW_CODE_POINTS: Should the contact list show the Code and Points columns. Defaults to true.
  • DEFAULT_COURT_PERIODS: The default number of court periods set when creating a new member record. Defaults to 2.

 
Address Types
 
top

address-types1.png

Address Types allow you to record different types of address records for each user if required.

For example, you may need to record a postal address and a separate physical address.

Each address record can have up to 4 lines and each line can be up to 30 charachers in length.

The following address types are setup by default:

  • P: Postal address.

 
Contact Types
 
top

contact-types1.png

Contact Types are a way of recording different ways of contacting your players, such as home and work telephone, email contact details, etc.

The following contact types are setup by default:

  • H. Home or after hours telephone number.
  • W. Work or daytime telephone number.
  • M. Mobile telephone number.
  • F. Fax telephone number.
  • E. Email address.

You can add your own categories, for example, home email and work email or different telephone numbers.

Each contact record can be up to 60 characters in length and you can also choose whether the information should be visible to other users on the Contact List.

If multiple email addresses are loaded for an individual then any automated emails (e.g. new user registration, invoices, receipt confirmation, etc) will be sent to all email addresses.

 
Contact Types
 
top

group-flag-types1.png

Group Flags are a way of grouping your players, for example, Juniors, Masters, Committee members, etc.

The group flag type can be up to 10 characters and its description up to 100 characters in length.

Each users group flag records are marked with a single character marking their inclusion in that pariticular group, e.g. Y or N.

 
Note Types
 
top

note-types1.png

Note types allow you to record general information about each user.

Your can add your own note categories, such as general, interclub, volunteer skills, etc.

The note type is a single character (A-Z, 0-9) and the description is up to 100 characters in length. The extension is for future use, currently only text (TXT) fields are supported.

 
Account Types
 
top

account-types1.png

You can setup one or more Account Types where each Account Type is treated as a separate "bank account" for each user. The Account Type is a single character (A-Z, 0-9) and the Description can be up to 100 characters in length.

For example, you might have a "Court Hire" account for all court hire transactions, and a separate "Membership" account for tracking the players affiliation or joining fees.

If required each account type can be hidden from the users details and reports pages by unchecking the Enabled box.

If you want to enable automatic user group billing of subscriptions or other periodic amounts you must select one of your account types, e.g. the 'Subscriptions' account, to be used for User Group Billing by checking the 'User Group Billing' checkbox. This will cause all user accounts to be checked each night for an expired group and then debit their account with the amount defined for that user group type.

 
Transaction Types
 
top

transaction-types1.png

Transaction Types are used to ensure the financial records of court hire, shuttles, balls, racket hire, etc are kept in separate categories for ease of financial reporting.

The 'Transaction Type' is a 3 character code and its description can be up to 100 characters in length.

The following transaction types are setup by default:

  • HIR: Court hire charges.
  • CSH: Cash transaction.
  • CHQ: Cheque transaction.
  • EFT: Eftpos transaction.
  • DIR: Direct Credit transactions.
  • JNL: Journal / adjustment transaction.

 
Sport Setup
 
top

sport-setup1.png

This screen allows you to setup the name of the sport(s) played at your facility. Multi sport facilities are also supported.

If your facility has courts for the same sport which should be handled separately, such as indoor tennis and outdoor tennis courts, you can record these as different sports, for example naming them 'Indoor Tennis' and 'Outdoor Tennis'.

If a particular sport does not use the 'two cards' option for turning on court lights then you can hide these fields from the members and bookings pages.

Within each sport you can also record details of each court, such as its name or number, refer to the section on Court Setup for more information.

 
Court Setup
 
top

This screen allows you to record details of each court at your facility:

court-setup1.png

  • Court number, for example 1,2,3...
  • Court name, such as a reference to a sponsor, 'Pak'N Save' or 'Macs Gold'
  • Valid playing/booking times, select a preset Valid Time schedule from the drop down list.
  • Default charging category, select a preset Charge Category from the drop down list.
  • Start Time, enter the earilest time a player may book this court, for example 6:00am
  • Period, enter the standard court booking period in minutes, either 15, 20, 30, 45 or 60.

 
Play/Access Time Setup
 
top

time-setup1.png

The Play/Access Times (or Valid Times) screen allows you to define time periods during the day (and days of the week) which can then be linked to door access times or playing times.

For example, committe members or your security monitoring company need 24 hour access to the facility, so you link their door access to a "24 hour" Valid Time record. Normal users are only allowed to enter the facility from 6:00am to 11:30pm, so their door access is linked to this record.

Similarly, for playing times, you can define when all users or certain groups of users can turn on the court lights.

For court hire charging, the Valid Time records can be used to charge different amounts, e.g. to charge more during 'peak time'.

 
Court Hire Rates
 
top

court-hire-rates1.png

This screen allows you to setup different court hire rates. You may have a simple scheme where all players are charged the same amount, or multiple hire rates, e.g. $4.00 for Juniors, $6.00 for Adults, $10.00 for non 'members', etc. You can make the hire rates as simple or as complex as you like to suit your facility.

All rates are specified in a dollar amount per hour. If your court periods are not in even hour periods you must calculate the appropriate hourly charge, e.g. if you charge $4.50 per 45 minutes, your hourly rate is $6.00.

On the user details page you can specify 2 court hire rates. One for the first court used and a separate rate if multiple courts are used at the same time (obviously to make use of the second rate the user must have the 'Multi Court' option also). The lowest numbered court will always be at the 'single' court hire rate regardless of the order the bookings were made.

Each court hire rate can have an option 'No Show Fee' set which will be charged to the player if they do not turn up to use their booking and the booking is automatically cancelled by the system after the 10 minute waiting period. Note that if the player has multiple courts booked and does not show up, then the no show fee charged will be the fee for the single court hire rate for all courts, not the fee for the multi court hire rate.

 
User Details
 
top

Selecting Users. This screen displays a list of users in alphabetical or card number order.
member-select1.png
member-select2.png

To select a user from the list, simply click the mouse on their name. To search for a user, enter the first few letters of their name then click the search button. There are also alphabetical 'quick search' links to jump to a part of the alphabet.

User Details Once you have selected an individual user, you can then view or edit their details, including name, address, contact information, and account details. Simply click the save button to record your changes in the database.
member-details1.png

For individual players you should record their name using the surname, firstname and middlename fields. For group or business records you should record the group/business name in the surname field and the contact person in the contact field.

After you change the users details you must click one of the Save buttons on the right hand side of the page to save all changes. Any Save button will do, they all do the same thing, multiple buttons are displayed so you don't have to scroll the page up and down.

The following fields on the users details page have special features:

  • Expiry Date: Once the expiry date is reached the users internet login and all cards for this player are automatically disabled. This is useful if you use a fixed term 'membership' so you don't have to remember to disable the account manually.

You cannot setup a login username and password for a user until their email address has been recorded in the database. Once the email address is recorded you can enter their login username and password which will be automatically emailed to the user when you save these details. If the password is lost or compromised you must create a new password as the actual password is not held in the database, only its SHA1 hash value. For security, whenever a user login attempt fails an email will be sent to the SECURITY_EMAIL_ADDRESS defined in your site_config.php file.

You can link family groups together by choosing who will be the primary group member and then selecting the other members of the group. As an option you can specify that the primary group member will pay the court hire for the other members of the group by checking the 'Pays for family members' box on the member details page. Each card within the group operates independently just like any other card, but if a group member runs out of money funds for court hire funds can be automatically transferred from the primary member.

Securlty Levels. The following security access levels are used to restrict users from accessing certain database information.

  • Guest access. Most users get this access level, it only allows them to access the court bookings via the internet and update their own contact details.
  • Team Captain access. This level extends the Guest access with the ability to view/print selected reports as specified on their User Details page.
  • Committee access. Your committee members normally get this class of access, it allows access to all user information, bookings and they can receipt money.
  • Accounts access. All the access of 'User' and can process user group charges, import bank statements, modify/delete accounts records and bulk email invoices.
  • System Administrator access. Unrestricted access to all database information including deleting user records. Only a user with 'Admin' access can set a security access level of 'User', 'Accounts' or 'Admin'. Access to the 'Setup' and 'Maintenance' menus is also restricted to users with 'Admin' access. For security, whenever a new user is allocated the 'Admin' security level, an email will be sent to all other 'admin' level users.

 
Bookings
 
top

This screen shows the court bookings for the selected date and sport.
bookings1.png

By clicking on a blank court time slot you can select the player then create a new booking.

If you click on an existing booking the booking details will be displayed. If the booking has not yet started you can alter any of the booking details. If the booking has already started you can only alter the booking end time.

If a player arrives early, they can swipe their card up to 10 minutes (configurable via the site_config.php file) before their booking time to set the lights to come on automatically when the booking time is reached.

If a player turns up late for their booking, the booking will only be held for 10 minutes (configurable via the site_config.php file) after which it will be cancelled.

Long term bookings vs one off bookings. The best way to enter bookings for a "long term" booking (club nights) vs one off events (tournaments) is the following order:

  1. Enter the long term booking - this creates individual booking records for each booking date and court.
  2. Go to the date of the one off event in the bookings screen and delete the SINGLE DATE of the booking that clashes (do not delete the entire booking by mistake !) - alternatively you could only delete some of the courts booked or reduce the booked time - do whatever is needed to fit in the one off booking. This will leave all other dates unchanged for the long term booking.
  3. Make the one off booking as per normal - there should be no booking clash.

The other situation you will encounter is when there is already a one off booking in the future which clashes with the long term booking you are trying to enter. In this case you have 2 choices:

  • Delete or shorted the time of the one off booking so your long term booking fits around it as above, or
  • Split the dates of your long term booking into 2 separate bookings which jump across the one off booking date.
Currently the software cannot handle booking clashes automatically - it just tells you the first booking which clashes. We hope to improve this in the future.

 
New Bookings
 
top

The new booking details are displayed here, including the start time, duration and cost of the booking.

If the booking has not yet started you can alter any of the booking details. If the booking has started you can only alter the booking end time or turn the lights off immediately.

If the player is set to require two separate cards to turn the lights on they can also choose to play with a visitor or a solo practice session - if they have visitor or practice sessions alailable on their card settings.

If the lights are turned on with two cards each player will pay half the standard court hire charge.

If the player turns the lights on with the visitor option they will pay half the standard court hire charge plus any optional visitor charge loaded against ther card settings.

If the player turns the lights on with the practice option they will pay half the standard court hire charge plus any optional practice charge loaded against ther card settings.

 
Accounts
 
top

This is where you record money received from the player to put against their account, which they can then use for purchases such as court hire, racket stringing, etc.

You can also deduct money from a players account using this same screen, for example, for an annual facility usage fee or interclub fees.

The following fields can be entered when adding a accounts record:

  • Transaction Date
  • Initials - 3 character initials of who is entering the account change
  • Transaction Type - e.g. 'JNL' for journals
  • Amount - usually greater than zero, but can be less than zero if the transaction type is JNL
  • Account Type - e.g. 'Court Hire Account'
  • Split Amount 1,2,3 - allows you to split a single payments across multiple accounts
  • Split Account Type 1,2,3 - allows you to split a single payments across multiple accounts
  • Comment - optional except when you are entering a Journal
  • Receipt Number - optional
  • User Group Type (x2) - this field will only appear when adding 'User Group Charges' in bulk
  • Exclude these Users (x2) - this field will only appear when adding 'User Group Charges' in bulk

 
Accounts - User Group Charges
 
top

User Group Charges allow you to rapidly add charges (or credits) to all users in the selected user group.

This feature is useful, for example, when billing annual charges - $10.00 to each affiliated member and $20.00 to each non affiliated member. Or crediting the court hire account with $20.00 for each division team member as sponsorship.

For flexibility, you also have the option of selecting 2 different user groups and to decide whether to include or exclude these types of users. For example, you can bill all affiliated members who are not also committee members.

If you define a user group amount and period (1, 2, 3, 4 or 6 months or Y yearly) then any user assigned this user group will be automatically billed the amount specified here when their group expiry date is reached.

 
Change User Groups
 
top

The Change User Groups page allows you to change user group membership for all players to make end of year rollover much easier. You can also clear the expiry date and comment when making the user group change.

Optionally you can delete the selected user group from all users.

You can also change the court hire rates (both single and multi court rates) from this page also. To leave the hire rates unchanged, simply leave the sport selection blank.

 
Accounts - Zero Acocunt Balances
 
top

The Zero Account Balances feature allows you to easily reset all player balances for the selected account type to zero. You may wish to do this at the start of each financial year for example. Normally this feature would be used by facilities who have transferred user and account information from another software package are are wanting to start the new accounts from a zero balance.

 
Account History
 
top

The account history page show a list of all financial transactions for the selected user for the date period entered.

account-history1.png

If you have been allocated 'Accounts' security level you can click on the transaction date which will allow you to edit the transaction.

account-history2.png

Deleting Receipts

Depending on the site_config settings you can use one of two ways to delete a receipt record:

  • Delete method. The original receipt record is permanently deleted, this step cannot be undone. The Audit Log will show that the deletion has occurred.
  • Journal method. The original receipt record is left unchanged and a journal record for the negative amount is added to cancel out the original amount.

 
Device Setup
 
top

device-setup1.png

Devices are microcontroller units which form the interface between the server computer and the real world.

The following types of devices are currently supported by OpenSportz:

  • 0. Court lighting controller where each court has its own separate lights.
  • 1. Door controller, reads prox cards and locks/unlocks the door.
  • 2. Desk/Kiosk controller, reads prox cards to allow players to make bookings.
  • 3. Message controller, displays information on the LCD message monitors.
  • 4. Court lighting controller where each court shares lights with the next court (e.g. court 1 needs court 1 and 2 lights, court 2 needs 2 and 3, etc).

Device Setup

  • Description. This is the name of the control unit, e.g. Tennis Lights or Front Door.
  • Device Hardware Index: this is the 4th digit of the controller IP address. For serially connected (RS232) control units (e.g. the Kiosk or Desktop card readers) the Device Hardware Index is always 255.
  • Device Type. Select the type of control unit from the drop down list, e.g. lights, door, etc
  • Default Access Allowed Time (Door Controllers only). Assigning a time category here means all enabled cards will be allowed access during this time (e.g. main entry door). If you do not select a time category then by default no cards will have access and you must allocate access to individual players from the user details page (e.g. bar or office door).
  • Sport (Lighting Controller Only). Select the sport for this lighting controll er from the drop down list.
  • Start Court No (Lighting Controller Only). The starting court number for this lighting controller, e.g. 1 or 9.
  • End Court No (Lighting Controller Only). The ending court number for this lighting controller, e.g. 8 or 18.
  • Non Court Lights (Lighting Controller Only). If you are controlling non-court-lights from this controller enter the output number here, normally it is the 'ending court number' + 1.
  • Door Open for Bookings (Door Controller only). Tick this box if you want this door to be unlocked automatically for a court booking if the booking has this option enabled.

Card Reader LED and Beeper. The card reader has a 2 colour LED and beeper used to indicate the status of the device. For door access card readers, the card reader is connected to the micro-controller unit which in turn is connected to the server over the ethernet network. For kiosk card readers, the card reader is connected to the micro-controller unit which is connected to the Kiosk PC via an RS-232 serial cable. The card reader and the micro-controller unit in combination form what is called a 'device' in OpenSportz.

  • Card Reader LED
  • No LED showing: The device has no power or is faulty.
  • LED not flashing: The micro-controller is not functioning or card reader is faulty.
  • LED flashing mostly Red: The micro-controller is functioning but cannot communicate with the server.
  • LED flashing mostly Green: Normal state, the micro-controller is functioning and can communicate with the server.
  • Card Reader Beeper
  • Single short beep: Your card has been read, if your card is valid there will be a second short beep when the server authorises your operation, either door access or court booking.
  • Single long beep: Your card was denied or the micro-controller cannot communicate with the server.
  • Multiple short beeps: There was a data error reading your card, please try again.

Modtronix SBC65EC Configuration

  • For new SBD65EC boards from Modtronix the default IP address is 10.1.0.1 with a username/password of admin/pw
  • Update the SBC65EC Firmware and web pages by using the Modtronix Network Bootloader (v1.06 or later) available from Modtronix.
  • The default OpenSportz IP Address is 192.168.1.150 with a username/password of admin/passw0rd
  • Network Settings: configure these via your browser
    • Set the IP address for this device (e.g. 192.168.1.152)
    • Set the Gateway IP address to match your network (e.g. 192.168.1.1)
    • Set the MAC address 6th byte = IP address 4th byte (e.g. 0 4 163 0 0 152)
    • Set the OpenSportz server IP address (e.g. 192.168.1.1)
  • Power cycle the SBC65EC board after changing the network settings.

 
Device Firmware Upgrade
 
top

Upgrading the device firmware is done using the Modtronix Netloader software which is written in Java so it can run on Windows or Linux.

The following steps are required when upgrading the device firmware:

  • Start the Netloader software and choose the new firmware HEX file by clicking the Browse button
    modtronix1.png
    You should also enter the current IP address of the device and ensure the 'Reset Target Before Connecting' is ticked. Normally 'Update EEPROM Configuration Data' is also ticked - but note that this will reset the device IP address to 192.168.1.150 - so you then need to set this back to the correct address using your web browser as shown below.
  • Clicking the 'Connect' button will pop up the username/password window
    modtronix2.png
    The username and password is included with your installation documentation but is not included here for security reasons.
  • If the device is connected to the network it will respond to the Netloader software and initiate its bootloader software
    modtronix3.png
    Once the device is running its bootloader software it cannot communicate with OpenSportz until it has been reprogrammed and reset.
  • Clicking the 'Upgrade Firmware' button will initiate the programming process which includes erasing the current software version.
    modtronix4.png
    This concludes the reprogramming process and you can exit the Netloader software. At this time the device will have the default IP address of 192.168.1.150 so OpenSportz will not know what to do with the device until you change its IP address back to the correct value.
  • Use your web browser to connect to the device by entering its IP address into the browsers 'Location Bar' - the device will request a username and password for security reasons.
    modtronix5.png
    The username and password is the same as was used above with the Netloader software.
  • The device 'home page' will describe the firmware version number (e.g. 1.09) and build type (e.g. Door Access Controller or Lighting Controller). Confirm here that you have reprogrammed the device with the correct software build type.
    modtronix6.png
  • Click the 'Network Settings' link on the LHS menu to display the default network settings.
    modtronix7.png
  • Change the network settings for IP address, gateway address and last digit of the MAC address as shown. Ensure you use the correct 4th digit of the IP address. Click the 'Submit' button to write the changes to the devices EEPROM.
    modtronix8.png
  • Finally, move to the 'System Settings' page and click the 'Reset Board' button. The device will now reconnect with OpenSportz with the correct IP address.
    modtronix9.png
  • The firmware upgrade process is now complete.

 
Audit Log
 
top

The Audit Log records a summary of all database transactions made by all users of the system, including changes to user details, bookings and financial transactions.

If something appears to be incorrect with any aspect of a users information you can review the history of all changes, this will show when the change was made and who made it.

 
Court Usage Report
 
top

court-usage-report1.png

The Court Usage report provides details of how your courts are being used, from both a time of day and day of week perspective.

You can also get a list of bookings which were cancelled by the system for one of the following reasons:

  • Timeout waiting for card: The player did not turn up for the booking.
  • Sport disabled: The sport is disabled for this player.
  • No money for play: The player did not have sufficient money to pay for the booking.
  • System error: The booking had ended before the lights were turned on.
This allows you to monitor for abuse of the bookings system, e.g. players booking courts and not turning up to play.

Usage details by court time and revenue are displayed for any selected date period.

 
Door Access Report
 
top

door-access-report1.png

The Door Access report provides details of when access controlled doors were opened and by who.

If a controlled door is opened without a card, e.g. by forced entry, this will also be recorded.

 
Financial Report
 
top

The following financial reports are available:

 
Transaction Report
 
top

transaction-report1.png

The Transaction report shows all financial transactions for the selected date period, for all transaction types or for only the select transaction type (for example cash receipts only).

By clicking the transaction date hyperlink you can view and change the details of any individual transaction - if you have the 'Accounts' or 'Admin' security access level.

You can print the report or export it to a CSV file.

 
Trial Balance Report
 
top

trial-balance-report1.png

The Trial Balance report displays a list of members/players with their account balance as at the selected date and the balance at the end of the previous two months.

By default all players are displayed even if they have a zero balance. If you check Show Debtors Only then only players owing money will be displayed. If you check Show Creditors Only then only players with a credit balance will be displayed.

You can print the report or export it to a CSV file.

 
Incorrect Balance Report
 
top

incorrect-balance-report1.png

The Incorrect Balance report checks all account balances to ensure the sum of the individual transaction in the database matches the balance record held in a separate table in the database. These 2 totals can be different if database corruption has occurred due to, for example, a power cut damaging the database or as a result of a software bug.

You can manually correct any incorrect balances shown in the report from the selected members Account History page, and clicking the "Fix the Balance Record" button.

You can print the report or export it to a CSV file.

 
Invoicing
 
top

invoice1.png

Invoicing allows you to display or print a GST Tax Invoice for any player for the selected date period.

You can create invoices for any individual player simply by selecting their name and the date period. Alternatively you can email invoices in bulk.

Bulk invoices are an easy way to bulk bill all players/groups operating a debit account simply by selecting the account type and date period. Once the list of accounts owing money is displayed on screen you can exclude individual accounts by clicking 'Process Invoice' link. A copy of each emailed invoice can be sent to your accounts email address if required.

You can also print or display your clubs logo at the top right of the invoice, simply define the image file name in the site_config.php file.

 
Door Control
 
top

The Door Control page allows you to manually lock or unlock any of the access controlled doors on the system.

If a door has been manually unlocked and the automatic door lock time is reached the door will be locked for security reasons.

For ease of entry there is also an 'Unlock Door for 5 Seconds' button to make it easy to let someone in while keeping the facility secure.

 
Lights On / Off
 
top

The Lights On / Off page allows you to quickly turn court lights on or off without having to make a booking first. Before turning the lights on you must first select the user account to be charged the court hire.

 
Import Data
 
top

The Import Data feature allows you to import user details in bulk from a text file. The field data in the text file must be TAB or comma delimited and data may (or may not) be quoted. If required, some lines in the text file can be commented out (by starting the line with '#' or '//'), for example, the first line may contain column titles and not actual data.

The following data fields can be imported for each user:

  • Surname (or Business Name) - max 50 characters
  • Firstname - max 25 characters
  • Middlename - max 25 characters
  • Contact (for business records) - max 25 characters
  • Address Line 1 - max 30 characters
  • Address Line 2 - max 30 characters
  • Address Line 3 - max 30 characters
  • Address Line 4 - max 30 characters
  • Work Phone - max 60 characters
  • Home Phone - max 60 characters
  • Mobile Phone - max 60 characters
  • Email - max 60 characters
  • Current Balance - journal created with the comment 'Opening balance from data import'
  • Card Number (must be 5 digits)
  • Membership1, Membership2, Membership3, Membership4 - up to 4 user groups
  • Enabled - Internet bookings and cards should be enabled 'Y' or not 'N'
  • Notes - multiple import fields can be combined into the general notes fields
  • Occupation - max 50 characters
  • DOB - Date of Birth in dd/mm/yyyy format
  • Gender - M, F or blank
  • Grade - Max of 10 characters
  • Code - National player code, max of 10 characters
  • GradePoints - National or club grading points
  • PointsDate - Date of the last grading points update
  • AgeGroup - 1 character field, J, M, etc
  • IgnoreThisField - Multiple import fields can be ignored

The import is done in 2 steps, first the text file is uploaded to the server and the data is checked and displayed on the screen for checking. If the data format appears to be correct you then click the 'Import Data' button to add the records to the database. If there is something wrong with the displayed data you should corrcet the original data in the text file and repeat the upload/checking step - otherwise you may have a lot of user records to correct manually.

 
System Status
 
top

The System Status page allows access to various information about the current operation of your OpenSportz server.

The following information is currently provided:

 
Server Status
 
top

The Server Status page shows various details about the current performance of your OpenSportz server.

The following information is currently provided:

  • OS Information (OS version, load average and uptime)
  • Memory Information
  • Disk Information
  • RAID Information
  • CPU Information

The most important parameters from the above information are as follows:

  • Load average: This is a measure of how busy ths server is and except for short periods the load average should be less than the number of CPU's in your server. For example, if you have a dual core CPU the load average should be less than 2.0. Higher numbers > 4 are ok as long as they reduce after a few minutes.
  • Memory Swap Free: This is a measure of how much swap memory is in use and the SwapFree value should generally be very close to the SwapTotal value - indicating that minimal or no swap is being used. If large amounts of swap are being used your server may run very slowly and may also indicate a process has a memory leak.
  • Disk Usage: This is a measure of how much disk/partition space has been used and if greater than 90% you should investigate if there are unwanted files which can be deleted. An exception to this are the disks/partitions which are used to store the ZoneMinder video files. This partition will normally grow to > 90% in use and will hover about this value as old video files are deleted automatically by ZoneMinder and new recordings are saved.
  • RAID Status: The recommended server RAID setting is RAID1 or Mirrored drives so the status should say active raid1 and each md raid disk should display [UU] indicating both disks are functioning correctly. If you see [_U] or [U_] one of your disks has failed or has major problems.

In addition to the above information there are 2 important log files containing important information:

  • system log: /var/log/messages
  • apache web server log: /var/log/apache/error_log
To view the information in these files you must be at the command shell and be logged on as the 'root' user.

 
OpenSportz Status
 
top

The OpenSportz Status page shows the latest log file produced by the osz-ethernet.php script which interfaces to the door access controllers and lighting controller.

The following message types are sent between the server and control units:

  • $SUP - Startup: The control unit has just connected to the server.
  • $SDN - Shutdown: The control unit is shutting down and about to disconnect from the server.
  • $SET - Setup: The server advises the control units of various settings. The following setup message can be sent:
    • 1: Door controller. Access allowed green LED timer in 100msec units, default = 40 (for 4 seconds).
    • 2: Door Controller. Access open/unlocked timer in 100msec units, default = 50 (for 5 seconds).
    • 3: Door Controller. Sound the door open alarm (=1) or not (=0), default = 1.
    • 4: Lighing Controller. Use shared lighint (=1) or individual lighting (=0), default = 0.
  • $DST - Door State: The door state (open/closed/locked/unlocked) has changed.
  • $DSW - Door Swipe: A card has been read at the door card reader, the servers sends a $DSW in reply.
  • $LON - Lights On: The server is turning on court lights.
  • $SOF - Lights Off: The server is turning off court lights.
  • $PNG - Ping: A ping sent in both directions every 15 seconds, only logged if LoggingLevel=0.
  • $COI - Coin Deposit: A coin deposit message if one is installed.
  • $SWP - Kiosk Card Read: A card number being read on the kiosk card reader. Note that the $SWP message will only appear in the osz-serial.php.log file on the Kiosk PC.

For all messages, the first parameter is the control unit device index (or 4th digit of the device's IP address).

A 2 byte checksum is included in each message to detect any data errors - this appears after the '*' character at the end of the message. Here is an example of a typical message: $SET,152,01,040*6D.

 
Kiosk Information
 
top

This text can be viewed on the bookings kiosk by touching/clicking the "Information" button on the left hand side menu. The first line of each information category will be displayed on the main 'Information' display as a title so the user can see which page of information they want to view more of.

When entering the information text from the 'Database' setup menu you should not include 'Tab' characters as these will be replaced by a single space for formatting reasons when the information is saved.

There are 4 categories of general information available, such as committee contact details, shop opening hours, etc. Each of the 4 categories of information can be one or more pages in length, the user can touch the 'Scroll Up' or 'Scroll Down' buttons on the kiosk to view the entire document.

The Contact List is also available on the kiosk but will only be displayed after the user has swiped their card.

 
User Groups
 
top

user-groups1.png

User groups are a way of arbitrarily grouping your users for reporting or billing purposes.

For example, if you create a user group of 'J - Junior Members', you can then automatically display or print a report of all users assigned to this group.

Each user group record allows you to record an expiry date and a comment, at least one of these fields must be entered. You can also add the user group amount and billing frequency (1, 2, 3, 4 or 6 months or Y for yearly).

To delete a user group record from an individual user, click the 'Del' checkbox, then save the record.

 
User Groups Report
 
top

user-groups-report1.png

The User Groups Report allows you to display or print information on the makeup of your member/player types. You can generate a report listing individual players or just the total number of players in selected user groups.

You can also choose to print or download an email address list for all users or a particular muser group. You can then import this list (name and email address in text CSV format) into the email program of your choice to make emailing your users easier.

You can use the user groups report to check for players who are missing a user group expiry date by checking the appropriate box. The will help to ensure players are not missed when using the automatic user group billing features of OpenSportz.

 
User Details Report
 
top

user-details-report1.png

The User Details Report allows you to display or print information on your users such as name, address, card number and email address.

You can also choose to print or export the list in CSV format.

 
Contact List
 
top

The Contact List allows players to choose that some, none or all of their contact details are visible to other club players either at the club on the bookings kiosk, or over the internet (after the user has logged on). This should make it easier for players to arrange matches between themselves.

Also included on the contact list is each players grade, code and grading points value.

 
Card Details
 
top

Each sport allows individual control of the folloing lighting/booking parameters for each player:

Enabled: This checkbox enables or disables lighting and bookings for this sport.

Debt Limit: This allows the card to operate as a credit card (e.g. for club and coaches set it to $500.00) or a debit card (for individual players set it to $0.00).

Multi Courts: Check this to allow this card to book multiple courts at the same time, normally this is only allocated to clubs or coaches, not individual players.

Book All Courts: Check this to force this user to always book all courts, i.e. the entire hall or facility. This option would be used, for example, to lease out your Badminton stadium for the Trampoline club who use the entire facility.

Manager Card: This feature allows this card to turn on or off other players lights and cancel bookings.

Special Card Types is a feature which allows these cards to have automatic actions or triggers applied. The following Special Card Types are available.

  • C. Casual Card (or Prepaid Card): This type of card is automatically disabled (both lighting and door access) when its balance reduces to zero (or less than $0.50). This is useful for pre-paid cards available to non 'members' who collect and pay the preset amount (say $20 for 2 hours play) from a local shop. When they have used their time the card will no longer work therefore keeping your facility secure. The card would then be returned to your club for re-activation.
  • T. Tennis Entry Card (or Entry Card): This type of card is automatically disabled after door access has been granted, optionally after an additional period of a number of hours (set by SPECIAL_CARD_TYPE_T_HOURS in the site_config.php file). This is usefull for tennis clubs, where bookings and lights are often not used, to provide a casual pre paid card.

Default No. of Periods: If your standard court periods are 30 minutes, setting this to 1 means the default court booking will be 30 minutes, 2 means 60 minutes, etc.

Auto Lights On for Bookings: This means that once the court is booked the lights will automatically turn on regardless of whether the player turns up to play. Normally used for club or event cards.

Charge Category: Sets how much this player is charged for booking a court.

Playing Times: Sets when this player may book a court.

Two Cards Reqired: If checked this player can book a court with their own card but cannot turn the lights on without a second card or choosing the visitor or practice option.

Visitor Count: How many visitor sessions are available to this player.

Practice Count: How many practice sessions are available to this player.

Visitor Charge: How much extra is charged when a visitor session is used, on top of half the normal court hire charge, in $ per hour.

Practice Charge: How much extra is charged when a practice session is used, on top of half the normal court hire charge, in $ per hour.

Door Open for Bookings: This option allows the door to be automatically unlocked for the duration of the booking. The following option are available:

  • Disabled: The door will not unlock for the booking, each user must use their card for access.
  • Unlock 10, 20 or 30: The door is automatically unlocked 10/20/30 minutes before the booking start time.
  • Unlock after first swipe: The door will remain unlocked after any user uses their card to unlock the door (optionally this requires the booking owner to swipe, see site_config.php). The user must unlock the door up to 30 minutes before or any time during the booking.

 
Door Access Info
 
top

Each access controlled door has a default valid time category assigned when the control unit configured from the Device Setup page. This specifies either the default access allowed period (e.g. 'Hall Open Time'), or you can choose that access is disabled by default.

If access is allowed by default then all users with a valid card will be able to gain access during the default access allowed period. You can alter the access for individual users if required from the user details page.

If access is disabled by default then no users can gain access until their individual door access is configured from their user details page.

The user details page allows door access to be configured on an individual user basis, either by simply selecting the desired valid time category or choose 'Access Not Permitted' to disable access. Optionally you can grant access only for a specified date/time period. This may be useful for a bar duty roster, for example.

 
Bank Statement Import
 
top

This feature allows you to import a bank statement in text CSV format into OpenSportz and process all the credits against each players court hire account. The last number in the comment field of the bank statement is expected to be the players card number - when making the direct credit the player must put their cadr number in the Reference field.

A 'CSV' file is a text file with Comma Separated Values.

 
Backup
 
top

Database Backups can be performed from a command shell on the server with the following command:
> mysqldump -u opensportz_user_name -p opensportz_db_name > /some/path/and/filename.sql

The opensportz_user_name and opensportz_db_name information is in the file /srv/www/htdocs/opensportz/site_config.php which was setup during the OpenSportz installation.

The above command should be run periodically (e.g. every day by cron) to take a backup of your data. This can be done by setting up a cron job running as the superuser 'root' as shown below.

> sudo crontab -e
MAILTO=some_email_address
PATH=/usr/bin:/bin:/usr/local/bin
9 16 * * * /usr/local/bin/opensportz-backup.sh

The above crontab file will execute the named script at 4:09pm every day. The following shows an example of the backup script using the mysqldump command shown above.

>sudo vi /usr/local/bin/opensportz-backup.sh
#!/bin/bash
mysqldump -u opensportz_user_name -p opensportz_db_name > /var/tmp/opensportz-backup.sql