shiftly 0.0.1 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f70fb53ea3961e1c36ec36286a2ce803c28dd493
4
- data.tar.gz: b4ae7a2fcedfea5eefb2e2b65f8fb29c023f8764
3
+ metadata.gz: 69bba3c12f3134fd781d150495e5676de21e992f
4
+ data.tar.gz: 1e25adb9b0b968faaefde24416feaf04d7a5b2a3
5
5
  SHA512:
6
- metadata.gz: 1d86a1bb96feebb5abe66573ce031467d742e19a8fe2bcdfde581611ebf6ddc62325ac49ea9769eba2558248e2cd8110591574a51f0ee91c5f554b055bc6d9e9
7
- data.tar.gz: b9a284cb5e4981e57c5e38c596dad061192f1db3c45ff917b900fad292887005dbe17b0d821d52a59d4b1fa5d0ac3d3791526cca595f7bf92c4bce60d1788e5d
6
+ metadata.gz: c2a103b68aa547c25e605408538c927fa8ec5d97f2992a1ee4bccbc843d37d0e925dbae8e76a97cfd891087ee431f3cc923a7e64237f3056af7db21ac73a25ca
7
+ data.tar.gz: d94be01731188a4bb2ab432dd4425faa1a6ac76cbe58026509de232139d411489301b73c75dd03fedf5cb800140040a81f6021be81cc7cb833cbfd2df5456029
@@ -1,4 +1,4 @@
1
- Copyright 2014 YOURNAME
1
+ Copyright 2014 http://rubylogic.eu
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
@@ -1,3 +1,5 @@
1
+ require 'business_time'
2
+
1
3
  Time.class_eval do
2
4
 
3
5
  def shift
@@ -21,6 +23,6 @@ Time.class_eval do
21
23
  end
22
24
 
23
25
  def to_factory_date
24
- self.hour < 6 ? self.to_date - 1.day : self.to_date
26
+ self.hour < 6 ? 1.business_day.before(self.to_date) : self.to_date
25
27
  end
26
28
  end
@@ -1,3 +1,3 @@
1
1
  module Shiftly
2
- VERSION = "0.0.1"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,31 +1,31 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shiftly
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alek Niemczyk
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-27 00:00:00.000000000 Z
11
+ date: 2014-12-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: rails
14
+ name: business_time
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '4.1'
19
+ version: '0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '4.1'
26
+ version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
- name: rspec-rails
28
+ name: rails
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - ">="
@@ -52,6 +52,20 @@ dependencies:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rspec-rails
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
55
69
  description: Factory shift methods collection
56
70
  email:
57
71
  - alek@rubylogic.pl