GithubHelp home page GithubHelp logo

dave0 / leaguerunner Goto Github PK

View Code? Open in Web Editor NEW
15.0 15.0 5.0 3.09 MB

Leaguerunner is a web-based application for managing scheduling, score submission and standings for an Ultimate Frisbee league.

License: GNU General Public License v2.0

JavaScript 3.86% Perl 17.19% PHP 78.95%

leaguerunner's People

Contributors

anguscarr avatar dave0 avatar dcardamo avatar g-regl avatar h07r0d avatar mackking avatar thekrush avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

leaguerunner's Issues

use sunset time instead of "dark" for game end times

Originally filed by dave0000 on 2007-05-09T17:55:16

PHP has date_sunset(), which will give the sunset time for a given date,
latitude and longitude. We should use to show a timecap when displaying
summer games with no end date.

Something like:

$zenith = 96; // Civil twilight
$end_timestamp = date_sunset( time(), SUNFUNCS_RET_TIMESTAMP, $lat,
$long , $timezone, $zenith);
// End 10 minutes (600 seconds) before sunset
$end_timestamp -= 600;

$this->game_end = strftime('%H:%M', $end_timestamp);

should work, though it won't guarantee a consistent end time for all games
on a given week -- Monday could be a minute or so earlier or later than
Friday. To guarantee this, we could just use Monday's date for calculating
all end times.

At a minimum, we'd want config options for:

  • local latitude/longitude to use for calculating time
  • local timezone offset from GMT

Possible further enhancements if we want to be fancy:

  • make this a config option "Autogenerate timecaps using sunset"
  • configurable number of minutes before civil twilight rather than 10

spirit summary page should be sorted better

Originally filed by dave0000 on 2007-01-20T21:33:11

It was suggested that the spirit summary page is not well sorted. A
suggestion of sorting it by date was made. I'm not entirely sure what, if
anything, should be changed on this page, but someone should investigate it
and see if an improvement can be made.

need 'delete week' functionality

Originally filed by tonysa13 on 2007-05-23T03:01:56

Currently, games sets are created, and individual games can be deleted, but
not the entire game set. On the schedule page, there's an "edit week"
feature... beside "edit week" it would be nice to have a "delete week"
which would delete all games in that gameset (ie: all games for that league
on that day), unless any of the games have results.

Need better ranking system for round-robin leagues

Originally filed by dave0000 on 2007-01-20T13:56:06

Round-robin team standings ranking is filled with nasty edge cases and
impossible-to-fix conditions at present because teams are compared using a
sort function that can't resolve three-way ties. This should be fixed by
writing new standings code that avoids the need to force our comparisons
into something that works with PHP's sort callbacks.

Store historical standings information

Originally filed by dave0000 on 2007-01-20T21:36:21

"It would be fun and informative to freeze the pyramid once per week and be
able to scan through the snapshots to see how teams have moved"

This enhancement could be interesting... to keep track of where teams are
in the ladder week-by-week. Some investigation required.

Tie registration to team maintenance

Originally filed by trawna.com on 2007-02-03T01:44:22

Once we have enhanced the event prerequisite definitions, we can use the
same structure to (optionally) control operations like players being added
to rosters, so that they can't happen until the appropriate registration
(and payment) has been completed.

Choice of "Least Preferred" region

Originally filed by tonysa13 on 2007-03-16T04:02:26

We already have the choice of preferred region, we should add the choice
of Least Preferred region.

Then, the scheduler needs to take that into account and try to
accommodate (no guarantees).

Implement change date

Originally filed by tonysa13 on 2007-08-29T14:42:47

Currently, there is 'edit week' functionality. We need to add 'delete
week' and 'change date'. Delete week is self explanatory.

Change date means that they want to keep all matchups and field allocations
(if possible), but they want the date for the games changed. This is a
little harder due to game slots, but we should be able to keep the matchups
and make a best-effort at keeping the field allocations.

Better multi-season support

Originally filed by dave0000 on 2007-01-20T13:58:53

Right now, Leaguerunner can support multiple seasons simultaneously as long
as those seasons are different (ie: no two seasons named "Summer"). This
should be fixed to permit historical data to be retained in Leaguerunner
for multiple years (ie: "Summer 2005, Summer 2004, etc).

This will likely require a major change in the way Leaguerunner handles
teams, as right now a team cannot be listed in multiple seasons. Perhaps we
can allow teams to exist in multiple seasons as long as they aren't
concurrent. This presents other issues, such as knowing who is a current
player on that team and who was a player in the previous season, so we'll
need multi-roster support as well.

Require answer to roster invitations before proceeding

Originally filed by trawna.com on 2007-02-03T01:52:00

We want the option to be able to force users to accept or decline roster
invitations before they can do anything else in the system, just like with
incomplete user records or unsigned waivers. This will be configurable,
and likely not enabled during busy roster-building times when players may
have multiple invitations they are considering.

Field ratings information

Originally filed by dave0000 on 2007-01-20T21:34:51

It would be nice to allow captains to enter field ratings after their
games. There is already a field rating field, but it needs to be updated by
an administrator.

Ideally, captains could enter their thoughts on the quality of the field,
and an average captain rating could be shown...

This may require some more investigation.

Publish schedule feature

Originally filed by tonysa13 on 2007-08-29T14:40:27

When a schedule is generated, coordinators often tweak field assignments,
opponents, etc. Therefore, a newly created schedule should start in a
'not-published' state, and be visible only to coordinators. Then, the
coordinator can change it's state to 'published' after he/she is done
tweaking. At that point, everyone can see it.

change the "rating points transfer statement"

Originally filed by dave0000 on 2007-01-20T21:33:45

People are confused by the ratings point transfer statement. It was
suggested to me that it be changed to something like:

"Team A loses 3 ratings pts. Team B gains 3 ratings pts"

player statistics page demographic breakdowns

Originally filed by dave0000 on 2007-01-20T21:35:36

On the "player statistics" page it would be nice to have all the
demographic breakdowns by "active player" (either as a separate option or
as a replacement of the current view)

Improve event prerequisite definition

Originally filed by trawna.com on 2007-02-03T01:37:56

The first version of registration uses only event IDs for prerequisites and
antirequisites. We need more flexible options, such as checking age (for
junior events), paid-up membership status, etc. Also, the first version
has no UI for maintaining the prerequisites, relying on manual database entry.

Implement automatic email notifications

Originally filed by dave0000 on 2007-01-20T14:00:30

Leaguerunner needs more automatic email notifications. Right now, only
password changes are sent via email. We should implement:

* score-submission reminders to notify captains of missing scores
* watchdog reminders to notify coordinators of abnormal conditions (ie:

defaulted games, unplayed games on nights with no official cancellation,
low spirit, etc)
* notification to captains when players request to join a team
* notification to players when captains request or accept them

To implement this, we will need a much, much better way of sending email,
as the existing PHP functionality is inadequate, and we don't really want
to be sending mail from within the web code anyway.

add new field regions

Originally filed by dave0000 on 2007-01-20T21:32:35

Glenda asked for new field regions: South/East, South/West, and Gatineau

SOTG system improvements

Originally filed by dave0000 on 2007-01-20T21:38:48

  • ask the SOTG questions then present the SOTG number which the captain
    could change before submitting the score.
  • each question could have a wider range of answers
  • drop the highest and lowest SOTG from the average SOTG calculation
  • investigate different ways to present SOTG (numeric or Xs & checks)

"playoff" game type, "exhibition" game type

Originally filed by tonysa13 on 2007-08-29T14:44:24

It should be possible to mark games as 'playoff' games or as 'exhibition'
games. The results of those games should NOT affect the ratings or standings.

Improve LR / Drupal user auth bridge

Originally filed by dave0000 on 2007-01-20T21:31:22

I have recently discovered an issue with the LR / Drupal authentication
bridge stuff. It stems from the fact that in LR we require a unique
username where as Drupal requires a unique 'name' (the equivalent of the
First Name + Last Name from LR).

A number of people have run into problems whereby they are able to login to
LR but cannot login to the main site to access the Forum.

We need to divise a mechanism / modify the existing one to detect full name
clashes and resolve them (like by appending (2) to the end of the 2nd 'Bob
Smith' to register).

OCUA request relating to volunteer information

Originally filed by tonysa13 on 2007-03-15T17:22:30

OCUA would like the player information section to include more volunteer
information gathering as per the attached document.

This would be specifically to collect information at the beginning of the
season when accounts are reset and people must re-activate their accounts.

Add edit functionality to FormBuilder

Originally filed by trawna.com on 2007-02-03T01:34:02

The registration code uses FormBuilder for asking the user their
preferences re the event they are registering for. Currently, FormBuilder
reads the form data from the database, but cannot edit or write it, meaning
that events must be set up by manually inserting database records, which is
tedious and error-prone.

Submitter information is lost when game is finalized

Originally filed by dave0000 on 2007-01-20T21:32:06

Please use labels and text to provide additional information.
When a game gets finalized, there's no way to tell who entered the game
results.

Before it's finalized, if one team has entered a result, you can see that
user BLAH entered a score of BLAH. But, once the other team enters a
matching result, or the game is finalized in any other manner, the
information about who entered the results is lost.

We should at least store the username of who entered the results, and maybe
even the date/time of entry. Coordinators can make use of this information.

/home not found - new install

Originally filed by angus.carr on 2007-06-14T21:10:04

What steps will reproduce the problem?

  1. Install according to the README
  2. Change leaguerunner.conf to refer to localhost, at the root directory
  3. Go to http://localhost
  4. When presented with login page, enter admin/admin, according to README
  5. It returns a page referring to /home, which doesn't exist.

What is the expected output? What do you see instead?
Reference to the URL /home, which gets a 404 Not Found

What version of the product are you using? On what operating system?
Release 2.2, and tested with svn of June 13/2007.
Tested on XAMPP 1.6 on Windows, and on Ubuntu Feisty.

Please provide any additional information below.

Home Field specification

Originally filed by tonysa13 on 2007-03-16T00:45:21

It would be nice if a team could be given a home field whereby the
scheduler would assign this team it's home field for all home games. The
home field would only be editable by a coordinator.

OCUA related use-cases:

  • a team "wins" their choice of a home field
  • a team finds a new field for OCUA to use, and is therefore rewarded with
    that field as their home field
  • a team wishes to pay more team fees for a particular home field

zero ratings points transferred for a defaulted game

Originally filed by tonysa13 on 2007-06-15T02:04:54

Consider having some ratings points transferred for a defaulted game.
Not sure how many the some should be... maybe make it equivalent to a 6-
0 regular win?

Scenario is this: two teams are close in the standings, they each have a
game scheduled, but not against each other. Team A's opponent is going to
have to default the game due to missing players, etc. Team B happens to
be playing a relatively easier opponent, and is expected to win, thus they
will gain ratings points. Since Team A didn't play and they get no points
for the default win, Team B will pass them in the standings

Another scenario: Team A is ahead of Team B by a good amount of ratings
points... Team A is in 8th, Team B is in 9th... last game of the season is
here, and Team A happens to be scheduled against the #1 team, and will
surely lose. Team B happens to be scheduled against a weaker opponent,
and will surely win. If Team A loses, and Team B wins, it's possible that
Team B will overtake Team A, and finish the season in 8th, knocking Team A
out of the Tier 1 playoffs. So, Team A decides to default the game to
prevent any ratings points from being transferred, and Team B has no
chance to catch them.

Install issues (and a spelling fix) - with patch.

Originally filed by angus.carr on 2007-06-15T22:23:54

What steps will reproduce the problem?

  1. Install according to readme
  2. Cannot get to login page - fputcsv() function fails
  3. Fix that in common.inc
  4. Carry on with logging in
  5. After loggin in, goes to /home
  6. PHP Warning issued on admin login about array_merge
  7. Panic and wave your arms in the air!

What is the expected output? What do you see instead?
I expected no failures, or warnings

What version of the product are you using? On what operating system?
svn r866, on Ubuntu 6.06LTS, with php4.

Please provide any additional information below.
There's also a spelling error fixed in this patch.

The fputcsv function error was fixed by adding a conditional around the
function (re-)definition. It's not well-indented, but that's because I
don't know what the policy is here.

The warnings were fixed by following the suggestion in the php web pages
for array_merge that we could cast them as arrays anyway, just for the sake
of it.

Implement player/team matching system

Originally filed by dave0000 on 2007-01-20T14:01:46

Leaguerunner needs a system for matching up players looking for teams and
teams looking for players. It should:

* allow players to specify they're looking for a team on one or more

specified nights and seasons, playing at a certain level or range of levels
* allow players or captains to specify permanent or substitute status
desired
* allow players or captains to set an expiry date for their request
* allow captains to specify that they want someone with a particular rating
* provide a "notes" field for players to sell themselves, or for
captains to state particular requests (ie: "Our team needs a handler/coach,
we've got too many receivers already:)
* automatically remove requests from the list when fulfilled or expired
* display "game-day" sub hunts in a special manner indicating their
urgent status (ie: replace the "teams looking for players" forum

This system should be written in a generic manner so that the "players
looking for teams" portion can also be used to sign up for hat leagues. For
an example of how NOT to do this, look at the SVN history for
source:tags/OCUA_RC_17/src/Handler/WaitingList.php One thing to note is
that since hat leagues are usually first-come-first-served or tryout-based,
the signup procedure will need to take this into account.

Playoff/tourney support needed

Originally filed by dave0000 on 2007-01-20T13:57:52

Leaguerunner doesn't support recording or scheduling playoff or tournament
games in a simple manner. Right now, the back-end code exists to allow
games to depend on each other, but it isn't used.

First step should be to allow scheduling of a simple playoff using OCUA's
traditional format (pools of four, each team guaranteed two games with the
winners of game 1 playing each other to win the pool) where coordinators
manually seed the first round of the playoff and the second round is
auto-generated.

Future enhancements might include support for auto-generation from tier
standings, and for other playoff and tournament formats

remove results function works, but resulting page is blank

Originally filed by tonysa13 on 2007-05-23T02:49:38

when you use the 'remove results' function to delete game results (but
leave the game in the schedule), it works, except that the resulting page
is blank... it should at least give a message like "results for game BLAH
have been removed"...

Unpaid registration timeouts

Originally filed by trawna.com on 2007-02-03T02:06:16

When a registration record is created, but online payment is not made,
there should be a time limit for receiving the payment, after which the
user may be bumped in favour of someone who will pay promptly. This is to
keep people from "camping out", and also to account for people who might
register for something and then forget about it.

Handle registration events with no cost

Originally filed by trawna.com on 2007-02-03T01:57:31

The current registration code assumes that there is some cost associated
with events. It also assumes that online payments will be accepted. We
need to handle the cases where there is no payment to be made, and where
only offline payments are accepted.

Feature: Automate Pyramid Ladder scheduling

Originally filed by dave0000 on 2007-01-20T14:02:24

The pyramid ladder should be automated in the future. Because it is new it
wasn't automated yet so that we can work out any problems that may be there.

It needs to take into account: - There can be more than one game per week
per league - It should expire games as soon as it is reasonable to that
recent data is used - It should be able to a configurable amount of games
per week, but not more - It should send an email to the coordinator to let
them know that it scheduled games. If it failed to come up with matches for
everyone then it should email them to let them know that.

Post-Nuke module

Originally filed by trawna.com on 2007-02-03T02:16:05

The current TUC implementation of Post-Nuke integration is not available in
CVS, because it is hackish, requires modifications to Post-Nuke code, and
has a number of functional shortcomings. These issues should all be
addressed by creating a full-blown Post-Nuke module that wraps Leaguerunner.

Multiple roster support for teams

Originally filed by dave0000 on 2007-01-20T13:59:38

In order to support having teams in multiple leagues at the same time, we
need to be able to differentiate the rosters for each league (ie: summer
roster and fall roster for a team, or the 2005 and 2004 summer rosters).

A possible solution is to allow teams to have multiple rosters. A given
roster would need to be activated for a given league at the beginning of
the season.

Some implementation details:

* implement a roster (team, rostername, roster_id, status) table to

associate rosters with teams. The 'status' field would be 'active',
'locked', or 'inactive', with inactive rosters being used for historical
purposes and locked rosters used by coordinators and admins to freeze a
roster (in advance of playoffs, for example).
* extend the teamroster table to have a roster_id field indicating
which roster that player is on.
* extend leagueteams table with a roster_id field as well, to define
which roster is active for a team in that league.

Bad stylesheet link

Originally filed by dave0000 on 2007-01-20T21:30:37

There is a link to the stylesheet which is on line 25 of
src/includes/theme.inc.

This style.css file should be moved into the svn repsitory if it isn't
already there and it should be linked to properly rather than an absolute
link to the ocua.ca website.

I copied this bug into classes/league.inc so it needs to be fixed there also.

Pyramid Ladder improvements

Originally filed by dave0000 on 2007-01-20T21:37:41

Notes from meeting way back in Oct 2006:

  • The tie-breakers we have now are not horrible but they are not great
    either. Two updates were suggested:

o Change 2nd tie-breaker to "wins & ties within rung and all rungs above"

o Change 2nd tie-breaker to "Average Rung" so that teams spending more time
in higher rungs would stay at the top of the rung.

  • This topic morphed into a fascinating discussion on movement within the
    pyramid:

o Right now a 17 - 16 win is treated the same as a 15 - 2 win.

o No consideration is given to teams from separate rungs playing one another.

o Ties are essentially treated like losses.

o Teams may either move too fast or not fast enough as a result of the
above factors

Improved Google maps integration

Originally filed by trawna.com on 2007-02-03T02:10:35

There should be a way for Google maps to be dynamically generated,
including showing field orientation. In 2006 TUC did this with hard-coded
values and a clunky JavaScript interface for maintenance. There is clearly
a better way to do it, storing the required data in the field database, but
it will also take some clever JavaScript, interfacing with the Google maps
API, to provide a user-friendly administrative interface for maintaining
this data.

Install schema Issue

Originally filed by angus.carr on 2007-09-08T07:12:58

What steps will reproduce the problem?

  1. Install according to the instructions
  2. When the schema is being created, mysql 5 returns a failure from lack of
    commas in the creation of two tables

What is the expected output? What do you see instead?
mysql failure in lines 222 and 232. Missing commas before the primary key
statement for two tables.

Please use labels and text to provide additional information.

I have a fix ready to check in, but I thought I would ask if anyone else
has had this issue.

Better end-user documentation needed

Originally filed by dave0000 on 2007-01-20T13:56:56

The end-user documentation really sucks. Docs are not up to date, and are
not friendly enough for the various levels of user (player, captain,
coordinator) to understand.

Possibly reimplement the docs via this wiki, and extract them to a static
format for inclusion with the software?

Buttons should be re-labeled

Originally filed by tonysa13 on 2007-08-29T14:36:47

People seem to get confused. For example, submitting the game results is a
3 screen operations: 1- score, 2- SOTG, 3- confirm. Many people seem to
forget to submit the confirm page, and think that the system has saved
their answers.

With that in mind, all button labels should be looked at. SUBMIT should
only be used when something is actually being saved. NEXT should be used
for something that is an intermediate step.

Better handling of bye games

Originally filed by dave0000 on 2007-02-09T20:38:08

If you have a league with an odd number of teams, scheduling one for a bye
week is a pain.

Right now, the following steps are necessary:

  1. add a 'bye' team to your league
  2. add a 'bye' field location to your league
  3. schedule as normal using one-at-a-time or round-robin generation
  4. go back and fix the fields so that the 'bye' game is on the 'bye' field

and, with this method, the bye games show up as regular games, with score
entries requested from captains, etc. This can cause problems when
captains accidentally enter a score that shouldn't be there and the
auto-finalization code takes their score and applies it. Or, with funnier
results, the problem of a player failing to read the schedule correctly
and trying to find the location of field BYE 1, or worse, showing up
somewhere at 00:01 to try and play.

One way to improve this would be to treat a bye game as special, so that
the field manipulations aren't necessary, and it doesn't show up with
start/end times and score entry links, or in the 'games played' count for
standings purposes.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.