business icon indicating copy to clipboard operation
business copied to clipboard

Ruby business day calculations

Results 13 business issues
Sort by recently updated
recently updated
newest added

Updates the requirements on [rubocop](https://github.com/rubocop/rubocop) to permit the latest version. Release notes Sourced from rubocop's releases. RuboCop 1.35 New features #9364: Add Style/MagicCommentFormat cop. (@​dvandersluis, @​mattbearman) #10776: New option (consistent)...

dependencies

The code changes in this PR resolve the problem by accurately counting business days, including those instances where an `extra_working` day occurs on a weekend.

### Set up for mac (other platforms not tested) - **Install rust** - **Ensure that your ruby installation has "enabled shared" configured** You can check this by running: `ruby -e...

I realize this would be a disruptive change, but I have to maintain my own fork with the `Business` module renamed to `BusinessDay` because my application has a class named...

In some countries, like Poland, when a public holiday occurs on a Saturday, the employer has to pick a working day which will be a holiday. Adding `extra_holidays` key will...

Updates the requirements on [rspec_junit_formatter](https://github.com/sj26/rspec_junit_formatter) to permit the latest version. Release notes Sourced from rspec_junit_formatter's releases. v0.6.0 Changed Restrict to Ruby 2.3+ Fixed Fix handling of nil durations (#100) Changelog...

dependencies

`add_business_days` and `subtract_business_days` are implemented by repeatedly applying `next_business_day` and `previous_business_day` respectively. The code is identical. This refactor makes the intent more explicit, improving readability.

Updates the requirements on [rubocop](https://github.com/rubocop/rubocop) to permit the latest version. Release notes Sourced from rubocop's releases. RuboCop 1.36 New features #10931: Add AllowOnSelfClass option to Style/CaseEquality. (@​sambostock) Bug fixes #10958:...

dependencies

Updates the requirements on [rubocop](https://github.com/rubocop/rubocop) to permit the latest version. Release notes Sourced from rubocop's releases. RuboCop 1.62.1 Bug fixes #12761: Fix a false positive for Style/HashEachMethods when the key...

dependencies

Define these instance methods of `Business::Calendar`: - `earliest_business_date_on_or_after` – alias for [`roll_forward`](https://github.com/gocardless/business/blob/936546b2ef5ee132e1e4dd7ad9a42c521afd2e43/lib/business/calendar.rb#L93) - `latest_business_date_on_or_before` – alias for [`roll_backward`](https://github.com/gocardless/business/blob/936546b2ef5ee132e1e4dd7ad9a42c521afd2e43/lib/business/calendar.rb#L101) While these names are more verbose, my team agrees that they are...