← All articles
Timesheets

Rules that stop a bad timesheet before it is submitted

A 20-hour day, an entry from three weeks ago, a week with no descriptions: project rules catch them when the time is saved, not when the manager reviews it. How to build rules that block, warn or alert, and what they cannot do.

· 6 min read · The LogTicks team

Most timesheet mistakes are small and obvious. Someone types 80 instead of 8. Someone logs last month's forgotten hours into this month. Someone fills a week with numbers and no word about what the time was for. A manager catches some of these on Monday and sends the week back, the person fixes it on Tuesday, and it is approved on Wednesday. Three days for a typo.

The cheaper place to catch a mistake is the moment it is made. Project rules in LogTicks are checks that run when time is saved and when a week is submitted. A rule can refuse the save, let it through with a warning, or tell the manager. This article builds a small, sensible set and shows what people see when one fires.

What a rule is

The four parts of a rule
ConditionHours in the day greater than 12
ActionBlock, warn, or alert the manager
Applies toAll projects, or the ones you choose
Run historyEvery firing is recorded

Rules live under Company Settings, Project Rules, and managers create them. The list shows each rule's condition, what it does, how many times it has fired and when it last did.

The Project rules page with tiles for rules enforced now, inactive rules, times fired and not enforced yet, and a table of three rules: Daily hours limit blocks, Budget alert at 80 percent alerts the manager, Weekend work warns
Three rules in the demo company. The Does column is the one to read: Blocks, Alerts manager, Warns.

What a rule can check

WhenConditionTypical use
Time is savedHours in the dayRefuse a day over 12 hours; warn over 8
Time is savedHours in the weekRefuse a week over 60 hours
Time is savedHours in one entryCatch 80 typed for 8
Time is savedDays in the pastNo entries older than 14 days
Time is savedDays in the futureNo time logged for a day that has not come
Time is savedDescription missingEvery entry says what was done
Time is savedType of dayWarn on a weekend; refuse on a holiday
Time is savedPercentage of budget or estimated hours spentAlert the manager at 80%
A week is submittedThe week's total hoursWarn under 40; refuse over 60
A week is submittedEntries without a noteNo week goes to a client blank

What a rule can do

ActionWhat happensWhat the person sees
BlockThe save is refused. Nothing changesThe rule's message, as an error
WarnThe time is savedA warning saying why it was flagged
Alert the managerThe time is savedNothing. The project's manager sees an alert on their dashboard

Step by step: start from a template

  1. Open Company Settings, Project Rules.
  2. Press Templates. There are 13, each with its condition and action shown.
  3. Pick one, for example Weekly hours limit. It opens as a new rule you can adjust.
  4. Check the Rule name. It is shown to people when the rule blocks or warns, so make it something they will understand.
  5. Adjust the condition: what to check, the comparison, and the value.
  6. Choose the action, and write a message if the standard wording is not what you want to say.
  7. Under Applies to, leave it on all projects or choose the ones it covers.
  8. Press Create rule.
The New project rule dialog opened from the Weekly hours limit template: rule name, type Validation, priority, a condition Hours in the week greater than 60, an action Block with an optional message, Applies to all projects, a Rule active switch and a note that the rule is enforced
A template opened as a new rule. The note at the bottom says whether the rule as written will be enforced.

"Not enforced yet"

The form tells you if a rule cannot be applied. A rule type or condition that LogTicks does not check is labelled "Not enforced yet" on the form and counted in its own tile on the list, so a rule never looks active when it is not.

What happens when a rule fires

Liam opens his week and types 14 into Monday for a project that already has hours on other projects that day. The daily limit rule refuses it.

The weekly timesheet with an error at the top right: Initech Data Migration on Monday 9 November was not saved. Daily hours limit: Monday 9 November would come to 20 hours, the limit is 12 hours a day. The cell shows its previous value
A blocked save. The message names the rule, the day, what the total would have been and what the limit is. The cell has gone back to 2.

Three things about this are deliberate:

  • The message is specific. It gives the total the day would have reached, not just "invalid entry".
  • Nothing was saved. A blocked entry leaves the timesheet as it was.
  • It applies everywhere time is saved. The grid, Quick entry, the timer and the API all go through the same check. A script that logs time gets the rule's message back as an error.

Back on the rules list, the rule's Fired count has gone up by one, and its run history has a line for it. If a rule fires fifty times in a week, either the team has a habit to change or the limit is wrong, and the count is how you find out.

A starter set

RuleActionWhy
Hours in the day over 12BlockAlmost always a typo
Days in the past over 14BlockKeeps closed months closed
Days in the future over 0BlockNobody has worked tomorrow yet
Hours in the day over 8WarnLegitimate, but worth a second look
Type of day is weekendWarnLegitimate, but should be deliberate
Week's total under 40 at submitWarnCatches a forgotten day
Budget spent over 80%Alert the managerTime to talk to the client

Block only what is certainly wrong. A rule that blocks legitimate work teaches people to enter false numbers that pass, which is worse than the mistake it was meant to stop.

Rules and the project's own settings

A project also has a Description required switch of its own. That one warns when time is saved without a description and again when the week is submitted. It does not block. If you want a missing description to be refused, add the Description required rule with the Block action.

  • Block only what is certainly a mistake
  • Give each rule a name a member will understand in an error message
  • Scope budget alerts to the projects that have a budget worth watching
  • Read the Fired counts after the first month and adjust
  • Tell the team before you switch on a blocking rule

What it doesn't do (yet)

  • A budget alert fires once per rule and project, when the threshold is first crossed. It does not repeat each day.
  • Weeks are Monday to Sunday. A weekly limit cannot follow a different week.
  • Some rule types are not enforced. They are labelled "Not enforced yet" on the form and the list.
  • Rules check time as it is saved. Turning a rule on does not go back and flag time that is already there.
  • The project's own "description required" warns; it does not block.
  • Alerts go to the dashboard. A rule does not send an e-mail or a chat message.

Catch the typo while the person is still looking at the cell.

Add your first rule

Open Project Rules, pick the Daily hours limit template, and try to log a 20-hour day.

Start free