Class: Kamome::Models::Jigyosho

Inherits:
Object
  • Object
show all
Defined in:
lib/kamome/models/jigyosho.rb

Overview

CSV Model: 大口事業所個別番号データ

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ Jigyosho

Returns a new instance of Jigyosho.



81
82
83
84
85
# File 'lib/kamome/models/jigyosho.rb', line 81

def initialize(params = {})
  params.each do |key, value|
    public_send("#{key}=", value)
  end
end

Instance Attribute Details

#cityString

市区町村名(漢字)

Returns:

  • (String)


32
33
34
# File 'lib/kamome/models/jigyosho.rb', line 32

def city
  @city
end

#codeObject

大口事業所の所在地のJISコード



12
13
14
# File 'lib/kamome/models/jigyosho.rb', line 12

def code
  @code
end

#company_nameObject

Returns the value of attribute company_name.



22
23
24
# File 'lib/kamome/models/jigyosho.rb', line 22

def company_name
  @company_name
end

#company_name_kanaObject

Returns the value of attribute company_name_kana.



17
18
19
# File 'lib/kamome/models/jigyosho.rb', line 17

def company_name_kana
  @company_name_kana
end

#has_post_office_boxObject

Returns the value of attribute has_post_office_box.



62
63
64
# File 'lib/kamome/models/jigyosho.rb', line 62

def has_post_office_box
  @has_post_office_box
end

#japanpost_office_nameString

取扱局

Returns:

  • (String)


57
58
59
# File 'lib/kamome/models/jigyosho.rb', line 57

def japanpost_office_name
  @japanpost_office_name
end

#multipleObject

Returns the value of attribute multiple.



71
72
73
# File 'lib/kamome/models/jigyosho.rb', line 71

def multiple
  @multiple
end

#nameString

大口事業所名(漢字)

Returns:

  • (String)


22
# File 'lib/kamome/models/jigyosho.rb', line 22

attr_accessor :company_name

#name_kanaString

大口事業所名(カナ)

Returns:

  • (String)


17
# File 'lib/kamome/models/jigyosho.rb', line 17

attr_accessor :company_name_kana

#post_office_boxBoolean

私書箱: true, 大口事業所: false

Returns:

  • (Boolean)


47
48
49
# File 'lib/kamome/models/jigyosho.rb', line 47

def post_office_box
  @post_office_box
end

#prefectureString

都道府県名(漢字)

Returns:

  • (String)


27
28
29
# File 'lib/kamome/models/jigyosho.rb', line 27

def prefecture
  @prefecture
end

#required_chomeInteger

複数番号の有無

  • 「0」複数番号無し

  • 「1」複数番号を設定している場合の個別番号の1

  • 「2」複数番号を設定している場合の個別番号の2

  • 「3」複数番号を設定している場合の個別番号の3

Returns:

  • (Integer)


71
# File 'lib/kamome/models/jigyosho.rb', line 71

attr_accessor :multiple

#stateInteger

修正コード

  • 「0」修正なし

  • 「1」新規追加

  • 「5」廃止

Returns:

  • (Integer)


79
80
81
# File 'lib/kamome/models/jigyosho.rb', line 79

def state
  @state
end

#streetString

小字名、丁目、番地等(漢字)

Returns:

  • (String)


42
43
44
# File 'lib/kamome/models/jigyosho.rb', line 42

def street
  @street
end

#townString

大口事業所個別番号

Returns:

  • (String)


37
38
39
# File 'lib/kamome/models/jigyosho.rb', line 37

def town
  @town
end

#zipcodeObject

Returns the value of attribute zipcode.



52
53
54
# File 'lib/kamome/models/jigyosho.rb', line 52

def zipcode
  @zipcode
end

Instance Method Details

#attributesObject



87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
# File 'lib/kamome/models/jigyosho.rb', line 87

def attributes
  {
    code: code,
    company_name_kana: company_name_kana,
    company_name: company_name,
    prefecture: prefecture,
    city: city,
    town: town,
    street: street,
    post_office_box: post_office_box,
    zipcode: zipcode,
    japanpost_office_name: japanpost_office_name,
    has_post_office_box: has_post_office_box,
    multiple: multiple,
    state: state
  }
end