debitcredit 0.0.8 → 0.0.9
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a5ef2706b310724b17c5c806f1f833b3150c584d
|
4
|
+
data.tar.gz: 3151004ca530b8cdc74e52b189ccd0a17812c945
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 68ad956fde9ff67286115563e8dd576be91de77fe7361a32aac2f4549755feac7f30760f88349fae57c009869f47f178ac67892b7afbd8fde52bdfb03387a72e
|
7
|
+
data.tar.gz: be72dc033737575ac2118602123c9f0e5d483f091cd1425fe1b14767804710b4cc1eac4f907a6f4853dee3434f4c0a8fe1188f6dbd284663e4c94ad1683c11f5
|
@@ -1,10 +1,25 @@
|
|
1
|
-
class Debitcredit::Transaction::
|
1
|
+
class Debitcredit::Transaction::Dsl
|
2
2
|
attr_accessor :transaction
|
3
3
|
attr_accessor :accounts
|
4
|
+
|
4
5
|
def initialize(transaction)
|
5
6
|
@transaction = transaction
|
6
7
|
end
|
7
8
|
|
9
|
+
def kind(kind)
|
10
|
+
@transaction.kind = kind
|
11
|
+
end
|
12
|
+
|
13
|
+
def description(desc)
|
14
|
+
@transaction.description = desc
|
15
|
+
end
|
16
|
+
alias desc description
|
17
|
+
|
18
|
+
def reference(ref)
|
19
|
+
@transaction.reference = ref
|
20
|
+
end
|
21
|
+
alias ref reference
|
22
|
+
|
8
23
|
def debit(account, amount, comment = nil)
|
9
24
|
build_item true, account, amount, comment
|
10
25
|
end
|
data/lib/debitcredit/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: debitcredit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vitaly Kushner
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-04-
|
11
|
+
date: 2014-04-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|