|
@@ -170,13 +170,19 @@ func (b *PurchaseBillExcel) drawTableTitle() error {
|
|
|
|
|
|
drawCol2("C", "D", "尺寸(mm)", "长", "宽")
|
|
|
drawCol2("C", "D", "尺寸(mm)", "长", "宽")
|
|
|
- unit1 := "元/张"
|
|
|
- unit2 := "元/吨"
|
|
|
+ unit1 := "-"
|
|
|
+ unit2 := "-"
|
|
|
if len(b.Content.Paper) > 0 {
|
|
|
if b.Content.Paper[0].PriceUnit != "" {
|
|
|
unit1 = b.Content.Paper[0].PriceUnit
|
|
|
+ } else if b.Content.Paper[0].Price2Unit != "" {
|
|
|
+ unit2 = b.Content.Paper[0].Price2Unit
|
|
|
+ } else {
|
|
|
+ unit1 = "元/张"
|
|
|
+ unit2 = "元/吨"
|
|
|
}
|
|
|
- if b.Content.Paper[0].Price2Unit != "" {
|
|
|
+ if b.Content.Paper[0].PriceUnit != "" && b.Content.Paper[0].Price2Unit != "" {
|
|
|
+ unit1 = b.Content.Paper[0].PriceUnit
|
|
|
unit2 = b.Content.Paper[0].Price2Unit
|
|
|
}
|
|
|
}
|