コード例 #1
0
        /// <summary>
        /// จัดการใบโอนสินค้า
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void รายการโอนสนคาประจำวนToolStripMenuItem_Click(object sender, EventArgs e)
        {
            TransferOutListForm obj = new TransferOutListForm();

            obj.MdiParent = this;
            obj.Show();
        }
コード例 #2
0
 public frmMainReport(TransferOutListForm transferOutListForm, string code, string brachDestination)
 {
     InitializeComponent();
     this.transferOutListForm = transferOutListForm;
     this.code             = code;
     this.brachDestination = brachDestination;
     this.TypeReport       = MyConstant.TypeReport.TransferOut;
 }
コード例 #3
0
 /// <summary>
 /// จากการแก้ไข
 /// </summary>
 /// <param name="transferOutListForm"></param>
 /// <param name="code"></param>
 public TransferOutForm(TransferOutListForm transferOutListForm, string code)
 {
     InitializeComponent();
     using (SSLsEntities db = new SSLsEntities())
     {
         hd = db.StoreFrontTransferOut.FirstOrDefault(w => w.Code == code);
         if (hd.Enable == false)
         {
             button2.Enabled = false;
         }
         else if (hd.ConfirmDate != null)
         {
             button2.Enabled = false;
         }
         // bindding
         BinddingBranchSelected(hd.Branch);
         textBoxTOCode.Text       = hd.Code;
         textBoxTODate.Text       = Library.ConvertDateToThaiDate(hd.CreateDate);
         textBoxDesc.Text         = hd.Remark;
         textBoxQtyUnit.Text      = Library.ConvertDecimalToStringForm(hd.TotalQtyUnit);
         textBoxTotalBalance.Text = Library.ConvertDecimalToStringForm(hd.TotalBalance);
         this.transferOutListForm = transferOutListForm;
         this.code = code;
         foreach (var item in hd.StoreFrontTransferOutDtl.Where(w => w.Enable == true).ToList())
         {
             dataGridView1.Rows.Add
             (
                 item.FKProductDetails,
                 item.ProductDetails.Code,
                 "",
                 item.ProductDetails.Products.ThaiName,
                 item.ProductDetails.PackSize,
                 item.ProductDetails.ProductUnit.Name,
                 Library.ConvertDecimalToStringForm(item.Qty),
                 Library.ConvertDecimalToStringForm(item.CostPerUnit),
                 Library.ConvertDecimalToStringForm(item.TotalPrice),
                 item.ProductDetails.Products.ProductVatType.Name,
                 item.Description
             );
         }
         //dataGridView1.Rows.Add("");
     }
 }
コード例 #4
0
 public TransferOutEditForm(TransferOutListForm transferOutListForm, string code)
 {
     InitializeComponent();
     this.transferOutListForm = transferOutListForm;
     this.code = code;
 }