mirror of
https://github.com/rickbarrette/stopwatch.git
synced 2026-11-17 11:50:36 -05:00
- New top-menu page listing running timers: owner, issue, project, activity, start time, time on this run and entry total, oldest first; refreshes every minute - Role permissions "View running timers" and "Stop other users' timers", checked against each timer's project; users can always stop their own - A timer can be stopped at an earlier time (when the person left): hours logged after it are taken off the entry, and the comment notes who stopped it and when - Timers now record when they were started (session_started_at); timers running from before show "unknown" until restarted - Integration tests for permissions, project scoping and stopping; unit tests for Timer#stop_for Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
71 lines
3.8 KiB
Markdown
71 lines
3.8 KiB
Markdown
# Stopwatch Plugin for Redmine [](https://github.com/jkraemer/stopwatch/actions/workflows/redmine.yml)
|
|
|
|
Minimal plugin that aims to make tracking your time with Redmine much easier.
|
|
|
|
## Features
|
|
|
|
- Adds a **Log time** menu item to the account menu (top right)
|
|
- That link leads to an overlay listing today's time entries, with a form that
|
|
allows editing existing or creating a new entry.
|
|
- Time entries can be started / stopped from the overlay as well as via their
|
|
context menu. There can only be one currently running entry, which will be
|
|
periodically updated with the time lapsed since it was started. Previously
|
|
running entry is stopped automatically when another is started.
|
|
- The hours:minutes of the currently *running* entry is highlighted in time
|
|
entry listings as well as shown next to the **Log time** menu item as well as
|
|
in the window title.
|
|
- Creating an entry with 0 minutes saves it in *running* state.
|
|
|
|

|
|
|
|
## Changes in this fork
|
|
|
|
This is a fork of [jkraemer/stopwatch](https://github.com/jkraemer/stopwatch), modified by
|
|
Rick Barrette (2026):
|
|
|
|
- **Redmine 7:** requires Redmine 7.0+. The issue context-menu Start/Stop entry now uses Redmine 7's
|
|
`view_issues_context_menu_start` hook instead of patching `ContextMenusController` (July 2026).
|
|
- **Colour-coded Start/Stop:** an optional setting ("Color-code Start/Stop") shows the issue Start
|
|
link in green and Stop in red, with tinted buttons on mobile (March 2026; colours adjusted for
|
|
readable contrast in October 2026).
|
|
- **Timer safety (October 2026):**
|
|
- *Maximum timer length* setting (default 10 hours): a forgotten timer is stopped at the limit and
|
|
its time entry's comment is flagged, instead of adding a night or weekend of hours.
|
|
- Running timers are saved every minute on the server (a background job), so issues show the time
|
|
live even with no browser open; open tabs keep saving too. Saves lock the timer, so several tabs
|
|
can't add the same time twice.
|
|
- Closing an issue stops any timer running on it first, so the logged time is final (e.g. before
|
|
billing). Deleting a time entry only stops the timer if it runs on that entry.
|
|
- Issue timers require an issue the user can see; starting twice moves the timer instead of
|
|
erroring.
|
|
- Tests run against Redmine 7.0.
|
|
- **Running timers page (October 2026):** a top-menu page listing everyone's running timers, with
|
|
owner, issue, project, activity, start time, how long it has run and the entry total, oldest first.
|
|
Two role permissions: *View running timers* and *Stop other users' timers*, applied per project.
|
|
A forgotten timer can be stopped at the time the person actually left; hours logged after that
|
|
are taken off the entry, and the entry's comment notes who stopped it.
|
|
|
|
## Installation
|
|
|
|
Add the plugin to your Redmine installation's `plugins` folder, run `bundle
|
|
install` and restart Redmine. No database migrations necessary.
|
|
|
|
|
|
## License
|
|
|
|
Copyright (C) 2020 [Jens Krämer](https://jkraemer.net)
|
|
|
|
The Stopwatch plugin for Redmine is free software: you can redistribute
|
|
it and/or modify it under the terms of the GNU General Public License as
|
|
published by the Free Software Foundation, either version 3 of the License, or
|
|
(at your option) any later version.
|
|
|
|
The Stopwatch plugin for Redmine is distributed in the hope that it
|
|
will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
|
|
Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License along with
|
|
the plugin. If not, see [www.gnu.org/licenses](https://www.gnu.org/licenses/).
|
|
|