jishan_fast_track_gem 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3004f97d8e017db74bc31e69a364fe03b6e8266d6d65982eaaa3615135583c08
4
- data.tar.gz: 2d090b42855900c293f79af1c2dd2e822cdc85d0a1bda1da40aaefdc051e09e0
3
+ metadata.gz: 9eb7330cec0d1d1825a87b6961e91c3cd299b48da14da0e6eedc931b3e2ea0ef
4
+ data.tar.gz: b047ac28d5e251024ebd351a0414cef4ad012ec3c9983b892adbdbea6ca325c4
5
5
  SHA512:
6
- metadata.gz: cbafaff3602098979750bd2185211239815cd1514e0e8e4753094eff6be2b9ff4f6bf1f79eb28242c3663f6d70b922e03d8323f3554f1247c9513b2be5c41374
7
- data.tar.gz: 81121f2fda24bbc4e3b31e713a1198f123f1268cc21dd0e3de028ce2d21b7037d0c8817ba3b67e0bb1b85a094c79670a97e2f00ac6aab125d00deb127ecd4ede
6
+ metadata.gz: 89ffe07f583fb80e1a3093ff5037d4a24470fe7356cb038e1e1b8c8c785af36d6b53c4d6dc6b7a2506603d55517c2223bb7e3b71a139a9699944b8ddc681c6d4
7
+ data.tar.gz: f569d73a731e14937c178708c1759af0cf7f62cc7aecb5e1672b8ebe6e40dfea3fa87d0f05aa129a2fb902c2b7a73252223e205820f3cc880f0f931716893d72
data/Gemfile CHANGED
@@ -7,5 +7,5 @@ gem 'colorize', '~> 0.8.1'
7
7
  gem 'gemoji'
8
8
  gem 'progress_bar'
9
9
  gem 'tty-prompt'
10
- gem 'logging'
11
- gem 'rspec', '~> 3.0.0'
10
+ gem 'rspec', '~> 3.0.0'
11
+ gem 'table_print'
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- jishan_fast_track_gem (0.1.3)
4
+ jishan_fast_track_gem (0.1.4)
5
5
  colorize (~> 0.8.1)
6
6
 
7
7
  GEM
@@ -12,11 +12,6 @@ GEM
12
12
  equatable (0.6.1)
13
13
  gemoji (3.0.1)
14
14
  highline (2.0.3)
15
- little-plugger (1.1.4)
16
- logging (2.2.2)
17
- little-plugger (~> 1.1)
18
- multi_json (~> 1.10)
19
- multi_json (1.14.1)
20
15
  necromancer (0.5.1)
21
16
  options (2.3.2)
22
17
  pastel (0.7.3)
@@ -38,6 +33,7 @@ GEM
38
33
  rspec-mocks (3.0.4)
39
34
  rspec-support (~> 3.0.0)
40
35
  rspec-support (3.0.4)
36
+ table_print (1.5.6)
41
37
  tty-color (0.5.1)
42
38
  tty-cursor (0.7.1)
43
39
  tty-prompt (0.21.0)
@@ -58,10 +54,10 @@ DEPENDENCIES
58
54
  colorize (~> 0.8.1)
59
55
  gemoji
60
56
  jishan_fast_track_gem!
61
- logging
62
57
  progress_bar
63
58
  rake (~> 12.0)
64
59
  rspec (~> 3.0.0)
60
+ table_print
65
61
  tty-prompt
66
62
 
67
63
  BUNDLED WITH
data/lib/files_check.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'uri'
2
2
  require 'csv'
3
3
  require 'colorize'
4
-
4
+ require 'table_print'
5
5
 
6
6
 
7
7
  class Provided_files_check
@@ -13,17 +13,16 @@ class Provided_files_check
13
13
  puts "provide the proof of income document URL (only .pdf or .doc): ".colorize(:light_blue)
14
14
  url = gets.chomp
15
15
  if url =~ URI::regexp
16
- puts "valid file URL."
17
16
  else
18
- puts "not valid file URL."
17
+ puts "It's not a valid file URL."
19
18
  end
20
19
 
21
20
  file_type = File.extname(URI.parse(url).path)
22
21
  if file_type == ".pdf" || file_type == ".doc"
23
- puts "file upload succeeded."
22
+ puts "File upload succeeded."
24
23
  two_forms_of_identity
25
24
  else
26
- puts "upload failed. please provide valid URL to .pdf or .doc ."
25
+ puts "upload failed. please provide .pdf or .doc document."
27
26
  end
28
27
  end
29
28
 
@@ -35,7 +34,7 @@ class Provided_files_check
35
34
  if url =~ URI::regexp
36
35
  puts "valid file URL."
37
36
  else
38
- puts "not valid file URL."
37
+ puts "It's not a valid file URL."
39
38
  end
40
39
 
41
40
  file_type = File.extname(URI.parse(url).path)
@@ -43,7 +42,7 @@ class Provided_files_check
43
42
  file_arr << file_type
44
43
  puts "file upload succeeded."
45
44
  else
46
- puts "upload failed. please provide valid URL to .pdf or .doc ."
45
+ puts "upload failed. please provide .pdf or .doc document."
47
46
  end
48
47
  break if file_arr.size == 2
49
48
  end
@@ -55,17 +54,16 @@ class Provided_files_check
55
54
  url = gets.chomp
56
55
  file_type = File.extname(URI.parse(url).path)
57
56
 
58
- if url =~ URI::regexp
59
- puts "valid file URL."
57
+ if url =~ URI::regexp
60
58
  else
61
- puts "not valid file URL."
59
+ puts "It's not a valid file URL."
62
60
  end
63
61
 
64
62
  if file_type == ".pdf" || file_type == ".doc"
65
63
  puts "file upload succeeded."
66
64
  eligible_quote(url)
67
65
  else
68
- puts "upload failed. please provide valid URL to .pdf or .doc ."
66
+ puts "upload failed. please provide .pdf or .doc document."
69
67
  end
70
68
  end
71
69
  def eligible_quote(url)
@@ -81,7 +79,8 @@ class Provided_files_check
81
79
  if result != nil
82
80
  puts "Eligible retailer."
83
81
  else
84
- puts "Not Eligible retailer."
82
+ puts "Not Eligible retailer. Please check the provided list of CEC approved retailers below"
83
+ tp csv.map { |row| row.to_hash }, {:NAME => {display_name: "Company Name"}}, {:URL => {width: 35}}
85
84
  end
86
85
  end
87
86
  end
@@ -1,3 +1,3 @@
1
1
  module JishanFastTrackGem
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  end
@@ -3,39 +3,34 @@ require_relative 'rebate_calculator'
3
3
  require_relative 'files_check'
4
4
  require_relative 'eligibility_check'
5
5
  require_relative 'manage_lists'
6
- require 'logging'
7
6
 
8
- # logging write the intro
7
+ # write the intro
9
8
  # Help file includes *comprehensive* instructions which *accurately* describe: steps to install the application; dependencies required by the application; system/hardware requirements; features of the application.
10
9
 
11
10
  ruby = Solar_panel_rebate_egilibility_check.new("Ruby")
12
- ruby.ower_of_the_property
11
+ # ruby.ower_of_the_property
13
12
 
14
13
  john_files = Provided_files_check.new("john_files")
15
- # john_files.income_proof
16
- john_rebate = Rebate_calculator.new("john_rebate")
14
+ john_files.eligible_quote("www.wrong.com")
15
+ john_rebate = Rebate_calculator.new
17
16
  # john_rebate.stc_postcode_rating(3000)
18
17
  # john_rebate.stc_calculator(5, 5)
19
18
  # p john_rebate.rebate
20
19
 
21
-
22
-
23
- # john_files.retailer_quote
24
20
  # peta_files= Provided_files_check.new("peta_files")
25
21
  # peta_files.retailer_quote
26
22
 
27
23
 
28
- # a_list = Manage_list.new("a_list")
24
+ # a_list = Manage_list.new
29
25
  # a_list.add_to_eligible_list("John")
30
26
  # a_list.add_to_eligible_list("Peta")
31
27
  # a_list.add_to_eligible_list("Peta")
32
28
  # a_list.remove_applicant("John")
33
29
 
34
-
35
30
  # p Manage_list.display_processing_number
36
31
  # p a_list.eligible_list
37
32
 
38
- # john_rebate = Rebate_calculator.new("John_rebate")
33
+ # john_rebate = Rebate_calculator.new
39
34
  # john_rebate.stc_postcode_rating(3163)
40
35
  # john_rebate.stc_calculator(3, 15)
41
36
  # p john_rebate.rebate
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jishan_fast_track_gem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jishan_Lu