Exemplo n.º 1
0
        private void FillProductGroup()
        {
            var coll = ProductGroupController.GetAllProudctGroups();

            coll.Insert(0, new ProductGroup
            {
                ProductGroupCode = 0,
                ProductGroupName = "--ทั้งหมด--"
            });
            comboxProductGroup.ValueMember   = "ProductGroupCode";
            comboxProductGroup.DisplayMember = "ProductGroupName";
            comboxProductGroup.DataSource    = coll;
        }
Exemplo n.º 2
0
        private void Populate()
        {
            var coll = ProductGroupController.GetAllProudctGroups(TxtFilter.Text.Trim());

            gv.DataSource = coll;

            gv.Columns[1].HeaderText = "รหัสกลุ่มสินค้า";
            gv.Columns[2].HeaderText = "ชื่อกลุ่มสินค้า";
            gv.Columns[3].HeaderText = "ใช้งาน";
            gv.Columns[4].HeaderText = "วันเวลาสร้าง";
            gv.Columns[5].HeaderText = "ผู้สร้าง";
            gv.Columns[6].HeaderText = "วันเวลาแก้ไข";
            gv.Columns[7].HeaderText = "ผู้แก้ไข";

            gv.Columns[ConstColumns.CreateAt].DefaultCellStyle.Format   = "dd/MM/yyyy HH:mm:ss";
            gv.Columns[ConstColumns.ModifiedAt].DefaultCellStyle.Format = "dd/MM/yyyy HH:mm:ss";
        }
        private void FillProductGroup()
        {
            //bool showSelectAllflag = true;
            //comboxProductGroup.DataSource = ProductGroupController.GetAllProudctGroups(showSelectAllflag);
            //comboxProductGroup.ValueMember = "ProductGroupCode";
            //comboxProductGroup.DisplayMember = "ProductGroupName";
            var coll = ProductGroupController.GetAllProudctGroups();

            coll.Insert(0, new ProductGroup
            {
                ProductGroupCode = 0,
                ProductGroupName = "--ทั้งหมด--"
            });
            comboxProductGroup.ValueMember   = "ProductGroupCode";
            comboxProductGroup.DisplayMember = "ProductGroupName";
            comboxProductGroup.DataSource    = coll;
        }
 private void FillProductGroup()
 {
     comboxProductGroup.DataSource    = ProductGroupController.GetAllProudctGroups();
     comboxProductGroup.ValueMember   = "ProductGroupCode";
     comboxProductGroup.DisplayMember = "ProductGroupName";
 }