2906 lines
126 KiB
Plaintext
2906 lines
126 KiB
Plaintext
using System;
|
|
using System.Drawing;
|
|
using System.Collections;
|
|
using System.ComponentModel;
|
|
using System.Windows.Forms;
|
|
using GZTW.AyaNova.BLL;
|
|
using Infragistics.Win;
|
|
using Infragistics.Win.UltraWinGrid;
|
|
using Infragistics.Win.UltraWinToolbars;
|
|
using System.Text;
|
|
using log4net;
|
|
|
|
namespace AyaNova
|
|
{
|
|
/// <summary>
|
|
/// Summary description for PurchaseOrderInfoForm.
|
|
/// </summary>
|
|
public class PurchaseOrderInfoForm : System.Windows.Forms.Form
|
|
{
|
|
// Create a logger for use in this class
|
|
private static readonly log4net.ILog log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
|
|
|
|
private System.Windows.Forms.CheckBox ckIsDirty;
|
|
private System.Windows.Forms.ErrorProvider ErrorProvider;
|
|
private Infragistics.Win.UltraWinEditors.UltraTextEditor edNotes;
|
|
private System.Windows.Forms.Panel panelLeft;
|
|
private System.Windows.Forms.Panel panelRight;
|
|
private System.Windows.Forms.Panel panelBottom;
|
|
private System.Windows.Forms.Splitter splitter1;
|
|
private Infragistics.Win.UltraWinToolbars.UltraToolbarsManager tbManager;
|
|
private System.Windows.Forms.Panel panelCustom;
|
|
private Infragistics.Win.UltraWinGrid.UltraGrid gridCustom;
|
|
private Infragistics.Win.Misc.UltraLabel lblNotes;
|
|
private Infragistics.Win.Misc.UltraLabel lblVendorMemo;
|
|
private GZTW.WinForm.Controls.GZUltraComboEditor cbVendorID;
|
|
private Infragistics.Win.Misc.UltraButton btnVendorID;
|
|
private Infragistics.Win.UltraWinEditors.UltraTextEditor edVendorInfo;
|
|
private Infragistics.Win.UltraWinEditors.UltraTextEditor edClientInfo;
|
|
private Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea _PurchaseOrderInfoForm_Toolbars_Dock_Area_Left;
|
|
private Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea _PurchaseOrderInfoForm_Toolbars_Dock_Area_Right;
|
|
private Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea _PurchaseOrderInfoForm_Toolbars_Dock_Area_Top;
|
|
private Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea _PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom;
|
|
private Infragistics.Win.Misc.UltraLabel lblOrderedDate;
|
|
private Infragistics.Win.UltraWinEditors.UltraDateTimeEditor dtOrderedDate;
|
|
private Infragistics.Win.UltraWinEditors.UltraDateTimeEditor dtExpectedReceiveDate;
|
|
private Infragistics.Win.Misc.UltraLabel lblExpectedReceiveDate;
|
|
private Infragistics.Win.UltraWinGrid.UltraGrid Grid;
|
|
private Infragistics.Win.Misc.UltraButton btnClientID;
|
|
private GZTW.WinForm.Controls.GZUltraComboEditor cbClientID;
|
|
private Infragistics.Win.UltraWinEditors.UltraTextEditor edVendorMemo;
|
|
private Infragistics.Win.Misc.UltraLabel lblStatus;
|
|
private System.Windows.Forms.CheckBox ckClosed;
|
|
private Infragistics.Win.Misc.UltraLabel lblReferenceNumber;
|
|
private Infragistics.Win.UltraWinEditors.UltraTextEditor edReferenceNumber;
|
|
private System.ComponentModel.IContainer components;
|
|
|
|
|
|
public PurchaseOrderInfoForm()
|
|
{
|
|
//
|
|
// Required for Windows Form Designer support
|
|
//
|
|
InitializeComponent();
|
|
|
|
|
|
}
|
|
|
|
/// <summary>
|
|
/// Clean up any resources being used.
|
|
/// </summary>
|
|
protected override void Dispose( bool disposing )
|
|
{
|
|
if( disposing )
|
|
{
|
|
if(components != null)
|
|
{
|
|
components.Dispose();
|
|
}
|
|
}
|
|
base.Dispose( disposing );
|
|
}
|
|
//
|
|
#region BROKEN? Windows Form Designer generated code
|
|
// /// <summary>
|
|
// /// Required method for Designer support - do not modify
|
|
// /// the contents of this method with the code editor.
|
|
// /// </summary>
|
|
// private void InitializeComponent()
|
|
// {
|
|
// this.components = new System.ComponentModel.Container();
|
|
// Infragistics.Win.UltraWinToolbars.UltraToolbar ultraToolbar1 = new Infragistics.Win.UltraWinToolbars.UltraToolbar("PurchaseOrderEntryMenuBar");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool1 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Toolbar.Print");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool2 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveClose");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool3 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.RecordHistory");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool4 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveNew");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool5 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Close");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool6 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Save");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool7 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Delete");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool8 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Ordered");
|
|
// Infragistics.Win.UltraWinToolbars.ControlContainerTool controlContainerTool1 = new Infragistics.Win.UltraWinToolbars.ControlContainerTool("LT:UI.Command.Closed");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool9 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:WorkorderItemPartRequest.Label.List");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool10 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:PurchaseOrder.Label.UI.RestockList");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool11 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveClose");
|
|
// Infragistics.Win.Appearance appearance1 = new Infragistics.Win.Appearance();
|
|
// System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(PurchaseOrderInfoForm));
|
|
// Infragistics.Win.Appearance appearance2 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool12 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.RecordHistory");
|
|
// Infragistics.Win.Appearance appearance3 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance4 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool13 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Save");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool14 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveNew");
|
|
// Infragistics.Win.Appearance appearance5 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance6 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool15 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Close");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool16 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Delete");
|
|
// Infragistics.Win.Appearance appearance7 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance8 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool17 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Ordered");
|
|
// Infragistics.Win.UltraWinToolbars.ControlContainerTool controlContainerTool2 = new Infragistics.Win.UltraWinToolbars.ControlContainerTool("LT:UI.Command.Closed");
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool18 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Toolbar.Print");
|
|
// Infragistics.Win.Appearance appearance9 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance10 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool19 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:WorkorderItemPartRequest.Label.List");
|
|
// Infragistics.Win.Appearance appearance11 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance12 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool20 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:PurchaseOrder.Label.UI.RestockList");
|
|
// Infragistics.Win.Appearance appearance13 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance14 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance15 = new Infragistics.Win.Appearance();
|
|
// Infragistics.Win.Appearance appearance16 = new Infragistics.Win.Appearance();
|
|
// this.ckClosed = new System.Windows.Forms.CheckBox();
|
|
// this.ckIsDirty = new System.Windows.Forms.CheckBox();
|
|
// this.tbManager = new Infragistics.Win.UltraWinToolbars.UltraToolbarsManager(this.components);
|
|
// this.panelLeft = new System.Windows.Forms.Panel();
|
|
// this.lblStatus = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.edVendorInfo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
// this.btnVendorID = new Infragistics.Win.Misc.UltraButton();
|
|
// this.cbVendorID = new GZTW.WinForm.Controls.GZUltraComboEditor();
|
|
// this.cbClientID = new GZTW.WinForm.Controls.GZUltraComboEditor();
|
|
// this.edClientInfo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
// this.btnClientID = new Infragistics.Win.Misc.UltraButton();
|
|
// this.ErrorProvider = new System.Windows.Forms.ErrorProvider();
|
|
// this.panelRight = new System.Windows.Forms.Panel();
|
|
// this.edReferenceNumber = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
// this.lblReferenceNumber = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.dtExpectedReceiveDate = new Infragistics.Win.UltraWinEditors.UltraDateTimeEditor();
|
|
// this.lblOrderedDate = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.dtOrderedDate = new Infragistics.Win.UltraWinEditors.UltraDateTimeEditor();
|
|
// this.lblExpectedReceiveDate = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.lblVendorMemo = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.edVendorMemo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
// this.lblNotes = new Infragistics.Win.Misc.UltraLabel();
|
|
// this.edNotes = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
// this.panelBottom = new System.Windows.Forms.Panel();
|
|
// this.Grid = new Infragistics.Win.UltraWinGrid.UltraGrid();
|
|
// this.splitter1 = new System.Windows.Forms.Splitter();
|
|
// this.panelCustom = new System.Windows.Forms.Panel();
|
|
// this.gridCustom = new Infragistics.Win.UltraWinGrid.UltraGrid();
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.tbManager)).BeginInit();
|
|
// this.panelLeft.SuspendLayout();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edVendorInfo)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.cbVendorID)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.cbClientID)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edClientInfo)).BeginInit();
|
|
// this.panelRight.SuspendLayout();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edReferenceNumber)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.dtExpectedReceiveDate)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.dtOrderedDate)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edVendorMemo)).BeginInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edNotes)).BeginInit();
|
|
// this.panelBottom.SuspendLayout();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.Grid)).BeginInit();
|
|
// this.panelCustom.SuspendLayout();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.gridCustom)).BeginInit();
|
|
// this.SuspendLayout();
|
|
// //
|
|
// // ckClosed
|
|
// //
|
|
// this.ckClosed.Location = new System.Drawing.Point(-10000, -10000);
|
|
// this.ckClosed.Name = "ckClosed";
|
|
// this.ckClosed.Size = new System.Drawing.Size(158, 30);
|
|
// this.ckClosed.TabIndex = 4;
|
|
// this.ckClosed.Tag = "LT:UI.Command.Closed";
|
|
// this.ckClosed.Text = "LT:UI.Command.Closed";
|
|
// this.ckClosed.CheckedChanged += new System.EventHandler(this.ckClosed_CheckedChanged);
|
|
// //
|
|
// // ckIsDirty
|
|
// //
|
|
// this.ckIsDirty.Location = new System.Drawing.Point(-280, 24);
|
|
// this.ckIsDirty.Name = "ckIsDirty";
|
|
// this.ckIsDirty.Size = new System.Drawing.Size(176, 24);
|
|
// this.ckIsDirty.TabIndex = 5;
|
|
// //
|
|
// // tbManager
|
|
// //
|
|
// this.tbManager.DesignerFlags = 1;
|
|
// this.tbManager.DockWithinContainer = this;
|
|
// this.tbManager.RuntimeCustomizationOptions = Infragistics.Win.UltraWinToolbars.RuntimeCustomizationOptions.None;
|
|
// this.tbManager.ShowFullMenusDelay = 500;
|
|
// ultraToolbar1.DockedColumn = 0;
|
|
// ultraToolbar1.DockedRow = 0;
|
|
// ultraToolbar1.Text = "PurchaseOrderEntryMenuBar";
|
|
// controlContainerTool1.Control = this.ckClosed;
|
|
// controlContainerTool1.InstanceProps.Width = 160;
|
|
// ultraToolbar1.Tools.AddRange(new Infragistics.Win.UltraWinToolbars.ToolBase[] {
|
|
// buttonTool1,
|
|
// buttonTool2,
|
|
// buttonTool3,
|
|
// buttonTool4,
|
|
// buttonTool5,
|
|
// buttonTool6,
|
|
// buttonTool7,
|
|
// buttonTool8,
|
|
// controlContainerTool1,
|
|
// buttonTool9,
|
|
// buttonTool10});
|
|
// this.tbManager.Toolbars.AddRange(new Infragistics.Win.UltraWinToolbars.UltraToolbar[] {
|
|
// ultraToolbar1});
|
|
// this.tbManager.ToolbarSettings.AllowCustomize = Infragistics.Win.DefaultableBoolean.False;
|
|
// this.tbManager.ToolbarSettings.AllowFloating = Infragistics.Win.DefaultableBoolean.False;
|
|
// this.tbManager.ToolbarSettings.AllowHiding = Infragistics.Win.DefaultableBoolean.False;
|
|
// buttonTool11.SharedProps.AccessibleDescription = "recorddd";
|
|
// appearance1.Image = ((object)(resources.GetObject("appearance1.Image")));
|
|
// buttonTool11.SharedProps.AppearancesLarge.Appearance = appearance1;
|
|
// appearance2.Image = ((object)(resources.GetObject("appearance2.Image")));
|
|
// buttonTool11.SharedProps.AppearancesSmall.Appearance = appearance2;
|
|
// buttonTool11.SharedProps.Caption = "LT:UI.Command.SaveClose";
|
|
// appearance3.Image = ((object)(resources.GetObject("appearance3.Image")));
|
|
// buttonTool12.SharedProps.AppearancesLarge.Appearance = appearance3;
|
|
// appearance4.Image = ((object)(resources.GetObject("appearance4.Image")));
|
|
// buttonTool12.SharedProps.AppearancesSmall.Appearance = appearance4;
|
|
// buttonTool12.SharedProps.Caption = "LT:UI.Command.RecordHistory";
|
|
// buttonTool13.SharedProps.Caption = "LT:UI.Command.Save";
|
|
// buttonTool13.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
// appearance5.Image = ((object)(resources.GetObject("appearance5.Image")));
|
|
// buttonTool14.SharedProps.AppearancesLarge.Appearance = appearance5;
|
|
// appearance6.Image = ((object)(resources.GetObject("appearance6.Image")));
|
|
// buttonTool14.SharedProps.AppearancesSmall.Appearance = appearance6;
|
|
// buttonTool14.SharedProps.Caption = "LT:UI.Command.SaveNew";
|
|
// buttonTool15.SharedProps.Caption = "LT:UI.Command.Close";
|
|
// buttonTool15.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
// appearance7.Image = ((object)(resources.GetObject("appearance7.Image")));
|
|
// buttonTool16.SharedProps.AppearancesLarge.Appearance = appearance7;
|
|
// appearance8.Image = ((object)(resources.GetObject("appearance8.Image")));
|
|
// buttonTool16.SharedProps.AppearancesSmall.Appearance = appearance8;
|
|
// buttonTool16.SharedProps.Caption = "LT:UI.Command.Delete";
|
|
// buttonTool17.SharedProps.Caption = "LT:UI.Command.Ordered";
|
|
// buttonTool17.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
// controlContainerTool2.Control = this.ckClosed;
|
|
// controlContainerTool2.SharedProps.Caption = "LT:UI.Command.Closed";
|
|
// controlContainerTool2.SharedProps.Width = 160;
|
|
// appearance9.Image = ((object)(resources.GetObject("appearance9.Image")));
|
|
// buttonTool18.SharedProps.AppearancesLarge.Appearance = appearance9;
|
|
// appearance10.Image = ((object)(resources.GetObject("appearance10.Image")));
|
|
// buttonTool18.SharedProps.AppearancesSmall.Appearance = appearance10;
|
|
// buttonTool18.SharedProps.Caption = "LT:UI.Toolbar.Print";
|
|
// appearance11.Image = ((object)(resources.GetObject("appearance11.Image")));
|
|
// buttonTool19.SharedProps.AppearancesLarge.Appearance = appearance11;
|
|
// appearance12.Image = ((object)(resources.GetObject("appearance12.Image")));
|
|
// buttonTool19.SharedProps.AppearancesSmall.Appearance = appearance12;
|
|
// buttonTool19.SharedProps.Caption = "LT:WorkorderItemPartRequest.Label.List";
|
|
// appearance13.Image = ((object)(resources.GetObject("appearance13.Image")));
|
|
// buttonTool20.SharedProps.AppearancesLarge.Appearance = appearance13;
|
|
// appearance14.Image = ((object)(resources.GetObject("appearance14.Image")));
|
|
// buttonTool20.SharedProps.AppearancesSmall.Appearance = appearance14;
|
|
// buttonTool20.SharedProps.Caption = "LT:PurchaseOrder.Label.UI.RestockList";
|
|
// this.tbManager.Tools.AddRange(new Infragistics.Win.UltraWinToolbars.ToolBase[] {
|
|
// buttonTool11,
|
|
// buttonTool12,
|
|
// buttonTool13,
|
|
// buttonTool14,
|
|
// buttonTool15,
|
|
// buttonTool16,
|
|
// buttonTool17,
|
|
// controlContainerTool2,
|
|
// buttonTool18,
|
|
// buttonTool19,
|
|
// buttonTool20});
|
|
// this.tbManager.UseLargeImagesOnToolbar = true;
|
|
// this.tbManager.ToolClick += new Infragistics.Win.UltraWinToolbars.ToolClickEventHandler(this.tbManager_ToolClick);
|
|
// //
|
|
// // panelLeft
|
|
// //
|
|
// this.panelLeft.Controls.Add(this.lblStatus);
|
|
// this.panelLeft.Controls.Add(this.edVendorInfo);
|
|
// this.panelLeft.Controls.Add(this.btnVendorID);
|
|
// this.panelLeft.Controls.Add(this.cbVendorID);
|
|
// this.panelLeft.Controls.Add(this.cbClientID);
|
|
// this.panelLeft.Controls.Add(this.edClientInfo);
|
|
// this.panelLeft.Controls.Add(this.btnClientID);
|
|
// this.panelLeft.Dock = System.Windows.Forms.DockStyle.Left;
|
|
// this.panelLeft.Location = new System.Drawing.Point(0, 40);
|
|
// this.panelLeft.Name = "panelLeft";
|
|
// this.panelLeft.Size = new System.Drawing.Size(250, 277);
|
|
// this.panelLeft.TabIndex = 96;
|
|
// //
|
|
// // lblStatus
|
|
// //
|
|
// this.lblStatus.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.lblStatus.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
|
|
// this.lblStatus.Location = new System.Drawing.Point(8, 6);
|
|
// this.lblStatus.Name = "lblStatus";
|
|
// this.lblStatus.Size = new System.Drawing.Size(232, 18);
|
|
// this.lblStatus.TabIndex = 161;
|
|
// this.lblStatus.Tag = "";
|
|
// //
|
|
// // edVendorInfo
|
|
// //
|
|
// this.edVendorInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.edVendorInfo.Location = new System.Drawing.Point(8, 78);
|
|
// this.edVendorInfo.Multiline = true;
|
|
// this.edVendorInfo.Name = "edVendorInfo";
|
|
// this.edVendorInfo.ReadOnly = true;
|
|
// this.edVendorInfo.Scrollbars = System.Windows.Forms.ScrollBars.Vertical;
|
|
// this.edVendorInfo.Size = new System.Drawing.Size(216, 58);
|
|
// this.edVendorInfo.TabIndex = 155;
|
|
// //
|
|
// // btnVendorID
|
|
// //
|
|
// this.btnVendorID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// appearance15.TextHAlign = Infragistics.Win.HAlign.Left;
|
|
// this.btnVendorID.Appearance = appearance15;
|
|
// this.btnVendorID.ButtonStyle = Infragistics.Win.UIElementButtonStyle.PopupBorderless;
|
|
// this.btnVendorID.HotTracking = true;
|
|
// this.btnVendorID.Location = new System.Drawing.Point(0, 30);
|
|
// this.btnVendorID.Name = "btnVendorID";
|
|
// this.btnVendorID.Size = new System.Drawing.Size(224, 24);
|
|
// this.btnVendorID.TabIndex = 0;
|
|
// this.btnVendorID.Tag = "LT:O.Vendor";
|
|
// this.btnVendorID.Text = "LT:O.Vendor";
|
|
// this.btnVendorID.Click += new System.EventHandler(this.btnVendorID_Click);
|
|
// //
|
|
// // cbVendorID
|
|
// //
|
|
// this.cbVendorID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.cbVendorID.Location = new System.Drawing.Point(8, 54);
|
|
// this.cbVendorID.Name = "cbVendorID";
|
|
// this.cbVendorID.Size = new System.Drawing.Size(216, 21);
|
|
// this.cbVendorID.TabIndex = 0;
|
|
// this.cbVendorID.SelectionChanged += new System.EventHandler(this.cbVendorID_SelectionChanged);
|
|
// this.cbVendorID.NeedMoreData += new GZTW.WinForm.Controls.NeedMoreDataHandler(this.cbVendorID_NeedMoreData);
|
|
// //
|
|
// // cbClientID
|
|
// //
|
|
// this.cbClientID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.cbClientID.Location = new System.Drawing.Point(8, 168);
|
|
// this.cbClientID.Name = "cbClientID";
|
|
// this.cbClientID.Size = new System.Drawing.Size(216, 21);
|
|
// this.cbClientID.TabIndex = 1;
|
|
// this.cbClientID.SelectionChanged += new System.EventHandler(this.cbClientID_SelectionChanged);
|
|
// this.cbClientID.NeedMoreData += new GZTW.WinForm.Controls.NeedMoreDataHandler(this.cbClientID_NeedMoreData);
|
|
// //
|
|
// // edClientInfo
|
|
// //
|
|
// this.edClientInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.edClientInfo.Location = new System.Drawing.Point(8, 192);
|
|
// this.edClientInfo.Multiline = true;
|
|
// this.edClientInfo.Name = "edClientInfo";
|
|
// this.edClientInfo.ReadOnly = true;
|
|
// this.edClientInfo.Scrollbars = System.Windows.Forms.ScrollBars.Vertical;
|
|
// this.edClientInfo.Size = new System.Drawing.Size(216, 72);
|
|
// this.edClientInfo.TabIndex = 158;
|
|
// //
|
|
// // btnClientID
|
|
// //
|
|
// this.btnClientID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// appearance16.TextHAlign = Infragistics.Win.HAlign.Left;
|
|
// this.btnClientID.Appearance = appearance16;
|
|
// this.btnClientID.ButtonStyle = Infragistics.Win.UIElementButtonStyle.PopupBorderless;
|
|
// this.btnClientID.HotTracking = true;
|
|
// this.btnClientID.Location = new System.Drawing.Point(0, 144);
|
|
// this.btnClientID.Name = "btnClientID";
|
|
// this.btnClientID.Size = new System.Drawing.Size(216, 24);
|
|
// this.btnClientID.TabIndex = 3;
|
|
// this.btnClientID.Tag = "LT:PurchaseOrder.Label.DropShipToClientID";
|
|
// this.btnClientID.Text = "LT:PurchaseOrder.Label.DropShipToClientID";
|
|
// this.btnClientID.Click += new System.EventHandler(this.btnClientID_Click);
|
|
// //
|
|
// // ErrorProvider
|
|
// //
|
|
// this.ErrorProvider.ContainerControl = this;
|
|
// //
|
|
// // panelRight
|
|
// //
|
|
// this.panelRight.Controls.Add(this.edReferenceNumber);
|
|
// this.panelRight.Controls.Add(this.lblReferenceNumber);
|
|
// this.panelRight.Controls.Add(this.dtExpectedReceiveDate);
|
|
// this.panelRight.Controls.Add(this.lblOrderedDate);
|
|
// this.panelRight.Controls.Add(this.dtOrderedDate);
|
|
// this.panelRight.Controls.Add(this.lblExpectedReceiveDate);
|
|
// this.panelRight.Controls.Add(this.lblVendorMemo);
|
|
// this.panelRight.Controls.Add(this.edVendorMemo);
|
|
// this.panelRight.Controls.Add(this.lblNotes);
|
|
// this.panelRight.Controls.Add(this.edNotes);
|
|
// this.panelRight.Controls.Add(this.ckClosed);
|
|
// this.panelRight.Dock = System.Windows.Forms.DockStyle.Left;
|
|
// this.panelRight.Location = new System.Drawing.Point(250, 40);
|
|
// this.panelRight.Name = "panelRight";
|
|
// this.panelRight.Size = new System.Drawing.Size(250, 277);
|
|
// this.panelRight.TabIndex = 101;
|
|
// //
|
|
// // edReferenceNumber
|
|
// //
|
|
// this.edReferenceNumber.Location = new System.Drawing.Point(160, 80);
|
|
// this.edReferenceNumber.Name = "edReferenceNumber";
|
|
// this.edReferenceNumber.Size = new System.Drawing.Size(88, 21);
|
|
// this.edReferenceNumber.TabIndex = 2;
|
|
// //
|
|
// // lblReferenceNumber
|
|
// //
|
|
// this.lblReferenceNumber.Location = new System.Drawing.Point(8, 80);
|
|
// this.lblReferenceNumber.Name = "lblReferenceNumber";
|
|
// this.lblReferenceNumber.Size = new System.Drawing.Size(88, 16);
|
|
// this.lblReferenceNumber.TabIndex = 164;
|
|
// this.lblReferenceNumber.Tag = "LT:PurchaseOrder.Label.ReferenceNumber";
|
|
// this.lblReferenceNumber.Text = "LT:PurchaseOrder.Label.ReferenceNumber";
|
|
// this.lblReferenceNumber.WrapText = false;
|
|
// //
|
|
// // dtExpectedReceiveDate
|
|
// //
|
|
// this.dtExpectedReceiveDate.Location = new System.Drawing.Point(160, 48);
|
|
// this.dtExpectedReceiveDate.Name = "dtExpectedReceiveDate";
|
|
// this.dtExpectedReceiveDate.Size = new System.Drawing.Size(88, 21);
|
|
// this.dtExpectedReceiveDate.TabIndex = 1;
|
|
// //
|
|
// // lblOrderedDate
|
|
// //
|
|
// this.lblOrderedDate.Location = new System.Drawing.Point(8, 16);
|
|
// this.lblOrderedDate.Name = "lblOrderedDate";
|
|
// this.lblOrderedDate.Size = new System.Drawing.Size(88, 16);
|
|
// this.lblOrderedDate.TabIndex = 159;
|
|
// this.lblOrderedDate.Tag = "LT:PurchaseOrder.Label.OrderedDate";
|
|
// this.lblOrderedDate.Text = "LT:PurchaseOrder.Label.OrderedDate";
|
|
// this.lblOrderedDate.WrapText = false;
|
|
// //
|
|
// // dtOrderedDate
|
|
// //
|
|
// this.dtOrderedDate.Location = new System.Drawing.Point(160, 16);
|
|
// this.dtOrderedDate.Name = "dtOrderedDate";
|
|
// this.dtOrderedDate.Size = new System.Drawing.Size(88, 21);
|
|
// this.dtOrderedDate.TabIndex = 0;
|
|
// this.dtOrderedDate.EditorButtonClick += new Infragistics.Win.UltraWinEditors.EditorButtonEventHandler(this.dtOrderedDate_EditorButtonClick);
|
|
// //
|
|
// // lblExpectedReceiveDate
|
|
// //
|
|
// this.lblExpectedReceiveDate.Location = new System.Drawing.Point(8, 48);
|
|
// this.lblExpectedReceiveDate.Name = "lblExpectedReceiveDate";
|
|
// this.lblExpectedReceiveDate.Size = new System.Drawing.Size(88, 16);
|
|
// this.lblExpectedReceiveDate.TabIndex = 163;
|
|
// this.lblExpectedReceiveDate.Tag = "LT:PurchaseOrder.Label.ExpectedReceiveDate";
|
|
// this.lblExpectedReceiveDate.Text = "LT:PurchaseOrder.Label.ExpectedReceiveDate";
|
|
// this.lblExpectedReceiveDate.WrapText = false;
|
|
// //
|
|
// // lblVendorMemo
|
|
// //
|
|
// this.lblVendorMemo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.lblVendorMemo.Location = new System.Drawing.Point(8, 112);
|
|
// this.lblVendorMemo.Name = "lblVendorMemo";
|
|
// this.lblVendorMemo.Size = new System.Drawing.Size(240, 16);
|
|
// this.lblVendorMemo.TabIndex = 133;
|
|
// this.lblVendorMemo.Tag = "LT:PurchaseOrder.Label.VendorMemo";
|
|
// this.lblVendorMemo.Text = "LT:PurchaseOrder.Label.VendorMemo";
|
|
// //
|
|
// // edVendorMemo
|
|
// //
|
|
// this.edVendorMemo.AcceptsReturn = true;
|
|
// this.edVendorMemo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.edVendorMemo.Location = new System.Drawing.Point(8, 128);
|
|
// this.edVendorMemo.Multiline = true;
|
|
// this.edVendorMemo.Name = "edVendorMemo";
|
|
// this.edVendorMemo.Size = new System.Drawing.Size(240, 56);
|
|
// this.edVendorMemo.TabIndex = 3;
|
|
// //
|
|
// // lblNotes
|
|
// //
|
|
// this.lblNotes.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.lblNotes.Location = new System.Drawing.Point(8, 192);
|
|
// this.lblNotes.Name = "lblNotes";
|
|
// this.lblNotes.Size = new System.Drawing.Size(216, 16);
|
|
// this.lblNotes.TabIndex = 131;
|
|
// this.lblNotes.Tag = "LT:PurchaseOrder.Label.Notes";
|
|
// this.lblNotes.Text = "LT:PurchaseOrder.Label.Notes";
|
|
// //
|
|
// // edNotes
|
|
// //
|
|
// this.edNotes.AcceptsReturn = true;
|
|
// this.edNotes.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
// | System.Windows.Forms.AnchorStyles.Right)));
|
|
// this.edNotes.Location = new System.Drawing.Point(8, 208);
|
|
// this.edNotes.Multiline = true;
|
|
// this.edNotes.Name = "edNotes";
|
|
// this.edNotes.Size = new System.Drawing.Size(240, 56);
|
|
// this.edNotes.TabIndex = 4;
|
|
// //
|
|
// // panelBottom
|
|
// //
|
|
// this.panelBottom.Controls.Add(this.Grid);
|
|
// this.panelBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
|
|
// this.panelBottom.Location = new System.Drawing.Point(0, 325);
|
|
// this.panelBottom.Name = "panelBottom";
|
|
// this.panelBottom.Size = new System.Drawing.Size(728, 176);
|
|
// this.panelBottom.TabIndex = 102;
|
|
// //
|
|
// // Grid
|
|
// //
|
|
// this.Grid.Cursor = System.Windows.Forms.Cursors.Default;
|
|
// this.Grid.DisplayLayout.Override.AllowAddNew = Infragistics.Win.UltraWinGrid.AllowAddNew.TemplateOnBottom;
|
|
// this.Grid.DisplayLayout.Override.AllowDelete = Infragistics.Win.DefaultableBoolean.True;
|
|
// this.Grid.DisplayLayout.Override.AllowUpdate = Infragistics.Win.DefaultableBoolean.True;
|
|
// this.Grid.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
// this.Grid.Location = new System.Drawing.Point(0, 0);
|
|
// this.Grid.Name = "Grid";
|
|
// this.Grid.Size = new System.Drawing.Size(728, 176);
|
|
// this.Grid.TabIndex = 0;
|
|
// this.Grid.Tag = "LT:O.PurchaseOrderItem";
|
|
// this.Grid.Text = "LT:O.PurchaseOrderItem";
|
|
// this.Grid.BeforeRowInsert += new Infragistics.Win.UltraWinGrid.BeforeRowInsertEventHandler(this.Grid_BeforeRowInsert);
|
|
// this.Grid.AfterCellUpdate += new Infragistics.Win.UltraWinGrid.CellEventHandler(this.Grid_AfterCellUpdate);
|
|
// this.Grid.MouseDown += new System.Windows.Forms.MouseEventHandler(this.Grid_MouseDown);
|
|
// this.Grid.InitializeRow += new Infragistics.Win.UltraWinGrid.InitializeRowEventHandler(this.Grid_InitializeRow);
|
|
// this.Grid.SummaryValueChanged += new Infragistics.Win.UltraWinGrid.SummaryValueChangedEventHandler(this.Grid_SummaryValueChanged);
|
|
// //
|
|
// // splitter1
|
|
// //
|
|
// this.splitter1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
|
// this.splitter1.Dock = System.Windows.Forms.DockStyle.Bottom;
|
|
// this.splitter1.Location = new System.Drawing.Point(0, 317);
|
|
// this.splitter1.Name = "splitter1";
|
|
// this.splitter1.Size = new System.Drawing.Size(728, 8);
|
|
// this.splitter1.TabIndex = 0;
|
|
// this.splitter1.TabStop = false;
|
|
// //
|
|
// // panelCustom
|
|
// //
|
|
// this.panelCustom.Controls.Add(this.gridCustom);
|
|
// this.panelCustom.Dock = System.Windows.Forms.DockStyle.Right;
|
|
// this.panelCustom.Location = new System.Drawing.Point(504, 40);
|
|
// this.panelCustom.Name = "panelCustom";
|
|
// this.panelCustom.Size = new System.Drawing.Size(224, 277);
|
|
// this.panelCustom.TabIndex = 108;
|
|
// //
|
|
// // gridCustom
|
|
// //
|
|
// this.gridCustom.Cursor = System.Windows.Forms.Cursors.Default;
|
|
// this.gridCustom.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
// this.gridCustom.Location = new System.Drawing.Point(0, 0);
|
|
// this.gridCustom.Name = "gridCustom";
|
|
// this.gridCustom.Size = new System.Drawing.Size(224, 277);
|
|
// this.gridCustom.TabIndex = 0;
|
|
// this.gridCustom.Tag = "LT:ObjectCustomField.Label.CustomGrid";
|
|
// this.gridCustom.Text = "LT:ObjectCustomField.Label.CustomGrid";
|
|
// this.gridCustom.AfterCellUpdate += new Infragistics.Win.UltraWinGrid.CellEventHandler(this.gridCustom_AfterCellUpdate);
|
|
// //
|
|
// // _PurchaseOrderInfoForm_Toolbars_Dock_Area_Left
|
|
// //
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.BackColor = System.Drawing.SystemColors.Control;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Left;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Location = new System.Drawing.Point(0, 40);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Left";
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Size = new System.Drawing.Size(0, 461);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.ToolbarsManager = this.tbManager;
|
|
// //
|
|
// // _PurchaseOrderInfoForm_Toolbars_Dock_Area_Right
|
|
// //
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.BackColor = System.Drawing.SystemColors.Control;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Right;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Location = new System.Drawing.Point(728, 40);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Right";
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Size = new System.Drawing.Size(0, 461);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.ToolbarsManager = this.tbManager;
|
|
// //
|
|
// // _PurchaseOrderInfoForm_Toolbars_Dock_Area_Top
|
|
// //
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.BackColor = System.Drawing.SystemColors.Control;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Top;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Location = new System.Drawing.Point(0, 0);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Top";
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Size = new System.Drawing.Size(728, 40);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.ToolbarsManager = this.tbManager;
|
|
// //
|
|
// // _PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom
|
|
// //
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.BackColor = System.Drawing.SystemColors.Control;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Bottom;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Location = new System.Drawing.Point(0, 501);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom";
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Size = new System.Drawing.Size(728, 0);
|
|
// this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.ToolbarsManager = this.tbManager;
|
|
// //
|
|
// // PurchaseOrderInfoForm
|
|
// //
|
|
// this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
|
|
// this.ClientSize = new System.Drawing.Size(728, 501);
|
|
// this.Controls.Add(this.panelCustom);
|
|
// this.Controls.Add(this.panelRight);
|
|
// this.Controls.Add(this.panelLeft);
|
|
// this.Controls.Add(this.splitter1);
|
|
// this.Controls.Add(this.panelBottom);
|
|
// this.Controls.Add(this.ckIsDirty);
|
|
// this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left);
|
|
// this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right);
|
|
// this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top);
|
|
// this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom);
|
|
// this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
|
|
// this.MinimumSize = new System.Drawing.Size(512, 488);
|
|
// this.Name = "PurchaseOrderInfoForm";
|
|
// this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Show;
|
|
// this.Closing += new System.ComponentModel.CancelEventHandler(this.PurchaseOrderInfoForm_Closing);
|
|
// this.SizeChanged += new System.EventHandler(this.PurchaseOrderInfoForm_SizeChanged);
|
|
// this.Load += new System.EventHandler(this.PurchaseOrderInfoForm_Load);
|
|
// ((System.ComponentModel.ISupportInitialize)(this.tbManager)).EndInit();
|
|
// this.panelLeft.ResumeLayout(false);
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edVendorInfo)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.cbVendorID)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.cbClientID)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edClientInfo)).EndInit();
|
|
// this.panelRight.ResumeLayout(false);
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edReferenceNumber)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.dtExpectedReceiveDate)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.dtOrderedDate)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edVendorMemo)).EndInit();
|
|
// ((System.ComponentModel.ISupportInitialize)(this.edNotes)).EndInit();
|
|
// this.panelBottom.ResumeLayout(false);
|
|
// ((System.ComponentModel.ISupportInitialize)(this.Grid)).EndInit();
|
|
// this.panelCustom.ResumeLayout(false);
|
|
// ((System.ComponentModel.ISupportInitialize)(this.gridCustom)).EndInit();
|
|
// this.ResumeLayout(false);
|
|
//
|
|
// }
|
|
#endregion BROKEN?
|
|
#region Windows Form Designer generated code
|
|
/// <summary>
|
|
/// Required method for Designer support - do not modify
|
|
/// the contents of this method with the code editor.
|
|
/// </summary>
|
|
private void InitializeComponent()
|
|
{
|
|
this.components = new System.ComponentModel.Container();
|
|
Infragistics.Win.UltraWinToolbars.UltraToolbar ultraToolbar1 = new Infragistics.Win.UltraWinToolbars.UltraToolbar("PurchaseOrderEntryMenuBar");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool1 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Toolbar.Print");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool2 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveClose");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool3 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.RecordHistory");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool4 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveNew");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool5 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Close");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool6 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Save");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool7 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Delete");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool8 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Ordered");
|
|
Infragistics.Win.UltraWinToolbars.ControlContainerTool controlContainerTool1 = new Infragistics.Win.UltraWinToolbars.ControlContainerTool("LT:UI.Command.Closed");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool9 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:WorkorderItemPartRequest.Label.List");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool10 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:PurchaseOrder.Label.UI.RestockList");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool11 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveClose");
|
|
Infragistics.Win.Appearance appearance1 = new Infragistics.Win.Appearance();
|
|
System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(PurchaseOrderInfoForm));
|
|
Infragistics.Win.Appearance appearance2 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool12 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.RecordHistory");
|
|
Infragistics.Win.Appearance appearance3 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance4 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool13 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Save");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool14 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.SaveNew");
|
|
Infragistics.Win.Appearance appearance5 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance6 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool15 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Close");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool16 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Delete");
|
|
Infragistics.Win.Appearance appearance7 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance8 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool17 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Command.Ordered");
|
|
Infragistics.Win.UltraWinToolbars.ControlContainerTool controlContainerTool2 = new Infragistics.Win.UltraWinToolbars.ControlContainerTool("LT:UI.Command.Closed");
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool18 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:UI.Toolbar.Print");
|
|
Infragistics.Win.Appearance appearance9 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance10 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool19 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:WorkorderItemPartRequest.Label.List");
|
|
Infragistics.Win.Appearance appearance11 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance12 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.UltraWinToolbars.ButtonTool buttonTool20 = new Infragistics.Win.UltraWinToolbars.ButtonTool("LT:PurchaseOrder.Label.UI.RestockList");
|
|
Infragistics.Win.Appearance appearance13 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance14 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance15 = new Infragistics.Win.Appearance();
|
|
Infragistics.Win.Appearance appearance16 = new Infragistics.Win.Appearance();
|
|
this.ckClosed = new System.Windows.Forms.CheckBox();
|
|
this.ckIsDirty = new System.Windows.Forms.CheckBox();
|
|
this.tbManager = new Infragistics.Win.UltraWinToolbars.UltraToolbarsManager(this.components);
|
|
this.panelLeft = new System.Windows.Forms.Panel();
|
|
this.lblStatus = new Infragistics.Win.Misc.UltraLabel();
|
|
this.edVendorInfo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
this.btnVendorID = new Infragistics.Win.Misc.UltraButton();
|
|
this.cbVendorID = new GZTW.WinForm.Controls.GZUltraComboEditor();
|
|
this.cbClientID = new GZTW.WinForm.Controls.GZUltraComboEditor();
|
|
this.edClientInfo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
this.btnClientID = new Infragistics.Win.Misc.UltraButton();
|
|
this.ErrorProvider = new System.Windows.Forms.ErrorProvider();
|
|
this.panelRight = new System.Windows.Forms.Panel();
|
|
this.edReferenceNumber = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
this.lblReferenceNumber = new Infragistics.Win.Misc.UltraLabel();
|
|
this.dtExpectedReceiveDate = new Infragistics.Win.UltraWinEditors.UltraDateTimeEditor();
|
|
this.lblOrderedDate = new Infragistics.Win.Misc.UltraLabel();
|
|
this.dtOrderedDate = new Infragistics.Win.UltraWinEditors.UltraDateTimeEditor();
|
|
this.lblExpectedReceiveDate = new Infragistics.Win.Misc.UltraLabel();
|
|
this.lblVendorMemo = new Infragistics.Win.Misc.UltraLabel();
|
|
this.edVendorMemo = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
this.lblNotes = new Infragistics.Win.Misc.UltraLabel();
|
|
this.edNotes = new Infragistics.Win.UltraWinEditors.UltraTextEditor();
|
|
this.panelBottom = new System.Windows.Forms.Panel();
|
|
this.Grid = new Infragistics.Win.UltraWinGrid.UltraGrid();
|
|
this.splitter1 = new System.Windows.Forms.Splitter();
|
|
this.panelCustom = new System.Windows.Forms.Panel();
|
|
this.gridCustom = new Infragistics.Win.UltraWinGrid.UltraGrid();
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom = new Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea();
|
|
((System.ComponentModel.ISupportInitialize)(this.tbManager)).BeginInit();
|
|
this.panelLeft.SuspendLayout();
|
|
((System.ComponentModel.ISupportInitialize)(this.edVendorInfo)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.cbVendorID)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.cbClientID)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edClientInfo)).BeginInit();
|
|
this.panelRight.SuspendLayout();
|
|
((System.ComponentModel.ISupportInitialize)(this.edReferenceNumber)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.dtExpectedReceiveDate)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.dtOrderedDate)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edVendorMemo)).BeginInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edNotes)).BeginInit();
|
|
this.panelBottom.SuspendLayout();
|
|
((System.ComponentModel.ISupportInitialize)(this.Grid)).BeginInit();
|
|
this.panelCustom.SuspendLayout();
|
|
((System.ComponentModel.ISupportInitialize)(this.gridCustom)).BeginInit();
|
|
this.SuspendLayout();
|
|
//
|
|
// ckClosed
|
|
//
|
|
this.ckClosed.Location = new System.Drawing.Point(-10000, -10000);
|
|
this.ckClosed.Name = "ckClosed";
|
|
this.ckClosed.Size = new System.Drawing.Size(158, 30);
|
|
this.ckClosed.TabIndex = 4;
|
|
this.ckClosed.Tag = "LT:UI.Command.Closed";
|
|
this.ckClosed.Text = "LT:UI.Command.Closed";
|
|
this.ckClosed.CheckedChanged += new System.EventHandler(this.ckClosed_CheckedChanged);
|
|
//
|
|
// ckIsDirty
|
|
//
|
|
this.ckIsDirty.Location = new System.Drawing.Point(-280, 24);
|
|
this.ckIsDirty.Name = "ckIsDirty";
|
|
this.ckIsDirty.Size = new System.Drawing.Size(176, 24);
|
|
this.ckIsDirty.TabIndex = 5;
|
|
//
|
|
// tbManager
|
|
//
|
|
this.tbManager.DesignerFlags = 1;
|
|
this.tbManager.DockWithinContainer = this;
|
|
this.tbManager.RuntimeCustomizationOptions = Infragistics.Win.UltraWinToolbars.RuntimeCustomizationOptions.None;
|
|
this.tbManager.ShowFullMenusDelay = 500;
|
|
ultraToolbar1.DockedColumn = 0;
|
|
ultraToolbar1.DockedRow = 0;
|
|
ultraToolbar1.Text = "PurchaseOrderEntryMenuBar";
|
|
controlContainerTool1.Control = this.ckClosed;
|
|
controlContainerTool1.InstanceProps.Width = 160;
|
|
ultraToolbar1.Tools.AddRange(new Infragistics.Win.UltraWinToolbars.ToolBase[] {
|
|
buttonTool1,
|
|
buttonTool2,
|
|
buttonTool3,
|
|
buttonTool4,
|
|
buttonTool5,
|
|
buttonTool6,
|
|
buttonTool7,
|
|
buttonTool8,
|
|
controlContainerTool1,
|
|
buttonTool9,
|
|
buttonTool10});
|
|
this.tbManager.Toolbars.AddRange(new Infragistics.Win.UltraWinToolbars.UltraToolbar[] {
|
|
ultraToolbar1});
|
|
this.tbManager.ToolbarSettings.AllowCustomize = Infragistics.Win.DefaultableBoolean.False;
|
|
this.tbManager.ToolbarSettings.AllowFloating = Infragistics.Win.DefaultableBoolean.False;
|
|
this.tbManager.ToolbarSettings.AllowHiding = Infragistics.Win.DefaultableBoolean.False;
|
|
buttonTool11.SharedProps.AccessibleDescription = "recorddd";
|
|
appearance1.Image = ((object)(resources.GetObject("appearance1.Image")));
|
|
buttonTool11.SharedProps.AppearancesLarge.Appearance = appearance1;
|
|
appearance2.Image = ((object)(resources.GetObject("appearance2.Image")));
|
|
buttonTool11.SharedProps.AppearancesSmall.Appearance = appearance2;
|
|
buttonTool11.SharedProps.Caption = "LT:UI.Command.SaveClose";
|
|
appearance3.Image = ((object)(resources.GetObject("appearance3.Image")));
|
|
buttonTool12.SharedProps.AppearancesLarge.Appearance = appearance3;
|
|
appearance4.Image = ((object)(resources.GetObject("appearance4.Image")));
|
|
buttonTool12.SharedProps.AppearancesSmall.Appearance = appearance4;
|
|
buttonTool12.SharedProps.Caption = "LT:UI.Command.RecordHistory";
|
|
buttonTool13.SharedProps.Caption = "LT:UI.Command.Save";
|
|
buttonTool13.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
appearance5.Image = ((object)(resources.GetObject("appearance5.Image")));
|
|
buttonTool14.SharedProps.AppearancesLarge.Appearance = appearance5;
|
|
appearance6.Image = ((object)(resources.GetObject("appearance6.Image")));
|
|
buttonTool14.SharedProps.AppearancesSmall.Appearance = appearance6;
|
|
buttonTool14.SharedProps.Caption = "LT:UI.Command.SaveNew";
|
|
buttonTool15.SharedProps.Caption = "LT:UI.Command.Close";
|
|
buttonTool15.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
appearance7.Image = ((object)(resources.GetObject("appearance7.Image")));
|
|
buttonTool16.SharedProps.AppearancesLarge.Appearance = appearance7;
|
|
appearance8.Image = ((object)(resources.GetObject("appearance8.Image")));
|
|
buttonTool16.SharedProps.AppearancesSmall.Appearance = appearance8;
|
|
buttonTool16.SharedProps.Caption = "LT:UI.Command.Delete";
|
|
buttonTool17.SharedProps.Caption = "LT:UI.Command.Ordered";
|
|
buttonTool17.SharedProps.DisplayStyle = Infragistics.Win.UltraWinToolbars.ToolDisplayStyle.TextOnlyAlways;
|
|
controlContainerTool2.Control = this.ckClosed;
|
|
controlContainerTool2.SharedProps.Caption = "LT:UI.Command.Closed";
|
|
controlContainerTool2.SharedProps.Width = 160;
|
|
appearance9.Image = ((object)(resources.GetObject("appearance9.Image")));
|
|
buttonTool18.SharedProps.AppearancesLarge.Appearance = appearance9;
|
|
appearance10.Image = ((object)(resources.GetObject("appearance10.Image")));
|
|
buttonTool18.SharedProps.AppearancesSmall.Appearance = appearance10;
|
|
buttonTool18.SharedProps.Caption = "LT:UI.Toolbar.Print";
|
|
appearance11.Image = ((object)(resources.GetObject("appearance11.Image")));
|
|
buttonTool19.SharedProps.AppearancesLarge.Appearance = appearance11;
|
|
appearance12.Image = ((object)(resources.GetObject("appearance12.Image")));
|
|
buttonTool19.SharedProps.AppearancesSmall.Appearance = appearance12;
|
|
buttonTool19.SharedProps.Caption = "LT:WorkorderItemPartRequest.Label.List";
|
|
appearance13.Image = ((object)(resources.GetObject("appearance13.Image")));
|
|
buttonTool20.SharedProps.AppearancesLarge.Appearance = appearance13;
|
|
appearance14.Image = ((object)(resources.GetObject("appearance14.Image")));
|
|
buttonTool20.SharedProps.AppearancesSmall.Appearance = appearance14;
|
|
buttonTool20.SharedProps.Caption = "LT:PurchaseOrder.Label.UI.RestockList";
|
|
this.tbManager.Tools.AddRange(new Infragistics.Win.UltraWinToolbars.ToolBase[] {
|
|
buttonTool11,
|
|
buttonTool12,
|
|
buttonTool13,
|
|
buttonTool14,
|
|
buttonTool15,
|
|
buttonTool16,
|
|
buttonTool17,
|
|
controlContainerTool2,
|
|
buttonTool18,
|
|
buttonTool19,
|
|
buttonTool20});
|
|
this.tbManager.UseLargeImagesOnToolbar = true;
|
|
this.tbManager.ToolClick += new Infragistics.Win.UltraWinToolbars.ToolClickEventHandler(this.tbManager_ToolClick);
|
|
//
|
|
// panelLeft
|
|
//
|
|
this.panelLeft.Controls.Add(this.lblStatus);
|
|
this.panelLeft.Controls.Add(this.edVendorInfo);
|
|
this.panelLeft.Controls.Add(this.btnVendorID);
|
|
this.panelLeft.Controls.Add(this.cbVendorID);
|
|
this.panelLeft.Controls.Add(this.cbClientID);
|
|
this.panelLeft.Controls.Add(this.edClientInfo);
|
|
this.panelLeft.Controls.Add(this.btnClientID);
|
|
this.panelLeft.Dock = System.Windows.Forms.DockStyle.Left;
|
|
this.panelLeft.Location = new System.Drawing.Point(0, 40);
|
|
this.panelLeft.Name = "panelLeft";
|
|
this.panelLeft.Size = new System.Drawing.Size(250, 277);
|
|
this.panelLeft.TabIndex = 96;
|
|
//
|
|
// lblStatus
|
|
//
|
|
this.lblStatus.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.lblStatus.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
|
|
this.lblStatus.Location = new System.Drawing.Point(8, 6);
|
|
this.lblStatus.Name = "lblStatus";
|
|
this.lblStatus.Size = new System.Drawing.Size(232, 18);
|
|
this.lblStatus.TabIndex = 161;
|
|
this.lblStatus.Tag = "";
|
|
//
|
|
// edVendorInfo
|
|
//
|
|
this.edVendorInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.edVendorInfo.Location = new System.Drawing.Point(8, 78);
|
|
this.edVendorInfo.Multiline = true;
|
|
this.edVendorInfo.Name = "edVendorInfo";
|
|
this.edVendorInfo.ReadOnly = true;
|
|
this.edVendorInfo.Scrollbars = System.Windows.Forms.ScrollBars.Vertical;
|
|
this.edVendorInfo.Size = new System.Drawing.Size(216, 58);
|
|
this.edVendorInfo.TabIndex = 155;
|
|
//
|
|
// btnVendorID
|
|
//
|
|
this.btnVendorID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
appearance15.TextHAlign = Infragistics.Win.HAlign.Left;
|
|
this.btnVendorID.Appearance = appearance15;
|
|
this.btnVendorID.ButtonStyle = Infragistics.Win.UIElementButtonStyle.PopupBorderless;
|
|
this.btnVendorID.HotTracking = true;
|
|
this.btnVendorID.Location = new System.Drawing.Point(0, 30);
|
|
this.btnVendorID.Name = "btnVendorID";
|
|
this.btnVendorID.Size = new System.Drawing.Size(224, 24);
|
|
this.btnVendorID.TabIndex = 0;
|
|
this.btnVendorID.Tag = "LT:O.Vendor";
|
|
this.btnVendorID.Text = "LT:O.Vendor";
|
|
this.btnVendorID.Click += new System.EventHandler(this.btnVendorID_Click);
|
|
//
|
|
// cbVendorID
|
|
//
|
|
this.cbVendorID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.cbVendorID.Location = new System.Drawing.Point(8, 54);
|
|
this.cbVendorID.Name = "cbVendorID";
|
|
this.cbVendorID.Size = new System.Drawing.Size(216, 21);
|
|
this.cbVendorID.TabIndex = 0;
|
|
this.cbVendorID.SelectionChanged += new System.EventHandler(this.cbVendorID_SelectionChanged);
|
|
this.cbVendorID.NeedMoreData += new GZTW.WinForm.Controls.NeedMoreDataHandler(this.cbVendorID_NeedMoreData);
|
|
//
|
|
// cbClientID
|
|
//
|
|
this.cbClientID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.cbClientID.Location = new System.Drawing.Point(8, 168);
|
|
this.cbClientID.Name = "cbClientID";
|
|
this.cbClientID.Size = new System.Drawing.Size(216, 21);
|
|
this.cbClientID.TabIndex = 1;
|
|
this.cbClientID.SelectionChanged += new System.EventHandler(this.cbClientID_SelectionChanged);
|
|
this.cbClientID.NeedMoreData += new GZTW.WinForm.Controls.NeedMoreDataHandler(this.cbClientID_NeedMoreData);
|
|
//
|
|
// edClientInfo
|
|
//
|
|
this.edClientInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.edClientInfo.Location = new System.Drawing.Point(8, 192);
|
|
this.edClientInfo.Multiline = true;
|
|
this.edClientInfo.Name = "edClientInfo";
|
|
this.edClientInfo.ReadOnly = true;
|
|
this.edClientInfo.Scrollbars = System.Windows.Forms.ScrollBars.Vertical;
|
|
this.edClientInfo.Size = new System.Drawing.Size(216, 72);
|
|
this.edClientInfo.TabIndex = 158;
|
|
//
|
|
// btnClientID
|
|
//
|
|
this.btnClientID.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
appearance16.TextHAlign = Infragistics.Win.HAlign.Left;
|
|
this.btnClientID.Appearance = appearance16;
|
|
this.btnClientID.ButtonStyle = Infragistics.Win.UIElementButtonStyle.PopupBorderless;
|
|
this.btnClientID.HotTracking = true;
|
|
this.btnClientID.Location = new System.Drawing.Point(0, 144);
|
|
this.btnClientID.Name = "btnClientID";
|
|
this.btnClientID.Size = new System.Drawing.Size(216, 24);
|
|
this.btnClientID.TabIndex = 3;
|
|
this.btnClientID.Tag = "LT:PurchaseOrder.Label.DropShipToClientID";
|
|
this.btnClientID.Text = "LT:PurchaseOrder.Label.DropShipToClientID";
|
|
this.btnClientID.Click += new System.EventHandler(this.btnClientID_Click);
|
|
//
|
|
// ErrorProvider
|
|
//
|
|
this.ErrorProvider.ContainerControl = this;
|
|
//
|
|
// panelRight
|
|
//
|
|
this.panelRight.Controls.Add(this.edReferenceNumber);
|
|
this.panelRight.Controls.Add(this.lblReferenceNumber);
|
|
this.panelRight.Controls.Add(this.dtExpectedReceiveDate);
|
|
this.panelRight.Controls.Add(this.lblOrderedDate);
|
|
this.panelRight.Controls.Add(this.dtOrderedDate);
|
|
this.panelRight.Controls.Add(this.lblExpectedReceiveDate);
|
|
this.panelRight.Controls.Add(this.lblVendorMemo);
|
|
this.panelRight.Controls.Add(this.edVendorMemo);
|
|
this.panelRight.Controls.Add(this.lblNotes);
|
|
this.panelRight.Controls.Add(this.edNotes);
|
|
this.panelRight.Controls.Add(this.ckClosed);
|
|
this.panelRight.Dock = System.Windows.Forms.DockStyle.Left;
|
|
this.panelRight.Location = new System.Drawing.Point(250, 40);
|
|
this.panelRight.Name = "panelRight";
|
|
this.panelRight.Size = new System.Drawing.Size(250, 277);
|
|
this.panelRight.TabIndex = 101;
|
|
//
|
|
// edReferenceNumber
|
|
//
|
|
this.edReferenceNumber.Location = new System.Drawing.Point(160, 80);
|
|
this.edReferenceNumber.Name = "edReferenceNumber";
|
|
this.edReferenceNumber.Size = new System.Drawing.Size(88, 21);
|
|
this.edReferenceNumber.TabIndex = 2;
|
|
//
|
|
// lblReferenceNumber
|
|
//
|
|
this.lblReferenceNumber.Location = new System.Drawing.Point(8, 80);
|
|
this.lblReferenceNumber.Name = "lblReferenceNumber";
|
|
this.lblReferenceNumber.Size = new System.Drawing.Size(88, 16);
|
|
this.lblReferenceNumber.TabIndex = 164;
|
|
this.lblReferenceNumber.Tag = "LT:PurchaseOrder.Label.ReferenceNumber";
|
|
this.lblReferenceNumber.Text = "LT:PurchaseOrder.Label.ReferenceNumber";
|
|
this.lblReferenceNumber.WrapText = false;
|
|
//
|
|
// dtExpectedReceiveDate
|
|
//
|
|
this.dtExpectedReceiveDate.Location = new System.Drawing.Point(160, 48);
|
|
this.dtExpectedReceiveDate.Name = "dtExpectedReceiveDate";
|
|
this.dtExpectedReceiveDate.Size = new System.Drawing.Size(88, 21);
|
|
this.dtExpectedReceiveDate.TabIndex = 1;
|
|
//
|
|
// lblOrderedDate
|
|
//
|
|
this.lblOrderedDate.Location = new System.Drawing.Point(8, 16);
|
|
this.lblOrderedDate.Name = "lblOrderedDate";
|
|
this.lblOrderedDate.Size = new System.Drawing.Size(88, 16);
|
|
this.lblOrderedDate.TabIndex = 159;
|
|
this.lblOrderedDate.Tag = "LT:PurchaseOrder.Label.OrderedDate";
|
|
this.lblOrderedDate.Text = "LT:PurchaseOrder.Label.OrderedDate";
|
|
this.lblOrderedDate.WrapText = false;
|
|
//
|
|
// dtOrderedDate
|
|
//
|
|
this.dtOrderedDate.Location = new System.Drawing.Point(160, 16);
|
|
this.dtOrderedDate.Name = "dtOrderedDate";
|
|
this.dtOrderedDate.Size = new System.Drawing.Size(88, 21);
|
|
this.dtOrderedDate.TabIndex = 0;
|
|
this.dtOrderedDate.EditorButtonClick += new Infragistics.Win.UltraWinEditors.EditorButtonEventHandler(this.dtOrderedDate_EditorButtonClick);
|
|
//
|
|
// lblExpectedReceiveDate
|
|
//
|
|
this.lblExpectedReceiveDate.Location = new System.Drawing.Point(8, 48);
|
|
this.lblExpectedReceiveDate.Name = "lblExpectedReceiveDate";
|
|
this.lblExpectedReceiveDate.Size = new System.Drawing.Size(88, 16);
|
|
this.lblExpectedReceiveDate.TabIndex = 163;
|
|
this.lblExpectedReceiveDate.Tag = "LT:PurchaseOrder.Label.ExpectedReceiveDate";
|
|
this.lblExpectedReceiveDate.Text = "LT:PurchaseOrder.Label.ExpectedReceiveDate";
|
|
this.lblExpectedReceiveDate.WrapText = false;
|
|
//
|
|
// lblVendorMemo
|
|
//
|
|
this.lblVendorMemo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.lblVendorMemo.Location = new System.Drawing.Point(8, 112);
|
|
this.lblVendorMemo.Name = "lblVendorMemo";
|
|
this.lblVendorMemo.Size = new System.Drawing.Size(240, 16);
|
|
this.lblVendorMemo.TabIndex = 133;
|
|
this.lblVendorMemo.Tag = "LT:PurchaseOrder.Label.VendorMemo";
|
|
this.lblVendorMemo.Text = "LT:PurchaseOrder.Label.VendorMemo";
|
|
//
|
|
// edVendorMemo
|
|
//
|
|
this.edVendorMemo.AcceptsReturn = true;
|
|
this.edVendorMemo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.edVendorMemo.Location = new System.Drawing.Point(8, 128);
|
|
this.edVendorMemo.Multiline = true;
|
|
this.edVendorMemo.Name = "edVendorMemo";
|
|
this.edVendorMemo.Size = new System.Drawing.Size(240, 56);
|
|
this.edVendorMemo.TabIndex = 3;
|
|
//
|
|
// lblNotes
|
|
//
|
|
this.lblNotes.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.lblNotes.Location = new System.Drawing.Point(8, 192);
|
|
this.lblNotes.Name = "lblNotes";
|
|
this.lblNotes.Size = new System.Drawing.Size(216, 16);
|
|
this.lblNotes.TabIndex = 131;
|
|
this.lblNotes.Tag = "LT:PurchaseOrder.Label.Notes";
|
|
this.lblNotes.Text = "LT:PurchaseOrder.Label.Notes";
|
|
//
|
|
// edNotes
|
|
//
|
|
this.edNotes.AcceptsReturn = true;
|
|
this.edNotes.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
|
| System.Windows.Forms.AnchorStyles.Right)));
|
|
this.edNotes.Location = new System.Drawing.Point(8, 208);
|
|
this.edNotes.Multiline = true;
|
|
this.edNotes.Name = "edNotes";
|
|
this.edNotes.Size = new System.Drawing.Size(240, 56);
|
|
this.edNotes.TabIndex = 4;
|
|
//
|
|
// panelBottom
|
|
//
|
|
this.panelBottom.Controls.Add(this.Grid);
|
|
this.panelBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
|
|
this.panelBottom.Location = new System.Drawing.Point(0, 325);
|
|
this.panelBottom.Name = "panelBottom";
|
|
this.panelBottom.Size = new System.Drawing.Size(728, 176);
|
|
this.panelBottom.TabIndex = 102;
|
|
//
|
|
// Grid
|
|
//
|
|
this.Grid.Cursor = System.Windows.Forms.Cursors.Default;
|
|
this.Grid.DisplayLayout.Override.AllowAddNew = Infragistics.Win.UltraWinGrid.AllowAddNew.TemplateOnBottom;
|
|
this.Grid.DisplayLayout.Override.AllowDelete = Infragistics.Win.DefaultableBoolean.True;
|
|
this.Grid.DisplayLayout.Override.AllowUpdate = Infragistics.Win.DefaultableBoolean.True;
|
|
this.Grid.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
this.Grid.Location = new System.Drawing.Point(0, 0);
|
|
this.Grid.Name = "Grid";
|
|
this.Grid.Size = new System.Drawing.Size(728, 176);
|
|
this.Grid.TabIndex = 0;
|
|
this.Grid.Tag = "LT:O.PurchaseOrderItem";
|
|
this.Grid.Text = "LT:O.PurchaseOrderItem";
|
|
this.Grid.BeforeRowInsert += new Infragistics.Win.UltraWinGrid.BeforeRowInsertEventHandler(this.Grid_BeforeRowInsert);
|
|
this.Grid.AfterCellUpdate += new Infragistics.Win.UltraWinGrid.CellEventHandler(this.Grid_AfterCellUpdate);
|
|
this.Grid.MouseDown += new System.Windows.Forms.MouseEventHandler(this.Grid_MouseDown);
|
|
this.Grid.InitializeRow += new Infragistics.Win.UltraWinGrid.InitializeRowEventHandler(this.Grid_InitializeRow);
|
|
this.Grid.SummaryValueChanged += new Infragistics.Win.UltraWinGrid.SummaryValueChangedEventHandler(this.Grid_SummaryValueChanged);
|
|
//
|
|
// splitter1
|
|
//
|
|
this.splitter1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
|
this.splitter1.Dock = System.Windows.Forms.DockStyle.Bottom;
|
|
this.splitter1.Location = new System.Drawing.Point(0, 317);
|
|
this.splitter1.Name = "splitter1";
|
|
this.splitter1.Size = new System.Drawing.Size(728, 8);
|
|
this.splitter1.TabIndex = 0;
|
|
this.splitter1.TabStop = false;
|
|
//
|
|
// panelCustom
|
|
//
|
|
this.panelCustom.Controls.Add(this.gridCustom);
|
|
this.panelCustom.Dock = System.Windows.Forms.DockStyle.Right;
|
|
this.panelCustom.Location = new System.Drawing.Point(504, 40);
|
|
this.panelCustom.Name = "panelCustom";
|
|
this.panelCustom.Size = new System.Drawing.Size(224, 277);
|
|
this.panelCustom.TabIndex = 108;
|
|
//
|
|
// gridCustom
|
|
//
|
|
this.gridCustom.Cursor = System.Windows.Forms.Cursors.Default;
|
|
this.gridCustom.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
this.gridCustom.Location = new System.Drawing.Point(0, 0);
|
|
this.gridCustom.Name = "gridCustom";
|
|
this.gridCustom.Size = new System.Drawing.Size(224, 277);
|
|
this.gridCustom.TabIndex = 0;
|
|
this.gridCustom.Tag = "LT:ObjectCustomField.Label.CustomGrid";
|
|
this.gridCustom.Text = "LT:ObjectCustomField.Label.CustomGrid";
|
|
this.gridCustom.AfterCellUpdate += new Infragistics.Win.UltraWinGrid.CellEventHandler(this.gridCustom_AfterCellUpdate);
|
|
//
|
|
// _PurchaseOrderInfoForm_Toolbars_Dock_Area_Left
|
|
//
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.BackColor = System.Drawing.SystemColors.Control;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Left;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Location = new System.Drawing.Point(0, 40);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Left";
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.Size = new System.Drawing.Size(0, 461);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left.ToolbarsManager = this.tbManager;
|
|
//
|
|
// _PurchaseOrderInfoForm_Toolbars_Dock_Area_Right
|
|
//
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.BackColor = System.Drawing.SystemColors.Control;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Right;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Location = new System.Drawing.Point(728, 40);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Right";
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.Size = new System.Drawing.Size(0, 461);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right.ToolbarsManager = this.tbManager;
|
|
//
|
|
// _PurchaseOrderInfoForm_Toolbars_Dock_Area_Top
|
|
//
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.BackColor = System.Drawing.SystemColors.Control;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Top;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Location = new System.Drawing.Point(0, 0);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Top";
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.Size = new System.Drawing.Size(728, 40);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top.ToolbarsManager = this.tbManager;
|
|
//
|
|
// _PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom
|
|
//
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.AccessibleRole = System.Windows.Forms.AccessibleRole.Grouping;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.BackColor = System.Drawing.SystemColors.Control;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.DockedPosition = Infragistics.Win.UltraWinToolbars.DockedPosition.Bottom;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.ForeColor = System.Drawing.SystemColors.ControlText;
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Location = new System.Drawing.Point(0, 501);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Name = "_PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom";
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.Size = new System.Drawing.Size(728, 0);
|
|
this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom.ToolbarsManager = this.tbManager;
|
|
//
|
|
// PurchaseOrderInfoForm
|
|
//
|
|
this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
|
|
this.ClientSize = new System.Drawing.Size(728, 501);
|
|
this.Controls.Add(this.panelCustom);
|
|
this.Controls.Add(this.panelRight);
|
|
this.Controls.Add(this.panelLeft);
|
|
this.Controls.Add(this.splitter1);
|
|
this.Controls.Add(this.panelBottom);
|
|
this.Controls.Add(this.ckIsDirty);
|
|
this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Left);
|
|
this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Right);
|
|
this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Top);
|
|
this.Controls.Add(this._PurchaseOrderInfoForm_Toolbars_Dock_Area_Bottom);
|
|
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
|
|
this.MinimumSize = new System.Drawing.Size(512, 488);
|
|
this.Name = "PurchaseOrderInfoForm";
|
|
this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Show;
|
|
this.Closing += new System.ComponentModel.CancelEventHandler(this.PurchaseOrderInfoForm_Closing);
|
|
this.SizeChanged += new System.EventHandler(this.PurchaseOrderInfoForm_SizeChanged);
|
|
this.Load += new System.EventHandler(this.PurchaseOrderInfoForm_Load);
|
|
((System.ComponentModel.ISupportInitialize)(this.tbManager)).EndInit();
|
|
this.panelLeft.ResumeLayout(false);
|
|
((System.ComponentModel.ISupportInitialize)(this.edVendorInfo)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.cbVendorID)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.cbClientID)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edClientInfo)).EndInit();
|
|
this.panelRight.ResumeLayout(false);
|
|
((System.ComponentModel.ISupportInitialize)(this.edReferenceNumber)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.dtExpectedReceiveDate)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.dtOrderedDate)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edVendorMemo)).EndInit();
|
|
((System.ComponentModel.ISupportInitialize)(this.edNotes)).EndInit();
|
|
this.panelBottom.ResumeLayout(false);
|
|
((System.ComponentModel.ISupportInitialize)(this.Grid)).EndInit();
|
|
this.panelCustom.ResumeLayout(false);
|
|
((System.ComponentModel.ISupportInitialize)(this.gridCustom)).EndInit();
|
|
this.ResumeLayout(false);
|
|
|
|
}
|
|
#endregion
|
|
|
|
|
|
// __ _ _ ___ ____ __ __ __ __ __ ___ ___
|
|
// / _)( )( )/ __)(_ _)/ \( \/ ) / _)/ \( \( _)
|
|
// ( (_ )()( \__ \ )( ( () )) ( ( (_( () )) ) )) _)
|
|
// \__) \__/ (___/ (__) \__/(_/\/\_) \__)\__/(___/(___)
|
|
//
|
|
|
|
|
|
|
|
#region Form Load / Close
|
|
//variable to hold user form settings
|
|
UIUserFormSetting mFormSetting;
|
|
|
|
//Variable to hold tax codes used in calculating line totals etc
|
|
TaxCodeList TaxList;
|
|
|
|
//Variable to hold part prices / cost / tax codes
|
|
//used in calculating line totals etc
|
|
PartPickList PartList;
|
|
|
|
PartRestockRequiredByVendorList mRestockList=null;
|
|
PartWorkorderItemRequestByVendorList mRequestList=null;
|
|
/// <summary>
|
|
/// Prepare the form
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void PurchaseOrderInfoForm_Load(object sender, System.EventArgs e)
|
|
{
|
|
log.Debug("PurchaseOrderInfoForm_Load");
|
|
|
|
Cursor.Current = Cursors.WaitCursor;
|
|
this.Visible=false;
|
|
|
|
|
|
//See if user has any rights to be here...
|
|
//(this is done here to ensure that no matter what happens if a user has no rights they can't get here
|
|
//useful in case we miss a way of getting to a client edit screen from elsewhere in the program)
|
|
if(Util.BP.Right("Object.PurchaseOrder")< (int)SecurityLevelTypes.ReadOnly)//Less than read only instead of NoAccess to catch records where it's zero instead of 1
|
|
{
|
|
//Inform them of their wicked ways and boot them out of here...
|
|
|
|
MessageBox.Show(string.Format(
|
|
Util.LocaleText.GetLocalizedText("Error.Security.NotAuthorizedToRetrieve"),
|
|
Util.LocaleText.GetLocalizedText("O.PurchaseOrder")));
|
|
|
|
this.Close();
|
|
return;
|
|
}
|
|
|
|
//Populate tax code list so we can
|
|
//quickly calculate taxes on line items
|
|
TaxList= TaxCodeList.GetList();
|
|
|
|
|
|
|
|
InitializeComboBoxes();
|
|
DataBind();
|
|
InitializeGrid();
|
|
|
|
|
|
|
|
|
|
//size and move form per last setting
|
|
mFormSetting=Util.GetFormSettings("PurchaseOrderInfo");
|
|
if(mFormSetting.FormWidth!=0)
|
|
{
|
|
this.Width=mFormSetting.FormWidth;
|
|
this.Height=mFormSetting.FormHeight;
|
|
this.splitter1.SplitPosition=mFormSetting.SplitPosition1;
|
|
this.Left=mFormSetting.LocationX;
|
|
this.Top=mFormSetting.LocationY;
|
|
}
|
|
|
|
//==========================================================================
|
|
//Load the toolbarmanager layout
|
|
if(mFormSetting.ToolBarManagerLayoutSize>0 && ((Control.ModifierKeys & Keys.Shift)==0) /*Shift key not held down*/)
|
|
{
|
|
tbManager.LoadFromBinary(mFormSetting.GetToolBarManagerLayoutContent());
|
|
}
|
|
//==========================================================================
|
|
Util.Localize(this);
|
|
|
|
Cursor.Current = Cursors.Default;
|
|
Application.Idle+= new EventHandler(Application_Idle);
|
|
|
|
//get the totals re-calc'ed
|
|
RefreshCalcs();
|
|
|
|
//Fill address info boxes
|
|
DisplayFullerAddressForVendorSelected();
|
|
DisplayFullerAddressForClientSelected();
|
|
|
|
Util.LocalizeGrid(Grid);
|
|
|
|
//show requests if any present
|
|
RefreshRestockRequestToolBarButtons();
|
|
|
|
//restrict UI based on security settings
|
|
RestrictUI();
|
|
|
|
this.Visible=true;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
/// Used to track whether the close was done by the program
|
|
/// or done by the user clicking on the upper left corner X control
|
|
/// </summary>
|
|
bool bClosingHandled=false;
|
|
|
|
bool bSuspendAppIdleHandler=false;
|
|
|
|
/// <summary>
|
|
/// Save form layout and grid layout for next time
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void PurchaseOrderInfoForm_Closing(object sender, System.ComponentModel.CancelEventArgs e)
|
|
{
|
|
log.Debug("PurchaseOrderInfoForm_Closing");
|
|
|
|
bSuspendAppIdleHandler=true;
|
|
|
|
if(!bClosingHandled)
|
|
{
|
|
//Save record if necessary
|
|
//User may opt to not cancel exit
|
|
if(!RecordUpdate(RecordActionType.PromptToSave) )
|
|
{
|
|
e.Cancel=true;
|
|
bSuspendAppIdleHandler=false;
|
|
return;
|
|
}
|
|
}
|
|
|
|
Application.Idle-= new EventHandler(Application_Idle);
|
|
|
|
Util.SaveGridLayout("PurchaseOrderItems","","",Grid);
|
|
mFormSetting.FormWidth=this.Width;
|
|
mFormSetting.FormHeight=this.Height;
|
|
mFormSetting.SplitPosition1=this.splitter1.SplitPosition;
|
|
mFormSetting.LocationX=this.Location.X;
|
|
mFormSetting.LocationY=this.Location.Y;
|
|
|
|
//===========================================================
|
|
//Save ToolBar customization
|
|
System.IO.MemoryStream msTemp=new System.IO.MemoryStream();
|
|
tbManager.SaveAsBinary(msTemp,true);
|
|
mFormSetting.SetToolBarManagerLayoutContent(msTemp);
|
|
//===========================================================
|
|
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Form Sizing
|
|
/// <summary>
|
|
/// Adjust the layout proportionately as it's sized by user
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void PurchaseOrderInfoForm_SizeChanged(object sender, System.EventArgs e)
|
|
{
|
|
log.Debug("PurchaseOrderInfoForm_SizeChanged");
|
|
|
|
int nWidth=0;
|
|
int nHeight=(this.DisplayRectangle.Height/3)*2;
|
|
if(bShowCustomFields) //there are three panels
|
|
nWidth=this.DisplayRectangle.Width/3;
|
|
else//there are two panels
|
|
nWidth=this.DisplayRectangle.Width/2;
|
|
|
|
this.panelLeft.Width=nWidth;
|
|
this.panelRight.Width=nWidth;
|
|
if(bShowCustomFields)
|
|
this.panelCustom.Width=nWidth;
|
|
this.panelLeft.Height=nHeight;
|
|
this.panelRight.Height=nHeight;
|
|
this.panelCustom.Height=nHeight;
|
|
this.panelBottom.Height=(this.DisplayRectangle.Height/3)-40;
|
|
|
|
//Size of controls in panel
|
|
//One third
|
|
int nLeftWidth=(this.panelLeft.Width/3);
|
|
//two thirds
|
|
int nRightWidth=this.panelLeft.Width-nLeftWidth;
|
|
|
|
//Size and align controls in right panel
|
|
nRightWidth=nRightWidth-8;
|
|
|
|
lblOrderedDate.Width=nLeftWidth;
|
|
dtOrderedDate.Left=nLeftWidth+8;
|
|
dtOrderedDate.Width=nRightWidth;
|
|
|
|
lblExpectedReceiveDate.Width=nLeftWidth;
|
|
dtExpectedReceiveDate.Left=nLeftWidth+8;
|
|
dtExpectedReceiveDate.Width=nRightWidth;
|
|
|
|
lblReferenceNumber.Width=nLeftWidth;
|
|
edReferenceNumber.Left=nLeftWidth+8;
|
|
edReferenceNumber.Width=nRightWidth;
|
|
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Form UI commands
|
|
|
|
#region Toolbar menu items
|
|
|
|
/// <summary>
|
|
/// Respond to a click on a toolbar menu item
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void tbManager_ToolClick(object sender, Infragistics.Win.UltraWinToolbars.ToolClickEventArgs e)
|
|
{
|
|
if(log.IsDebugEnabled) log.Debug("ToolClick: "+e.Tool.Key);
|
|
|
|
|
|
switch (e.Tool.Key)
|
|
{
|
|
case "LT:UI.Command.SaveClose": // ButtonTool
|
|
RecordUpdate(RecordActionType.SaveAndExit);
|
|
break;
|
|
|
|
case "LT:UI.Command.RecordHistory": // ButtonTool
|
|
RecordHistoryForm RH=new RecordHistoryForm(mPurchaseOrder.Creator,mPurchaseOrder.Modifier,mPurchaseOrder.Created,mPurchaseOrder.Modified);
|
|
RH.ShowDialog();
|
|
break;
|
|
|
|
case "LT:UI.Command.Save": // ButtonTool
|
|
RecordUpdate(RecordActionType.SaveOnly);
|
|
break;
|
|
|
|
case "LT:UI.Command.SaveNew": // ButtonTool
|
|
RecordUpdate(RecordActionType.SaveAndNew);
|
|
break;
|
|
|
|
case "LT:UI.Command.Close": // ButtonTool
|
|
this.Close();
|
|
break;
|
|
|
|
case "LT:UI.Command.Delete": // ButtonTool
|
|
RecordUpdate(RecordActionType.DeleteAndExit);
|
|
break;
|
|
|
|
case "LT:UI.Command.Ordered": // ButtonTool
|
|
//Are you sure you want to set this P.O. to Ordered status?
|
|
DialogResult result=MessageBox.Show(Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.UI.OrderedWarning"),"Warning",MessageBoxButtons.YesNo,
|
|
MessageBoxIcon.Warning,MessageBoxDefaultButton.Button2);
|
|
|
|
if(result!=DialogResult.Yes)
|
|
return;
|
|
|
|
//commit any changes to grid before changing status
|
|
Grid.UpdateData();
|
|
btnVendorID.Focus();
|
|
|
|
//set to open ordered status
|
|
mPurchaseOrder.Status=PurchaseOrderStatus.OpenOrdered;
|
|
break;
|
|
|
|
case "LT:UI.Command.Closed": // ControlContainerTool
|
|
//does nothing, is handled by the ckClosed Click event itself since
|
|
//this item is just a control container and doesn't have a click event
|
|
break;
|
|
|
|
|
|
case "LT:PurchaseOrder.Label.UI.RestockList": // ButtonTool
|
|
//without this things go wierd as if the vendorid combo is keeping focus
|
|
//somehow and when you go to type in another edit box you don't get a cursor
|
|
btnVendorID.Focus();
|
|
PartRestockRequiredByVendorForm f = new PartRestockRequiredByVendorForm();
|
|
f.PartInventoriesToEdit=this.mRestockList;
|
|
f.VendorNameToDisplay=cbVendorID.Text;
|
|
f.PurchaseOrderToEdit=this.mPurchaseOrder;
|
|
if(f.ShowDialog()==DialogResult.OK)
|
|
RefreshCalcs();
|
|
|
|
break;
|
|
|
|
case "LT:WorkorderItemPartRequest.Label.List": // ButtonTool
|
|
//without this things go wierd as if the vendorid combo is keeping focus
|
|
//somehow and when you go to type in another edit box you don't get a cursor
|
|
btnVendorID.Focus();
|
|
PartWorkorderItemRequestByVendorForm r = new PartWorkorderItemRequestByVendorForm();
|
|
r.PartWorkorderItemRequestToEdit=this.mRequestList;
|
|
r.VendorNameToDisplay=cbVendorID.Text;
|
|
r.PurchaseOrderToEdit=this.mPurchaseOrder;
|
|
if(r.ShowDialog()==DialogResult.OK)
|
|
RefreshCalcs();
|
|
break;
|
|
//
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
#endregion Toolbar menu items
|
|
|
|
#region hyperButtons
|
|
|
|
private void btnVendorID_Click(object sender, System.EventArgs e)
|
|
{
|
|
log.Debug("btnVendorID_Click");
|
|
|
|
VendorInfoForm cf=new VendorInfoForm();
|
|
if(cbVendorID.Value!=null && (Guid)cbVendorID.Value!=Guid.Empty)
|
|
{
|
|
cf.VendorToEdit=Vendor.GetItem((Guid)cbVendorID.Value);
|
|
}
|
|
else
|
|
{
|
|
if(Util.BP.Right("Object.Vendor")< (int)SecurityLevelTypes.ReadWrite)
|
|
{
|
|
log.Debug("No Vendor selected to view and user has no rights to create a new one.");
|
|
return;
|
|
}
|
|
cf.VendorToEdit=Vendor.NewItem();
|
|
}
|
|
cf.Visible=false;
|
|
cf.ShowDialog();
|
|
if(cf.ChangesMade)
|
|
{
|
|
mPurchaseOrder.VendorID=Guid.Empty;
|
|
Util.FillGZComboBoxWithNameIDList("Vendor",cbVendorID,false,Guid.Empty);
|
|
mPurchaseOrder.VendorID=cf.VendorToEdit.ID;
|
|
|
|
}
|
|
}
|
|
|
|
private void btnClientID_Click(object sender, System.EventArgs e)
|
|
{
|
|
log.Debug("btnClientID_Click");
|
|
|
|
ClientInfoForm cf=new ClientInfoForm();
|
|
if(cbClientID.Value!=null && (Guid)cbClientID.Value!=Guid.Empty)
|
|
{
|
|
cf.ClientToEdit=Client.GetItem((Guid)cbClientID.Value);
|
|
}
|
|
else
|
|
{
|
|
if(Util.BP.Right("Object.Client")< (int)SecurityLevelTypes.ReadWrite)
|
|
{
|
|
log.Debug("No Client selected to view and user has no rights to create a new one.");
|
|
return;
|
|
}
|
|
cf.ClientToEdit=Client.NewItem();
|
|
}
|
|
cf.Visible=false;
|
|
cf.ShowDialog();
|
|
if(cf.ChangesMade)
|
|
{
|
|
mPurchaseOrder.DropShipToClientID=Guid.Empty;
|
|
Util.FillGZComboBoxWithNameIDList("Client",cbClientID,false,Guid.Empty);
|
|
mPurchaseOrder.DropShipToClientID=cf.ClientToEdit.ID;
|
|
}
|
|
}
|
|
|
|
|
|
#endregion hyperButtons
|
|
|
|
|
|
//Click on closed checkbox (which is actually in the menu)
|
|
//but handled here just like a regular form item
|
|
private void ckClosed_CheckedChanged(object sender, System.EventArgs e)
|
|
{
|
|
log.Debug("ckClosed_CheckedChanged");
|
|
|
|
|
|
|
|
//Flip the status depending upon what it currently is
|
|
switch(mPurchaseOrder.Status)
|
|
{
|
|
//It's one of these which are the only statuses where
|
|
//closed is even visible
|
|
case PurchaseOrderStatus.ClosedNoneReceived:
|
|
mPurchaseOrder.Status=PurchaseOrderStatus.OpenOrdered;
|
|
break;
|
|
case PurchaseOrderStatus.ClosedPartialReceived:
|
|
mPurchaseOrder.Status=PurchaseOrderStatus.OpenPartialReceived;
|
|
break;
|
|
case PurchaseOrderStatus.OpenOrdered:
|
|
mPurchaseOrder.Status=PurchaseOrderStatus.ClosedNoneReceived;
|
|
break;
|
|
case PurchaseOrderStatus.OpenPartialReceived:
|
|
mPurchaseOrder.Status=PurchaseOrderStatus.ClosedPartialReceived;
|
|
break;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion Form UI commands
|
|
|
|
#region Form UI / Business object synchronization and Restrictions
|
|
|
|
/// <summary>
|
|
/// used on load of form and when adding parts from lists
|
|
/// to force a recalc of all taxes etc
|
|
/// </summary>
|
|
private void RefreshCalcs()
|
|
{
|
|
//get the totals calced
|
|
if(Grid.Rows.Count>0)
|
|
{
|
|
|
|
foreach(UltraGridRow r in Grid.Rows)
|
|
{
|
|
r.Refresh(RefreshRow.FireInitializeRow);
|
|
}
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// Synchronize the state of the UI to the BO's
|
|
/// </summary>
|
|
private void SyncUI()
|
|
{
|
|
bool CanEdit=Util.BP.Right("Object.PurchaseOrder")> (int)SecurityLevelTypes.ReadOnly;
|
|
|
|
tbManager.Tools["LT:UI.Command.Save"].SharedProps.Enabled=mPurchaseOrder.IsSavable;
|
|
tbManager.Tools["LT:UI.Command.SaveClose"].SharedProps.Enabled=mPurchaseOrder.IsSavable;
|
|
tbManager.Tools["LT:UI.Command.SaveNew"].SharedProps.Enabled=mPurchaseOrder.IsSavable;
|
|
|
|
|
|
//adjust UI access on the fly
|
|
//as po status changes
|
|
switch(mPurchaseOrder.Status)
|
|
{
|
|
case PurchaseOrderStatus.ClosedFullReceived:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.ClosedFullReceived");
|
|
SetAccess(true,false);
|
|
break;
|
|
|
|
case PurchaseOrderStatus.ClosedNoneReceived:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.ClosedNoneReceived");
|
|
SetAccess(true,false);
|
|
//Allowed to edit?
|
|
tbManager.Tools["LT:UI.Command.Closed"].SharedProps.Visible=CanEdit;
|
|
|
|
|
|
break;
|
|
|
|
case PurchaseOrderStatus.ClosedPartialReceived:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.ClosedPartialReceived");
|
|
SetAccess(true,false);
|
|
tbManager.Tools["LT:UI.Command.Closed"].SharedProps.Visible=CanEdit;
|
|
|
|
|
|
break;
|
|
|
|
case PurchaseOrderStatus.OpenNotYetOrdered:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.OpenNotYetOrdered");
|
|
tbManager.Tools["LT:UI.Command.Closed"].SharedProps.Visible=false;
|
|
tbManager.Tools["LT:UI.Command.Ordered"].SharedProps.Visible=CanEdit;
|
|
|
|
//Allowed to edit?
|
|
if(CanEdit)
|
|
{
|
|
SetAccess(false,false);
|
|
}
|
|
|
|
break;
|
|
|
|
case PurchaseOrderStatus.OpenOrdered:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.OpenOrdered");
|
|
|
|
//restrict all access...
|
|
SetAccess(true,false);
|
|
|
|
|
|
//re-enable some items
|
|
tbManager.Tools["LT:UI.Command.Closed"].SharedProps.Visible=CanEdit;
|
|
tbManager.Tools["LT:UI.Command.Ordered"].SharedProps.Visible=false;
|
|
if(CanEdit)
|
|
Grid.DisplayLayout.Bands[0].Columns["Closed"].CellActivation=Activation.AllowEdit;
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns["Closed"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
|
|
break;
|
|
|
|
case PurchaseOrderStatus.OpenPartialReceived:
|
|
lblStatus.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PurchaseOrderStatus.OpenPartialReceived");
|
|
SetAccess(true,false);
|
|
|
|
tbManager.Tools["LT:UI.Command.Closed"].SharedProps.Visible=CanEdit;
|
|
if(CanEdit)
|
|
Grid.DisplayLayout.Bands[0].Columns["Closed"].CellActivation=Activation.AllowEdit;
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns["Closed"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
}
|
|
|
|
|
|
//PurchaseOrder.Label.PONumber
|
|
if(mPurchaseOrder.PONumber!=0)
|
|
this.Text=Util.LocaleText.GetLocalizedText("PurchaseOrder.Label.PONumber")+" "+mPurchaseOrder.PONumber.ToString();
|
|
else
|
|
this.Text=Util.LocaleText.GetLocalizedText("O.PurchaseOrder");
|
|
|
|
//lock vendor if there are items selected
|
|
cbVendorID.Enabled=(mPurchaseOrder.OrderItems.Count==0);
|
|
|
|
//Status sensitive items
|
|
//within grid itself
|
|
switch(mPurchaseOrder.Status)
|
|
{
|
|
case PurchaseOrderStatus.OpenNotYetOrdered:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=true;
|
|
//tbManager.Tools["LT:UI.Command.Save"].SharedProps.Enabled=mPurchaseOrder.IsSavable;
|
|
break;
|
|
case PurchaseOrderStatus.OpenOrdered:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=true;
|
|
break;
|
|
case PurchaseOrderStatus.OpenPartialReceived:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=false;
|
|
break;
|
|
case PurchaseOrderStatus.ClosedPartialReceived:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=false;
|
|
break;
|
|
case PurchaseOrderStatus.ClosedFullReceived:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=false;
|
|
break;
|
|
case PurchaseOrderStatus.ClosedNoneReceived:
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].Hidden=false;
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/// <summary>
|
|
/// When the application enters an idle state
|
|
/// update the UI to reflect changs in BO status
|
|
/// (required because grids don't tell the UI to update when they are
|
|
/// bound to a business object and are edited)
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void Application_Idle(object sender, EventArgs e)
|
|
{
|
|
if(!bSuspendAppIdleHandler)
|
|
SyncUI();
|
|
|
|
}
|
|
|
|
/// <summary>
|
|
/// Adapt UI to accomodate users security access level
|
|
/// </summary>
|
|
private void RestrictUI()
|
|
{
|
|
if(log.IsDebugEnabled) log.Debug("RestrictUI: " + ((SecurityLevelTypes)Util.BP.Right("Object.PurchaseOrder")).ToString());
|
|
|
|
|
|
//PurchaseOrder - Read only
|
|
if(Util.BP.Right("Object.PurchaseOrder") == (int)SecurityLevelTypes.ReadOnly)
|
|
SetAccess(true,true);
|
|
else
|
|
SetAccess(false,true);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
//Flag to save time setting to read only if has been done already
|
|
bool bCurrentStateIsReadOnly=false;
|
|
|
|
/// <summary>
|
|
/// Set everything to Read only or editable state
|
|
/// used to set access rights and or
|
|
/// if po is locked after entry
|
|
/// safe to call repeatedly from anywhere, takes into account
|
|
/// security rights
|
|
/// </summary>
|
|
/// <param name="ReadOnly">Set access rights to read only if true</param>
|
|
/// <param name="ForceSetting">Make settings regardless if already set that way, used to initialize first time</param>
|
|
private void SetAccess(bool ReadOnly, bool ForceSetting)
|
|
{
|
|
log.Debug("SetAccess");
|
|
|
|
//Already set this way?
|
|
if(!ForceSetting && bCurrentStateIsReadOnly==ReadOnly) return;
|
|
|
|
//Set tool visibility
|
|
tbManager.Tools["LT:UI.Command.SaveClose"].SharedProps.Visible=!ReadOnly;
|
|
tbManager.Tools["LT:UI.Command.Delete"].SharedProps.Visible=!ReadOnly;
|
|
tbManager.Tools["LT:UI.Command.SaveNew"].SharedProps.Visible=!ReadOnly;
|
|
tbManager.Tools["LT:UI.Command.Save"].SharedProps.Visible=!ReadOnly;
|
|
tbManager.Tools["LT:UI.Command.Close"].SharedProps.Visible=true;
|
|
|
|
|
|
|
|
|
|
//DISABLE / ENABLE EDITABLE CONTROLS
|
|
|
|
//Text editors
|
|
edReferenceNumber.ReadOnly=ReadOnly;
|
|
edNotes.ReadOnly=ReadOnly;
|
|
edVendorMemo.ReadOnly=ReadOnly;
|
|
|
|
//Date pickers
|
|
dtOrderedDate.ReadOnly=ReadOnly;
|
|
dtExpectedReceiveDate.ReadOnly=ReadOnly;
|
|
|
|
//Combo boxes
|
|
cbVendorID.ReadOnly=ReadOnly;
|
|
cbClientID.ReadOnly=ReadOnly;
|
|
|
|
//Buttons
|
|
btnVendorID.Enabled=!ReadOnly;
|
|
btnVendorID.Appearance.ForeColorDisabled=System.Drawing.SystemColors.ControlText;
|
|
btnClientID.Enabled=!ReadOnly;
|
|
btnClientID.Appearance.ForeColorDisabled=System.Drawing.SystemColors.ControlText;
|
|
|
|
//Grids
|
|
if(ReadOnly)
|
|
{
|
|
Grid.DisplayLayout.Override.AllowAddNew=AllowAddNew.No;
|
|
Grid.DisplayLayout.Override.AllowDelete=DefaultableBoolean.False;
|
|
|
|
//disallow editing on all columns
|
|
//Can't just turn off editing for grid as a whole
|
|
//because there is a single field that needs to sometimes
|
|
//be editable even when the rest is read only
|
|
foreach(UltraGridColumn c in Grid.DisplayLayout.Bands[0].Columns)
|
|
{
|
|
c.CellActivation=Activation.ActivateOnly;
|
|
|
|
}
|
|
|
|
gridCustom.DisplayLayout.Override.AllowAddNew=AllowAddNew.No;
|
|
gridCustom.DisplayLayout.Override.AllowDelete=DefaultableBoolean.False;
|
|
gridCustom.DisplayLayout.Override.AllowUpdate=DefaultableBoolean.False;
|
|
}
|
|
else
|
|
{
|
|
Grid.DisplayLayout.Override.AllowAddNew=AllowAddNew.TemplateOnBottom;
|
|
Grid.DisplayLayout.Override.AllowDelete=DefaultableBoolean.True;
|
|
|
|
//Allow editing on all columns
|
|
foreach(UltraGridColumn c in Grid.DisplayLayout.Bands[0].Columns)
|
|
{
|
|
c.CellActivation=Activation.AllowEdit;
|
|
|
|
}
|
|
|
|
//this column should never be editable here
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
//always no for custom fields since there is a fixed number
|
|
//of rows, this is just insurance
|
|
gridCustom.DisplayLayout.Override.AllowAddNew=AllowAddNew.No;
|
|
gridCustom.DisplayLayout.Override.AllowDelete=DefaultableBoolean.False;
|
|
|
|
//however we can allow updating of data...
|
|
gridCustom.DisplayLayout.Override.AllowUpdate=DefaultableBoolean.True;
|
|
|
|
}
|
|
|
|
|
|
//Fixup for additional restriction if full access...
|
|
//PurchaseOrder - Full but no delete
|
|
if(!ReadOnly)
|
|
{
|
|
if(Util.BP.Right("Object.PurchaseOrder")== (int)SecurityLevelTypes.ReadWrite)
|
|
{
|
|
tbManager.Tools["LT:UI.Command.Delete"].SharedProps.Enabled=false;
|
|
//Remove tools that user is not allowed access to use
|
|
tbManager.Tools["LT:UI.Command.Delete"].SharedProps.Visible=false;
|
|
|
|
//Disable delete row in grid
|
|
Grid.DisplayLayout.Override.AllowDelete=DefaultableBoolean.False;
|
|
|
|
return;
|
|
}
|
|
}
|
|
|
|
|
|
bCurrentStateIsReadOnly=ReadOnly;
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// retrieve and display address
|
|
/// and contact info for selected vendor
|
|
/// </summary>
|
|
private void DisplayFullerAddressForVendorSelected()
|
|
{
|
|
|
|
log.Debug("DisplayFullerAddressForVendorSelected");
|
|
|
|
//Need a selected vendor to be able to do this
|
|
//If there isn't one, then bail
|
|
if(cbVendorID.Value==null || (Guid)cbVendorID.Value==Guid.Empty)
|
|
return;
|
|
|
|
//Retrieve the vendor record
|
|
Vendor v = Vendor.GetItem((Guid)cbVendorID.Value);
|
|
|
|
StringBuilder b = new StringBuilder();
|
|
b.Append(v.MailToAddress.FullAddress);
|
|
b.Append("\r\n");
|
|
b.Append(v.Contacts.GetPrimaryContactDefaultContactInfo());
|
|
|
|
edVendorInfo.Text=b.ToString();
|
|
|
|
}
|
|
|
|
/// <summary>
|
|
/// retrieve and display address
|
|
/// and contact info for selected Client
|
|
/// </summary>
|
|
private void DisplayFullerAddressForClientSelected()
|
|
{
|
|
|
|
log.Debug("DisplayFullerAddressForClientSelected");
|
|
|
|
//Need a selected Client to be able to do this
|
|
//If there isn't one, then bail
|
|
if(cbClientID.Value==null || (Guid)cbClientID.Value==Guid.Empty)
|
|
return;
|
|
|
|
//retrieve the client record
|
|
Client c = Client.GetItem((Guid)cbClientID.Value);
|
|
|
|
StringBuilder b = new StringBuilder();
|
|
b.Append(c.MailToAddress.FullAddress);
|
|
b.Append("\r\n");
|
|
b.Append(c.Contacts.GetPrimaryContactDefaultContactInfo());
|
|
|
|
edClientInfo.Text=b.ToString();
|
|
|
|
}
|
|
#endregion
|
|
|
|
#region Form DataBinding and BrokenRules handling
|
|
|
|
bool bShowCustomFields=false;
|
|
bool bBinding=false;
|
|
/// <summary>
|
|
/// Bind controls to business objects
|
|
/// </summary>
|
|
private void DataBind()
|
|
{
|
|
|
|
log.Debug("DataBind");
|
|
|
|
bBinding=true;
|
|
|
|
//prevent initialze row from firing and throwing errors when it finds there is no data
|
|
//to calculate line totals on...
|
|
Grid.EventManager.SetEnabled(GridEventIds.InitializeRow,false);
|
|
|
|
//Custom fields are not databound, but must be initiated manually...
|
|
FillCustomFieldGrid();
|
|
|
|
//Subscribe to broken rules changed event OnBrokenRulesChanged
|
|
mPurchaseOrder.GetBrokenRulesCollection().ListChanged += new System.ComponentModel.ListChangedEventHandler(OnBrokenRulesChanged);
|
|
|
|
|
|
//=-=-=-=-=-=- Form Field bindings =-=-=-=-=-=-=-=-=-=-=-=
|
|
|
|
//Text editors
|
|
Util.BindField(edNotes,"Text",mPurchaseOrder,"Notes");
|
|
|
|
Util.BindField(edReferenceNumber,"Text",mPurchaseOrder,"ReferenceNumber");
|
|
Util.BindField(edVendorMemo,"Text",mPurchaseOrder,"VendorMemo");
|
|
|
|
//Combo boxes
|
|
|
|
Util.BindField(cbVendorID,"Value",mPurchaseOrder,"VendorID");
|
|
Util.BindField(cbClientID,"Value",mPurchaseOrder,"DropShipToClientID");
|
|
|
|
|
|
|
|
//Grids
|
|
Util.BindField(Grid,"DataSource",mPurchaseOrder,"OrderItems");
|
|
|
|
//Dates
|
|
Util.BindField(dtOrderedDate,"Value", mPurchaseOrder, "OrderedDate");
|
|
Util.BindField(dtExpectedReceiveDate,"Value", mPurchaseOrder, "ExpectedReceiveDate");
|
|
|
|
//Bind IsDirty property to hidden checkbox to
|
|
//ensure isdirtychanged event is available
|
|
//to data binding infrastructure
|
|
Util.BindField(ckIsDirty,"Checked",mPurchaseOrder,"IsDirty");
|
|
|
|
//Setup initial link to broken rules
|
|
OnBrokenRulesChanged(null,null);
|
|
|
|
bBinding=false;
|
|
|
|
//turn initialize row event back on
|
|
Grid.EventManager.SetEnabled(GridEventIds.InitializeRow,true);
|
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Handle a change in broken rules
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void OnBrokenRulesChanged(object sender, System.ComponentModel.ListChangedEventArgs e)
|
|
{
|
|
Util.BrokenRuleFeedback(this,mPurchaseOrder,ErrorProvider);
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
#region Business object editing / adding / deletion related code
|
|
|
|
|
|
private PurchaseOrder mPurchaseOrder;
|
|
/// <summary>
|
|
/// PurchaseOrder record to display
|
|
/// set by caller
|
|
/// </summary>
|
|
public PurchaseOrder PurchaseOrderToEdit
|
|
{
|
|
get
|
|
{
|
|
return mPurchaseOrder;
|
|
}
|
|
set
|
|
{
|
|
mPurchaseOrder=value;
|
|
//mPurchaseOrder.BeginEdit();
|
|
|
|
}
|
|
}
|
|
|
|
|
|
//Used to signal to main form that there are changes
|
|
//which could affect it if true
|
|
private bool mbChangesMade=false;
|
|
public bool ChangesMade
|
|
{
|
|
get
|
|
{
|
|
return mbChangesMade;
|
|
}
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Update record and quit if requested
|
|
///
|
|
/// </summary>
|
|
/// <returns>True if handled, false if not handled</returns>
|
|
private bool RecordUpdate(RecordActionType SaveType)
|
|
{
|
|
if(log.IsDebugEnabled) log.Debug("SaveHandler(Action="+SaveType.ToString()+")");
|
|
|
|
//switch the focus to a non-editable control
|
|
//so that any changes in the current editable control
|
|
//will get updated before attempting to save
|
|
btnVendorID.Focus();
|
|
|
|
//Added by John Dec 2 2004 (catches change in grid when above is non focusable)
|
|
Grid.UpdateData();
|
|
|
|
switch(SaveType)
|
|
{
|
|
case RecordActionType.DeleteAndExit:
|
|
if(Util.PromptForDelete()==DialogResult.Yes)
|
|
{
|
|
//Delete, then exit
|
|
try
|
|
{
|
|
PurchaseOrder.DeleteItem(mPurchaseOrder.ID);
|
|
}
|
|
catch(Exception ex)
|
|
{
|
|
Util.ReportSQLError(ex);
|
|
return false;
|
|
}
|
|
bClosingHandled=true;
|
|
this.Close();
|
|
mbChangesMade=true;
|
|
return true;
|
|
}
|
|
else return false;
|
|
|
|
case RecordActionType.SaveAndExit:
|
|
//Save if necessary and exit
|
|
if(mPurchaseOrder.IsSavable)
|
|
{
|
|
mPurchaseOrder.ApplyEdit();
|
|
mPurchaseOrder.Save();
|
|
bClosingHandled=true;
|
|
mbChangesMade=true;
|
|
this.Close();
|
|
return true;
|
|
}
|
|
if(mPurchaseOrder.IsDirty)//dirty and unsaveable due to broken rules
|
|
{
|
|
if(Util.PromptForBrokenRulesCancelSave()==DialogResult.Yes)
|
|
{
|
|
bClosingHandled=true;
|
|
this.Close();
|
|
return true;
|
|
}
|
|
else
|
|
return false;
|
|
}
|
|
//not dirty so just exit
|
|
bClosingHandled=true;
|
|
this.Close();
|
|
return true;
|
|
|
|
case RecordActionType.SaveAndNew:
|
|
if(mPurchaseOrder.IsSavable)
|
|
{
|
|
mPurchaseOrder.ApplyEdit();
|
|
mPurchaseOrder.Save();
|
|
AddNewPurchaseOrder();
|
|
mbChangesMade=true;
|
|
return true;
|
|
|
|
}
|
|
if(mPurchaseOrder.IsDirty)//dirty and unsaveable due to broken rules
|
|
{
|
|
//User says that's ok, continue on?
|
|
if(Util.PromptForBrokenRulesCancelSave()==DialogResult.Yes)
|
|
{
|
|
//Ok, add new PurchaseOrder and don't save old record
|
|
AddNewPurchaseOrder();
|
|
return true;
|
|
}
|
|
else return false;
|
|
|
|
}
|
|
|
|
//Current record isn't dirty so just add a new PurchaseOrder
|
|
AddNewPurchaseOrder();
|
|
return true;
|
|
|
|
case RecordActionType.SaveOnly:
|
|
if(mPurchaseOrder.IsSavable)
|
|
{
|
|
mPurchaseOrder.ApplyEdit();
|
|
mPurchaseOrder=(PurchaseOrder)mPurchaseOrder.Save();
|
|
DataBind();
|
|
mbChangesMade=true;
|
|
return true;
|
|
|
|
}
|
|
return true;
|
|
|
|
case RecordActionType.PromptToSave:
|
|
//Prompt to save and save if
|
|
//required
|
|
if(mPurchaseOrder.IsDirty)
|
|
{
|
|
DialogResult dr=Util.PromptForSave();
|
|
if(dr==DialogResult.Cancel)
|
|
{
|
|
//Cancel
|
|
return false;
|
|
}
|
|
if(dr==DialogResult.Yes)
|
|
{
|
|
//Save before exit
|
|
|
|
if(mPurchaseOrder.IsSavable)
|
|
{
|
|
mPurchaseOrder.ApplyEdit();
|
|
mPurchaseOrder.Save();
|
|
mbChangesMade=true;
|
|
return true;
|
|
}
|
|
if(mPurchaseOrder.IsDirty)//dirty and unsaveable due to broken rules
|
|
{
|
|
if(Util.PromptForBrokenRulesCancelSave()==DialogResult.Yes)
|
|
{
|
|
return true;
|
|
}
|
|
else
|
|
return false;
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
}
|
|
|
|
/// <summary>
|
|
///
|
|
///Creates a new PurchaseOrder record and opens it for editing
|
|
/// </summary>
|
|
private void AddNewPurchaseOrder()
|
|
{
|
|
log.Debug("AddNewPurchaseOrder");
|
|
|
|
try
|
|
{
|
|
mPurchaseOrder=PurchaseOrder.NewItem();
|
|
//mPurchaseOrder.BeginEdit();
|
|
DataBind();
|
|
}
|
|
catch(Exception ex)
|
|
{
|
|
log.Error("AddNewPurchaseOrder",ex);
|
|
MessageBox.Show(ex.Message+"\r\n"+ex.Source);
|
|
}
|
|
}
|
|
|
|
|
|
#endregion
|
|
|
|
#region Form ComboBoxes (Setup / Events)
|
|
|
|
|
|
|
|
/// <summary>
|
|
/// when selection changes for vendor, need to re-build parts list
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void cbVendorID_SelectionChanged(object sender, System.EventArgs e)
|
|
{
|
|
if(!bBinding)
|
|
{
|
|
PopulateGridValueLists();
|
|
//Fill address info boxes
|
|
DisplayFullerAddressForVendorSelected();
|
|
RefreshRestockRequestToolBarButtons();
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
private void cbClientID_SelectionChanged(object sender, System.EventArgs e)
|
|
{
|
|
if(!bBinding)
|
|
{
|
|
//Fill address info boxes
|
|
DisplayFullerAddressForClientSelected();
|
|
//a drop ship precludes doing the regular vendor requests thing
|
|
RefreshRestockRequestToolBarButtons();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void InitializeComboBoxes()
|
|
{
|
|
|
|
log.Debug("InitializeComboBoxes");
|
|
|
|
//Load combo boxes with initial values
|
|
Util.FillGZComboBoxWithNameIDList("Vendor",cbVendorID,true,mPurchaseOrder.VendorID);
|
|
Util.FillGZComboBoxWithNameIDList("Client",cbClientID,true,mPurchaseOrder.DropShipToClientID);
|
|
//TODO: below gives error when uncommented - not sure why - joyce -
|
|
//because there is no business object that corresponds
|
|
// Util.FillGZComboBoxWithNameIDList("PurchaseOrderStatus",cbStatus,true,mPurchaseOrder.Status);
|
|
|
|
}
|
|
|
|
private void cbVendorID_NeedMoreData()
|
|
{
|
|
|
|
cbVendorID.ClearList();
|
|
VendorPickList v = VendorPickList.GetList();
|
|
foreach(VendorPickList.VendorPickListInfo i in v)
|
|
{
|
|
if(i.Active==true && i.VendorType!=VendorTypes.Shipper)
|
|
{
|
|
cbVendorID.Items.Add(i.ID,i.Name);
|
|
|
|
}
|
|
else
|
|
{
|
|
//is the current, inactive item the one selected in this record?
|
|
if(i.ID==this.mPurchaseOrder.VendorID)
|
|
{
|
|
//yes, so add it manually and grayed out
|
|
ValueListItem vi=cbVendorID.Items.Add(i.ID,i.Name);
|
|
vi.Appearance.ForeColor=System.Drawing.SystemColors.GrayText;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
private void cbClientID_NeedMoreData()
|
|
{
|
|
Util.FillGZComboBoxWithNameIDList("Client",cbClientID,false,Guid.Empty);
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
#region Grid Events
|
|
/// <summary>
|
|
/// Handle right click column selection popup
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void Grid_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)
|
|
{
|
|
if( e.Button == MouseButtons.Right)
|
|
{
|
|
UltraGridBand b=Util.BandRightClicked(Grid,e);
|
|
if(b!=null)
|
|
{
|
|
UtilGridColumnSelector c = new UtilGridColumnSelector();
|
|
c.HideColumns.Add("IsLocked",0);
|
|
c.HideColumns.Add("WorkorderItemPartRequestID",0);
|
|
c.HideColumns.Add("PurchaseOrderID",0);
|
|
|
|
c.BandToEdit=b;
|
|
c.ShowDialog(this);
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
private void Grid_BeforeRowInsert(object sender, Infragistics.Win.UltraWinGrid.BeforeRowInsertEventArgs e)
|
|
{
|
|
mPurchaseOrder.OrderItems.Add(mPurchaseOrder);
|
|
//Don't allow the default behaviour of the row insert because it doesn't work
|
|
e.Cancel=true;
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Display workorder button if item from workorder
|
|
/// Calculate taxes and line totals ..etc
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void Grid_InitializeRow(object sender, Infragistics.Win.UltraWinGrid.InitializeRowEventArgs e)
|
|
{
|
|
object oWo=e.Row.Cells["WorkorderNumber"].Value;
|
|
|
|
if(oWo==null || (int)oWo==0)
|
|
{
|
|
e.Row.Cells["WorkorderNumber"].Hidden=true;
|
|
e.Row.Cells["PartRequestedByID"].Hidden=true;
|
|
|
|
}
|
|
else
|
|
{
|
|
//it's a workorder request line so show the wo number and requestor
|
|
//and lock down the editable fields for this row
|
|
e.Row.Cells["WorkorderNumber"].Hidden=false;
|
|
e.Row.Cells["PartRequestedByID"].Hidden=false;
|
|
e.Row.Cells["PartRequestedByID"].Activation=Activation.NoEdit;
|
|
e.Row.Cells["WorkorderNumber"].Activation=Activation.NoEdit;
|
|
e.Row.Cells["QuantityOrdered"].Activation=Activation.NoEdit;
|
|
e.Row.Cells["PartWarehouseID"].Activation=Activation.NoEdit;
|
|
e.Row.Cells["PartID"].Activation=Activation.NoEdit;
|
|
}
|
|
|
|
|
|
|
|
|
|
//Calculate taxes and line total
|
|
if(e.Row.Cells["PartID"].Value!=null && (Guid)e.Row.Cells["PartID"].Value!=Guid.Empty)
|
|
{
|
|
//update alternative numbers
|
|
PartPickList.PartPickListInfo p=PartList[(Guid)e.Row.Cells["PartID"].Value];
|
|
e.Row.Cells["ManufacturerNumber"].Value=p.PartManufacturerNumber;
|
|
e.Row.Cells["WholesalerNumber"].Value=p.PartWholesalerNumber;
|
|
e.Row.Cells["AlternativeWholesalerNumber"].Value=p.PartAlternativeWholesalerNumber;
|
|
|
|
|
|
if(e.Row.Cells["QuantityOrdered"].Value!=null)
|
|
{
|
|
if(e.Row.Cells["PurchaseOrderCost"].Value!=null)
|
|
{
|
|
decimal dNet=(decimal)e.Row.Cells["QuantityOrdered"].Value*(decimal)e.Row.Cells["PurchaseOrderCost"].Value;
|
|
decimal dTaxA=0M;
|
|
decimal dTaxB=0M;
|
|
|
|
//Calculate taxes
|
|
if(e.Row.Cells["PurchaseTaxCodeID"].Value!=null && (Guid)e.Row.Cells["PurchaseTaxCodeID"].Value!=Guid.Empty)
|
|
{
|
|
//Get the percentages and other info for the current tax code...
|
|
TaxCodeList.TaxCodeListInfo t = TaxList[(Guid)e.Row.Cells["PurchaseTaxCodeID"].Value];
|
|
|
|
//If tax A exempt then no further processing needs to be done
|
|
//as both taxes already set at zero, otherwise...
|
|
if(!t.TaxAExempt)
|
|
{
|
|
//Tax A is always just tax A percent times net...
|
|
dTaxA=t.TaxA*dNet;
|
|
|
|
//Tax B on the other hand could be simple or tax on tax...
|
|
if(!t.TaxOnTax)
|
|
{
|
|
//simple
|
|
dTaxB=t.TaxB*dNet;
|
|
}
|
|
else
|
|
{
|
|
//tax on tax
|
|
dTaxB=(dNet+dTaxA)*t.TaxB;
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
//set line total and taxes display values
|
|
e.Row.Cells["TaxA"].Value=dTaxA;
|
|
e.Row.Cells["TaxB"].Value=dTaxB;
|
|
e.Row.Cells["NetTotal"].Value=dNet;
|
|
e.Row.Cells["LineTotal"].Value=dNet+dTaxA+dTaxB;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
private void Grid_AfterCellUpdate(object sender, Infragistics.Win.UltraWinGrid.CellEventArgs e)
|
|
{
|
|
//If part ID has changed then update the cost and tax code fields
|
|
if((string)e.Cell.Column.Key=="PartID")
|
|
{
|
|
PartPickList.PartPickListInfo p=PartList[(Guid)e.Cell.Value];
|
|
e.Cell.Row.Cells["PurchaseOrderCost"].Value=p.Cost;
|
|
e.Cell.Row.Cells["PurchaseTaxCodeID"].Value=Util.GlobalSettings.TaxPartPurchaseID;
|
|
|
|
|
|
e.Cell.Row.Refresh(RefreshRow.FireInitializeRow);
|
|
|
|
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// Ensure the summary box has the same display format as the column above it
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void Grid_SummaryValueChanged(object sender, Infragistics.Win.UltraWinGrid.SummaryValueChangedEventArgs e)
|
|
{
|
|
e.SummaryValue.SummarySettings.DisplayFormat="{0:" +e.SummaryValue.SummarySettings.SourceColumn.Format+"}";
|
|
}
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
#region Grid Initialization
|
|
|
|
|
|
/// <summary>
|
|
/// Get grid ready
|
|
/// </summary>
|
|
private void InitializeGrid()
|
|
{
|
|
log.Debug("InitializeGrid");
|
|
|
|
//prevent initialze row from firing and throwing errors when it finds there is no data
|
|
//to calculate line totals on...
|
|
Grid.EventManager.SetEnabled(GridEventIds.InitializeRow,false);
|
|
|
|
Grid.DisplayLayout.Override.AllowRowSummaries=AllowRowSummaries.BasedOnDataType;
|
|
Grid.DisplayLayout.Override.HeaderClickAction=HeaderClickAction.SortSingle;
|
|
Grid.DisplayLayout.Override.AllowAddNew=AllowAddNew.TemplateOnBottom;
|
|
Util.GridPreLocalize("PurchaseOrderItem",Grid.DisplayLayout.Bands[0]);
|
|
Util.FetchGridLayout("PurchaseOrderItems","",Grid);
|
|
Util.GridHideEditableBizObjectInternalFields(Grid);
|
|
Grid.DisplayLayout.Bands[0].Columns["IsLocked"].Hidden=true;
|
|
Grid.DisplayLayout.Bands[0].Columns["WorkorderItemPartRequestID"].Hidden=true;
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseOrderID"].Hidden=true;
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityReceived"].CellActivation=Activation.ActivateOnly;
|
|
Grid.DisplayLayout.Bands[0].Columns["Closed"].CellActivation=Activation.ActivateOnly;
|
|
|
|
Grid.DisplayLayout.Bands[0].Columns["WorkorderNumber"].AllowRowSummaries=AllowRowSummaries.False;
|
|
|
|
//decimal number formatting
|
|
Grid.DisplayLayout.Bands[0].Columns["QuantityOrdered"].Format="F";
|
|
|
|
Grid.DisplayLayout.Bands[0].Columns["PartWarehouseID"].Header.Caption=Util.LocaleText.GetLocalizedText("O.PartWarehouse");
|
|
Grid.DisplayLayout.Bands[0].Columns["PartID"].Header.Caption=Util.LocaleText.GetLocalizedText("O.Part");
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseTaxCodeID"].Header.Caption=Util.LocaleText.GetLocalizedText("O.TaxCode");
|
|
|
|
//COST
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseOrderCost"].Format="c";
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseOrderCost"].CellAppearance.TextHAlign=HAlign.Right;
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//Manufacturer number
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("ManufacturerNumber"))
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].Header.Caption=Util.LocaleText.GetLocalizedText("Part.Label.ManufacturerNumber");
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("ManufacturerNumber",Util.LocaleText.GetLocalizedText("Part.Label.ManufacturerNumber"));
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].DataType=typeof(string);
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].CellActivation=Activation.ActivateOnly;
|
|
//-------------------------------------------------------------------------------------------------
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//Wholesaler number
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("WholesalerNumber"))
|
|
Grid.DisplayLayout.Bands[0].Columns["WholesalerNumber"].Header.Caption=Util.LocaleText.GetLocalizedText("Part.Label.WholesalerNumber");
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("WholesalerNumber",Util.LocaleText.GetLocalizedText("Part.Label.WholesalerNumber"));
|
|
Grid.DisplayLayout.Bands[0].Columns["WholesalerNumber"].DataType=typeof(string);
|
|
Grid.DisplayLayout.Bands[0].Columns["WholesalerNumber"].CellActivation=Activation.ActivateOnly;
|
|
//-------------------------------------------------------------------------------------------------
|
|
//-------------------------------------------------------------------------------------------------
|
|
//AlternativeWholesaler number
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("AlternativeWholesalerNumber"))
|
|
Grid.DisplayLayout.Bands[0].Columns["AlternativeWholesalerNumber"].Header.Caption=Util.LocaleText.GetLocalizedText("Part.Label.AlternativeWholesalerNumber");
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("AlternativeWholesalerNumber",Util.LocaleText.GetLocalizedText("Part.Label.AlternativeWholesalerNumber"));
|
|
Grid.DisplayLayout.Bands[0].Columns["AlternativeWholesalerNumber"].DataType=typeof(string);
|
|
Grid.DisplayLayout.Bands[0].Columns["AlternativeWholesalerNumber"].CellActivation=Activation.ActivateOnly;
|
|
//-------------------------------------------------------------------------------------------------
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//Manufacturer number
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("ManufacturerNumber"))
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].Header.Caption=Util.LocaleText.GetLocalizedText("Part.Label.ManufacturerNumber");
|
|
else
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("ManufacturerNumber",Util.LocaleText.GetLocalizedText("Part.Label.ManufacturerNumber"));
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].DataType=typeof(string);
|
|
Grid.DisplayLayout.Bands[0].Columns["ManufacturerNumber"].CellActivation=Activation.ActivateOnly;
|
|
//-------------------------------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//TaxA, TaxB, Total columns
|
|
|
|
//___TAX_A___
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("TaxA"))
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxA"].Header.Caption=Util.LocaleText.GetLocalizedText("TaxCode.Label.TaxA");
|
|
}
|
|
else
|
|
{
|
|
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("TaxA",Util.LocaleText.GetLocalizedText("TaxCode.Label.TaxA"));
|
|
}
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxA"].DataType=typeof(decimal);
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxA"].Format="c";
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxA"].CellAppearance.TextHAlign=HAlign.Right;
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxA"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
//___TAX_B___
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("TaxB"))
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxB"].Header.Caption=Util.LocaleText.GetLocalizedText("TaxCode.Label.TaxB");
|
|
}
|
|
else
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("TaxB",Util.LocaleText.GetLocalizedText("TaxCode.Label.TaxB"));
|
|
}
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxB"].DataType=typeof(decimal);
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxB"].Format="c";
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxB"].CellAppearance.TextHAlign=HAlign.Right;
|
|
Grid.DisplayLayout.Bands[0].Columns["TaxB"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
|
|
//___LineTotal___
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("LineTotal"))
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns["LineTotal"].Header.Caption=Util.LocaleText.GetLocalizedText("PurchaseOrderItem.Label.LineTotal");
|
|
}
|
|
else
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("LineTotal",Util.LocaleText.GetLocalizedText("PurchaseOrderItem.Label.LineTotal"));
|
|
}
|
|
Grid.DisplayLayout.Bands[0].Columns["LineTotal"].DataType=typeof(decimal);
|
|
Grid.DisplayLayout.Bands[0].Columns["LineTotal"].Format="c";
|
|
Grid.DisplayLayout.Bands[0].Columns["LineTotal"].CellAppearance.TextHAlign=HAlign.Right;
|
|
Grid.DisplayLayout.Bands[0].Columns["LineTotal"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
//___NetTotal___
|
|
if(Grid.DisplayLayout.Bands[0].Columns.Exists("NetTotal"))
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns["NetTotal"].Header.Caption=Util.LocaleText.GetLocalizedText("PurchaseOrderItem.Label.NetTotal");
|
|
}
|
|
else
|
|
{
|
|
Grid.DisplayLayout.Bands[0].Columns.Add("NetTotal",Util.LocaleText.GetLocalizedText("PurchaseOrderItem.Label.NetTotal"));
|
|
}
|
|
Grid.DisplayLayout.Bands[0].Columns["NetTotal"].DataType=typeof(decimal);
|
|
Grid.DisplayLayout.Bands[0].Columns["NetTotal"].Format="c";
|
|
Grid.DisplayLayout.Bands[0].Columns["NetTotal"].CellAppearance.TextHAlign=HAlign.Right;
|
|
Grid.DisplayLayout.Bands[0].Columns["NetTotal"].CellActivation=Activation.ActivateOnly;
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
|
|
PopulateGridValueLists();
|
|
//Allow empty string entry on grid
|
|
Util.SetTextColumnsNullable(Grid);
|
|
|
|
//turn initialize row event back on
|
|
Grid.EventManager.SetEnabled(GridEventIds.InitializeRow,true);
|
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Populate the drop down lists inside the grid
|
|
/// so they display and can select the correct underlying
|
|
/// value
|
|
/// </summary>
|
|
private void PopulateGridValueLists()
|
|
{
|
|
log.Debug("PopulateGridValueLists");
|
|
|
|
|
|
//Empty the existing value lists if present
|
|
Grid.DisplayLayout.ValueLists.Clear();
|
|
|
|
//Need a selected vendor to be able to do this
|
|
//If there isn't one, then bail
|
|
if(cbVendorID.Value==null || (Guid)cbVendorID.Value==Guid.Empty)
|
|
return;
|
|
|
|
//Populate value lists
|
|
ValueList vl=Grid.DisplayLayout.ValueLists.Add("Parts");
|
|
vl.SortStyle=ValueListSortStyle.Ascending;
|
|
|
|
//Get a part list of costs and prices for later calcs
|
|
PartList=PartPickList.GetAllPartsForVendor((Guid)cbVendorID.Value);
|
|
|
|
|
|
|
|
foreach(PartPickList.PartPickListInfo ppi in PartList)
|
|
{
|
|
|
|
vl.ValueListItems.Add(ppi.ID,ppi.DisplayName(Util.GlobalSettings.DefaultPartDisplayFormat));
|
|
}
|
|
|
|
|
|
|
|
//Bind value lists to correct columns in grid
|
|
Grid.DisplayLayout.Bands[0].Columns["PartID"].ValueList=Grid.DisplayLayout.ValueLists["Parts"];
|
|
|
|
//Set column to dropdownlist style so that user can not type an invalid value in a cell
|
|
//but must select from the list only
|
|
Grid.DisplayLayout.Bands[0].Columns["PartID"].Style=ColumnStyle.DropDownList;
|
|
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//Warehouses
|
|
vl=Grid.DisplayLayout.ValueLists.Add("Warehouses");
|
|
vl.SortStyle=ValueListSortStyle.Ascending;
|
|
GenericNVList l=GenericNVList.GetList("aPartWarehouse","aName","aID",true,false);
|
|
|
|
//Add initial empty guid value
|
|
//so that records with no value yet entered in the
|
|
//field will be shown as an empty string
|
|
vl.ValueListItems.Add(Guid.Empty," ");
|
|
|
|
//Loop through the items in the list and put them
|
|
//into the valuelist
|
|
for(int x=0;x<l.Count;x++)
|
|
{
|
|
vl.ValueListItems.Add(new Guid(((DictionaryEntry)l.BindableList[x]).Value.ToString()),
|
|
((DictionaryEntry)l.BindableList[x]).Key.ToString());
|
|
}
|
|
|
|
|
|
//Bind value lists to correct columns in grid
|
|
Grid.DisplayLayout.Bands[0].Columns["PartWarehouseID"].ValueList=Grid.DisplayLayout.ValueLists["Warehouses"];
|
|
|
|
//Set column to dropdownlist style so that user can not type an invalid value in a cell
|
|
//but must select from the list only
|
|
Grid.DisplayLayout.Bands[0].Columns["PartWarehouseID"].Style=ColumnStyle.DropDownList;
|
|
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//Tax codes TaxID
|
|
|
|
vl=Grid.DisplayLayout.ValueLists.Add("TaxCodes");
|
|
vl.SortStyle=ValueListSortStyle.Ascending;
|
|
l=GenericNVList.GetList("aTaxCode","aName","aID",true,false);
|
|
|
|
//Add initial empty guid value
|
|
//so that records with no value yet entered in the
|
|
//field will be shown as an empty string
|
|
vl.ValueListItems.Add(Guid.Empty," ");
|
|
|
|
//Loop through the items in the list and put them
|
|
//into the valuelist
|
|
for(int x=0;x<l.Count;x++)
|
|
{
|
|
vl.ValueListItems.Add(new Guid(((DictionaryEntry)l.BindableList[x]).Value.ToString()),
|
|
((DictionaryEntry)l.BindableList[x]).Key.ToString());
|
|
}
|
|
|
|
|
|
//Bind value lists to correct columns in grid
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseTaxCodeID"].ValueList=Grid.DisplayLayout.ValueLists["TaxCodes"];
|
|
|
|
//Set column to dropdownlist style so that user can not type an invalid value in a cell
|
|
//but must select from the list only
|
|
Grid.DisplayLayout.Bands[0].Columns["PurchaseTaxCodeID"].Style=ColumnStyle.DropDownList;
|
|
|
|
|
|
|
|
//-------------------------------------------------------------------------------------------------
|
|
//UserID for part requestor field
|
|
|
|
vl=Grid.DisplayLayout.ValueLists.Add("Users");
|
|
vl.SortStyle=ValueListSortStyle.Ascending;
|
|
UserPickList UList=UserPickList.GetList();
|
|
|
|
//Add initial empty guid value
|
|
//so that records with no value yet entered in the
|
|
//field will be shown as an empty string
|
|
vl.ValueListItems.Add(Guid.Empty," ");
|
|
|
|
|
|
foreach(UserPickList.UserPickListInfo ui in UList)
|
|
{
|
|
|
|
vl.ValueListItems.Add(ui.ID,ui.Name);
|
|
}
|
|
|
|
|
|
|
|
//Bind value lists to correct columns in grid
|
|
Grid.DisplayLayout.Bands[0].Columns["PartRequestedByID"].ValueList=Grid.DisplayLayout.ValueLists["Users"];
|
|
|
|
//Set column to dropdownlist style so that user can not type an invalid value in a cell
|
|
//but must select from the list only
|
|
Grid.DisplayLayout.Bands[0].Columns["PartRequestedByID"].Style=ColumnStyle.DropDownList;
|
|
|
|
|
|
}
|
|
#endregion
|
|
|
|
#region Custom fields
|
|
|
|
/// <summary>
|
|
/// put custom field data into custom grid and show it if applicable
|
|
/// </summary>
|
|
private void FillCustomFieldGrid()
|
|
{
|
|
log.Debug("FillCustomFieldGrid");
|
|
|
|
bShowCustomFields=Util.PrepareCustomFieldsGrid("PurchaseOrder",gridCustom);
|
|
|
|
if(bShowCustomFields)
|
|
{
|
|
this.panelCustom.Visible=true;
|
|
|
|
Util.GridFromCustomFields(mPurchaseOrder,gridCustom);
|
|
|
|
}
|
|
else
|
|
{
|
|
this.panelCustom.Visible=false;
|
|
}
|
|
|
|
}
|
|
private void gridCustom_AfterCellUpdate(object sender, Infragistics.Win.UltraWinGrid.CellEventArgs e)
|
|
{
|
|
|
|
Util.GridToCustomFields(mPurchaseOrder,gridCustom);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
#region DatePickerEditorButton
|
|
private void dtOrderedDate_EditorButtonClick(object sender, Infragistics.Win.UltraWinEditors.EditorButtonEventArgs e)
|
|
{
|
|
//Set the date to null or unchosen
|
|
dtOrderedDate.Value=DBNull.Value;
|
|
}
|
|
#endregion
|
|
|
|
#region Update restock / request buttons on toolbar
|
|
|
|
private void RefreshRestockRequestToolBarButtons()
|
|
{
|
|
//Need a selected vendor to be able to do this
|
|
//If there isn't one, then bail
|
|
if(cbVendorID.Value==null || (Guid)cbVendorID.Value==Guid.Empty || (cbClientID.Value!=null && (Guid)cbClientID.Value!=Guid.Empty))
|
|
{
|
|
this.mRestockList=null;
|
|
this.mRequestList=null;
|
|
}
|
|
else
|
|
{
|
|
this.mRestockList= PartRestockRequiredByVendorList.GetList((Guid)cbVendorID.Value);
|
|
this.mRequestList= PartWorkorderItemRequestByVendorList.GetList((Guid)cbVendorID.Value);
|
|
}
|
|
|
|
bool bShowRestockButton=true;
|
|
if(bShowRestockButton && Util.BP.Right("Object.PurchaseOrder")< (int)SecurityLevelTypes.ReadWrite) bShowRestockButton=false;
|
|
if(mRestockList==null || mRestockList.Count==0) bShowRestockButton=false;
|
|
if(bShowRestockButton && mPurchaseOrder.Status > PurchaseOrderStatus.OpenNotYetOrdered) bShowRestockButton=false;
|
|
|
|
|
|
//Show if not on order or farther, no drop ship client id, and a valid restock list with items present
|
|
tbManager.Tools["LT:PurchaseOrder.Label.UI.RestockList"].SharedProps.Visible=bShowRestockButton;
|
|
|
|
|
|
bool bShowRequestButton=true;
|
|
if(bShowRequestButton && Util.BP.Right("Object.PurchaseOrder")< (int)SecurityLevelTypes.ReadWrite) bShowRequestButton=false;
|
|
if(mRequestList==null || mRequestList.Count==0) bShowRequestButton=false;
|
|
if(bShowRequestButton && mPurchaseOrder.Status > PurchaseOrderStatus.OpenNotYetOrdered) bShowRequestButton=false;
|
|
|
|
|
|
//Show workorder item part request list button
|
|
tbManager.Tools["LT:WorkorderItemPartRequest.Label.List"].SharedProps.Visible=bShowRequestButton;
|
|
|
|
|
|
|
|
}
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
}
|