stockor 0.2 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -2
- data/Gemfile.lock +40 -54
- data/client/skr/components/BankAccountFinder.cjsx +2 -1
- data/client/skr/components/CustomerFinder.cjsx +1 -1
- data/client/skr/components/CustomerProjectFinder.cjsx +2 -5
- data/client/skr/components/LocationChooser.cjsx +2 -5
- data/client/skr/components/PaymentCategoryFinder.cjsx +2 -1
- data/client/skr/components/SkuFinder.cjsx +2 -1
- data/client/skr/components/SkuLines.cjsx +14 -6
- data/client/skr/components/SystemSettings.cjsx +1 -0
- data/client/skr/components/UOMChooser.cjsx +2 -2
- data/client/skr/models/Invoice.coffee +2 -0
- data/client/skr/models/SalesOrder.coffee +2 -1
- data/client/skr/models/TimeEntry.coffee +2 -1
- data/client/skr/models/mixins/PrintSupport.coffee +1 -1
- data/client/skr/screens/customer-projects/CustomerProjects.cjsx +1 -1
- data/client/skr/screens/fresh-books-import/ChooseRecords.cjsx +1 -1
- data/client/skr/screens/invoice/Invoice.cjsx +7 -0
- data/client/skr/screens/time-invoicing/TimeInvoicing.cjsx +1 -1
- data/client/skr/screens/time-tracking/PopoverMiniControls.cjsx +2 -2
- data/lib/skr/version.rb +1 -1
- data/stockor.gemspec +1 -1
- data/templates/print/partials/skus_table.tex.erb +1 -1
- data/templates/print/partials/skus_table_invoice_footer.tex.erb +12 -2
- data/templates/print/partials/skus_table_labor_footer.tex.erb +7 -0
- data/templates/print/types/invoice/default.tex.erb +1 -1
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d988a8e0b73432c66e3dc93eeeed449da3e30ce
|
4
|
+
data.tar.gz: 832a97c69b53d53f3a108342ec92008a0baafeed
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2c4adcf6481c6825caad4f0cbd5869bc2752484e7b834f0d430804d2f4965e8c6722071a713753da4f6d1d920280128ce22206ac34f7979e76b123951c1b5df0
|
7
|
+
data.tar.gz: c29089f8b3c4c45406278d764fd2a38b654565e1379f33353624e9a705baaed0e57542c01a1980a13b92c2d009f951619afe994e1fb4a513e7218da45631a4ab
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,58 +1,10 @@
|
|
1
|
-
GIT
|
2
|
-
remote: git://github.com/argosity/lanes.git
|
3
|
-
revision: 8347b9f30227829d8c52eb100299b9e30a455e02
|
4
|
-
branch: master
|
5
|
-
specs:
|
6
|
-
lanes (0.3.0)
|
7
|
-
activejob (~> 4.2)
|
8
|
-
activerecord (~> 4.2)
|
9
|
-
bcrypt (~> 3.1)
|
10
|
-
carrierwave (~> 0.10.0)
|
11
|
-
coffee-react (~> 3.0)
|
12
|
-
coffee-script (~> 2.3)
|
13
|
-
compass-import-once (~> 1.0)
|
14
|
-
execjs (~> 2.2)
|
15
|
-
fastimage (~> 1.8.1)
|
16
|
-
fog (~> 1.37.0)
|
17
|
-
guard (~> 2.0)
|
18
|
-
guard-jasmine (~> 2.0)
|
19
|
-
guard-minitest (~> 2.3)
|
20
|
-
hashie (~> 3.3)
|
21
|
-
jasmine-core (~> 2.0)
|
22
|
-
jobba (~> 1.4)
|
23
|
-
message_bus (= 2.0.0.beta.6)
|
24
|
-
mini_magick (~> 4.3.6)
|
25
|
-
minitest-around (~> 0.2)
|
26
|
-
mocha (~> 1.1)
|
27
|
-
oj (~> 2.1)
|
28
|
-
pg (~> 0.17)
|
29
|
-
rack-protection (~> 1.5)
|
30
|
-
rack-test (~> 0.6)
|
31
|
-
rake (~> 10.0)
|
32
|
-
require_all (~> 1.3)
|
33
|
-
resque (~> 1.25)
|
34
|
-
sanitize (~> 3.0)
|
35
|
-
sass (~> 3.4)
|
36
|
-
sinatra (~> 1.4)
|
37
|
-
sprockets (~> 3.0)
|
38
|
-
sprockets-helpers (~> 1.2)
|
39
|
-
thor (~> 0.19)
|
40
|
-
uglifier (~> 2.7)
|
41
|
-
|
42
|
-
GIT
|
43
|
-
remote: git://github.com/nathanstitt/erb_latex.git
|
44
|
-
revision: 6d16aea21c99710be94445b610e3ba03485f9bc7
|
45
|
-
branch: master
|
46
|
-
specs:
|
47
|
-
erb_latex (0.3.0)
|
48
|
-
|
49
1
|
PATH
|
50
2
|
remote: .
|
51
3
|
specs:
|
52
|
-
stockor (0.
|
4
|
+
stockor (0.3.0)
|
53
5
|
aasm (~> 4.1)
|
54
6
|
erb_latex (= 0.3)
|
55
|
-
lanes
|
7
|
+
lanes (~> 0.4.0)
|
56
8
|
numbers_in_words (~> 0.4.0)
|
57
9
|
ruby-freshbooks
|
58
10
|
|
@@ -102,6 +54,7 @@ GEM
|
|
102
54
|
crack (0.4.3)
|
103
55
|
safe_yaml (~> 1.0.0)
|
104
56
|
crass (1.0.2)
|
57
|
+
erb_latex (0.3.0)
|
105
58
|
excon (0.49.0)
|
106
59
|
execjs (2.6.0)
|
107
60
|
faker (1.6.3)
|
@@ -263,6 +216,41 @@ GEM
|
|
263
216
|
redis (~> 3.2)
|
264
217
|
redis-namespace
|
265
218
|
json (1.8.3)
|
219
|
+
lanes (0.4.0)
|
220
|
+
activejob (~> 4.2)
|
221
|
+
activerecord (~> 4.2)
|
222
|
+
bcrypt (~> 3.1)
|
223
|
+
carrierwave (~> 0.10.0)
|
224
|
+
coffee-react (~> 3.0)
|
225
|
+
coffee-script (~> 2.3)
|
226
|
+
compass-import-once (~> 1.0)
|
227
|
+
execjs (~> 2.2)
|
228
|
+
fastimage (~> 1.8.1)
|
229
|
+
fog (~> 1.37.0)
|
230
|
+
guard (~> 2.0)
|
231
|
+
guard-jasmine (~> 2.0)
|
232
|
+
guard-minitest (~> 2.3)
|
233
|
+
hashie (~> 3.3)
|
234
|
+
jasmine-core (~> 2.0)
|
235
|
+
jobba (~> 1.4)
|
236
|
+
message_bus (= 2.0.0.beta.6)
|
237
|
+
mini_magick (~> 4.3.6)
|
238
|
+
minitest-around (~> 0.2)
|
239
|
+
mocha (~> 1.1)
|
240
|
+
oj (~> 2.1)
|
241
|
+
pg (~> 0.17)
|
242
|
+
rack-protection (~> 1.5)
|
243
|
+
rack-test (~> 0.6)
|
244
|
+
rake (~> 10.0)
|
245
|
+
require_all (~> 1.3)
|
246
|
+
resque (~> 1.25)
|
247
|
+
sanitize (~> 3.0)
|
248
|
+
sass (~> 3.4)
|
249
|
+
sinatra (~> 1.4)
|
250
|
+
sprockets (~> 3.0)
|
251
|
+
sprockets-helpers (~> 1.2)
|
252
|
+
thor (~> 0.19)
|
253
|
+
uglifier (~> 2.7)
|
266
254
|
listen (3.0.6)
|
267
255
|
rb-fsevent (>= 0.9.3)
|
268
256
|
rb-inotify (>= 0.9.7)
|
@@ -318,7 +306,7 @@ GEM
|
|
318
306
|
builder
|
319
307
|
nokogiri (>= 1.4.1)
|
320
308
|
trollop
|
321
|
-
redis (3.
|
309
|
+
redis (3.3.0)
|
322
310
|
redis-namespace (1.5.2)
|
323
311
|
redis (~> 3.0, >= 3.0.4)
|
324
312
|
require_all (1.3.3)
|
@@ -343,7 +331,7 @@ GEM
|
|
343
331
|
rack-protection (~> 1.4)
|
344
332
|
tilt (>= 1.3, < 3)
|
345
333
|
slop (3.6.0)
|
346
|
-
sprockets (3.
|
334
|
+
sprockets (3.6.0)
|
347
335
|
concurrent-ruby (~> 1.0)
|
348
336
|
rack (> 1, < 3)
|
349
337
|
sprockets-helpers (1.2.1)
|
@@ -371,12 +359,10 @@ PLATFORMS
|
|
371
359
|
|
372
360
|
DEPENDENCIES
|
373
361
|
bundler (~> 1.5)
|
374
|
-
erb_latex!
|
375
362
|
faker
|
376
363
|
growl
|
377
364
|
guard
|
378
365
|
guard-minitest
|
379
|
-
lanes!
|
380
366
|
pry-byebug
|
381
367
|
puma
|
382
368
|
rake
|
@@ -26,7 +26,8 @@ class Skr.Components.BankAccountFinder extends Lanes.React.Component
|
|
26
26
|
props = _.clone(@props)
|
27
27
|
|
28
28
|
if props.selectField
|
29
|
-
<LC.SelectField queryModel={Skr.Models.BankAccount}
|
29
|
+
<LC.SelectField queryModel={Skr.Models.BankAccount}
|
30
|
+
labelField='code' sm=2 {...props} />
|
30
31
|
else
|
31
32
|
<LC.RecordFinder ref="finder" sm=3 autoFocus
|
32
33
|
commands={@props.commands}
|
@@ -29,7 +29,7 @@ class Skr.Components.CustomerFinder extends Lanes.React.Component
|
|
29
29
|
props.defaultLabel = @model.customer_code
|
30
30
|
|
31
31
|
if props.selectField
|
32
|
-
<LC.SelectField sm=2 labelField="code" {...props} />
|
32
|
+
<LC.SelectField labelField='code' sm=2 labelField="code" {...props} />
|
33
33
|
else
|
34
34
|
<LC.RecordFinder ref="finder" sm=3 autoFocus
|
35
35
|
commands={@props.commands}
|
@@ -36,11 +36,8 @@ class Skr.Components.CustomerProjectFinder extends Lanes.React.Component
|
|
36
36
|
props = _.clone(@props)
|
37
37
|
|
38
38
|
if props.selectField
|
39
|
-
<LC.SelectField sm=2
|
40
|
-
|
41
|
-
{...props}
|
42
|
-
model={@props.model}
|
43
|
-
/>
|
39
|
+
<LC.SelectField sm=2 labelField="code"
|
40
|
+
{...props} model={@props.model} />
|
44
41
|
else
|
45
42
|
<LC.RecordFinder ref="finder" sm=3 autoFocus
|
46
43
|
query={@query}
|
@@ -30,8 +30,5 @@ class Skr.Components.LocationChooser extends Lanes.React.Component
|
|
30
30
|
query={@query}
|
31
31
|
{...props} />
|
32
32
|
else
|
33
|
-
<LC.SelectField
|
34
|
-
{
|
35
|
-
choices={Skr.Models.Location.all.models}
|
36
|
-
labelField='code'
|
37
|
-
model={@props.model} />
|
33
|
+
<LC.SelectField {...props} choices={Skr.Models.Location.all.models}
|
34
|
+
labelField='code' model={@props.model} />
|
@@ -26,7 +26,8 @@ class Skr.Components.PaymentCategoryFinder extends Lanes.React.Component
|
|
26
26
|
props = _.clone(@props)
|
27
27
|
|
28
28
|
if props.selectField
|
29
|
-
<LC.SelectField queryModel={Skr.Models.PaymentCategory}
|
29
|
+
<LC.SelectField queryModel={Skr.Models.PaymentCategory}
|
30
|
+
labelField='code' sm=2 {...props} />
|
30
31
|
else
|
31
32
|
<LC.RecordFinder ref="finder" sm=3 autoFocus
|
32
33
|
commands={@props.commands}
|
@@ -25,6 +25,7 @@ class Skr.Components.SkuFinder extends Lanes.React.Component
|
|
25
25
|
render: ->
|
26
26
|
props = _.extend( {}, @props )
|
27
27
|
if @props.selectField
|
28
|
-
<LC.SelectField labelField="code"
|
28
|
+
<LC.SelectField labelField="code"
|
29
|
+
displayFallback={@model.sku_code} {...props} />
|
29
30
|
else
|
30
31
|
<LC.RecordFinder commands={@props.commands} query={@query} {...props} />
|
@@ -4,8 +4,12 @@ class Skr.Components.SkuLines extends Lanes.React.Component
|
|
4
4
|
lines: Lanes.PropTypes.Collection.isRequired
|
5
5
|
commands: React.PropTypes.object.isRequired
|
6
6
|
location: Lanes.PropTypes.Model.isRequired
|
7
|
+
queryBuilder: React.PropTypes.func.isRequired
|
7
8
|
saveImmediately: React.PropTypes.func.isRequired
|
8
9
|
|
10
|
+
getDefaultProps: ->
|
11
|
+
queryBuilder: (a) -> a
|
12
|
+
|
9
13
|
componentWillMount: ->
|
10
14
|
@createQuery(@props.lines)
|
11
15
|
|
@@ -13,16 +17,17 @@ class Skr.Components.SkuLines extends Lanes.React.Component
|
|
13
17
|
@createQuery(nextProps.lines) if nextProps.lines
|
14
18
|
|
15
19
|
createQuery: (lines) ->
|
16
|
-
@query = new Lanes.Models.Query
|
20
|
+
@query = new Lanes.Models.Query(@props.queryBuilder({
|
17
21
|
title: 'Lines'
|
18
22
|
defaultSort: false
|
19
|
-
src: lines,
|
23
|
+
src: lines,
|
24
|
+
fields: [
|
20
25
|
{ id:'id', visible: false }
|
21
26
|
{ id: 'sku_code', fixedWidth: 150 }
|
22
27
|
{ id: 'description', flex: 2 }
|
23
28
|
{
|
24
29
|
id: 'uom', title: 'UOM', query: false, fixedWidth: 100,
|
25
|
-
format: (v, r, q) -> v?.
|
30
|
+
format: (v, r, q) -> v?.combined
|
26
31
|
sortBy: (a, b) ->
|
27
32
|
Lanes.u.comparator(a.uom_size, b.uom_size) or
|
28
33
|
Lanes.u.comparator(a.uom_code, b.uom_code)
|
@@ -33,6 +38,7 @@ class Skr.Components.SkuLines extends Lanes.React.Component
|
|
33
38
|
format: (v, r, q) -> v?.toFixed(2)
|
34
39
|
}
|
35
40
|
]
|
41
|
+
}))
|
36
42
|
|
37
43
|
onSkuChange: (sku, options) ->
|
38
44
|
options.model.set({sku})
|
@@ -40,22 +46,24 @@ class Skr.Components.SkuLines extends Lanes.React.Component
|
|
40
46
|
_.dom(@, 'input[name="qty"]').focusAndSelect() if @isMounted()
|
41
47
|
|
42
48
|
editors: ->
|
49
|
+
|
43
50
|
sku_code: ({model, props}) =>
|
44
51
|
options = {
|
45
52
|
with: {in_location: props.location.id}
|
46
53
|
include: ['sku_locs', 'uoms']
|
47
54
|
}
|
48
55
|
<SC.SkuFinder
|
49
|
-
writable
|
56
|
+
writable selectField unstyled
|
50
57
|
setSelection={@onSkuChange}
|
51
58
|
name='sku' model={model}
|
52
|
-
|
59
|
+
syncOptions={options}
|
60
|
+
/>
|
53
61
|
|
54
62
|
uom: ({model}) ->
|
55
63
|
<SC.UOMChooser writable unstyled model={model} />
|
56
64
|
|
57
65
|
onSelectionChange: (model) ->
|
58
|
-
return unless model and @props.commands.isEditing()
|
66
|
+
return Promise.resolve() unless model and not model.isNew() and @props.commands.isEditing()
|
59
67
|
new _.Promise (res, rej) ->
|
60
68
|
model.withAssociations([
|
61
69
|
'sku_loc', 'sku', 'uom_choices'
|
@@ -18,6 +18,7 @@ class Skr.Components.SystemSettings extends Lanes.React.Component
|
|
18
18
|
|
19
19
|
<SC.BankAccountFinder selectField
|
20
20
|
sm=3 label="Default Bank Account"
|
21
|
+
model={Lanes.config.system_settings}
|
21
22
|
choices={this.banks.models}
|
22
23
|
setSelection={@setBankAccount}
|
23
24
|
getSelection={@getBankAccount}
|
@@ -10,15 +10,15 @@ class Skr.Components.UOMChooser extends Lanes.React.Component
|
|
10
10
|
render: ->
|
11
11
|
props = _.clone(@props)
|
12
12
|
props.choices ||= @props.model.uom_choices.models
|
13
|
+
|
13
14
|
<LC.SelectField
|
14
|
-
key="uom"
|
15
15
|
syncOptions={with: 'with_combined_uom'}
|
16
16
|
displayFallback={@props.model.uom.combined_uom}
|
17
17
|
editOnly writable unstyled
|
18
18
|
model={@props.model}
|
19
19
|
fetchWhenOpen={false}
|
20
20
|
queryOrder={size: 'desc'}
|
21
|
-
labelField="
|
21
|
+
labelField="combined"
|
22
22
|
name="uom"
|
23
23
|
{...props}
|
24
24
|
/>
|
@@ -70,6 +70,8 @@ class Skr.Models.Invoice extends Skr.Models.Base
|
|
70
70
|
|
71
71
|
onSetCustomer: (newCustomer) ->
|
72
72
|
return if not newCustomer or newCustomer.isNew()
|
73
|
+
for attr in ['terms_id']
|
74
|
+
@set(attr, newCustomer[attr])
|
73
75
|
@copyAssociationsFrom( newCustomer, 'billing_address', 'shipping_address')
|
74
76
|
|
75
77
|
setFromSalesOrder: (so) ->
|
@@ -66,7 +66,8 @@ class Skr.Models.SalesOrder extends Skr.Models.Base
|
|
66
66
|
onCustomerChange: ->
|
67
67
|
return unless @isNew()
|
68
68
|
associations = ['billing_address', 'shipping_address']
|
69
|
-
|
69
|
+
for attr in ['terms_id']
|
70
|
+
@set(attr, @customer[attr])
|
70
71
|
@customer.withAssociations(associations).then =>
|
71
72
|
for name in associations
|
72
73
|
@associations.replace(@, name, @customer[name])
|
@@ -50,7 +50,8 @@ class Skr.Models.TimeEntry extends Skr.Models.Base
|
|
50
50
|
@set('hours', _.moment(this.end_at).diff(this.start_at, 'hour', true).toFixed(2),
|
51
51
|
silent: true)
|
52
52
|
onHoursChange: ->
|
53
|
-
|
53
|
+
hours = @hours || _.bigDecimal('0')
|
54
|
+
@end_at = _.moment(@start_at).add(hours.toFixed(), 'hour').toDate()
|
54
55
|
|
55
56
|
length: (duration = 'hour') ->
|
56
57
|
@range.end.diff(@range.start, duration, true)
|
@@ -23,7 +23,7 @@ class Skr.Screens.CustomerProjects extends Skr.Screens.Base
|
|
23
23
|
@forceUpdate()
|
24
24
|
getColorReadOnly: ->
|
25
25
|
index = @getColor()
|
26
|
-
color = _.
|
26
|
+
color = _.find(Skr.Models.CustomerProject.COLORS, id: index)
|
27
27
|
<div className={"ro color-#{index}"}>{color?.name}</div>
|
28
28
|
|
29
29
|
getColor: ->
|
@@ -8,7 +8,7 @@ class TextInput extends Lanes.React.Component
|
|
8
8
|
@forceUpdate()
|
9
9
|
|
10
10
|
render: ->
|
11
|
-
<input value={@props.row.customer_code} onChange={@setCode} />
|
11
|
+
<input value={@props.row.customer_code || ''} onChange={@setCode} />
|
12
12
|
|
13
13
|
class UserSelect extends Lanes.React.Component
|
14
14
|
dataObjects:
|
@@ -35,6 +35,12 @@ class Skr.Screens.Invoice extends Skr.Screens.Base
|
|
35
35
|
shouldSaveLinesImmediately: ->
|
36
36
|
not @invoice.isNew()
|
37
37
|
|
38
|
+
linesQueryBuilder: (attrs) ->
|
39
|
+
unless this.invoice.isNew()
|
40
|
+
sc = _.find attrs.fields, id: 'sku_code'
|
41
|
+
sc.editable = false
|
42
|
+
attrs
|
43
|
+
|
38
44
|
render: ->
|
39
45
|
<LC.ScreenWrapper identifier="invoice" flexVertical>
|
40
46
|
|
@@ -85,6 +91,7 @@ class Skr.Screens.Invoice extends Skr.Screens.Base
|
|
85
91
|
</BS.Row>
|
86
92
|
|
87
93
|
<SC.SkuLines location={@invoice.location}
|
94
|
+
queryBuilder={@linesQueryBuilder}
|
88
95
|
saveImmediately={@shouldSaveLinesImmediately}
|
89
96
|
commands={@state.commands} lines={@invoice.lines} />
|
90
97
|
|
@@ -149,7 +149,7 @@ class InvoiceRequest extends Lanes.Models.Base
|
|
149
149
|
time_entry_ids: { type: 'array', default: -> [] }
|
150
150
|
|
151
151
|
api_path: ->
|
152
|
-
|
152
|
+
"/skr/invoices/from-time-entries"
|
153
153
|
|
154
154
|
associations:
|
155
155
|
customer_project: { model: "CustomerProject", autoCreate: true }
|
@@ -12,8 +12,8 @@ class Skr.Screens.TimeTracking.MiniControls extends Lanes.React.Component
|
|
12
12
|
render: ->
|
13
13
|
<div className="mini-controls">
|
14
14
|
<div className='l'>
|
15
|
-
{@props.date.format('MMM')}
|
16
|
-
{@props.date.format('Do')}
|
15
|
+
<span>{@props.date.format('MMM')}</span>
|
16
|
+
<span>{@props.date.format('Do')}</span>
|
17
17
|
</div>
|
18
18
|
<BS.Button onClick={@props.onCancel} title="Hide Controls">
|
19
19
|
<LC.Icon type='ban' 2x flush />
|
data/lib/skr/version.rb
CHANGED
data/stockor.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
|
|
25
25
|
|
26
26
|
spec.add_dependency 'aasm', '~>4.1'
|
27
27
|
spec.add_dependency 'erb_latex', '0.3'
|
28
|
-
spec.add_dependency 'lanes'
|
28
|
+
spec.add_dependency 'lanes', '~> 0.4.0'
|
29
29
|
spec.add_dependency 'numbers_in_words', '~> 0.4.0'
|
30
30
|
spec.add_dependency 'ruby-freshbooks'
|
31
31
|
|
@@ -11,7 +11,7 @@
|
|
11
11
|
\multicolumn{<%=ncols%>}{r}{Continued on next page...} \\
|
12
12
|
\endfoot
|
13
13
|
\hline
|
14
|
-
<%= partial @footer || 'skus_table_footer', record: @record, ncols: ncols %>
|
14
|
+
<%= partial @footer || 'skus_table_footer', record: @record, ncols: ncols, lines: @lines %>
|
15
15
|
\endlastfoot
|
16
16
|
<% if @groups %>
|
17
17
|
<% @groups.each_with_index do | group, i | -%>
|
@@ -1,7 +1,17 @@
|
|
1
|
+
<% hours = @lines.reduce(BigDecimal.new('0')){|t, l| l.time_entry ? t+l.qty : t } %>
|
1
2
|
<%= partial 'skus_table_other_charge_lines', record: @record, ncols: @ncols %>
|
2
|
-
\multicolumn{<%= @ncols-
|
3
|
+
\multicolumn{<%= @ncols-3 %>}{r}{{
|
4
|
+
<% unless hours.zero? %>
|
5
|
+
\textbf{<%= '%0.2f' % hours %>}
|
6
|
+
<% end %>
|
7
|
+
}} &
|
8
|
+
<% unless hours.zero? %>
|
9
|
+
\textbf{Hours} &
|
10
|
+
<% end %>
|
11
|
+
\textbf{Total} &
|
3
12
|
\textbf{\textsuperscript{\$}<%= Skr::String.number_with_delimiter @record.total %>} \\
|
4
|
-
\cline{<%= @ncols-3%>-<%= @ncols%>}
|
13
|
+
\cline{<%= @ncols - 3%>-<%= @ncols%>}
|
14
|
+
|
5
15
|
% \hline
|
6
16
|
<% unless @record.open? -%>
|
7
17
|
\multicolumn{<%= @ncols-1%>}{r}{{\textbf{Amount Paid}}} &
|
@@ -0,0 +1,7 @@
|
|
1
|
+
<%= partial 'skus_table_other_charge_lines', record: @record, ncols: @ncols %>
|
2
|
+
\multicolumn{<%= @ncols-4%>}{r}{} &
|
3
|
+
\textbf{<%= '%0.2f' % @lines.to_a.sum{|l| l.time_entry.hours } %>} &
|
4
|
+
\textbf{Hours} &
|
5
|
+
\textbf{Total} &
|
6
|
+
\textbf{\textsuperscript{\$}<%= Skr::String.number_with_delimiter @record.total %>} \\
|
7
|
+
\cline{<%= @ncols-3%>-<%= @ncols%>} \\
|
@@ -4,7 +4,7 @@
|
|
4
4
|
form_title: "Invoice # #{@invoice.visible_id}"
|
5
5
|
} ) %>
|
6
6
|
<%= partial 'bill_to_ship_to', record: @invoice -%>
|
7
|
-
<%=
|
7
|
+
<%=partial 'skus_table_invoice_info_line', invoice: @invoice -%>
|
8
8
|
<%= partial 'skus_table',
|
9
9
|
record: @invoice,
|
10
10
|
lines: @invoice.lines.regular,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stockor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nathan Stitt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-04-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aasm
|
@@ -42,16 +42,16 @@ dependencies:
|
|
42
42
|
name: lanes
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 0.4.0
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 0.4.0
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: numbers_in_words
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -633,6 +633,7 @@ files:
|
|
633
633
|
- templates/print/partials/skus_table_invoice_footer.tex.erb
|
634
634
|
- templates/print/partials/skus_table_invoice_info_line.tex.erb
|
635
635
|
- templates/print/partials/skus_table_labor_col_hdr.tex.erb
|
636
|
+
- templates/print/partials/skus_table_labor_footer.tex.erb
|
636
637
|
- templates/print/partials/skus_table_labor_group_footer.tex.erb
|
637
638
|
- templates/print/partials/skus_table_labor_line.tex.erb
|
638
639
|
- templates/print/partials/skus_table_line.tex.erb
|
@@ -663,7 +664,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
663
664
|
version: '0'
|
664
665
|
requirements: []
|
665
666
|
rubyforge_project:
|
666
|
-
rubygems_version: 2.
|
667
|
+
rubygems_version: 2.5.1
|
667
668
|
signing_key:
|
668
669
|
specification_version: 4
|
669
670
|
summary: Stockor is a complete ERP system
|