xeroizer-float 2.15.3.10 → 2.15.3.11

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,6 +1,6 @@
1
1
  require 'rake'
2
2
  require 'rake/testtask'
3
- #require 'rake/rdoctask'
3
+ require 'rdoc/task'
4
4
  require 'rubygems'
5
5
  require 'yard'
6
6
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.15.3.10
1
+ 2.15.3.11
@@ -10,8 +10,8 @@ module Xeroizer
10
10
  class BankTransaction < Base
11
11
 
12
12
  BANK_TRANSACTION_STATUS = {
13
- 'ACTIVE' => 'Bank transactions that are active',
14
- 'DELETED' => 'Bank transactions that are deleted',
13
+ 'ACTIVE' => 'Active bank transactions',
14
+ 'DELETED' => 'Deleted bank transactions',
15
15
  } unless defined?(BANK_TRANSACTION_STATUS)
16
16
  BANK_TRANSACTION_STATUSES = BANK_TRANSACTION_STATUS.keys.sort
17
17
 
@@ -11,6 +11,7 @@ module Xeroizer
11
11
 
12
12
  string :name
13
13
  string :tax_type
14
+ string :status
14
15
  boolean :can_apply_to_assets
15
16
  boolean :can_apply_to_equity
16
17
  boolean :can_apply_to_expenses
@@ -8,7 +8,10 @@ module Xeroizer
8
8
  include ClassLevelInheritableAttributes
9
9
  class_inheritable_attributes :api_controller_name
10
10
 
11
- class InvaidPermissionError < StandardError; end
11
+ module InvaidPermissionError; end
12
+ class InvalidPermissionError < StandardError
13
+ include InvaidPermissionError
14
+ end
12
15
  ALLOWED_PERMISSIONS = [:read, :write, :update]
13
16
  class_inheritable_attributes :permissions
14
17
 
@@ -40,7 +43,7 @@ module Xeroizer
40
43
  def set_permissions(*args)
41
44
  self.permissions = {}
42
45
  args.each do | permission |
43
- raise InvaidPermissionError.new("Permission #{permission} is invalid.") unless ALLOWED_PERMISSIONS.include?(permission)
46
+ raise InvalidPermissionError.new("Permission #{permission} is invalid.") unless ALLOWED_PERMISSIONS.include?(permission)
44
47
  self.permissions[permission] = true
45
48
  end
46
49
  end
@@ -17,7 +17,12 @@ module Xeroizer
17
17
  def parse_params(options)
18
18
  params = {}
19
19
  params[:ModifiedAfter] = options[:modified_since] if options[:modified_since]
20
- params[:OrderBy] = options[:order] if options[:order]
20
+
21
+ params[:order] = options[:order] if options[:order]
22
+ params[:reverseorder] = options[:reverseorder] if options[:reverseorder]
23
+
24
+ params[:order] = options[:order] if options[:order]
25
+ params[:reverseorder] = options[:order] if options[:reverseorder]
21
26
  if options[:where]
22
27
  params[:where] = case options[:where]
23
28
  when String then options[:where]
@@ -47,4 +47,12 @@ class RecordBaseModelTest < Test::Unit::TestCase
47
47
 
48
48
  end
49
49
 
50
+ context "InvalidPermissionError" do
51
+ should "also be catchable by the name 'InvaidPermissionError' for historical reasons" do
52
+ assert_raise(Xeroizer::Record::BaseModel::InvaidPermissionError) do
53
+ raise Xeroizer::Record::BaseModel::InvalidPermissionError
54
+ end
55
+ end
56
+ end
57
+
50
58
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xeroizer-float
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.15.3.10
4
+ version: 2.15.3.11
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2013-02-20 00:00:00.000000000 Z
13
+ date: 2013-02-21 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: builder