You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
2.0 KiB

3 weeks ago
  1. using NFine.Application.WMS;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Data;
  5. using System.IO;
  6. using System.Linq;
  7. using System.Web;
  8. using System.Web.Mvc;
  9. using NFine.Code;
  10. using System.Data.SqlClient;
  11. using NFine.Data.Extensions;
  12. using System.Data.OleDb;
  13. using System.Configuration;
  14. using ICS.Application.Entity;
  15. namespace NFine.Web.Areas.WMS.Controllers
  16. {
  17. public class ICSLotFreezeDHController : ControllerBase
  18. {
  19. ICSLotFreezeDHApp App = new ICSLotFreezeDHApp();
  20. // GET: WMS/Deciliter
  21. public ActionResult ICSLotFreezeDH()
  22. {
  23. return View();
  24. }
  25. public ActionResult From()
  26. {
  27. return View();
  28. }
  29. [HttpGet]
  30. [HandlerAjaxOnly]
  31. public ActionResult GetNewLotNo(string LotNO)
  32. {
  33. string ListData = App.GetNewLotNo(LotNO);
  34. var data = new
  35. {
  36. rows = ListData,
  37. };
  38. return Content(data.ToJson());
  39. }
  40. [HttpPost]
  41. [HandlerAjaxOnly]
  42. public ActionResult Freeze(string LotNOList, string Memo)
  43. {
  44. string msg = App.Freeze(LotNOList.TrimEnd(','), Memo);
  45. if (!string.IsNullOrEmpty(msg))
  46. {
  47. return Error(msg);
  48. }
  49. else
  50. {
  51. return Success("冻结成功!");
  52. }
  53. }
  54. [HttpPost]
  55. [HandlerAjaxOnly]
  56. public ActionResult UnFreeze(string LotNOList, string Memo)
  57. {
  58. string msg = App.UnFreeze(LotNOList.TrimEnd(','), Memo);
  59. if (!string.IsNullOrEmpty(msg))
  60. {
  61. return Error(msg);
  62. }
  63. else
  64. {
  65. return Success("解除冻结成功!");
  66. }
  67. }
  68. //根据ID获取条码
  69. public ActionResult GetLotNoByID(string ID)
  70. {
  71. DataTable dt = App.GetLotNoByID(ID);
  72. return Content(dt.ToJson());
  73. }
  74. }
  75. }