Beispiel #1
0
        private void EKanbanHistories_Load(object sender, EventArgs e)
        {
            try
            {
                var buildings = BuildingQuery.GetBuildings();
                int i = 0, k = 0;

                foreach (var b in buildings)
                {
                    treeView1.Nodes.Add(b.Name, $"Building: {b.Name}");

                    var lines = BuildingQuery.GetProductionLines(b.id);

                    foreach (var l in lines)
                    {
                        treeView1.Nodes[b.Name].Nodes.Add(l.LineName, $"Line: {l.LineName}");

                        var ekanbans = EKanbanTaskQuery.GetEKanbanDevicesByProductionLine(l.id);

                        foreach (var ekb in ekanbans)
                        {
                            treeView1.Nodes[b.Name].Nodes[l.LineName].Nodes.Add(ekb.Name, ekb.Name);
                        }
                        k++;
                    }
                    i++;
                }
            }
            catch { }
        }
Beispiel #2
0
        void UpdateTreeViewSource()
        {
            var scheduleClass = ScheduleQuery.GetScheduleClasses();

            if (scheduleClass == null)
            {
                return;
            }

            foreach (var cls in scheduleClass)
            {
                treeView1.Nodes.Add(cls.Name, $"Schedule: {cls.Name}");
                var buildings = BuildingQuery.GetBuildings();
                treeView1.Nodes[cls.Name].ExpandAll();
                foreach (var building in buildings)
                {
                    treeView1.Nodes[cls.Name].Nodes.Add(building.Name, $"Building: {building.Name}");
                    string[] modelName = GetScheduleModelName(building, cls);
                    foreach (string s in modelName)
                    {
                        treeView1.Nodes[cls.Name].Nodes[building.Name].Nodes.Add(s, $"Model name: {s}");
                    }
                }
            }
        }
Beispiel #3
0
        private void MANG_FORM_Load(object sender, EventArgs e)
        {
            try
            {
                DS_Building.DataSource = BuildingQuery.GetBuildings();
                UpdateEkanbanContainer();
            }
            catch { }

            EkanbanContainerPn.VerticalScroll.Enabled = true;
            EkanbanContainerPn.VerticalScroll.Value   = 10;
            EkanbanContainerPn.VerticalScroll.Visible = true;


            var admin = employeeQr.GetAppUser("admin", "admin");

            //LOGIN_UI.LOGIN_FORM LOGIN_FORM = new LOGIN_UI.LOGIN_FORM(3);
            //LOGIN_FORM.ShowDialog();

            //if (!LOGIN_FORM.LoginStatus)
            //    this.Close();

            //CurrentUser = LOGIN_FORM.User;
            OrderPage = new OrderPage(admin);
        }
Beispiel #4
0
 private void BDeviceStatistic_Load(object sender, EventArgs e)
 {
     try
     {
         DS_Building.DataSource  = BuildingQuery.GetBuildings();
         comboBox1.SelectedIndex = 1;
         comboBox1.SelectedIndex = 0;
     }
     catch { }
 }
Beispiel #5
0
        private void Form1_Load(object sender, EventArgs e)
        {
            DS_Building.DataSource = BuildingQuery.GetBuildings();
            SelectBuildingChanges();

            cbx_ScheduleTime.Items.Clear();
            for (int i = 1; i <= 12; i++)
            {
                cbx_ScheduleTime.Items.Add($"{i.ToString("00")}/{DateTime.Now.Year}");
            }
            cbx_ScheduleTime.SelectedIndex = DateTime.Now.Month - 1;
        }
Beispiel #6
0
        private void MForm_Load(object sender, EventArgs e)
        {
            DS_Building.DataSource = BuildingQuery.GetBuildings();
            SelectBuildingChanges();

            //cbx_ScheduleTime.Items.Clear();
            //for (int i = 1; i <= 12; i++)
            //{
            //    cbx_ScheduleTime.Items.Add($"{i.ToString("00")}/{DateTime.Now.Year}");
            //}
            //cbx_ScheduleTime.SelectedIndex = DateTime.Now.Month - 1;
            ScheduleClasses             = new List <ScheduleClass>();
            ScheduleClasses             = ScheduleQuery.GetScheduleClasses();
            DS_ScheduleClass.DataSource = ScheduleClasses;
        }
Beispiel #7
0
 private void OrderPage_Load(object sender, EventArgs e)
 {
     try
     {
         DS_Building.DataSource         = BuildingQuery.GetBuildings();
         DS_ScheduleClass.DataSource    = ScheduleQuery.GetScheduleClasses();
         cbxBuilding.SelectedIndex      = 1;
         cbxBuilding.SelectedIndex      = 0;
         cbxScheduleClass.SelectedIndex = cbxScheduleClass.Items.Count - 1;
         cbxLine.SelectedIndex          = 1;
         cbxLine.SelectedIndex          = 0;
         lbBDevice.SelectedIndex        = 1;
         lbBDevice.SelectedIndex        = 0;
     }
     catch { }
 }