extface 0.5.7 → 0.5.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/extface/driver/base/print.rb +11 -7
- data/lib/extface/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 22d78c8ea31d91b6bab4004883da84d8a43b1aeb
|
4
|
+
data.tar.gz: 1becebfb38a4251d08ad9fab7e99e58f995f3d2b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1a5d69ac6a6de65456ee059d7c1d023b355e2d6488221f4a2fa12e06b95e3f8b486a20201bb6e80bd9684f1df74569fea7a116ab6b77e14d9238489513cbec62
|
7
|
+
data.tar.gz: c43640283b80ba3101a7c19e290d35456d45efcd2568715a0d8400838019b7951719542c09ffb7cd120a8422f1330e51ebfe3de388d7bb8a8ee0132a684517cd
|
@@ -60,29 +60,29 @@ module Extface
|
|
60
60
|
end
|
61
61
|
|
62
62
|
def print_edges_row(text1, text2)
|
63
|
-
print "#{text1} #{text2.rjust(
|
63
|
+
print "#{text1} #{text2.rjust(char_columns - text1.length - 1)}\r\n"
|
64
64
|
end
|
65
65
|
|
66
66
|
def print_text_price_row(text, price)
|
67
67
|
rtext = ("%.2f" % price.to_f)
|
68
|
-
lsize =
|
68
|
+
lsize = char_columns - rtext.length - 1
|
69
69
|
print "#{text.truncate(lsize).ljust(lsize)} #{rtext}\r\n"
|
70
70
|
end
|
71
71
|
|
72
72
|
def print_fill_row(pattern)
|
73
|
-
print "\r\n".rjust(
|
73
|
+
print "\r\n".rjust(char_columns + 2, pattern)
|
74
74
|
end
|
75
75
|
|
76
76
|
def print_rjust_row(text, padstr=' ')
|
77
|
-
print "#{text.truncate(
|
77
|
+
print "#{text.truncate(char_columns).rjust(char_columns, padstr)}\r\n"
|
78
78
|
end
|
79
79
|
|
80
80
|
def print_ljust_row(text, padstr = ' ', margin=0)
|
81
|
-
print "#{text.truncate(
|
81
|
+
print "#{text.truncate(char_columns - margin).ljust(char_columns - margin)}\r\n"
|
82
82
|
end
|
83
83
|
|
84
84
|
def print_center_row(text, padstr = ' ')
|
85
|
-
print "#{text.truncate(
|
85
|
+
print "#{text.truncate(char_columns).center(char_columns, padstr)}\r\n"
|
86
86
|
end
|
87
87
|
|
88
88
|
def printize(bill, detailed = false, payments = true)
|
@@ -100,6 +100,10 @@ module Extface
|
|
100
100
|
|
101
101
|
end
|
102
102
|
end
|
103
|
-
|
103
|
+
|
104
|
+
def char_columns
|
105
|
+
self.class::CHAR_COLUMNS
|
106
|
+
end
|
104
107
|
end
|
108
|
+
|
105
109
|
end
|
data/lib/extface/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: extface
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Vangelov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-09-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: redis
|