Ejemplo n.º 1
0
        private void LogData()
        {
            _LogTransfer.SetLogValue("測驗名稱", cbxQuizName.Text);
            if (dtImplementationDate.IsEmpty)
            {
                _LogTransfer.SetLogValue("實施日期", "");
            }
            else
            {
                _LogTransfer.SetLogValue("實施日期", dtImplementationDate.Value.ToShortDateString());
            }

            if (dtAnalysisDate.IsEmpty)
            {
                _LogTransfer.SetLogValue("解析日期", "");
            }
            else
            {
                _LogTransfer.SetLogValue("解析日期", dtAnalysisDate.Value.ToShortDateString());
            }

            foreach (DataGridViewRow drv in dgQuizData.Rows)
            {
                if (drv.IsNewRow)
                {
                    continue;
                }
                if (drv.Cells[colDataField.Index].Value != null)
                {
                    if (drv.Cells[colDataValue.Index].Value == null)
                    {
                        _LogTransfer.SetLogValue("項目名稱:" + drv.Cells[colDataField.Index].Value.ToString(), "");
                    }
                    else
                    {
                        _LogTransfer.SetLogValue("項目名稱:" + drv.Cells[colDataField.Index].Value.ToString(), "測驗結果:" + drv.Cells[colDataValue.Index].Value.ToString());
                    }
                }
            }
        }
Ejemplo n.º 2
0
        private void LogData()
        {
            _LogTransfer.SetLogValue("代號", _CounselCareRecord.CodeName);
            if (_CounselCareRecord.FileDate.HasValue)
            {
                _LogTransfer.SetLogValue("立案日期", _CounselCareRecord.FileDate.Value.ToShortDateString());
            }
            else
            {
                _LogTransfer.SetLogValue("立案日期", "");
            }

            _LogTransfer.SetLogValue("個案類別", _CounselCareRecord.CaseCategory);
            _LogTransfer.SetLogValue("個案類別備註", _CounselCareRecord.CaseCategoryRemark);
            _LogTransfer.SetLogValue("個案來源", _CounselCareRecord.CaseOrigin);
            _LogTransfer.SetLogValue("個案來源備註", _CounselCareRecord.CaseOriginRemark);
            _LogTransfer.SetLogValue("優勢能力及財力", _CounselCareRecord.Superiority);
            _LogTransfer.SetLogValue("弱勢能力及阻力", _CounselCareRecord.Weakness);
            _LogTransfer.SetLogValue("輔導人員輔導目標", _CounselCareRecord.CounselGoal);
            _LogTransfer.SetLogValue("校外協輔機構", _CounselCareRecord.OtherInstitute);
            _LogTransfer.SetLogValue("輔導人員輔導方式", _CounselCareRecord.CounselType);
            _LogTransfer.SetLogValue("協同輔導人員協助導師事項", _CounselCareRecord.AssistedMatter);

            _LogTransfer.SetLogValue("記錄者", _CounselCareRecord.AuthorID);
            _LogTransfer.SetLogValue("記錄者姓名", _CounselCareRecord.AuthorName);
            _LogTransfer.SetLogValue("個案類別", _CounselCareRecord.CaseCategory);
        }
        private void LogData()
        {
            _LogTransfer.SetLogValue("晤談編號", txtInterviewNo.Text);
            _LogTransfer.SetLogValue("晤談老師", cbxInterviewer.Text);
            _LogTransfer.SetLogValue("晤談對象", cbxInterveweeType.Text);
            _LogTransfer.SetLogValue("晤談方式", cbxInterviewType.Text);
            _LogTransfer.SetLogValue("晤談日期", dtDate.Text);
            _LogTransfer.SetLogValue("晤談時間", txtTime.Text);
            _LogTransfer.SetLogValue("晤談地點", txtPlace.Text);
            _LogTransfer.SetLogValue("晤談事由", txtCause.Text);

            // 參與人員
            List <string> info1 = new List <string>();

            foreach (Control cr in groupPanel1.Controls)
            {
                CheckBox cb = cr as CheckBox;
                if (cb != null)
                {
                    if (cb.Checked)
                    {
                        if (cb.Text.IndexOf("其它") > -1)
                        {
                            info1.Add("其它:" + txt_cb010.Text);
                        }
                        else
                        {
                            info1.Add(cb.Text);
                        }
                    }
                }
            }
            _LogTransfer.SetLogValue("參與人員:", string.Join(",", info1.ToArray()));

            // 輔導方式
            List <string> info2 = new List <string>();

            foreach (Control cr in groupPanel2.Controls)
            {
                CheckBox cb = cr as CheckBox;
                if (cb != null)
                {
                    if (cb.Checked)
                    {
                        if (cb.Text.IndexOf("轉介") > -1)
                        {
                            info2.Add("轉介:" + txt_cb104.Text);
                        }
                        else if (cb.Text.IndexOf("就醫") > -1)
                        {
                            info2.Add("就醫:" + txt_cb105.Text);
                        }
                        else if (cb.Text.IndexOf("其它") > -1)
                        {
                            info2.Add("其它:" + txt_cb106.Text);
                        }
                        else
                        {
                            info2.Add(cb.Text);
                        }
                    }
                }
            }
            _LogTransfer.SetLogValue("輔導方式:", string.Join(",", info2.ToArray()));

            // 輔導歸類
            List <string> info3 = new List <string>();

            foreach (Control cr in groupPanel3.Controls)
            {
                CheckBox cb = cr as CheckBox;
                if (cb != null)
                {
                    if (cb.Checked)
                    {
                        if (cb.Text.IndexOf("其它") > -1)
                        {
                            info3.Add("其它:" + txt_cb218.Text);
                        }
                        else
                        {
                            info3.Add(cb.Text);
                        }
                    }
                }
            }
            _LogTransfer.SetLogValue("輔導歸類:", string.Join(",", info3.ToArray()));
            _LogTransfer.SetLogValue("內容要點", txtContentDigest.Text);
            _LogTransfer.SetLogValue("記錄者", txtAuthorID.Text);
            _LogTransfer.SetLogValue("記錄者姓名", txtAuthorName.Text);
        }
Ejemplo n.º 4
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            List <string> NameList = _QuizData.Select(x => x.QuizName).ToList();

            AddQuizNameForm aqnf = new AddQuizNameForm(NameList);

            if (aqnf.ShowDialog() == System.Windows.Forms.DialogResult.Yes)
            {
                if (!string.IsNullOrEmpty(aqnf.GetAddQuizName()))
                {
                    DAO.UDT_QuizDef qd = new DAO.UDT_QuizDef();
                    qd.QuizName = aqnf.GetAddQuizName();
                    // Log
                    _LogTransfer.Clear();
                    _LogTransfer.SetLogValue("測驗名稱", "");
                    _LogTransfer.SetLogValue("測驗名稱", qd.QuizName);
                    _LogTransfer.SaveInsertLog("輔導新增測驗名稱", "新增", "", "", "", "");

                    _UDTTransfer.InsertQuizData(qd);
                }
            }
            LoadData();
        }