huangxiaoqiang
2025-11-17 b07472f884708a6bfdf63d999004bbf0bb5f00a8
ÏîÄ¿´úÂë/Print/Print/Print/Controllers/PrintController.cs
@@ -64,7 +64,7 @@
                    TableCell QuantityObj = report.FindObject("Quantity") as TableCell;
                    if (QuantityObj != null)
                    {
                        QuantityObj.Text = inbound.Quantity.ToString();
                        QuantityObj.Text = inbound.Quantity.ToString("0");
                    }
                    TableCell ProductDrawingNumberObj = report.FindObject("ProductDrawingNumber") as TableCell;
                    if (ProductDrawingNumberObj != null)
@@ -81,14 +81,19 @@
                    {
                        WeightObj.Text = inbound.Weight.ToString();
                    }
                    TableCell DemandClassification = report.FindObject("DemandClassification") as TableCell;
                    if (DemandClassification != null)
                    {
                        DemandClassification.Text = inbound.DemandClassification.ToString();
                    }
                    report.Print();
                    report.Dispose();
                }
                return new { code = 200, status = false };
                return new { Code = 200, Status = true , Message = "打印成功" };
            }
            catch (Exception ex)
            {
                return ex.Message;
                return new { Code = 400, Status = false, Message = "打印失败,请查看是否连接打印机" };
            }
        }
@@ -115,11 +120,11 @@
                    report.Print();
                    report.Dispose();
                }
                return new { code = 200, status = false };
                return new { Code = 400, Status = false, Message = "打印成功" };
            }
            catch (Exception ex)
            {
                return ex.Message;
                return new { Code = 400, Status = false, Message = "打印失败,请查看是否连接打印机" };
            }
        }
@@ -127,6 +132,7 @@
        public class InboundOrder
        {
            public string OrderNo { get; set; }
            public string DemandClassification { get; set; }
            public string UpperOrderNo { get; set; }
            public string WarehouseName { get; set; }
            public string MaterialNo { get; set; }