luca-jp 0.7.0 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/exe/luca-jp +7 -2
- data/lib/luca/jp/aoiro.rb +21 -8
- data/lib/luca/jp/chihouzei.rb +34 -15
- data/lib/luca/jp/common.rb +82 -20
- data/lib/luca/jp/templates/beppyo2.xml.erb +2 -0
- data/lib/luca/jp/templates/beppyo4.xml.erb +59 -34
- data/lib/luca/jp/templates/el-no6-43.xml.erb +10 -9
- data/lib/luca/jp/templates/el-no6.xml.erb +8 -8
- data/lib/luca/jp/templates/eltax.xml.erb +2 -2
- data/lib/luca/jp/templates/gaikyo.xml.erb +4 -0
- data/lib/luca/jp/templates/yokin-meisai.xml.erb +1 -0
- data/lib/luca/jp/uchiwake.rb +1 -1
- data/lib/luca/jp/util.rb +4 -0
- data/lib/luca/jp/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4397cf29a4b348c06c854a7317bf1c7a63feef296635ffe5d8cc8ab237a5ca86
|
4
|
+
data.tar.gz: 8f0e650b20dcd79af950dfaf09b3e5df4f7e32094651d3661fe7f232c58685fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 25b4554065a779fee709b1f32e0120cfddf0ce23fa80397ff470f54d2a20604246781dee7c29c8f565477fedb32aa37a18398053b2411d92db1dd4e6002ce123
|
7
|
+
data.tar.gz: ba9dd2935aba7e2609278732f1db875d0896587db70605519282f94eca98264e0f51cc2d2f25ab12249477750c4debfcf74d73b472679367429a25dad2ffb9a1
|
data/exe/luca-jp
CHANGED
@@ -22,9 +22,14 @@ class LucaCmd
|
|
22
22
|
|
23
23
|
def self.chihouzei(args, params)
|
24
24
|
if params[:export]
|
25
|
-
Luca::Jp::
|
25
|
+
accounts = Luca::Jp::Util.eltax_config('reports').map do |report|
|
26
|
+
Luca::Jp::Chihouzei.range(*args).export_json(report)
|
27
|
+
end
|
28
|
+
puts JSON.dump(accounts)
|
26
29
|
else
|
27
|
-
|
30
|
+
Luca::Jp::Util.eltax_config('reports').each do |report|
|
31
|
+
File.open("chihouzei-#{report['jichitai_code']}#{report['jimusho_code']}.xml", 'w') { |f| f.puts(Luca::Jp::Chihouzei.range(*args).kani(report))}
|
32
|
+
end
|
28
33
|
end
|
29
34
|
end
|
30
35
|
|
data/lib/luca/jp/aoiro.rb
CHANGED
@@ -135,16 +135,16 @@ module Luca
|
|
135
135
|
@当期純損益 = readable(@pl_data.dig('HA'))
|
136
136
|
@法人税等 = readable(@pl_data.dig('H0'))
|
137
137
|
_, @納付事業税 = 未納事業税期中増減
|
138
|
-
|
138
|
+
@当期還付事業税 = 還付事業税
|
139
|
+
@翌期還付事業税 = 中間還付税額(確定事業税, @事業税中間納付)
|
140
|
+
@別表四調整所得 = @当期純損益 + @法人税等 - @納付事業税 - @翌期還付事業税 + @当期還付事業税
|
139
141
|
|
140
142
|
@当期還付法人税 = refund_tax('1502')
|
141
143
|
@当期還付都道府県住民税 = refund_tax('1503')
|
142
144
|
@翌期還付都道府県住民税 = 中間還付税額(@税額.dig(:kenmin, :kintou), @都道府県民税均等割中間納付) + 中間還付税額(@税額.dig(:kenmin, :houjinzei), @都道府県民税法人税割中間納付)
|
143
145
|
@当期還付市民税 = refund_tax('1505')
|
144
146
|
@翌期還付市民税 = 中間還付税額(@税額.dig(:shimin, :kintou), @市民税均等割中間納付) + 中間還付税額(@税額.dig(:shimin, :houjinzei), @市民税法人税割中間納付)
|
145
|
-
@当期還付事業税 = 還付事業税
|
146
147
|
@事業税期首残高 = 期首未納事業税 > 0 ? 期首未納事業税 : (@当期還付事業税 * -1)
|
147
|
-
@翌期還付事業税 = 中間還付税額(確定事業税, @事業税中間納付)
|
148
148
|
@仮払税金 = @翌期還付法人税 + @翌期還付都道府県住民税 + @翌期還付事業税 + @翌期還付市民税
|
149
149
|
|
150
150
|
render_erb(search_template('beppyo4.xml.erb'))
|
@@ -158,7 +158,8 @@ module Luca
|
|
158
158
|
@期首その他資本剰余金, @期末その他資本剰余金 = 期首期末残高('9132')
|
159
159
|
@その他資本剰余金期中減, @その他資本剰余金期中増 = 純資産期中増減('9132')
|
160
160
|
@期首自己株式, @期末自己株式 = 期首期末残高('916')
|
161
|
-
|
161
|
+
# 自己株式は負の純資産。借方集計は負の増加として認識
|
162
|
+
@自己株式期中増, @自己株式期中減 = 純資産期中増減('916').map { |t| t * -1 }
|
162
163
|
@資本金等の額期中減, @資本金等の額期中増 = 資本金等の額期中増減
|
163
164
|
render_erb(search_template('beppyo51.xml.erb'))
|
164
165
|
end
|
@@ -319,7 +320,12 @@ module Luca
|
|
319
320
|
return nil if beppyo2_config('total_shares').nil?
|
320
321
|
return nil if beppyo2_config('owners').nil?
|
321
322
|
|
322
|
-
|
323
|
+
total = if beppyo2_config('own_shares').nil?
|
324
|
+
beppyo2_config('total_shares')
|
325
|
+
else
|
326
|
+
beppyo2_config('total_shares') - beppyo2_config('own_shares')
|
327
|
+
end
|
328
|
+
(別表二上位株数 * 100.0 / total).round(1)
|
323
329
|
end
|
324
330
|
|
325
331
|
def 別表二上位議決権数
|
@@ -332,7 +338,12 @@ module Luca
|
|
332
338
|
return nil if beppyo2_config('total_votes').nil?
|
333
339
|
return nil if beppyo2_config('owners').nil?
|
334
340
|
|
335
|
-
|
341
|
+
total = if beppyo2_config('no_votes').nil?
|
342
|
+
beppyo2_config('total_votes')
|
343
|
+
else
|
344
|
+
beppyo2_config('total_votes') - beppyo2_config('no_votes')
|
345
|
+
end
|
346
|
+
(別表二上位議決権数 * 100.0 / total).round(1)
|
336
347
|
end
|
337
348
|
|
338
349
|
# TODO: 特定同族会社の判定
|
@@ -541,12 +552,14 @@ module Luca
|
|
541
552
|
# 資本金、資本準備金、その他資本剰余金、自己株式(控除)の合算
|
542
553
|
#
|
543
554
|
def 資本金等の額期中増減
|
544
|
-
inc = ['911', '913'
|
555
|
+
inc = ['911', '913'].map do |code|
|
545
556
|
credit_amount(code, @start_date.year, @start_date.month, @end_date.year, @end_date.month) || 0
|
546
557
|
end
|
547
|
-
|
558
|
+
inc << (debit_amount('916', @start_date.year, @start_date.month, @end_date.year, @end_date.month)||0) * -1
|
559
|
+
dec = ['911', '913'].map do |code|
|
548
560
|
debit_amount(code, @start_date.year, @start_date.month, @end_date.year, @end_date.month) || 0
|
549
561
|
end
|
562
|
+
dec << (credit_amount('916', @start_date.year, @start_date.month, @end_date.year, @end_date.month)||0) * -1
|
550
563
|
|
551
564
|
[readable(dec.sum), readable(inc.sum)]
|
552
565
|
end
|
data/lib/luca/jp/chihouzei.rb
CHANGED
@@ -18,16 +18,13 @@ module Luca
|
|
18
18
|
@dirname = 'journals'
|
19
19
|
@record_type = 'raw'
|
20
20
|
|
21
|
-
def kani(export: false)
|
21
|
+
def kani(report_cfg, export: false)
|
22
22
|
set_pl(4)
|
23
23
|
set_bs(4)
|
24
24
|
@issue_date = Date.today
|
25
|
-
@company = CGI.escapeHTML(config.dig('company', 'name'))
|
26
25
|
@software = 'LucaJp'
|
27
|
-
@
|
28
|
-
@
|
29
|
-
@app_version = eltax_config('app_version')
|
30
|
-
@form_vers = proc_version
|
26
|
+
@report_category = report_cfg['type']
|
27
|
+
@employee = report_cfg['employee'] || 1
|
31
28
|
|
32
29
|
@税額 = 税額計算
|
33
30
|
@均等割 = @税額.dig(:kenmin, :kintou)
|
@@ -61,19 +58,42 @@ module Luca
|
|
61
58
|
}
|
62
59
|
}
|
63
60
|
else
|
61
|
+
@company = CGI.escapeHTML(config.dig('company', 'name'))
|
62
|
+
@form_vers = proc_version
|
63
|
+
@jichitai_code = report_cfg['jichitai_code']
|
64
|
+
@jimusho_code = report_cfg['jimusho_code']
|
65
|
+
@jimusho_name = report_cfg['jimusho_name']
|
66
|
+
@kanri_bango = report_cfg['x_houjin_bango']
|
67
|
+
@app_version = report_cfg['app_version']
|
68
|
+
@address = report_cfg['address'] || it_part_config('nozeisha_adr')
|
64
69
|
@procedure_code = 'R0102100'
|
65
70
|
@procedure_name = '法人都道府県民税・事業税・特別法人事業税又は地方法人特別税 確定申告'
|
66
|
-
@form_sec =
|
71
|
+
@form_sec = case @report_category
|
72
|
+
when 'prefecture'
|
73
|
+
["R0102AA#{@form_vers['R0102AA']}", 別表九フォーム]
|
74
|
+
.compact.map{ |c| form_attr(c) }.join('')
|
75
|
+
when '23ku'
|
76
|
+
["R0102AA#{@form_vers['R0102AA']}", "R0102AG120", 別表九フォーム]
|
77
|
+
.compact.map{ |c| form_attr(c) }.join('')
|
78
|
+
when 'city'
|
79
|
+
# TODO: implement
|
80
|
+
end
|
67
81
|
@user_inf = render_erb(search_template('eltax-userinf.xml.erb'))
|
68
|
-
@form_data =
|
82
|
+
@form_data = case @report_category
|
83
|
+
when 'prefecture'
|
84
|
+
[第六号, 別表九].compact.join("\n")
|
85
|
+
when '23ku'
|
86
|
+
[第六号, 別表四三, 別表九].compact.join("\n")
|
87
|
+
when 'city'
|
88
|
+
# TODO: implement
|
89
|
+
end
|
69
90
|
render_erb(search_template('eltax.xml.erb'))
|
70
91
|
end
|
71
92
|
end
|
72
93
|
|
73
|
-
def export_json
|
74
|
-
records = kani(export: true)
|
75
|
-
|
76
|
-
item = {}
|
94
|
+
def export_json(report_cfg)
|
95
|
+
records = kani(report_cfg, export: true)
|
96
|
+
{}.tap do |item|
|
77
97
|
item['date'] = @end_date
|
78
98
|
item['debit'] = []
|
79
99
|
item['credit'] = []
|
@@ -100,13 +120,12 @@ module Luca
|
|
100
120
|
item['debit'] << { 'label' => '法人税、住民税及び事業税', 'amount' => dat[:zeigaku] } if dat[:zeigaku] > 0
|
101
121
|
end
|
102
122
|
item['x-editor'] = 'LucaJp'
|
103
|
-
res << item
|
104
|
-
puts JSON.dump(res)
|
105
123
|
end
|
106
124
|
end
|
107
125
|
|
108
126
|
def 第六号
|
109
|
-
@資本金準備金 =
|
127
|
+
@資本金準備金 = readable(['911', '9131'].map { |cd| @bs_data.dig(cd) }.compact.sum)
|
128
|
+
STDERR.puts "第六号様式: 「決算確定の日」「国外関連者」などの追記が必要"
|
110
129
|
render_erb(search_template('el-no6.xml.erb'))
|
111
130
|
end
|
112
131
|
|
data/lib/luca/jp/common.rb
CHANGED
@@ -74,11 +74,12 @@ module Luca
|
|
74
74
|
|
75
75
|
# 税引前当期利益をもとに計算
|
76
76
|
# 消費税を租税公課に計上している場合、控除済みの金額
|
77
|
-
#
|
77
|
+
# 事業税は仮払経理の場合にも納付時損金/還付時益金
|
78
78
|
#
|
79
79
|
def 当期所得金額
|
80
80
|
_, 納付事業税 = 未納事業税期中増減
|
81
|
-
|
81
|
+
事業税中間納付 = prepaid_tax('1854') + prepaid_tax('1855') + prepaid_tax('1856') + prepaid_tax('1857') + prepaid_tax('1858')
|
82
|
+
LucaSupport::Code.readable(@pl_data.dig('GA') - 納付事業税 - 事業税中間納付 + 還付事業税)
|
82
83
|
end
|
83
84
|
|
84
85
|
# -----------------------------------------------------
|
@@ -112,11 +113,23 @@ module Luca
|
|
112
113
|
# -----------------------------------------------------
|
113
114
|
|
114
115
|
def 均等割
|
115
|
-
if
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
116
|
+
tax = if 地方税資本金等の額 <= 10_000_000
|
117
|
+
city = @employee > 50 ? 120_000 : 50_000
|
118
|
+
[20_000, city]
|
119
|
+
elsif 地方税資本金等の額 <= 100_000_000
|
120
|
+
city = @employee > 50 ? 150_000 : 130_000
|
121
|
+
[50_000, city]
|
122
|
+
elsif 地方税資本金等の額 <= 1_000_000_000
|
123
|
+
city = @employee > 50 ? 400_000 : 160_000
|
124
|
+
[130_000, city]
|
125
|
+
elsif 地方税資本金等の額 <= 5_000_000_000
|
126
|
+
city = @employee > 50 ? 1_750_000 : 410_000
|
127
|
+
[540_000, city]
|
128
|
+
else
|
129
|
+
city = @employee > 50 ? 3_000_000 : 410_000
|
130
|
+
[800_000, city]
|
131
|
+
end
|
132
|
+
tokyo23? ? [tax.sum, 0] : tax
|
120
133
|
end
|
121
134
|
|
122
135
|
# 100円未満切り捨て
|
@@ -126,11 +139,30 @@ module Luca
|
|
126
139
|
else
|
127
140
|
法人税割課税標準
|
128
141
|
end
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
142
|
+
税率 = 法人税割税率(課税標準)
|
143
|
+
[
|
144
|
+
(課税標準 * 税率[0] / 100 / 100).floor * 100,
|
145
|
+
(課税標準 * 税率[1] / 100 / 100).floor * 100
|
146
|
+
]
|
147
|
+
end
|
148
|
+
|
149
|
+
def 法人税割税率(法人税 = nil)
|
150
|
+
課税標準 = if 法人税
|
151
|
+
(法人税 / 1000).floor * 1000
|
152
|
+
else
|
153
|
+
法人税割課税標準
|
154
|
+
end
|
155
|
+
rate = if 期末資本金 > 100_000_000 || 課税標準 > 10_000_000
|
156
|
+
[2.0, 8.4]
|
157
|
+
else
|
158
|
+
[1.0, 6.0]
|
159
|
+
end
|
160
|
+
tokyo23? ? [rate.sum, 0] : rate
|
161
|
+
end
|
162
|
+
|
163
|
+
# 100円未満切り捨て
|
164
|
+
def 所得割400万以下(所得 = nil)
|
165
|
+
((所得400万以下(所得) * 所得割税率400万以下(所得) / 100) / 100).floor * 100
|
134
166
|
end
|
135
167
|
|
136
168
|
def 所得400万以下(所得 = nil)
|
@@ -144,9 +176,18 @@ module Luca
|
|
144
176
|
end
|
145
177
|
end
|
146
178
|
|
179
|
+
def 所得割税率400万以下(所得 = nil)
|
180
|
+
所得 ||= 所得金額
|
181
|
+
if 期末資本金 > 100_000_000 || 所得 > 25_000_000
|
182
|
+
軽減税率不適用法人 ? 7.48 : 3.75
|
183
|
+
else
|
184
|
+
軽減税率不適用法人 ? 7.0 : 3.5
|
185
|
+
end
|
186
|
+
end
|
187
|
+
|
147
188
|
# 100円未満切り捨て
|
148
|
-
def 所得割
|
149
|
-
((所得
|
189
|
+
def 所得割800万以下(所得 = 0)
|
190
|
+
((所得800万以下(所得) * 所得割税率800万以下(所得) / 100) / 100).floor * 100
|
150
191
|
end
|
151
192
|
|
152
193
|
def 所得800万以下(所得 = nil)
|
@@ -162,9 +203,18 @@ module Luca
|
|
162
203
|
end
|
163
204
|
end
|
164
205
|
|
206
|
+
def 所得割税率800万以下(所得 = nil)
|
207
|
+
所得 ||= 所得金額
|
208
|
+
if 期末資本金 > 100_000_000 || 所得 > 25_000_000
|
209
|
+
軽減税率不適用法人 ? 7.48 : 5.665
|
210
|
+
else
|
211
|
+
軽減税率不適用法人 ? 7.0 : 5.3
|
212
|
+
end
|
213
|
+
end
|
214
|
+
|
165
215
|
# 100円未満切り捨て
|
166
|
-
def 所得割800
|
167
|
-
((所得800
|
216
|
+
def 所得割800万超(所得 = 0)
|
217
|
+
((所得800万超(所得) * 所得割税率800万超(所得) / 100) / 100).floor * 100
|
168
218
|
end
|
169
219
|
|
170
220
|
def 所得800万超(所得 = nil)
|
@@ -178,9 +228,13 @@ module Luca
|
|
178
228
|
end
|
179
229
|
end
|
180
230
|
|
181
|
-
|
182
|
-
|
183
|
-
|
231
|
+
def 所得割税率800万超(所得 = nil)
|
232
|
+
所得 ||= 所得金額
|
233
|
+
if 期末資本金 > 100_000_000 || 所得 > 25_000_000
|
234
|
+
7.48
|
235
|
+
else
|
236
|
+
7.0
|
237
|
+
end
|
184
238
|
end
|
185
239
|
|
186
240
|
# 100円未満切り捨て
|
@@ -234,7 +288,15 @@ module Luca
|
|
234
288
|
# :section: 外形標準の計算
|
235
289
|
# -----------------------------------------------------
|
236
290
|
def 資本金等の額
|
237
|
-
readable(
|
291
|
+
readable(['911', '913', '916'].map { |cd| @bs_data.dig(cd) }.compact.sum)
|
292
|
+
end
|
293
|
+
|
294
|
+
def 地方税資本金等の額
|
295
|
+
[資本金等の額, readable(['911', '9131'].map { |cd| @bs_data.dig(cd) }.compact.sum)].max
|
296
|
+
end
|
297
|
+
|
298
|
+
def 軽減税率不適用法人
|
299
|
+
期末資本金 > 10_000_000 && eltax_config('no_keigen')
|
238
300
|
end
|
239
301
|
|
240
302
|
def 期末資本金
|
@@ -7,10 +7,12 @@
|
|
7
7
|
<VAA00040 IDREF="NOZEISHA_NM"/>
|
8
8
|
</VAA00000>
|
9
9
|
<VAB00000>
|
10
|
+
<%= render_attr('VAB00005', beppyo2_config('own_shares')) %>
|
10
11
|
<%= render_attr('VAB00010', beppyo2_config('total_shares')) %>
|
11
12
|
<%= render_attr('VAB00020', 別表二上位株数) %>
|
12
13
|
<%= render_attr('VAB00030', 別表二上位株割合) %>
|
13
14
|
<VAB00040>
|
15
|
+
<%= render_attr('VAB00050', beppyo2_config('no_votes')) %>
|
14
16
|
<%= render_attr('VAB00060', beppyo2_config('total_votes')) %>
|
15
17
|
</VAB00040>
|
16
18
|
<%= render_attr('VAB00070', 別表二上位議決権数) %>
|
@@ -7,82 +7,107 @@
|
|
7
7
|
<ARA00040 IDREF="NOZEISHA_NM"/>
|
8
8
|
</ARA00000>
|
9
9
|
<ARB00000>
|
10
|
-
|
11
|
-
|
10
|
+
<% ['ARB00010', 'ARB00020'].each do |code| %>
|
11
|
+
<%= render_attr(code, @当期純損益) %>
|
12
|
+
<% end %>
|
12
13
|
</ARB00000>
|
13
14
|
<ARC00000>
|
14
15
|
<ARC00010>
|
15
|
-
|
16
|
-
|
16
|
+
<% ['ARC00020', 'ARC00030'].each do |code| %>
|
17
|
+
<%= render_attr(code, 法人税損金納付額 + 法人税仮払納付額) %>
|
18
|
+
<% end %>
|
17
19
|
</ARC00010>
|
18
20
|
<ARC00040>
|
19
|
-
|
20
|
-
|
21
|
+
<% ['ARC00050', 'ARC00060'].each do |code| %>
|
22
|
+
<%= render_attr(code, [都道府県民税損金納付, 市民税損金納付, 都道府県民税仮払納付, 市民税仮払納付].compact.sum) %>
|
23
|
+
<% end %>
|
21
24
|
</ARC00040>
|
22
25
|
<ARC00100>
|
23
|
-
|
24
|
-
|
26
|
+
<% ['ARC00110', 'ARC00120'].each do |code| %>
|
27
|
+
<%= render_attr(code, (@法人税等 - [法人税損金納付額, 都道府県民税損金納付, 市民税損金納付, 事業税損金納付].compact.sum)) %>
|
28
|
+
<% end %>
|
25
29
|
</ARC00100>
|
26
30
|
<%= 別表四還付事業税 %>
|
27
31
|
<% if (@当期還付法人税 + @当期還付都道府県住民税 + @当期還付市民税) > 0 %>
|
28
32
|
<ARC00220>
|
29
33
|
<%= render_attr('ARC00230', '前期仮払税金否認') %>
|
30
|
-
|
31
|
-
|
34
|
+
<% ['ARC00240', 'ARC00250'].each do |code| %>
|
35
|
+
<%= render_attr(code, [@当期還付法人税, @当期還付都道府県住民税, @当期還付市民税].compact.sum) %>
|
36
|
+
<% end %>
|
32
37
|
</ARC00220>
|
33
38
|
<% end %>
|
34
39
|
<ARC00325>
|
35
|
-
|
36
|
-
|
40
|
+
<% ['ARC00330', 'ARC00340'].each do |code| %>
|
41
|
+
<%= render_attr(code, [@法人税等, @当期還付事業税, 法人税仮払納付額, 都道府県民税仮払納付, 市民税仮払納付].compact.sum) %>
|
42
|
+
<% end %>
|
37
43
|
</ARC00325>
|
38
44
|
</ARC00000>
|
39
45
|
<ARD00000>
|
40
46
|
<ARD00040>
|
41
|
-
|
42
|
-
|
47
|
+
<% ['ARD00050', 'ARD00060'].each do |code| %>
|
48
|
+
<%= render_attr(code, @納付事業税) %>
|
49
|
+
<% end %>
|
43
50
|
</ARD00040>
|
44
51
|
<ARD00100>
|
45
|
-
|
46
|
-
|
52
|
+
<% ['ARD00110', 'ARD00120'].each do |code| %>
|
53
|
+
<%= render_attr(code, [@当期還付法人税, @当期還付都道府県住民税, @当期還付市民税].compact.sum) %>
|
54
|
+
<% end %>
|
47
55
|
</ARD00100>
|
48
56
|
<% if (法人税仮払納付額 + 都道府県民税仮払納付 + 市民税仮払納付) > 0 %>
|
49
57
|
<ARD00215>
|
50
58
|
<%= render_attr('ARD00220', '仮払税金認定損') %>
|
51
|
-
|
52
|
-
|
59
|
+
<% ['ARD00230', 'ARD00240'].each do |code| %>
|
60
|
+
<%= render_attr(code, [法人税仮払納付額, 都道府県民税仮払納付, 市民税仮払納付].compact.sum) %>
|
61
|
+
<% end %>
|
62
|
+
</ARD00215>
|
63
|
+
<% end %>
|
64
|
+
<% if @翌期還付事業税 > 0 %>
|
65
|
+
<ARD00215>
|
66
|
+
<%= render_attr('ARD00220', '仮払事業税認定損') %>
|
67
|
+
<% ['ARD00230', 'ARD00240'].each do |code| %>
|
68
|
+
<%= render_attr(code, @翌期還付事業税) %>
|
69
|
+
<% end %>
|
53
70
|
</ARD00215>
|
54
71
|
<% end %>
|
55
72
|
<ARD00280>
|
56
|
-
|
57
|
-
|
73
|
+
<% ['ARD00290', 'ARD00300'].each do |code| %>
|
74
|
+
<%= render_attr(code, [@納付事業税, @翌期還付事業税, 法人税仮払納付額, 都道府県民税仮払納付, 市民税仮払納付].compact.sum) %>
|
75
|
+
<% end %>
|
58
76
|
</ARD00280>
|
59
77
|
</ARD00000>
|
60
78
|
<ARE00000>
|
61
|
-
|
62
|
-
|
79
|
+
<% ['ARE00010', 'ARE00020'].each do |code| %>
|
80
|
+
<%= render_attr(code, @別表四調整所得) %>
|
81
|
+
<% end %>
|
63
82
|
</ARE00000>
|
64
83
|
<ARZ10000>
|
65
|
-
|
66
|
-
|
84
|
+
<% ['ARZ10010', 'ARZ10020'].each do |code| %>
|
85
|
+
<%= render_attr(code, @別表四調整所得) %>
|
86
|
+
<% end %>
|
67
87
|
</ARZ10000>
|
68
88
|
<ARK00000>
|
69
|
-
|
70
|
-
|
89
|
+
<% ['ARK00010', 'ARK00020'].each do |code| %>
|
90
|
+
<%= render_attr(code, @別表四調整所得) %>
|
91
|
+
<% end %>
|
71
92
|
</ARK00000>
|
72
93
|
<ARM00000>
|
73
|
-
|
74
|
-
|
94
|
+
<% ['ARM00010', 'ARM00020'].each do |code| %>
|
95
|
+
<%= render_attr(code, @別表四調整所得) %>
|
96
|
+
<% end %>
|
75
97
|
</ARM00000>
|
76
98
|
<ARS00000>
|
77
|
-
|
78
|
-
|
99
|
+
<% ['ARS00010', 'ARS00020'].each do |code| %>
|
100
|
+
<%= render_attr(code, @別表四調整所得) %>
|
101
|
+
<% end %>
|
79
102
|
</ARS00000>
|
80
103
|
<ART00000>
|
81
|
-
|
82
|
-
|
104
|
+
<% ['ART00010', 'ART00020'].each do |code| %>
|
105
|
+
<%= render_attr(code, @繰越損失管理.deduction) %>
|
106
|
+
<% end %>
|
83
107
|
</ART00000>
|
84
108
|
<ARV00000>
|
85
|
-
|
86
|
-
|
109
|
+
<% ['ARV00010', 'ARV00020'].each do |code| %>
|
110
|
+
<%= render_attr(code, @別表四調整所得 - @繰越損失管理.deduction) %>
|
111
|
+
<% end %>
|
87
112
|
</ARV00000>
|
88
113
|
</HOA420>
|
@@ -8,9 +8,9 @@
|
|
8
8
|
<gen:yyyymmdd></gen:yyyymmdd>
|
9
9
|
</AGA_JIGYO_EDATE>
|
10
10
|
<AGA_NAME idref="NAME"></AGA_NAME>
|
11
|
-
<AGB00100><%= @
|
11
|
+
<AGB00100><%= @address %></AGB00100>
|
12
12
|
<AGB00200>12</AGB00200>
|
13
|
-
<AGB00300
|
13
|
+
<AGB00300><%= @employee %></AGB00300>
|
14
14
|
<AGC00100 />
|
15
15
|
<AGC00110 />
|
16
16
|
<AGC00120 />
|
@@ -132,16 +132,17 @@
|
|
132
132
|
<AGE00710 />
|
133
133
|
<AGE00800 />
|
134
134
|
<AGE00900 />
|
135
|
-
<AGF00100
|
135
|
+
<AGF00100><%= @均等割 if @employee > 50 %></AGF00100>
|
136
136
|
<AGF00200 />
|
137
137
|
<AGF00300 />
|
138
|
-
<AGF00400
|
139
|
-
<AGF00500
|
140
|
-
<
|
138
|
+
<AGF00400><%= "12" if @employee > 50 %></AGF00400>
|
139
|
+
<AGF00500><%= @均等割 if @employee > 50 %></AGF00500>
|
140
|
+
<AGF00200 />
|
141
|
+
<AGF00600><%= @均等割 if @employee <= 50 %></AGF00600>
|
141
142
|
<AGF00700 />
|
142
143
|
<AGF00800 />
|
143
|
-
<AGF00900
|
144
|
-
<AGF01000
|
144
|
+
<AGF00900><%= "12" if @employee <= 50 %></AGF00900>
|
145
|
+
<AGF01000><%= @均等割 if @employee <= 50 %></AGF01000>
|
145
146
|
<AGF01100 />
|
146
147
|
<AGF01200 />
|
147
148
|
<AGF01300 />
|
@@ -173,6 +174,6 @@
|
|
173
174
|
<AGF03900 />
|
174
175
|
<AGF04000 />
|
175
176
|
<AGF04100 />
|
176
|
-
<AGF04200
|
177
|
+
<AGF04200><%= @均等割 %></AGF04200>
|
177
178
|
<AGG00100 />
|
178
179
|
</R0102AG120>
|
@@ -43,7 +43,7 @@
|
|
43
43
|
<AAA_SHIHON4></AAA_SHIHON4>
|
44
44
|
<AAA_SHIHON2><%= 資本金等の額 %></AAA_SHIHON2>
|
45
45
|
<AAA_SHIHON5><%= @資本金準備金 %></AAA_SHIHON5>
|
46
|
-
<AAA_SHIHON6><%=
|
46
|
+
<AAA_SHIHON6><%= 地方税資本金等の額 %></AAA_SHIHON6>
|
47
47
|
<AAA_JIGYO_SDATE idref="SDATE">
|
48
48
|
<gen:era></gen:era>
|
49
49
|
<gen:yy></gen:yy>
|
@@ -67,7 +67,7 @@
|
|
67
67
|
<AAB00500 />
|
68
68
|
<AAB00600><%= 法人税割課税標準 %></AAB00600>
|
69
69
|
<AAB00700 />
|
70
|
-
<AAB00800
|
70
|
+
<AAB00800><%= 法人税割税率[0] unless tokyo23? %></AAB00800>
|
71
71
|
<AAB00810><%= 法人税割[0] %></AAB00810>
|
72
72
|
<AAB00820 />
|
73
73
|
<AAB00850 />
|
@@ -85,21 +85,21 @@
|
|
85
85
|
<AAB02100><%= 納付税額(@確定法人税割, @法人税割中間納付) + 納付税額(@均等割, @均等割中間納付) %></AAB02100>
|
86
86
|
<AAB02200 />
|
87
87
|
<AAB02300><%= 納付税額(@確定法人税割, @法人税割中間納付) + 納付税額(@均等割, @均等割中間納付) %></AAB02300>
|
88
|
-
<AAC00100><%= 法人税割課税標準 %></AAC00100>
|
89
|
-
<AAC00200
|
90
|
-
<AAC00210><%= 法人税割[0] %></AAC00210>
|
88
|
+
<AAC00100><%= 法人税割課税標準 if tokyo23? %></AAC00100>
|
89
|
+
<AAC00200><%= 法人税割税率[0] if tokyo23? %></AAC00200>
|
90
|
+
<AAC00210><%= 法人税割[0] if tokyo23? %></AAC00210>
|
91
91
|
<AAC00300 />
|
92
92
|
<AAC00400 />
|
93
93
|
<AAC00410 />
|
94
94
|
<AAE00100><%= 所得金額 %></AAE00100>
|
95
95
|
<AAE00200><%= 所得400万以下 %></AAE00200>
|
96
|
-
<AAE00210
|
96
|
+
<AAE00210><%= 所得割税率400万以下 %></AAE00210>
|
97
97
|
<AAE00220><%= 所得割400万以下 %></AAE00220>
|
98
98
|
<AAE00300><%= 所得800万以下 %></AAE00300>
|
99
|
-
<AAE00310
|
99
|
+
<AAE00310><%= 所得割税率800万以下 %></AAE00310>
|
100
100
|
<AAE00320><%= 所得割800万以下 %></AAE00320>
|
101
101
|
<AAE00400><%= 所得800万超 %></AAE00400>
|
102
|
-
<AAE00410
|
102
|
+
<AAE00410><%= 所得割税率800万超 %></AAE00410>
|
103
103
|
<AAE00420><%= 所得割800万超 %></AAE00420>
|
104
104
|
<AAE00500><%= 所得400万以下 + 所得800万以下 + 所得800万超 %></AAE00500>
|
105
105
|
<%= render_attr('AAE00510', @所得割) %>
|
@@ -4,7 +4,7 @@
|
|
4
4
|
<KOUSEI_KANRI id="KOUSEI_KANRI">
|
5
5
|
<KANRI_INF id="KANRI_INF">
|
6
6
|
<KOUSEI_KANRI_VR>0001</KOUSEI_KANRI_VR><%# 固定値 %>
|
7
|
-
<ORG1_CD
|
7
|
+
<ORG1_CD><%= @jichitai_code %></ORG1_CD><%# 地方公共団体コード %>
|
8
8
|
<PROC_ID><%= @procedure_code %></PROC_ID>
|
9
9
|
<PROC_NAME><%= @procedure_name %></PROC_NAME>
|
10
10
|
<FIRST_RCPT_NUM></FIRST_RCPT_NUM>
|
@@ -74,7 +74,7 @@
|
|
74
74
|
<KAZEI_TEL id="KAZEI_TEL" />
|
75
75
|
<HOGEN_NUM id="HOGEN_NUM" />
|
76
76
|
<KANRI_NUM id="KANRI_NUM" />
|
77
|
-
<KAZEI_NUM id="KAZEI_NUM"><%=
|
77
|
+
<KAZEI_NUM id="KAZEI_NUM"><%= @kanri_bango %></KAZEI_NUM>
|
78
78
|
<HOJO_NUM id="HOJO_NUM" />
|
79
79
|
<STF_NUM id="STF_NUM" />
|
80
80
|
</ORG_INF>
|
@@ -81,6 +81,10 @@
|
|
81
81
|
<%= render_attr('IAT01200', gaikyo_config('ec_shiire') ? '<kubun_CD>1</kubun_CD>' : nil) %>
|
82
82
|
<%= render_attr('IAT01300', gaikyo_config('ec_keihi') ? '<kubun_CD>1</kubun_CD>' : nil) %>
|
83
83
|
</IAT01000>
|
84
|
+
<IAT01500>
|
85
|
+
<%= render_attr('IAT01600', gaikyo_config('ec_jisha') ? '<kubun_CD>1</kubun_CD>' : nil) %>
|
86
|
+
<%= render_attr('IAT01700', gaikyo_config('ec_tasha') ? '<kubun_CD>1</kubun_CD>' : nil) %>
|
87
|
+
</IAT01500>
|
84
88
|
</IAT00000>
|
85
89
|
<IAF00000>
|
86
90
|
<IAF01000>
|
data/lib/luca/jp/uchiwake.rb
CHANGED
@@ -57,7 +57,7 @@ module Luca #:nodoc:
|
|
57
57
|
h[k][:name] = metadata['name'][0..9] if metadata['name']
|
58
58
|
h[k][:security_purpose] = metadata['security_purpose']
|
59
59
|
h[k][:security_genre] = metadata['security_genre']
|
60
|
-
h[k][:security_units] = (h[:amount].nil? || h[:amount].zero?) ? 0 : metadata['security_units']
|
60
|
+
h[k][:security_units] = (h[k][:amount].nil? || h[k][:amount].zero?) ? 0 : metadata['security_units']
|
61
61
|
h[k][:note] = metadata['note']
|
62
62
|
end
|
63
63
|
h[k][:security_purpose] ||= 'その他' if /^332/.match(k.to_s)
|
data/lib/luca/jp/util.rb
CHANGED
data/lib/luca/jp/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: luca-jp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chuma Takahiro
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-03-
|
11
|
+
date: 2022-03-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: lucabook
|