This commit is contained in:
chi
2022-03-07 20:13:58 +09:00
parent 06dbd92893
commit dd3fcf149f
13 changed files with 646 additions and 468 deletions

View File

@@ -75,7 +75,7 @@ namespace FBS0000
fpSpread1_Sheet1.Columns.Count = cols.Count;
for (int c = 0; c < cols.Count; c++)
{
fpSpread1_Sheet1.Columns[c].Tag = coltag[c];
fpSpread1_Sheet1.Columns[c].Tag = new int[] { 0, 0, 0, 0 };
fpSpread1_Sheet1.Columns[c].Label = cols[c];
if (c < 4) fpSpread1_Sheet1.Columns[c].BackColor = Color.WhiteSmoke;
else if (c > cols.Count - 5) fpSpread1_Sheet1.Columns[c].BackColor = Color.WhiteSmoke;
@@ -103,16 +103,29 @@ namespace FBS0000
//{
// //입사일자를 체크해서. 이 날짜가 입사일 이전이면 넘어간다
//}
var newuser = new userinfo();
users.Add(new userinfo
{
grade = dr["grade"].ToString(),
name = dr["name"].ToString(),
empno = dr["id"].ToString(),
seq = dr["process"].ToString(),
indate = dr["indate"].ToString(),
outdate = dr["outdate"].ToString()
});
if (dr["grade"] == null) newuser.grade = string.Empty;
newuser.grade = dr["grade"].ToString();
if (dr["name"] == null) newuser.name = string.Empty;
newuser.name = dr["name"].ToString();
if (dr["id"] == null) newuser.empno = string.Empty;
newuser.empno = dr["id"].ToString();
if (dr["process"] == null) newuser.seq = string.Empty;
newuser.seq = dr["process"].ToString();
if (dr["indate"] == null) newuser.indate = string.Empty;
newuser.indate = dr["indate"].ToString();
if (dr["outdate"] == null) newuser.outdate = string.Empty;
newuser.outdate = dr["outdate"].ToString();
users.Add(newuser);
seq += 1;
}
@@ -146,6 +159,9 @@ namespace FBS0000
int c = 0;
for (c = 4; c < cols.Count - 3; c++)
{
var ps = (int[])fpSpread1_Sheet1.Columns[c].Tag;
var curDate = sd.AddDays(c - 4);
var bholy = false;
//이날짜가 휴일인지 체크한다.
@@ -153,8 +169,9 @@ namespace FBS0000
if (drHoly != null && drHoly.free)
{
bholy = true;
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.LightPink;
//fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.LightPink;
fpSpread1_Sheet1.Cells[rowindex, c].Tag = drHoly.memo;
if (drHoly.memo == "토요일" || drHoly.memo == "일요일")
{
@@ -164,6 +181,7 @@ namespace FBS0000
{
fpSpread1_Sheet1.Cells[rowindex, c].Note = drHoly.memo;
}
fpSpread1_Sheet1.Columns[c].BackColor = Color.FromArgb(250, 250, 250);
}
else
{
@@ -171,6 +189,7 @@ namespace FBS0000
fpSpread1_Sheet1.Cells[rowindex, c].Tag = null;
fpSpread1_Sheet1.Cells[rowindex, c].Note = string.Empty;
fpSpread1_Sheet1.Columns[c].BackColor = Color.White;
}
//기본으로 데이터를 초기화해준다.
@@ -183,11 +202,29 @@ namespace FBS0000
if (item.outdate == curDate.ToShortDateString())
fpSpread1_Sheet1.Cells[rowindex, c].Note += "퇴사";
//현재인원값
var bIndate = DateTime.TryParse(item.indate, out DateTime dtIn);
var bOutdate = DateTime.TryParse(item.outdate, out DateTime dtOut);
Boolean usePerson = true;
//
if (bIndate == true && curDate.ToShortDateString().CompareTo(dtIn.ToShortDateString()) < 0)
usePerson = false;
if (bOutdate == true && curDate.ToShortDateString().CompareTo(dtOut.ToShortDateString()) > 0)
usePerson = false;
ps[3] = bholy ? 1 : 0;
ps[2] += 1;
//근태기록에 자료가 있는지 확인한다.
var dr = dtHoly.Where(t => t.uid == item.empno && ( t.sdate.ToShortDateString().CompareTo(curDate.ToShortDateString()) <= 0 && t.edate.ToShortDateString().CompareTo(curDate.ToShortDateString()) >= 0)).FirstOrDefault();
var dr = dtHoly.Where(t => t.uid == item.empno && (t.sdate.ToShortDateString().CompareTo(curDate.ToShortDateString()) <= 0 && t.edate.ToShortDateString().CompareTo(curDate.ToShortDateString()) >= 0)).FirstOrDefault();
if (dr != null && fpSpread1_Sheet1.Cells[rowindex, c].Tag == null) //휴일이 아니여야 한다
{
ps[1] += 1;
//휴가내역이 있다.
if (dr.term > 0)
used += 1;
@@ -205,99 +242,13 @@ namespace FBS0000
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.Gold;
else if (dr.cate == "경조")
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.Pink;
else if (dr.cate == "대체")
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.Gold;
else
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.Lime;
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.LawnGreen;
fpSpread1_Sheet1.Cells[rowindex, c].Tag = "1";
}
//else if (dr.term > 0)
//{
// var timedays = dr.term;// Math.Floor(dr.CrTime / 8f);
// var curday = 0;
// var accday = 1;
// //while (accday <= timedays)
// {
// //var remaintime = dr.CrTime - accday * 8f;
// var columnindex = c + curday;
// if (columnindex >= fpSpread1_Sheet1.ColumnCount) break;
// var columnDate = (DateTime)this.fpSpread1_Sheet1.Columns[columnindex].Tag;
// var drHolyChk = HolyList.Where(t => t.pdate == columnDate.ToShortDateString()).FirstOrDefault();
// var drholyOK = false;
// if (drHolyChk != null && drHolyChk.free) drholyOK = true; //이러면 휴일이었다
// if (drholyOK == false)
// {
// fpSpread1_Sheet1.Cells[rowindex, c + curday].Value = dr.cate.Substring(0, 2);
// if (dr.cate == "이월")
// fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Gold;
// else if (dr.cate == "경조")
// fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Pink;
// else
// fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.Lime;
// fpSpread1_Sheet1.Cells[rowindex, c + curday].Tag = "1";
// accday += 1;
// }
// curday += 1;
// }
// //for (int ii = 0; ii < dr.term; ii++)
// //{
// // if (dr.cate == "이월")
// // fpSpread1_Sheet1.Cells[rowindex, c + ii].BackColor = Color.Gold;
// // else
// // fpSpread1_Sheet1.Cells[rowindex, c + ii].BackColor = Color.Lime;
// // fpSpread1_Sheet1.Cells[rowindex, c + ii].Value = dr.cate.Substring(0, 2);
// // fpSpread1_Sheet1.Cells[rowindex, c + ii].Tag = "1";
// //}
//}
//else if (dr.term != 0)
//{
// fpSpread1_Sheet1.Cells[rowindex, c].Value = dr.term.ToString() + "Y";
//}
//if (dr.CrTime != 0)
//{
// var timedays = Math.Floor(dr.CrTime / 8f);
// var curday = 0;
// var accday = 1;
// while (accday <= timedays)
// {
// var remaintime = dr.CrTime - ((accday - 1) * 8f);
// var columnindex = c + curday;
// var columnDate = (DateTime)this.fpSpread1_Sheet1.Columns[columnindex].Tag;
// var drHolyChk = HolyList.Where(t => t.pdate == columnDate.ToShortDateString()).FirstOrDefault();
// var drholyOK = false;
// if (drHolyChk != null && drHolyChk.free) drholyOK = true; //이러면 휴일이었다
// if (drholyOK == false)
// {
// if (remaintime > 8) remaintime = 8;
// fpSpread1_Sheet1.Cells[rowindex, c + curday].Value = remaintime.ToString();
// fpSpread1_Sheet1.Cells[rowindex, c + curday].BackColor = Color.DeepSkyBlue;
// fpSpread1_Sheet1.Cells[rowindex, c + curday].Tag = "1";
// accday += 1;
// }
// curday += 1;
// }
//}
if (string.IsNullOrEmpty(dr.contents) == false)
{
@@ -311,6 +262,9 @@ namespace FBS0000
}
else
{
ps[0] += 1;
var pdate = curDate.ToShortDateString();
if (pdate == "2022-02-07" && item.empno == "66630")
{
@@ -337,8 +291,8 @@ namespace FBS0000
else
fpSpread1_Sheet1.Cells[rowindex, c].Note += $"휴일근무({sum_ot2}h)";
}
else
fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.White;
//else
//fpSpread1_Sheet1.Cells[rowindex, c].BackColor = Color.White;
}
else
{
@@ -380,6 +334,8 @@ namespace FBS0000
}
}
}
fpSpread1_Sheet1.Columns[c].Tag = ps;
}
var jan = jand - used;
@@ -388,6 +344,51 @@ namespace FBS0000
fpSpread1_Sheet1.Cells[rowindex, c++].Value = jan > 0 ? jan.ToString() : string.Empty;
rowindex += 1;
} // --users
//총요약을 넣는다
fpSpread1_Sheet1.RowCount += 1;
fpSpread1_Sheet1.RowCount += 1;
fpSpread1_Sheet1.RowCount += 1;
fpSpread1_Sheet1.Rows[rowindex + 0].Border = new FarPoint.Win.LineBorder(Color.Gainsboro, 1, false, false, true, true);
fpSpread1_Sheet1.Rows[rowindex + 1].Border = new FarPoint.Win.LineBorder(Color.Gainsboro, 1, false, false, true, true);
fpSpread1_Sheet1.Rows[rowindex + 2].Border = new FarPoint.Win.LineBorder(Color.Gainsboro, 1, false, false, true, true);
//fpSpread1_Sheet1.RowCount += 1;
fpSpread1_Sheet1.Cells[rowindex + 0, 3].Value = "근무";
//fpSpread1_Sheet1.Cells[rowindex + 1, 3].Value = "휴가";
fpSpread1_Sheet1.Cells[rowindex + 1, 3].Value = "근무율(%)";// ps[0].ToString(); //근무율
fpSpread1_Sheet1.Cells[rowindex + 2, 3].Value = "총원";
for (var col = 4; col < cols.Count - 3; col++)
{
var ps = (int[])fpSpread1_Sheet1.Columns[col].Tag;
if (ps[3] == 1)
{
fpSpread1_Sheet1.Cells[rowindex + 0, col].Value = "--";
fpSpread1_Sheet1.Cells[rowindex + 1, col].Value = "--";
fpSpread1_Sheet1.Cells[rowindex + 2, col].Value = "--";
}
else
{
var krate = (ps[0] * 1f / ps[2]);
var trans = (int)(krate * 254);
fpSpread1_Sheet1.Cells[rowindex + 0, col].Value = ps[0].ToString(); //근무
//fpSpread1_Sheet1.Cells[rowindex + 1, col].Value = ps[1].ToString(); //휴가
fpSpread1_Sheet1.Cells[rowindex + 1, col].Value = (krate * 100f).ToString("N0");
fpSpread1_Sheet1.Cells[rowindex + 1, col].Note = $"근무:{ps[0]}\n휴가:{ps[1]}\n총원:{ps[2]}";
fpSpread1_Sheet1.Cells[rowindex + 2, col].Value = ps[2].ToString(); //총원
if (krate >= 0.8) fpSpread1_Sheet1.Cells[rowindex + 1, col].BackColor = Color.FromArgb(trans, Color.LightGreen);
else if (krate >= 0.6) fpSpread1_Sheet1.Cells[rowindex + 1, col].BackColor = Color.FromArgb(trans, Color.LightSkyBlue);
else if (krate >= 0.4) fpSpread1_Sheet1.Cells[rowindex + 1, col].BackColor = Color.FromArgb(trans, Color.HotPink);
else fpSpread1_Sheet1.Cells[rowindex + 1, col].BackColor = Color.FromArgb(trans, Color.Tomato);
}
}

View File

@@ -31,7 +31,7 @@ namespace FCM0000
private void fRequestItem_Load(object sender, EventArgs e)
{
if (FCOMMON.info.Login.level >= 9)
if (FCOMMON.info.Login.level >= 9 || FCOMMON.info.Login.no == "395552")
{
bn.Enabled = true;
BTsAVE.Enabled = true;

View File

@@ -273,24 +273,24 @@ namespace FPJ0000.OtConfirm
chkSendMail.Checked = true;
//일수계산
var term = tbED.Value - tbSD.Value;
var days = term.Days + 1;
if (radTime.Checked == false)
{
//if(tbDays.Text.isEmpty() || tbDays.Text=="0")
{
tbDays.Text = (days).ToString();
}
//var term = tbED.Value - tbSD.Value;
//var days = term.Days + 1;
//if (radTime.Checked == false)
//{
// //if(tbDays.Text.isEmpty() || tbDays.Text=="0")
// {
// tbDays.Text = (days).ToString();
// }
}
else
{
//여기는 시간
//if (tbTimes.Text.isEmpty() || tbTimes.Text == "0")
{
tbTimes.Text = (days * 8).ToString();
}
}
//}
//else
//{
// //여기는 시간
// //if (tbTimes.Text.isEmpty() || tbTimes.Text == "0")
// {
// tbTimes.Text = (days * 8).ToString();
// }
//}
}
private void radioButton1_CheckedChanged(object sender, EventArgs e)

View File

@@ -30,15 +30,15 @@
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fOTConfirm));
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle19 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle20 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle21 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle22 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle23 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle24 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle25 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle26 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle27 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle15 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle16 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle18 = new System.Windows.Forms.DataGridViewCellStyle();
this.bn = new System.Windows.Forms.BindingNavigator(this.components);
this.bs = new System.Windows.Forms.BindingSource(this.components);
this.dsMSSQL = new FPJ0000.dsPRJ();
@@ -268,8 +268,8 @@
this.btConf.Image = ((System.Drawing.Image)(resources.GetObject("btConf.Image")));
this.btConf.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btConf.Name = "btConf";
this.btConf.Size = new System.Drawing.Size(51, 22);
this.btConf.Text = "승인";
this.btConf.Size = new System.Drawing.Size(75, 22);
this.btConf.Text = "선택승인";
this.btConf.Click += new System.EventHandler(this.toolStripButton3_Click);
//
// toolStripSeparator4
@@ -501,9 +501,9 @@
// wwDataGridViewTextBoxColumn
//
this.wwDataGridViewTextBoxColumn.DataPropertyName = "ww";
dataGridViewCellStyle19.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle19.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.wwDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle19;
dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle10.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.wwDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle10;
this.wwDataGridViewTextBoxColumn.HeaderText = "WW";
this.wwDataGridViewTextBoxColumn.Name = "wwDataGridViewTextBoxColumn";
this.wwDataGridViewTextBoxColumn.ReadOnly = true;
@@ -512,8 +512,8 @@
// pdateDataGridViewTextBoxColumn
//
this.pdateDataGridViewTextBoxColumn.DataPropertyName = "pdate";
dataGridViewCellStyle20.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.pdateDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle20;
dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.pdateDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle11;
this.pdateDataGridViewTextBoxColumn.HeaderText = "날짜";
this.pdateDataGridViewTextBoxColumn.Name = "pdateDataGridViewTextBoxColumn";
this.pdateDataGridViewTextBoxColumn.ReadOnly = true;
@@ -522,8 +522,8 @@
// WeekName
//
this.WeekName.DataPropertyName = "WeekName";
dataGridViewCellStyle21.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.WeekName.DefaultCellStyle = dataGridViewCellStyle21;
dataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.WeekName.DefaultCellStyle = dataGridViewCellStyle12;
this.WeekName.HeaderText = "*";
this.WeekName.Name = "WeekName";
this.WeekName.ReadOnly = true;
@@ -564,8 +564,8 @@
// statusDataGridViewTextBoxColumn
//
this.statusDataGridViewTextBoxColumn.DataPropertyName = "status";
dataGridViewCellStyle22.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.statusDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle22;
dataGridViewCellStyle13.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.statusDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle13;
this.statusDataGridViewTextBoxColumn.HeaderText = "상태";
this.statusDataGridViewTextBoxColumn.Name = "statusDataGridViewTextBoxColumn";
this.statusDataGridViewTextBoxColumn.ReadOnly = true;
@@ -582,11 +582,11 @@
// otDataGridViewTextBoxColumn
//
this.otDataGridViewTextBoxColumn.DataPropertyName = "ot";
dataGridViewCellStyle23.Alignment = System.Windows.Forms.DataGridViewContentAlignment.TopCenter;
dataGridViewCellStyle23.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle23.ForeColor = System.Drawing.Color.Red;
dataGridViewCellStyle23.Format = "N1";
this.otDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle23;
dataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.TopCenter;
dataGridViewCellStyle14.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle14.ForeColor = System.Drawing.Color.Red;
dataGridViewCellStyle14.Format = "N1";
this.otDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle14;
this.otDataGridViewTextBoxColumn.HeaderText = "초과";
this.otDataGridViewTextBoxColumn.Name = "otDataGridViewTextBoxColumn";
this.otDataGridViewTextBoxColumn.ReadOnly = true;
@@ -595,10 +595,10 @@
// ot2DataGridViewTextBoxColumn
//
this.ot2DataGridViewTextBoxColumn.DataPropertyName = "ot2";
dataGridViewCellStyle24.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle24.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
dataGridViewCellStyle24.Format = "N1";
this.ot2DataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle24;
dataGridViewCellStyle15.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle15.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
dataGridViewCellStyle15.Format = "N1";
this.ot2DataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle15;
this.ot2DataGridViewTextBoxColumn.HeaderText = "승인";
this.ot2DataGridViewTextBoxColumn.Name = "ot2DataGridViewTextBoxColumn";
this.ot2DataGridViewTextBoxColumn.Width = 51;
@@ -606,8 +606,8 @@
// otReasonDataGridViewTextBoxColumn
//
this.otReasonDataGridViewTextBoxColumn.DataPropertyName = "otReason";
dataGridViewCellStyle25.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.otReasonDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle25;
dataGridViewCellStyle16.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.otReasonDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle16;
this.otReasonDataGridViewTextBoxColumn.HeaderText = "사유";
this.otReasonDataGridViewTextBoxColumn.Name = "otReasonDataGridViewTextBoxColumn";
this.otReasonDataGridViewTextBoxColumn.Width = 51;
@@ -615,10 +615,10 @@
// otStartDataGridViewTextBoxColumn
//
this.otStartDataGridViewTextBoxColumn.DataPropertyName = "otStart";
dataGridViewCellStyle26.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle26.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle26.Format = "HH:mm:ss";
this.otStartDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle26;
dataGridViewCellStyle17.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle17.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle17.Format = "HH:mm:ss";
this.otStartDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle17;
this.otStartDataGridViewTextBoxColumn.HeaderText = "시작";
this.otStartDataGridViewTextBoxColumn.Name = "otStartDataGridViewTextBoxColumn";
this.otStartDataGridViewTextBoxColumn.ReadOnly = true;
@@ -628,10 +628,10 @@
// otEnd
//
this.otEnd.DataPropertyName = "otEnd";
dataGridViewCellStyle27.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle27.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle27.Format = "HH:mm:ss";
this.otEnd.DefaultCellStyle = dataGridViewCellStyle27;
dataGridViewCellStyle18.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle18.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle18.Format = "HH:mm:ss";
this.otEnd.DefaultCellStyle = dataGridViewCellStyle18;
this.otEnd.HeaderText = "종료";
this.otEnd.Name = "otEnd";
this.otEnd.ReadOnly = true;

View File

@@ -514,20 +514,40 @@ namespace FPJ0000
private void toolStripButton3_Click(object sender, EventArgs e)
{
var drv = this.bs.Current as DataRowView;
if (drv == null) return;
var dr = drv.Row as dsPRJ.JobReportRow;
using (var f = new OtConfirm.fOTConfirmOK(dr))
//var drv = this.bs.Current as DataRowView;
//if (drv == null) return;
//var dr = drv.Row as dsPRJ.JobReportRow;
List<dsPRJ.JobReportRow> rows = new List<dsPRJ.JobReportRow>();
List<int> rowindex = new List<int>();
foreach (DataGridViewCell cell in dv1.SelectedCells)
{
if (cell.RowIndex < 0 || cell.ColumnIndex < 0) continue;
var drItem = ((DataRowView)(dv1.Rows[cell.RowIndex].DataBoundItem)).Row as dsPRJ.JobReportRow;
if (rows.Contains(drItem) == false) rows.Add(drItem);
if (rowindex.Contains(cell.RowIndex) == false) rowindex.Add(cell.RowIndex);
}
using (var f = new OtConfirm.fOTConfirmOK(rows.ToArray()))
{
if (f.ShowDialog() == DialogResult.OK)
{
dr.EndEdit();
foreach(var row in rows)
row.EndEdit();
try
{
var cnt = ta.Update(dr);
dr.AcceptChanges();
var cnt = ta.Update(rows.ToArray());
foreach (var row in rows)
row.AcceptChanges();
util.MsgI($"{cnt}건의 자료가 저장되었습니다");
FCOMMON.DBM.InsertLog("OTCONFIRM", $"{dr.username}:{dr.uid},요청:{dr.ot},승인:{dr.ot2},관리자비고:{dr.otReason}");
foreach (var dr in rows)
{
FCOMMON.DBM.InsertLog("OTCONFIRM", $"{dr.username}:{dr.uid},요청:{dr.ot},승인:{dr.ot2},관리자비고:{dr.otReason}");
}
FormattingData();
}
catch (Exception ex)
@@ -539,6 +559,7 @@ namespace FPJ0000
}
}
}
}
}

View File

@@ -181,20 +181,20 @@
<data name="toolStripButton5.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAALxSURBVDhPhZLrS1NhHMf3qv6EsF70MohSym7Ui9J0TQ26
moqZtzVFKxNdGGSLaWReQhMVKkQpelGhXXRaU3PO6YabZK6pa8674GWpu5yz7Zz57TlnSw2CfvDhefGc
74fz+54j4CbynirlbJlWea5c+0so01LkpHkquFNHnyvrp6Mfa4wnpOqqvbFvtvGhrRP1sFe9aKeXjSYz
a3O6YXNssmznoDEyb0fhx2kklI+6RDcV2wNR/8SUaBaNoxa2f9IL3RQD3TQD7SQDzYQHqp9utJuccDNA
yyiFwvdTSH9qpP6SCGXt1JrLA8MMi8EZhpwMBniJBz0WN76YXETgg2GehW7Oi2LFNMLvdr3mw/EVYdYr
sth1Se0lpNdcRs3nRhQ1VSBcFowwgqj4OCLlR1DZUsmv4qAZLKy4EJnSw/CCuLLwd13DrWg1v0CNNp+X
JFdHI/9VEm41JkBcdx5pdWloGVpAq9GBT9/XsEp6Esp7aV4gqhJtPyzLYbVj3Xg5LEep6iYvSamNIeEL
yHyWAbXFya/SaaagJD2sOL0QFvX5BdxElfTQufWp0Fs0qNPdwaOOPMRXnEZKdSz0ky7oSbFcwepxfyc2
IoiUbxGcvC/zHi3YjaQqEQzj/SjuzoJckYuEJxFoVH3At1kGelJs/4QXfYRFuxfhDwKCg9IgSah0F241
JOJqbRQSK8/wklxFEqRNGeRNIsDdG6ZZDHCfmGAnRYbkaPyCUOmO2VDpTvJQEELzg3CxNALZz1OhNilR
rCxA1ttUiGvjoCcCHfk3tERAe31EoNpc4VROLz2/SmNoluXpGZvD7fpMXCdBSV0C8hpubNxxuDwsETRv
CjjbjG1T8D+c3AoZWwTHcr+6VIaR9X89/C/M4xO+/cktjkCcFJnZYZ1ac9lVg2M+6xIF6yIFS4Alh5eH
a95BszCZrT6Kolb3XGv7EYgLBIcyP2eHiNs7DkiUthBJM73BdT/BfxA303vEbSv70to6g1MV6QKBQPAb
LVefkczmSCQAAAAASUVORK5CYII=
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAALxSURBVDhPhZLrS1NhHMf3qv6EsF70UohSSqmoF6WpTQ3s
Zipm3uYUTU10YZAtppF5CU1UqBCl6EWFdtGpTc05pxtukTkv0znvgpel7nKO7pz57TlnSw2EfvDhefGc
74fz+54j4Cb4oTLhSqlGEVGm+R0i1VDkpHnKuVNLR5T202HP1IbzElXlscj3B/jQ3gl90qtattKrhmEj
a7FvwmLbZdXKQWN00YqCL7OIKRtzCDPlBz1R94QXq5cNoxNs/7QT2hkG2lkGmmkG6qktKCc20TZixyYD
NI9RKPg0g+QXBuofSYi0jdpwbEE/x+LHHENOBgO8ZAs9pk18G3EQgQv6RRbaBSeK5LMIfND1jg9HlweY
b0kjt8U1N5BcfRPV7Q0obCxHoNQHAQRh0TkEy06jormCX8VGM1hacyA4vofhBVGlgR+7hlrQMv4a1Zo8
XhJfFYa8t3HIaoiBqPYqkmqT0Dy4hBaDDV9/bWCd9BQi66V5gbBSeNBfms1qjN14MyRDiTKTlyTUhJPw
NaS9TIXKZOdX6RynoCA9rNmdCCnscwu4CS3uoXPqEqEzqVGrvY+nHbmILr+EhKpI6KYd0JFiuYJVk+5O
LEQQLNsjuPBI6jyTfxRxlULoJ/tR1J0OmTwHMc+D0KD8jJ/zDHSk2P4pJ/oIy1YnAh97BKckXmI/yRFk
1cfidk0oYisu85IceRwkjankTYLA3etnWQxwn5hgJUX6ZqvdAj/JoXk/yWHykBf88rxwvSQIGa8SoRpR
oEiRj/QPiRDVREFHBFryb2iIgHa6iEC5u8LF7F56cZ3G4DzL02NcwL26NKSQoLg2Brn1d3fuOBxbLBE0
7Qo425xlV/A/7NwKqXsEZ3O+O7p1I9v7PbwfRpPZdSK+2eaJkyLTOswzGw5rt37MZV6hYF6mYPKwYnPy
cM3baBbDxkkXRVHr3ndahz1xgcA/rT3DV9TWcVKssPiKm+gdUtz4/EXURHuLWteOJ7V2+iTKkwUCgeAP
E1qff5A1Ne4AAAAASUVORK5CYII=
</value>
</data>
<data name="btConf.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">

View File

@@ -30,203 +30,51 @@ namespace FPJ0000.OtConfirm
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.label1 = new System.Windows.Forms.Label();
this.bs = new System.Windows.Forms.BindingSource(this.components);
this.dSKuntae = new FPJ0000.DSKuntae();
this.tbRemark = new System.Windows.Forms.RichTextBox();
this.grpUser = new System.Windows.Forms.GroupBox();
this.textBox1 = new System.Windows.Forms.TextBox();
this.textBox3 = new System.Windows.Forms.TextBox();
this.label10 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.grpAdmin = new System.Windows.Forms.GroupBox();
this.numericUpDown2 = new System.Windows.Forms.NumericUpDown();
this.numericUpDown1 = new System.Windows.Forms.NumericUpDown();
this.label11 = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label();
this.tbResponse = new System.Windows.Forms.RichTextBox();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle();
this.button1 = new System.Windows.Forms.Button();
this.ta = new FPJ0000.DSKuntaeTableAdapters.EETGW_HolydayRequestTableAdapter();
this.textBox2 = new System.Windows.Forms.TextBox();
this.dsMSSQL = new FPJ0000.dsPRJ();
this.bs = new System.Windows.Forms.BindingSource(this.components);
this.dv1 = new arCtl.arDatagridView();
this.wwDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.pdateDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.WeekName = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.FreeDay = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.usernameDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.requestpartDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.packageDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.statusDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.svalueDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.otDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ot2DataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.otReasonDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.otStartDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.otEnd = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.projectNameDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.descriptionDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.label1 = new System.Windows.Forms.Label();
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
this.label2 = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)(this.dsMSSQL)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.bs)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dSKuntae)).BeginInit();
this.grpUser.SuspendLayout();
this.grpAdmin.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dv1)).BeginInit();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(38, 42);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(93, 27);
this.label1.TabIndex = 2;
this.label1.Text = "업무일";
//
// bs
//
this.bs.DataMember = "EETGW_HolydayRequest";
this.bs.DataSource = this.dSKuntae;
//
// dSKuntae
//
this.dSKuntae.DataSetName = "DSKuntae";
this.dSKuntae.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema;
//
// tbRemark
//
this.tbRemark.BackColor = System.Drawing.Color.WhiteSmoke;
this.tbRemark.Font = new System.Drawing.Font("굴림", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.tbRemark.Location = new System.Drawing.Point(140, 123);
this.tbRemark.Name = "tbRemark";
this.tbRemark.ReadOnly = true;
this.tbRemark.Size = new System.Drawing.Size(878, 133);
this.tbRemark.TabIndex = 16;
this.tbRemark.Text = "";
//
// grpUser
//
this.grpUser.Controls.Add(this.textBox2);
this.grpUser.Controls.Add(this.textBox1);
this.grpUser.Controls.Add(this.textBox3);
this.grpUser.Controls.Add(this.label10);
this.grpUser.Controls.Add(this.label5);
this.grpUser.Controls.Add(this.tbRemark);
this.grpUser.Controls.Add(this.label1);
this.grpUser.Controls.Add(this.label4);
this.grpUser.Dock = System.Windows.Forms.DockStyle.Top;
this.grpUser.Location = new System.Drawing.Point(3, 3);
this.grpUser.Name = "grpUser";
this.grpUser.Size = new System.Drawing.Size(1029, 273);
this.grpUser.TabIndex = 0;
this.grpUser.TabStop = false;
this.grpUser.Text = "업무일지 정보";
//
// textBox1
//
this.textBox1.Location = new System.Drawing.Point(631, 37);
this.textBox1.Name = "textBox1";
this.textBox1.ReadOnly = true;
this.textBox1.Size = new System.Drawing.Size(387, 38);
this.textBox1.TabIndex = 18;
//
// textBox3
//
this.textBox3.Location = new System.Drawing.Point(140, 79);
this.textBox3.Name = "textBox3";
this.textBox3.ReadOnly = true;
this.textBox3.Size = new System.Drawing.Size(878, 38);
this.textBox3.TabIndex = 17;
//
// label10
//
this.label10.AutoSize = true;
this.label10.Location = new System.Drawing.Point(11, 86);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(120, 27);
this.label10.TabIndex = 13;
this.label10.Text = "프로젝트";
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(532, 40);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(93, 27);
this.label5.TabIndex = 0;
this.label5.Text = "담당자";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(65, 133);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(66, 27);
this.label4.TabIndex = 15;
this.label4.Text = "비고";
//
// grpAdmin
//
this.grpAdmin.Controls.Add(this.numericUpDown2);
this.grpAdmin.Controls.Add(this.numericUpDown1);
this.grpAdmin.Controls.Add(this.label11);
this.grpAdmin.Controls.Add(this.label7);
this.grpAdmin.Controls.Add(this.tbResponse);
this.grpAdmin.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpAdmin.Location = new System.Drawing.Point(3, 276);
this.grpAdmin.Name = "grpAdmin";
this.grpAdmin.Size = new System.Drawing.Size(1029, 267);
this.grpAdmin.TabIndex = 1;
this.grpAdmin.TabStop = false;
this.grpAdmin.Text = "관리자 승인";
//
// numericUpDown2
//
this.numericUpDown2.DecimalPlaces = 1;
this.numericUpDown2.Location = new System.Drawing.Point(293, 39);
this.numericUpDown2.Maximum = new decimal(new int[] {
-727379969,
232,
0,
0});
this.numericUpDown2.Name = "numericUpDown2";
this.numericUpDown2.ReadOnly = true;
this.numericUpDown2.Size = new System.Drawing.Size(157, 38);
this.numericUpDown2.TabIndex = 27;
this.numericUpDown2.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// numericUpDown1
//
this.numericUpDown1.DecimalPlaces = 1;
this.numericUpDown1.Location = new System.Drawing.Point(861, 37);
this.numericUpDown1.Maximum = new decimal(new int[] {
-727379969,
232,
0,
0});
this.numericUpDown1.Name = "numericUpDown1";
this.numericUpDown1.Size = new System.Drawing.Size(157, 38);
this.numericUpDown1.TabIndex = 26;
this.numericUpDown1.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// label11
//
this.label11.AutoSize = true;
this.label11.Location = new System.Drawing.Point(636, 41);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(219, 27);
this.label11.TabIndex = 25;
this.label11.Text = "담당자 승인 시간";
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(11, 47);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(276, 27);
this.label7.TabIndex = 23;
this.label7.Text = "담당자 O/T 입력 시간";
//
// tbResponse
//
this.tbResponse.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.tbResponse.Location = new System.Drawing.Point(10, 94);
this.tbResponse.Name = "tbResponse";
this.tbResponse.Size = new System.Drawing.Size(1008, 108);
this.tbResponse.TabIndex = 3;
this.tbResponse.Text = "";
//
// button1
//
this.button1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.button1.Location = new System.Drawing.Point(3, 493);
this.button1.Location = new System.Drawing.Point(3, 595);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(1029, 50);
this.button1.Size = new System.Drawing.Size(1505, 50);
this.button1.TabIndex = 2;
this.button1.Text = "확인";
this.button1.UseVisualStyleBackColor = true;
@@ -236,22 +84,268 @@ namespace FPJ0000.OtConfirm
//
this.ta.ClearBeforeFill = true;
//
// textBox2
// dsMSSQL
//
this.textBox2.Location = new System.Drawing.Point(139, 35);
this.textBox2.Name = "textBox2";
this.textBox2.ReadOnly = true;
this.textBox2.Size = new System.Drawing.Size(387, 38);
this.textBox2.TabIndex = 19;
this.dsMSSQL.DataSetName = "dsMSSQL";
this.dsMSSQL.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema;
//
// bs
//
this.bs.DataMember = "JobReport";
this.bs.DataSource = this.dsMSSQL;
this.bs.Sort = "pdate desc";
//
// dv1
//
this.dv1.A_DelCurrentCell = true;
this.dv1.A_EnterToTab = true;
this.dv1.A_KoreanField = null;
this.dv1.A_UpperField = null;
this.dv1.A_ViewRownumOnHeader = true;
this.dv1.AllowUserToAddRows = false;
this.dv1.AllowUserToDeleteRows = false;
this.dv1.AutoGenerateColumns = false;
this.dv1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
this.dv1.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.dv1.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.dv1.ColumnHeadersHeight = 35;
this.dv1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
this.dv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.wwDataGridViewTextBoxColumn,
this.pdateDataGridViewTextBoxColumn,
this.WeekName,
this.FreeDay,
this.usernameDataGridViewTextBoxColumn,
this.requestpartDataGridViewTextBoxColumn,
this.packageDataGridViewTextBoxColumn,
this.statusDataGridViewTextBoxColumn,
this.svalueDataGridViewTextBoxColumn,
this.otDataGridViewTextBoxColumn,
this.ot2DataGridViewTextBoxColumn,
this.otReasonDataGridViewTextBoxColumn,
this.otStartDataGridViewTextBoxColumn,
this.otEnd,
this.projectNameDataGridViewTextBoxColumn,
this.descriptionDataGridViewTextBoxColumn});
this.dv1.DataSource = this.bs;
dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle10.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle10.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
dataGridViewCellStyle10.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle10.Padding = new System.Windows.Forms.Padding(5);
dataGridViewCellStyle10.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dv1.DefaultCellStyle = dataGridViewCellStyle10;
this.dv1.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv1.Location = new System.Drawing.Point(3, 41);
this.dv1.Name = "dv1";
this.dv1.RowTemplate.Height = 23;
this.dv1.Size = new System.Drawing.Size(1505, 419);
this.dv1.TabIndex = 4;
//
// wwDataGridViewTextBoxColumn
//
this.wwDataGridViewTextBoxColumn.DataPropertyName = "ww";
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.wwDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle1;
this.wwDataGridViewTextBoxColumn.HeaderText = "WW";
this.wwDataGridViewTextBoxColumn.Name = "wwDataGridViewTextBoxColumn";
this.wwDataGridViewTextBoxColumn.ReadOnly = true;
this.wwDataGridViewTextBoxColumn.Width = 71;
//
// pdateDataGridViewTextBoxColumn
//
this.pdateDataGridViewTextBoxColumn.DataPropertyName = "pdate";
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.pdateDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle2;
this.pdateDataGridViewTextBoxColumn.HeaderText = "날짜";
this.pdateDataGridViewTextBoxColumn.Name = "pdateDataGridViewTextBoxColumn";
this.pdateDataGridViewTextBoxColumn.ReadOnly = true;
this.pdateDataGridViewTextBoxColumn.Width = 75;
//
// WeekName
//
this.WeekName.DataPropertyName = "WeekName";
dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.WeekName.DefaultCellStyle = dataGridViewCellStyle3;
this.WeekName.HeaderText = "*";
this.WeekName.Name = "WeekName";
this.WeekName.ReadOnly = true;
this.WeekName.Width = 50;
//
// FreeDay
//
this.FreeDay.DataPropertyName = "FreeDay";
this.FreeDay.HeaderText = "휴일";
this.FreeDay.Name = "FreeDay";
this.FreeDay.ReadOnly = true;
this.FreeDay.Width = 56;
//
// usernameDataGridViewTextBoxColumn
//
this.usernameDataGridViewTextBoxColumn.DataPropertyName = "username";
this.usernameDataGridViewTextBoxColumn.HeaderText = "담당";
this.usernameDataGridViewTextBoxColumn.Name = "usernameDataGridViewTextBoxColumn";
this.usernameDataGridViewTextBoxColumn.ReadOnly = true;
this.usernameDataGridViewTextBoxColumn.Width = 75;
//
// requestpartDataGridViewTextBoxColumn
//
this.requestpartDataGridViewTextBoxColumn.DataPropertyName = "requestpart";
this.requestpartDataGridViewTextBoxColumn.HeaderText = "요청부서";
this.requestpartDataGridViewTextBoxColumn.Name = "requestpartDataGridViewTextBoxColumn";
this.requestpartDataGridViewTextBoxColumn.ReadOnly = true;
this.requestpartDataGridViewTextBoxColumn.Width = 107;
//
// packageDataGridViewTextBoxColumn
//
this.packageDataGridViewTextBoxColumn.DataPropertyName = "package";
this.packageDataGridViewTextBoxColumn.HeaderText = "패키지";
this.packageDataGridViewTextBoxColumn.Name = "packageDataGridViewTextBoxColumn";
this.packageDataGridViewTextBoxColumn.ReadOnly = true;
this.packageDataGridViewTextBoxColumn.Width = 91;
//
// statusDataGridViewTextBoxColumn
//
this.statusDataGridViewTextBoxColumn.DataPropertyName = "status";
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.statusDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle4;
this.statusDataGridViewTextBoxColumn.HeaderText = "상태";
this.statusDataGridViewTextBoxColumn.Name = "statusDataGridViewTextBoxColumn";
this.statusDataGridViewTextBoxColumn.ReadOnly = true;
this.statusDataGridViewTextBoxColumn.Width = 75;
//
// svalueDataGridViewTextBoxColumn
//
this.svalueDataGridViewTextBoxColumn.DataPropertyName = "svalue";
this.svalueDataGridViewTextBoxColumn.HeaderText = "업무분류";
this.svalueDataGridViewTextBoxColumn.Name = "svalueDataGridViewTextBoxColumn";
this.svalueDataGridViewTextBoxColumn.ReadOnly = true;
this.svalueDataGridViewTextBoxColumn.Width = 107;
//
// otDataGridViewTextBoxColumn
//
this.otDataGridViewTextBoxColumn.DataPropertyName = "ot";
dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.TopCenter;
dataGridViewCellStyle5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle5.ForeColor = System.Drawing.Color.Red;
dataGridViewCellStyle5.Format = "N1";
this.otDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle5;
this.otDataGridViewTextBoxColumn.HeaderText = "초과";
this.otDataGridViewTextBoxColumn.Name = "otDataGridViewTextBoxColumn";
this.otDataGridViewTextBoxColumn.ReadOnly = true;
this.otDataGridViewTextBoxColumn.Width = 75;
//
// ot2DataGridViewTextBoxColumn
//
this.ot2DataGridViewTextBoxColumn.DataPropertyName = "ot2";
dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
dataGridViewCellStyle6.Format = "N1";
this.ot2DataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle6;
this.ot2DataGridViewTextBoxColumn.HeaderText = "승인";
this.ot2DataGridViewTextBoxColumn.Name = "ot2DataGridViewTextBoxColumn";
this.ot2DataGridViewTextBoxColumn.Width = 75;
//
// otReasonDataGridViewTextBoxColumn
//
this.otReasonDataGridViewTextBoxColumn.DataPropertyName = "otReason";
dataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.otReasonDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle7;
this.otReasonDataGridViewTextBoxColumn.HeaderText = "사유";
this.otReasonDataGridViewTextBoxColumn.Name = "otReasonDataGridViewTextBoxColumn";
this.otReasonDataGridViewTextBoxColumn.Width = 75;
//
// otStartDataGridViewTextBoxColumn
//
this.otStartDataGridViewTextBoxColumn.DataPropertyName = "otStart";
dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle8.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle8.Format = "HH:mm:ss";
this.otStartDataGridViewTextBoxColumn.DefaultCellStyle = dataGridViewCellStyle8;
this.otStartDataGridViewTextBoxColumn.HeaderText = "시작";
this.otStartDataGridViewTextBoxColumn.Name = "otStartDataGridViewTextBoxColumn";
this.otStartDataGridViewTextBoxColumn.ReadOnly = true;
this.otStartDataGridViewTextBoxColumn.Visible = false;
this.otStartDataGridViewTextBoxColumn.Width = 65;
//
// otEnd
//
this.otEnd.DataPropertyName = "otEnd";
dataGridViewCellStyle9.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle9.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(224)))), ((int)(((byte)(192)))));
dataGridViewCellStyle9.Format = "HH:mm:ss";
this.otEnd.DefaultCellStyle = dataGridViewCellStyle9;
this.otEnd.HeaderText = "종료";
this.otEnd.Name = "otEnd";
this.otEnd.ReadOnly = true;
this.otEnd.Visible = false;
this.otEnd.Width = 65;
//
// projectNameDataGridViewTextBoxColumn
//
this.projectNameDataGridViewTextBoxColumn.DataPropertyName = "projectName";
this.projectNameDataGridViewTextBoxColumn.HeaderText = "프로젝트(아이템)";
this.projectNameDataGridViewTextBoxColumn.Name = "projectNameDataGridViewTextBoxColumn";
this.projectNameDataGridViewTextBoxColumn.ReadOnly = true;
this.projectNameDataGridViewTextBoxColumn.Width = 167;
//
// descriptionDataGridViewTextBoxColumn
//
this.descriptionDataGridViewTextBoxColumn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.descriptionDataGridViewTextBoxColumn.DataPropertyName = "description";
this.descriptionDataGridViewTextBoxColumn.HeaderText = "비고";
this.descriptionDataGridViewTextBoxColumn.Name = "descriptionDataGridViewTextBoxColumn";
this.descriptionDataGridViewTextBoxColumn.ReadOnly = true;
//
// label1
//
this.label1.Dock = System.Windows.Forms.DockStyle.Top;
this.label1.Location = new System.Drawing.Point(3, 3);
this.label1.Name = "label1";
this.label1.Padding = new System.Windows.Forms.Padding(10, 0, 0, 0);
this.label1.Size = new System.Drawing.Size(1505, 38);
this.label1.TabIndex = 5;
this.label1.Text = "승인시간 및 사유를 입력하세요.";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
// richTextBox1
//
this.richTextBox1.BackColor = System.Drawing.Color.WhiteSmoke;
this.richTextBox1.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.bs, "description", true));
this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.richTextBox1.Location = new System.Drawing.Point(3, 495);
this.richTextBox1.Name = "richTextBox1";
this.richTextBox1.ReadOnly = true;
this.richTextBox1.Size = new System.Drawing.Size(1505, 100);
this.richTextBox1.TabIndex = 6;
this.richTextBox1.Text = "";
//
// label2
//
this.label2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.label2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.label2.Font = new System.Drawing.Font("굴림", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label2.Location = new System.Drawing.Point(3, 460);
this.label2.Name = "label2";
this.label2.Padding = new System.Windows.Forms.Padding(10, 0, 0, 0);
this.label2.Size = new System.Drawing.Size(1505, 35);
this.label2.TabIndex = 7;
this.label2.Text = "담당자 비고";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// fOTConfirmOK
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(1035, 546);
this.ClientSize = new System.Drawing.Size(1511, 648);
this.Controls.Add(this.dv1);
this.Controls.Add(this.label2);
this.Controls.Add(this.richTextBox1);
this.Controls.Add(this.label1);
this.Controls.Add(this.button1);
this.Controls.Add(this.grpAdmin);
this.Controls.Add(this.grpUser);
this.Font = new System.Drawing.Font("굴림", 20F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "fOTConfirmOK";
@@ -259,38 +353,37 @@ namespace FPJ0000.OtConfirm
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "OT 승인/취소 작업";
this.Load += new System.EventHandler(this.fHolyRequestAdd_Load);
((System.ComponentModel.ISupportInitialize)(this.dsMSSQL)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.bs)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dSKuntae)).EndInit();
this.grpUser.ResumeLayout(false);
this.grpUser.PerformLayout();
this.grpAdmin.ResumeLayout(false);
this.grpAdmin.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dv1)).EndInit();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label label1;
private System.Windows.Forms.RichTextBox tbRemark;
private System.Windows.Forms.GroupBox grpUser;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.GroupBox grpAdmin;
private System.Windows.Forms.RichTextBox tbResponse;
private System.Windows.Forms.Button button1;
private DSKuntae dSKuntae;
private System.Windows.Forms.BindingSource bs;
private DSKuntaeTableAdapters.EETGW_HolydayRequestTableAdapter ta;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.TextBox textBox3;
private System.Windows.Forms.NumericUpDown numericUpDown2;
private System.Windows.Forms.NumericUpDown numericUpDown1;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.TextBox textBox2;
private dsPRJ dsMSSQL;
private System.Windows.Forms.BindingSource bs;
private arCtl.arDatagridView dv1;
private System.Windows.Forms.DataGridViewTextBoxColumn wwDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn pdateDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn WeekName;
private System.Windows.Forms.DataGridViewCheckBoxColumn FreeDay;
private System.Windows.Forms.DataGridViewTextBoxColumn usernameDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn requestpartDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn packageDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn statusDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn svalueDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn otDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn ot2DataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn otReasonDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn otStartDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn otEnd;
private System.Windows.Forms.DataGridViewTextBoxColumn projectNameDataGridViewTextBoxColumn;
private System.Windows.Forms.DataGridViewTextBoxColumn descriptionDataGridViewTextBoxColumn;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.RichTextBox richTextBox1;
private System.Windows.Forms.Label label2;
}
}

View File

@@ -12,38 +12,45 @@ namespace FPJ0000.OtConfirm
{
public partial class fOTConfirmOK : Form
{
dsPRJ.JobReportRow dr;
dsPRJ.JobReportRow[] dr;
Boolean binit = false;
public fOTConfirmOK(dsPRJ.JobReportRow dr_)
//public fOTConfirmOK(dsPRJ.JobReportRow dr_)
//{
// InitializeComponent();
// dr = dr_;
// //var userlist = FCOMMON.DBM.getUserTable();
// //this.cmbUser.DataSource = userlist;
// //this.cmbUser.ValueMember = "id";
// //this.cmbUser.DisplayMember = "dispname";
// //textBox1.Text = dr.username;
// //textBox2.Text = dr.pdate;
// //textBox3.Text = dr.projectName;
// //tbRemark.Text = dr.description;
// //numericUpDown2.Value = (decimal)dr.ot;
// //tbRemark.ImeMode = ImeMode.Hangul;
// //var dt = DateTime.Parse(dr.pdate);
// //textBox2.Text = dt.ToLongDateString();
// //if(dt.DayOfWeek == DayOfWeek.Sunday || dt.DayOfWeek == DayOfWeek.Saturday)
// //{
// // numericUpDown1.Value = (decimal)(dr.ot * 1.5f);
// //}
// //else
// //{
// // numericUpDown1.Value = (decimal)dr.ot;
// //}
//}
public fOTConfirmOK(dsPRJ.JobReportRow[] dr_)
{
InitializeComponent();
dr = dr_;
//var userlist = FCOMMON.DBM.getUserTable();
//this.cmbUser.DataSource = userlist;
//this.cmbUser.ValueMember = "id";
//this.cmbUser.DisplayMember = "dispname";
textBox1.Text = dr.username;
textBox2.Text = dr.pdate;
textBox3.Text = dr.projectName;
tbRemark.Text = dr.description;
numericUpDown2.Value = (decimal)dr.ot;
tbRemark.ImeMode = ImeMode.Hangul;
var dt = DateTime.Parse(dr.pdate);
textBox2.Text = dt.ToLongDateString();
if(dt.DayOfWeek == DayOfWeek.Sunday || dt.DayOfWeek == DayOfWeek.Saturday)
{
numericUpDown1.Value = (decimal)(dr.ot * 1.5f);
}
else
{
numericUpDown1.Value = (decimal)dr.ot;
}
this.bs.DataSource = dr_;
//this.dv1.DataSource = dr_;
}
int curLevel = 0;
@@ -58,25 +65,20 @@ namespace FPJ0000.OtConfirm
private void button1_Click(object sender, EventArgs e)
{
var intime = (float)numericUpDown1.Value;
if (intime == 0f)
{
var dlg = FCOMMON.Util.MsgQ("승인시간이 입력되지 않았습니다. 저장 할까요?\n해당 자료는 미승인 자료가 됩니다");
if (dlg != DialogResult.Yes) return;
}
else
{
var dlg = FCOMMON.Util.MsgQ("승인시간을 입력할까요?\n" +
$"요청:{numericUpDown2.Value},승인:{numericUpDown1.Value}\n" +
$"비고:{tbResponse.Text}\n" +
$"바로 저장 됩니다");
//초과시간이 입력된 데이터만 확인한다.
var cnt = dr.Where(t => t.RowState == DataRowState.Modified).Count();
var dlg = FCOMMON.Util.MsgQ($"{cnt}건의 자료를 저장할까요?\n" +
"승인시간이 입력된 자료는 근태현황에 자동 입력됩니다\n" +
"승인시간이 0으로 초기화된 자료는 근태현황이 자동 삭제됩니다");
if (dlg != DialogResult.Yes) return;
if (dlg != DialogResult.Yes) return;
this.Validate();
foreach (var row in this.dr)
{
row.EndEdit();
}
dr.ot2 = (float)this.numericUpDown1.Value;
dr.otReason = this.tbResponse.Text.Trim();
dr.EndEdit();
DialogResult = DialogResult.OK;
}

View File

@@ -117,13 +117,22 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="bs.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>122, 17</value>
</metadata>
<metadata name="dSKuntae.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="ta.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>186, 17</value>
</metadata>
<metadata name="dsMSSQL.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>248, 17</value>
</metadata>
<metadata name="bs.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>353, 17</value>
</metadata>
<metadata name="WeekName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="FreeDay.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="otEnd.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>

Binary file not shown.

View File

@@ -724,11 +724,13 @@
//
// btMailAddr
//
this.btMailAddr.ForeColor = System.Drawing.Color.Red;
this.btMailAddr.Image = ((System.Drawing.Image)(resources.GetObject("btMailAddr.Image")));
this.btMailAddr.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btMailAddr.Name = "btMailAddr";
this.btMailAddr.Size = new System.Drawing.Size(99, 22);
this.btMailAddr.Text = "메일주소관리";
this.btMailAddr.Visible = false;
this.btMailAddr.Click += new System.EventHandler(this.btMailAddr_Click);
//
// btPath
@@ -742,11 +744,13 @@
//
// btSendMail
//
this.btSendMail.ForeColor = System.Drawing.Color.Red;
this.btSendMail.Image = ((System.Drawing.Image)(resources.GetObject("btSendMail.Image")));
this.btSendMail.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btSendMail.Name = "btSendMail";
this.btSendMail.Size = new System.Drawing.Size(99, 22);
this.btSendMail.Text = "알림메일발송";
this.btSendMail.Visible = false;
this.btSendMail.Click += new System.EventHandler(this.btSendMail_Click);
//
// dataGridView1

View File

@@ -227,19 +227,67 @@ namespace FPJ0000
private void btPath_Click(object sender, EventArgs e)
{
string path = tbPath.Text.Trim();
if (path == "")
{
path = "\\10.131.32.33\\Data\\Projects\\";
path += tbIdx.Text;
tbPath.Text = path;
}
var dlg = FCOMMON.Util.MsgQ("다음 폴더를 표시할까요?\n\n" +
path);
if (dlg == System.Windows.Forms.DialogResult.Yes)
FCOMMON.Util.RunExplorer(path);
showfolder();
//string path = tbPath.Text.Trim();
//if (path == "")
//{
// path = "\\10.131.32.33\\Data\\Projects\\";
// path += tbIdx.Text;
// tbPath.Text = path;
//}
//var dlg = FCOMMON.Util.MsgQ("다음 폴더를 표시할까요?\n\n" +
// path);
//if (dlg == System.Windows.Forms.DialogResult.Yes)
// FCOMMON.Util.RunExplorer(path);
}
void showfolder()
{
var dr = this.bs.Current as dsPRJ.ProjectsRow;
if (dr == null) return;
//var dr = drv.Row as dsPRJ.ProjectsRow;
var tbPath = dr.path;
if (tbPath == "") tbPath = "/" + dr.idx.ToString();
if (tbPath.StartsWith("\\") == false)
{
if (tbPath.StartsWith("/")) tbPath = tbPath.Replace("/", "\\");
else tbPath = "\\" + tbPath;
}
//\\10.131.32.29\Data
var serverpath = System.IO.Path.Combine(FCOMMON.info.datapath, "Data", "Project");
if (System.IO.Directory.Exists(serverpath) == false)
{
FCOMMON.Util.MsgE("프로젝트 기본경로가 존재하지 않아 진행할 수 없습니다\n\n" +
serverpath);
return;
}
var path = serverpath + tbPath;
if (System.IO.Directory.Exists(path) == false)
{
try
{
System.IO.Directory.CreateDirectory(path);
string[] subdir = new string[] { "Source", "Document", "Draw", "Estimate" };
foreach (var dir in subdir)
System.IO.Directory.CreateDirectory(path + "\\" + dir);
}
catch (Exception eX)
{
FCOMMON.Util.MsgE("프로젝트 저장소 생성실패\n" + eX.Message);
return;
}
}
FCOMMON.Util.RunExplorer(path);
}
private void btPart_Click(object sender, EventArgs e)
{
var f = new fPartList(dr.idx);