PurCkStatisti.cs 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using CoreFS.CA06;using Pur.Entity;
  10. using Pur.Entity.ck;
  11. using Pur.require_plan;
  12. using Pur.Entity.configureEntity;
  13. using com.hnshituo.pur.vo;
  14. using Core.Mes.Client.Comm.Control;
  15. using Infragistics.Win;
  16. using Pur.Entity;
  17. namespace Pur.ck
  18. {
  19. public partial class PurCkStatisti : FrmPmsBase
  20. {
  21. public PurCkStatisti()
  22. {
  23. InitializeComponent();
  24. ultraGrid1.DisplayLayout.Bands[0].Override.AllowUpdate = DefaultableBoolean.False;
  25. }
  26. //菜单按钮事件
  27. public override void ToolBar_Click(object sender, string ToolbarKey)
  28. {
  29. switch (ToolbarKey)
  30. {
  31. case "Query":
  32. GetPUR_CK_STATISTICS();
  33. break;
  34. }
  35. }
  36. /// <summary>
  37. /// 查询
  38. /// </summary>
  39. private void GetPUR_CK_STATISTICS()
  40. {
  41. CkStatistics CkSa = new CkStatistics();
  42. //CkSa.InvLogic = txt_invLogic.Text;
  43. CkSa.ItemCode = txt_itemCode.Text;
  44. CkSa.ItemName = txt_itemName.Text;
  45. DataTable dt = this.execute<DataTable>("com.hnshituo.pur.ck.service.CkStatisticsService", "find_Stat", new object[] { CkSa });
  46. GridHelper.CopyDataToDatatable(dt, dataTable1, true);
  47. }
  48. private void ultraPanel1_PaintClient(object sender, PaintEventArgs e)
  49. {
  50. }
  51. /// <summary>
  52. /// 物料弹窗
  53. /// </summary>
  54. /// <param name="sender"></param>
  55. /// <param name="e"></param>
  56. private void txt_itemCode_EditorButtonClick(object sender, Infragistics.Win.UltraWinEditors.EditorButtonEventArgs e)
  57. {
  58. FrmPurPlanMat mat = new FrmPurPlanMat(this.ob);
  59. mat.ShowDialog();
  60. if (mat.getItemCode().ToString() == null)
  61. {
  62. return;
  63. }
  64. txt_itemCode.Text = mat.getItemCode().ToString();
  65. txt_itemName.Text = mat.getItemName().ToString();
  66. }
  67. /// <summary>
  68. ///界面加载,下拉框加载
  69. /// </summary>
  70. /// <param name="sender"></param>
  71. /// <param name="e"></param>
  72. private void PurCkStatisti_Load(object sender, EventArgs e)
  73. {
  74. LogicWareHouseEntity lhouse = new LogicWareHouseEntity();
  75. lhouse.Validflag = "1";
  76. DataTable dt = this.execute<DataTable>("com.hnshituo.pur.configure.service.LogicSeatService", "getLogicSeat", new object[] { lhouse, 0, 0 });
  77. if (dt.Rows.Count > 0)
  78. {
  79. txt_invLogic.DataSource = dt;
  80. this.txt_invLogic.DisplayMember = "invLogicName";
  81. this.txt_invLogic.ValueMember = "invLogic";
  82. }
  83. //PhysicSeatEntity Phouse = new PhysicSeatEntity();
  84. //Phouse.Validflag = "1";
  85. //DataTable dt1 = this.execute<DataTable>("com.hnshituo.pur.configure.service.ActualSeatService", "getActualSeat", new object[] { Phouse, 0, 0 });
  86. //if (dt1.Rows.Count > 0)
  87. //{
  88. // txt_invPhysic.DataSource = dt1;
  89. // this.txt_invPhysic.DisplayMember = "invPhysicName";
  90. // this.txt_invPhysic.ValueMember = "invPhysic";
  91. //}
  92. //ActualSeatPosEntity PosEntity = new ActualSeatPosEntity();
  93. //PosEntity.Validflag = "1";
  94. //DataTable dt3 = this.execute<DataTable>("com.hnshituo.pur.configure.service.ActualSeatPosService", "find", new object[] { PosEntity, 0, 0 });
  95. //if (dt3.Rows.Count > 0)
  96. //{
  97. // txt_invBin.DataSource = dt3;
  98. // this.txt_invBin.DisplayMember = "invPosName";
  99. // this.txt_invBin.ValueMember = "invPos";
  100. //}
  101. GetPUR_CK_STATISTICS();
  102. }
  103. }
  104. }