diff --git a/app/documents/group_order_invoice_pdf.rb b/app/documents/group_order_invoice_pdf.rb index 1df35686..f69c36c9 100644 --- a/app/documents/group_order_invoice_pdf.rb +++ b/app/documents/group_order_invoice_pdf.rb @@ -112,6 +112,7 @@ class GroupOrderInvoicePdf < RenderPdf table.cells.border_color = '666666' table.row(0).column(0..4).width = 80 + table.row(0).column(0).width = 180 table.row(0).border_bottom_width = 2 table.columns(1).align = :right table.columns(1..6).align = :right @@ -131,6 +132,7 @@ class GroupOrderInvoicePdf < RenderPdf table.row(0..-1).columns(0..1).border_width = 0 table.rows(0..-1).columns(0..4).width = 80 + table.row(0).column(0).width = 180 table.row(0).column(-1).style(font_style: :bold) table.row(0).column(-2).style(font_style: :bold) table.row(0).column(-1).size = fontsize(10) @@ -228,7 +230,11 @@ class GroupOrderInvoicePdf < RenderPdf table.cells.border_width = 1 table.cells.border_color = '666666' table.row(0).columns(0..6).style(background_color: 'cccccc', font_style: :bold) - table.rows(0..-1).columns(0..6).width = 80 + table.rows(0..-1).columns(2..6).width = 80 + table.rows(0..-1).column(0).width = 160 + table.rows(0..-1).column(1).width = 40 + table.rows(0..-1).column(4).width = 60 + table.rows(0..-1).column(5).width = 90 table.row(0).border_bottom_width = 2 table.columns(1).align = :right table.columns(1..6).align = :right @@ -278,9 +284,14 @@ class GroupOrderInvoicePdf < RenderPdf table.cells.border_color = '666666' table.row(0).columns(2..6).style(align: :bottom) table.row(0).border_bottom_width = 2 - table.row(0..-1).columns(0..1).border_width = 0 + table.row(0..-1).columns(0).border_width = 0 + table.row(0..-1).columns(1).border_width = 0 if marge <= 0 + table.rows(0..-1).columns(2..6).width = 80 + table.rows(0..-1).column(0).width = 100 + table.rows(0..-1).column(1).width = 100 + table.rows(0..-1).column(4).width = 60 + table.rows(0..-1).column(5).width = 90 - table.rows(0..-1).columns(0..6).width = 80 table.row(-1).column(-1).style(font_style: :bold) table.row(-1).column(-2).style(font_style: :bold) table.row(-1).column(-1).size = fontsize(10)