public DoctorClientInfo(DoctorStartWork F, long Id)
        {
            InitializeComponent();
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            //this.WindowState = FormWindowState.Maximized;
            this.Id = Id;
            back    = F;
            FilterCondition filter = new FilterCondition("Client_Id", Id, ConditionType.Equal);
            //MessageBox.Show(Id.ToString());
            List <FilterCondition> filt = new List <FilterCondition>();

            filt.Add(filter);
            List <HistoryModel> collection = history.List(filt);

            /*foreach (HistoryModel H in collection)
             * {
             *  //MessageBox.Show(H.ToString());
             * }*/

            foreach (HistoryModel H in collection)
            {
                listBox1.Items.Add(
                    "Диагноз:  "
                    + H.Diagnosis
                    + "\t Запись от "
                    + date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Year + "."
                    + date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Month + "."
                    + date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Day
                    + ".   Врач "
                    + user.Get_Item("Id", H.Personal_Id.ToString(), ConditionType.Equal).Name
                    + " "
                    + user.Get_Item("Id", H.Personal_Id.ToString(), ConditionType.Equal).Surname
                    );
                listBox1.Items.Add("Симптомы: " + H.Symptoms);
            }

            List <AnalyseModel> ancollection = analyse.List(filt);

            foreach (AnalyseModel H in ancollection)
            {
                listBox2.Items.Add(
                    date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Year + "."
                    + date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Month + "."
                    + date.Get_Item("Id", H.Date_Id.ToString(), ConditionType.Equal).Day.Day
                    + "\tАнализ: "
                    + analysetype.Get_Item("Id", H.Type_Id.ToString(), ConditionType.Equal).Name
                    + "\t Значение: "
                    + H.Result
                    + "\t Комментарий: "
                    + H.Coment
                    );
            }
        }
        private void StartWork_Click(object sender, EventArgs e)
        {
            try
            {
                int selected = ListView.SelectedIndices[0];

                DateTime datetime = new DateTime(Program.Current_Date.Year, Program.Current_Date.Month, Program.Current_Date.Day, DateTime.Parse(ListView.Items[selected].SubItems[0].Text).Hour, DateTime.Parse(ListView.Items[selected].SubItems[0].Text).Minute, DateTime.Parse(ListView.Items[selected].SubItems[0].Text).Second);
                //MessageBox.Show(ListView.Items[selected].SubItems[0].Text.ToString());

                //MessageBox.Show(datetime.ToString());
                DateModel        selected_client_date = new DateModel();
                List <DateModel> date_List            = date.List("Get_Id", datetime);
                selected_client_date = date_List.Single();
                //MessageBox.Show(datetime.ToString());

                FilterCondition filter1 = new FilterCondition();
                filter1.Field = "Personal_Id";
                filter1.Value = Current_Id;
                filter1.Type  = ConditionType.Equal;

                FilterCondition filter2 = new FilterCondition();
                filter2.Field = "Date_Id";
                filter2.Value = selected_client_date.Id.ToString();
                filter2.Type  = ConditionType.Equal;

                List <FilterCondition> filt = new List <FilterCondition>();
                filt.Add(filter1);
                filt.Add(filter2);

                List <ProcModel> collection = proc.List(filt);

                long Id      = collection.Single().Client_Id;
                long Proc_Id = collection.Single().Id;
                // MessageBox.Show(Id.ToString());
                DoctorStartWork F = new DoctorStartWork(this, Id, Proc_Id);

                F.Show();
                this.Hide();
            }
            catch
            {
                MessageBox.Show("Ничего не выбрано");
            }
            this.Refresh_list();
        }