fix: 与旧版filenums保持一致
This commit is contained in:
parent
8cd17a42f3
commit
42171cba21
|
@ -1,7 +1,7 @@
|
|||
if params[:filepath].present?
|
||||
json.partial! "api/v1/projects/simple_gitea_diff_detail", diff: @result_object
|
||||
else
|
||||
json.file_numbers @result_object[:total_data]
|
||||
json.file_numbers @result_object[:total_data].to_i
|
||||
json.total_addition @result_object[:data]["total_addition"]
|
||||
json.total_deletion @result_object[:data]["total_deletion"]
|
||||
json.files @result_object[:data]["files"] do |file|
|
||||
|
|
|
@ -12,7 +12,7 @@ if params[:filepath].present?
|
|||
end
|
||||
end
|
||||
else
|
||||
json.file_numbers @compare_result[:total_data].to_i
|
||||
json.file_nums @compare_result[:total_data].to_i
|
||||
json.total_addition @compare_result[:data]["total_addition"]
|
||||
json.total_deletion @compare_result[:data]["total_deletion"]
|
||||
json.files @compare_result[:data]["files"] do |file|
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
if params[:filepath].present?
|
||||
json.partial! "api/v1/projects/simple_gitea_diff_detail", diff: @result_object
|
||||
else
|
||||
json.file_numbers @result_object[:total_data]
|
||||
json.file_nums @result_object[:total_data].to_i
|
||||
json.total_addition @result_object[:data]["total_addition"]
|
||||
json.total_deletion @result_object[:data]["total_deletion"]
|
||||
json.files @result_object[:data]["files"] do |file|
|
||||
|
|
Loading…
Reference in New Issue