|
@@ -91,7 +91,7 @@ func (u *InvoiceService) InvoiceAdd(solgan *entity.Invoice, resType string, isLo
|
|
util.Loger.Println("流水号:", solgan.Swno, "开具发票:结果", data)
|
|
util.Loger.Println("流水号:", solgan.Swno, "开具发票:结果", data)
|
|
//开票正常时
|
|
//开票正常时
|
|
//data["returnCode"] = entity.LineUpCode
|
|
//data["returnCode"] = entity.LineUpCode
|
|
- if data["returnCode"] == entity.LineUpCode || data["returnCode"] == entity.SealCode || data["returnCode"] == entity.SuccessCode {
|
|
|
|
|
|
+ if data["returnCode"] == entity.LineUpCode || data["returnCode"] == entity.SealCode || data["returnCode"] == entity.SuccessCode || data["returnCode"] == entity.WaitCode {
|
|
pdfData, code, msg := u.InvoiceDownload(solgan.Swno, solgan.SaleTax, isRed, 0, 0, solgan.Changed, resType, solgan.OrderCode)
|
|
pdfData, code, msg := u.InvoiceDownload(solgan.Swno, solgan.SaleTax, isRed, 0, 0, solgan.Changed, resType, solgan.OrderCode)
|
|
data1 := make(map[string]interface{})
|
|
data1 := make(map[string]interface{})
|
|
data1["fpdm"] = pdfData["fpdm"]
|
|
data1["fpdm"] = pdfData["fpdm"]
|
|
@@ -188,7 +188,7 @@ func (u *InvoiceService) InvoiceDownload(swno string, saleTax string, isRed stri
|
|
pdfData["fphm"] = "Fphm"*/
|
|
pdfData["fphm"] = "Fphm"*/
|
|
pdfData["swno"] = swno
|
|
pdfData["swno"] = swno
|
|
return pdfData, 0, dat.ReturnMsg.Msg
|
|
return pdfData, 0, dat.ReturnMsg.Msg
|
|
- } else if dat.ReturnMsg.MsgCode == entity.LineUpCode || dat.ReturnMsg.MsgCode == entity.SealCode {
|
|
|
|
|
|
+ } else if dat.ReturnMsg.MsgCode == entity.LineUpCode || dat.ReturnMsg.MsgCode == entity.SealCode || dat.ReturnMsg.MsgCode == entity.WaitCode {
|
|
if isLoop == 0 {
|
|
if isLoop == 0 {
|
|
u.Timer(swno, saleTax, isRed, isfeedback, changed, resType, orderCode)
|
|
u.Timer(swno, saleTax, isRed, isfeedback, changed, resType, orderCode)
|
|
}
|
|
}
|
|
@@ -274,7 +274,7 @@ func (u *InvoiceService) InvoiceRedSubmit(fpdm string, fphm string, orderCode st
|
|
}
|
|
}
|
|
util.Loger.Println("冲红:", "发票单号:", fpdm, "发票号码:", fphm, "结果:", data)
|
|
util.Loger.Println("冲红:", "发票单号:", fpdm, "发票号码:", fphm, "结果:", data)
|
|
//data["returnCode"] = entity.LineUpCode
|
|
//data["returnCode"] = entity.LineUpCode
|
|
- if data["returnCode"] == entity.LineUpCode || data["returnCode"] == entity.SealCode || data["returnCode"] == entity.SuccessCode {
|
|
|
|
|
|
+ if data["returnCode"] == entity.LineUpCode || data["returnCode"] == entity.SealCode || data["returnCode"] == entity.SuccessCode || data["returnCode"] == entity.WaitCode {
|
|
pdfData, code, msg := u.InvoiceDownload(data["redSwno"].(string), data["saleTax"].(string), "true", int(0), int(0), changed, resType, orderCode)
|
|
pdfData, code, msg := u.InvoiceDownload(data["redSwno"].(string), data["saleTax"].(string), "true", int(0), int(0), changed, resType, orderCode)
|
|
if fmt.Sprint(code) == "0" {
|
|
if fmt.Sprint(code) == "0" {
|
|
data1 := map[string]interface{}{
|
|
data1 := map[string]interface{}{
|