diff --git a/Project/Controller/DashBoardController.cs b/Project/Controller/DashBoardController.cs
new file mode 100644
index 0000000..8a36c3f
--- /dev/null
+++ b/Project/Controller/DashBoardController.cs
@@ -0,0 +1,115 @@
+using FCOMMON;
+using Newtonsoft.Json;
+using System;
+using System.Linq;
+using System.Net.Http;
+using System.Security.Cryptography;
+using System.Web.Http;
+
+namespace Project
+{
+ public class DashBoardController : BaseController
+ {
+ [HttpPost]
+ public void Index([FromBody] string value)
+ {
+
+ }
+
+ // PUT api/values/5
+ public void Put(int id, [FromBody] string value)
+ {
+ }
+
+ // DELETE api/values/5
+ public void Delete(int id)
+ {
+ }
+
+ [HttpGet]
+ public string TodayCountH()
+ {
+
+ var sql = "select count(*) from EETGW_HolydayRequest " +
+ "where gcode = 'EET1P' and conf = 1 and HolyDays > 0 and " +
+ "sdate <= GETDATE() and edate >= GETDATE()";
+ var cnt = DBM.ExecuteScalar(sql);
+ return cnt.ToString();
+
+ }
+
+
+ [HttpGet]
+ public HttpResponseMessage GetholyUser()
+ {
+ var sql = string.Empty;
+ sql = $"select uid,cate,sdate,edate,HolyReason " +
+ $"from EETGW_HolydayRequest " +
+ $"where gcode = '{FCOMMON.info.Login.gcode}'" +
+ $"and conf = 1 and HolyDays > 0 and sdate <= GETDATE() and edate >= GETDATE()";
+
+ if (info.Login.gcode == null)
+ info.Login.gcode = "EET1P";
+
+ sql = sql.Replace("{gcode}", FCOMMON.info.Login.gcode);
+
+ var cs = Properties.Settings.Default.gwcs;// "Data Source=K4FASQL.kr.ds.amkor.com,50150;Initial Catalog=EE;Persist Security Info=True;User ID=eeadm;Password=uJnU8a8q&DJ+ug-D!";
+ var cn = new System.Data.SqlClient.SqlConnection(cs);
+ var cmd = new System.Data.SqlClient.SqlCommand(sql, cn);
+ var da = new System.Data.SqlClient.SqlDataAdapter(cmd);
+ var dt = new System.Data.DataTable();
+ da.Fill(dt);
+ da.Dispose();
+ cmd.Dispose();
+ cn.Dispose();
+
+ var txtjson = JsonConvert.SerializeObject(dt, new JsonSerializerSettings
+ {
+ NullValueHandling = NullValueHandling.Ignore
+ });
+
+ var resp = new HttpResponseMessage()
+ {
+ Content = new StringContent(
+ txtjson,
+ System.Text.Encoding.UTF8,
+ "application/json")
+ };
+
+ return resp;
+
+
+ }
+
+ [HttpGet]
+ public HttpResponseMessage Index()
+ {
+ //로그인이 되어있지않다면 로그인을 가져온다
+ MethodResult result;
+ result = View();
+
+ var model = GetGlobalModel();
+ var getParams = Request.GetQueryNameValuePairs();// GetParameters(data);
+
+ //기본값을 찾아서 없애줘야한다
+ var contents = result.Content;
+
+ //공용값 적용
+ ApplyCommonValue(ref contents);
+
+ //최종문자 적용
+ result.Content = contents;
+
+ var resp = new HttpResponseMessage()
+ {
+ Content = new StringContent(
+ result.Content,
+ System.Text.Encoding.UTF8,
+ "text/html")
+ };
+
+ return resp;
+ }
+
+ }
+}
diff --git a/Project/Dialog/fDashboard.Designer.cs b/Project/Dialog/fDashboard.Designer.cs
index 92a9206..66c7523 100644
--- a/Project/Dialog/fDashboard.Designer.cs
+++ b/Project/Dialog/fDashboard.Designer.cs
@@ -38,7 +38,7 @@
this.label1.ForeColor = System.Drawing.Color.DimGray;
this.label1.Location = new System.Drawing.Point(0, 0);
this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(800, 450);
+ this.label1.Size = new System.Drawing.Size(1063, 567);
this.label1.TabIndex = 0;
this.label1.Text = "요약 화면 구성 중 입니다.\r\n\r\n업무일지는 \"관리->업무일지->목록\" 을 사용하세요";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -48,7 +48,7 @@
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(800, 450);
+ this.ClientSize = new System.Drawing.Size(1063, 567);
this.Controls.Add(this.label1);
this.Name = "fDashboard";
this.Text = "요약";
diff --git a/Project/Dialog/fDashboard.cs b/Project/Dialog/fDashboard.cs
index eef98ad..3e1cfa6 100644
--- a/Project/Dialog/fDashboard.cs
+++ b/Project/Dialog/fDashboard.cs
@@ -1,9 +1,13 @@
-using FCOMMON;
+using FCM0000.Mail;
+using FCOMMON;
+using Microsoft.Web.WebView2.Core;
+using Microsoft.Web.WebView2.WinForms;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
+using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -13,11 +17,65 @@ namespace Project.Dialog
{
public partial class fDashboard : fBase
{
+ private WebView2 webView21;
public fDashboard()
{
InitializeComponent();
+ InitializeWebView2();
}
+ private void InitializeWebView2()
+ {
+ // 수동으로 WebView2 컨트롤 생성
+ this.webView21 = new WebView2();
+ // 기본 속성 설정
+ this.webView21.CreationProperties = null;
+ this.webView21.DefaultBackgroundColor = Color.White;
+ this.webView21.Dock = DockStyle.Fill;
+ this.webView21.Location = new Point(0, 0);
+ this.webView21.Name = "webView21";
+ this.webView21.Size = new Size(800, 600);
+ this.webView21.TabIndex = 0;
+ this.webView21.ZoomFactor = 1D;
+
+ // 폼에 추가
+ this.Controls.Add(this.webView21);
+
+ // 비동기 초기화
+ InitializeAsync();
+ }
+ private async void InitializeAsync()
+ {
+ try
+ {
+ // Fixed Version 경로 설정
+ string runtimePath = Path.Combine(Application.StartupPath, "WebView2Runtime");
+
+ if (Directory.Exists(runtimePath))
+ {
+ var env = await CoreWebView2Environment.CreateAsync(runtimePath);
+ await this.webView21.EnsureCoreWebView2Async(env);
+ }
+ else
+ {
+ // 시스템에 설치된 WebView2 사용
+ await this.webView21.EnsureCoreWebView2Async();
+ }
+ var fn = "intro.html";
+ if (System.Diagnostics.Debugger.IsAttached)
+ fn = "dashboard.html";
+ var fi = new System.IO.FileInfo($"view\\{fn}");
+ if(fi.Exists)
+ {
+ webView21.Source = new Uri(fi.FullName);
+ label1.Visible = false;
+ }
+ }
+ catch (Exception ex)
+ {
+ MessageBox.Show($"WebView2 초기화 실패: {ex.Message}");
+ }
+ }
protected override void OnLoad(EventArgs e)
{
base.OnLoad(e);
diff --git a/Project/EETGW.csproj b/Project/EETGW.csproj
index 5c45d96..407f90d 100644
--- a/Project/EETGW.csproj
+++ b/Project/EETGW.csproj
@@ -261,6 +261,7 @@
+
@@ -623,6 +624,12 @@
PreserveNewest
+
+ PreserveNewest
+
+
+ PreserveNewest
+
diff --git a/Project/View/dashboard.html b/Project/View/dashboard.html
new file mode 100644
index 0000000..0aa91dc
--- /dev/null
+++ b/Project/View/dashboard.html
@@ -0,0 +1,114 @@
+
+
+
+
+
+ 근태현황 대시보드
+
+
+
+
+
+
+
+
+
+
+
+ | 이름 |
+ 출근 시간 |
+ 퇴근 시간 |
+ 상태 |
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Project/View/intro.html b/Project/View/intro.html
new file mode 100644
index 0000000..a5ffa4c
--- /dev/null
+++ b/Project/View/intro.html
@@ -0,0 +1 @@
+intro file
\ No newline at end of file
diff --git a/Project/fMain.cs b/Project/fMain.cs
index f8a2038..6598e02 100644
--- a/Project/fMain.cs
+++ b/Project/fMain.cs
@@ -253,40 +253,7 @@ namespace Project
var menu_kuntaeVisible = FCOMMON.Util.getBit(FCOMMON.info.Login.gpermission, (int)FCOMMON.eGroupPermission.menu_workday);
var menu_logdata = FCOMMON.Util.getBit(FCOMMON.info.Login.gpermission, (int)FCOMMON.eGroupPermission.menu_logdata);
-
this.Menu_Dashboard();
- // Menu_Note();
-
- ////시작폼 확인
- //if (Pub.setting.startForm == eFormList.NR구매관리 && menu_purchaseVisible == true)
- //{
- // menu_nrpurchase();
- //}
- //else if (Pub.setting.startForm == eFormList.업무일지 && menu_dailyhistoryVisible == true)
- //{
- // menu_work_report();
- //}
- //else if (Pub.setting.startForm == eFormList.프로젝트관리 && menu_projectVisible == true)
- //{
- // menu_projecT_list();
- //}
- //else if (Pub.setting.startForm == eFormList.재고관리 && menu_jagoVisible == true)
- //{
- // Menu_Inventory();
- //}
- //else if (Pub.setting.startForm == eFormList.재고현황 && menu_jagoVisible == true)
- //{
- // Menu_InventoryList();
- //}
- //else if(Pub.setting.startForm == eFormList.품목입고)
- //{
- // menu_itemin();
- //}
- //else if (Pub.setting.startForm == eFormList.근태입력)
- //{
- // Menu_WorkTable();
- //}
-
}
void Menu_WorkTable()
{
@@ -668,6 +635,12 @@ namespace Project
}
private void 로그인ToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ CloseAllForm();
+ Func_Login();
+ }
+
+ void CloseAllForm()
{
while (tabControl1.TabPages.Count > 0)
{
@@ -679,7 +652,6 @@ namespace Project
this.tabControl1.Refresh();
}
- Func_Login();
}
private void 메일전송ToolStripMenuItem_Click(object sender, EventArgs e)
diff --git a/Sub/Console_SendMail/DSMail.Designer.cs b/Sub/Console_SendMail/DSMail.Designer.cs
index 2575971..042da92 100644
--- a/Sub/Console_SendMail/DSMail.Designer.cs
+++ b/Sub/Console_SendMail/DSMail.Designer.cs
@@ -6307,11 +6307,11 @@ namespace Console_SendMail {
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
public bool SendOK2 {
get {
- try {
- return ((bool)(this[this.tableMailData.SendOK2Column]));
+ if (this.IsSendOK2Null()) {
+ return false;
}
- catch (global::System.InvalidCastException e) {
- throw new global::System.Data.StrongTypingException("\'MailData\' 테이블의 \'SendOK2\' 열의 값이 DBNull입니다.", e);
+ else {
+ return ((bool)(this[this.tableMailData.SendOK2Column]));
}
}
set {
@@ -6323,11 +6323,11 @@ namespace Console_SendMail {
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
public string SendMsg2 {
get {
- try {
- return ((string)(this[this.tableMailData.SendMsg2Column]));
+ if (this.IsSendMsg2Null()) {
+ return string.Empty;
}
- catch (global::System.InvalidCastException e) {
- throw new global::System.Data.StrongTypingException("\'MailData\' 테이블의 \'SendMsg2\' 열의 값이 DBNull입니다.", e);
+ else {
+ return ((string)(this[this.tableMailData.SendMsg2Column]));
}
}
set {
@@ -9749,7 +9749,7 @@ namespace Console_SendMail.DSMailTableAdapters {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -10473,7 +10473,7 @@ SELECT idx, gcode, cate, title, tolist, bcc, cc, subject, tail, body, selfTo, se
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -10602,28 +10602,47 @@ SELECT idx, gcode, cate, title, tolist, bcc, cc, subject, tail, body, selfTo, se
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_wdate", global::System.Data.SqlDbType.SmallDateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
this._adapter.InsertCommand.Connection = this.Connection;
- this._adapter.InsertCommand.CommandText = @"INSERT INTO [MailData] ([project], [gcode], [cate], [pdate], [subject], [fromlist], [tolist], [bcc], [cc], [body], [SendOK], [SendMsg], [aidx], [atime], [wuid], [wdate]) VALUES (@project, @gcode, @cate, @pdate, @subject, @fromlist, @tolist, @bcc, @cc, @body, @SendOK, @SendMsg, @aidx, @atime, @wuid, @wdate);
+ this._adapter.InsertCommand.CommandText = @"INSERT INTO MailData
+ (project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate, suid, sdate, SendOK2, SendMsg2, suid2, sdate2)
+VALUES (@project,@gcode,@cate,@pdate,@subject,@fromlist,@tolist,@bcc,@cc,@body,@SendOK,@SendMsg,@aidx,@atime,@wuid,@wdate,@suid,@sdate,@SendOK2,@SendMsg2,@suid2,@sdate2);
SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate FROM MailData WHERE (idx = SCOPE_IDENTITY())";
this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@project", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "project", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cate", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pdate", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "pdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@subject", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "subject", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fromlist", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fromlist", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@tolist", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "tolist", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@bcc", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "bcc", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cc", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cc", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@body", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "body", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendOK", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "SendOK", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendMsg", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "SendMsg", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@aidx", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "aidx", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@atime", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "atime", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wuid", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "wuid", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wdate", global::System.Data.SqlDbType.SmallDateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@project", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "project", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cate", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "cate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@pdate", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "pdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@subject", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "subject", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fromlist", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "fromlist", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@tolist", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "tolist", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@bcc", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "bcc", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cc", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "cc", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@body", global::System.Data.SqlDbType.VarChar, 2147483647, global::System.Data.ParameterDirection.Input, 0, 0, "body", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendOK", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "SendOK", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendMsg", global::System.Data.SqlDbType.VarChar, 255, global::System.Data.ParameterDirection.Input, 0, 0, "SendMsg", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@aidx", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "aidx", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@atime", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "atime", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wuid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "wuid", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@suid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "suid", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@sdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "sdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendOK2", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "SendOK2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendMsg2", global::System.Data.SqlDbType.VarChar, 255, global::System.Data.ParameterDirection.Input, 0, 0, "SendMsg2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@suid2", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "suid2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@sdate2", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "sdate2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
this._adapter.UpdateCommand.Connection = this.Connection;
- this._adapter.UpdateCommand.CommandText = @"UPDATE [MailData] SET [project] = @project, [gcode] = @gcode, [cate] = @cate, [pdate] = @pdate, [subject] = @subject, [fromlist] = @fromlist, [tolist] = @tolist, [bcc] = @bcc, [cc] = @cc, [body] = @body, [SendOK] = @SendOK, [SendMsg] = @SendMsg, [aidx] = @aidx, [atime] = @atime, [wuid] = @wuid, [wdate] = @wdate WHERE (([idx] = @Original_idx) AND ((@IsNull_project = 1 AND [project] IS NULL) OR ([project] = @Original_project)) AND ([gcode] = @Original_gcode) AND ((@IsNull_cate = 1 AND [cate] IS NULL) OR ([cate] = @Original_cate)) AND ((@IsNull_pdate = 1 AND [pdate] IS NULL) OR ([pdate] = @Original_pdate)) AND ((@IsNull_SendOK = 1 AND [SendOK] IS NULL) OR ([SendOK] = @Original_SendOK)) AND ((@IsNull_SendMsg = 1 AND [SendMsg] IS NULL) OR ([SendMsg] = @Original_SendMsg)) AND ((@IsNull_aidx = 1 AND [aidx] IS NULL) OR ([aidx] = @Original_aidx)) AND ((@IsNull_atime = 1 AND [atime] IS NULL) OR ([atime] = @Original_atime)) AND ([wuid] = @Original_wuid) AND ([wdate] = @Original_wdate));
+ this._adapter.UpdateCommand.CommandText = @"UPDATE MailData
+SET project = @project, gcode = @gcode, cate = @cate, pdate = @pdate, subject = @subject, fromlist = @fromlist, tolist = @tolist, bcc = @bcc, cc = @cc, body = @body, SendOK = @SendOK,
+ SendMsg = @SendMsg, aidx = @aidx, atime = @atime, wuid = @wuid, wdate = @wdate, suid = @suid, sdate = @sdate, SendOK2 = @SendOK2, SendMsg2 = @SendMsg2, suid2 = @suid2,
+ sdate2 = @sdate2
+WHERE (idx = @Original_idx) AND (@IsNull_project = 1 AND project IS NULL OR
+ project = @Original_project) AND (gcode = @Original_gcode) AND (@IsNull_cate = 1 AND cate IS NULL OR
+ cate = @Original_cate) AND (@IsNull_pdate = 1 AND pdate IS NULL OR
+ pdate = @Original_pdate) AND (@IsNull_SendOK = 1 AND SendOK IS NULL OR
+ SendOK = @Original_SendOK) AND (@IsNull_SendMsg = 1 AND SendMsg IS NULL OR
+ SendMsg = @Original_SendMsg) AND (@IsNull_aidx = 1 AND aidx IS NULL OR
+ aidx = @Original_aidx) AND (@IsNull_atime = 1 AND atime IS NULL OR
+ atime = @Original_atime) AND (wuid = @Original_wuid) AND (wdate = @Original_wdate);
SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate FROM MailData WHERE (idx = @idx)";
this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@project", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "project", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
@@ -10642,6 +10661,12 @@ SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, bod
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@atime", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "atime", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wuid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "wuid", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@wdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@suid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "suid", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@sdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "sdate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendOK2", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "SendOK2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SendMsg2", global::System.Data.SqlDbType.VarChar, 255, global::System.Data.ParameterDirection.Input, 0, 0, "SendMsg2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@suid2", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "suid2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@sdate2", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "sdate2", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idx", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idx", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_project", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "project", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_project", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "project", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
@@ -10660,14 +10685,14 @@ SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, bod
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_atime", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "atime", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_wuid", global::System.Data.SqlDbType.VarChar, 20, global::System.Data.ParameterDirection.Input, 0, 0, "wuid", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_wdate", global::System.Data.SqlDbType.SmallDateTime, 4, global::System.Data.ParameterDirection.Input, 0, 0, "wdate", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
- this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idx", global::System.Data.SqlDbType.Variant, 1024, global::System.Data.ParameterDirection.Input, 0, 0, "idx", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idx", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idx", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
private void InitConnection() {
this._connection = new global::System.Data.SqlClient.SqlConnection();
- this._connection.ConnectionString = global::Console_SendMail.Properties.Settings.Default.gwcs;
+ this._connection.ConnectionString = global::Console_SendMail.Properties.Settings.Default.cs;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -10909,7 +10934,13 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
global::System.Nullable aidx,
string atime,
string wuid,
- System.DateTime wdate) {
+ System.DateTime wdate,
+ string suid,
+ global::System.Nullable sdate,
+ global::System.Nullable SendOK2,
+ string SendMsg2,
+ string suid2,
+ global::System.Nullable sdate2) {
if ((project.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[0].Value = ((int)(project.Value));
}
@@ -11001,6 +11032,42 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
this.Adapter.InsertCommand.Parameters[14].Value = ((string)(wuid));
}
this.Adapter.InsertCommand.Parameters[15].Value = ((System.DateTime)(wdate));
+ if ((suid == null)) {
+ this.Adapter.InsertCommand.Parameters[16].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[16].Value = ((string)(suid));
+ }
+ if ((sdate.HasValue == true)) {
+ this.Adapter.InsertCommand.Parameters[17].Value = ((System.DateTime)(sdate.Value));
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[17].Value = global::System.DBNull.Value;
+ }
+ if ((SendOK2.HasValue == true)) {
+ this.Adapter.InsertCommand.Parameters[18].Value = ((bool)(SendOK2.Value));
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[18].Value = global::System.DBNull.Value;
+ }
+ if ((SendMsg2 == null)) {
+ this.Adapter.InsertCommand.Parameters[19].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[19].Value = ((string)(SendMsg2));
+ }
+ if ((suid2 == null)) {
+ this.Adapter.InsertCommand.Parameters[20].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[20].Value = ((string)(suid2));
+ }
+ if ((sdate2.HasValue == true)) {
+ this.Adapter.InsertCommand.Parameters[21].Value = ((System.DateTime)(sdate2.Value));
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[21].Value = global::System.DBNull.Value;
+ }
global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
@@ -11038,6 +11105,12 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
string atime,
string wuid,
System.DateTime wdate,
+ string suid,
+ global::System.Nullable sdate,
+ global::System.Nullable SendOK2,
+ string SendMsg2,
+ string suid2,
+ global::System.Nullable sdate2,
int Original_idx,
global::System.Nullable Original_project,
string Original_gcode,
@@ -11049,7 +11122,7 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
string Original_atime,
string Original_wuid,
System.DateTime Original_wdate,
- object idx) {
+ int idx) {
if ((project.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(project.Value));
}
@@ -11141,82 +11214,113 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
this.Adapter.UpdateCommand.Parameters[14].Value = ((string)(wuid));
}
this.Adapter.UpdateCommand.Parameters[15].Value = ((System.DateTime)(wdate));
- this.Adapter.UpdateCommand.Parameters[16].Value = ((int)(Original_idx));
- if ((Original_project.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[18].Value = ((int)(Original_project.Value));
+ if ((suid == null)) {
+ this.Adapter.UpdateCommand.Parameters[16].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[16].Value = ((string)(suid));
+ }
+ if ((sdate.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[17].Value = ((System.DateTime)(sdate.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[17].Value = global::System.DBNull.Value;
+ }
+ if ((SendOK2.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[18].Value = ((bool)(SendOK2.Value));
}
else {
- this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[18].Value = global::System.DBNull.Value;
}
+ if ((SendMsg2 == null)) {
+ this.Adapter.UpdateCommand.Parameters[19].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[19].Value = ((string)(SendMsg2));
+ }
+ if ((suid2 == null)) {
+ this.Adapter.UpdateCommand.Parameters[20].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[20].Value = ((string)(suid2));
+ }
+ if ((sdate2.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[21].Value = ((System.DateTime)(sdate2.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
+ }
+ this.Adapter.UpdateCommand.Parameters[22].Value = ((int)(Original_idx));
+ if ((Original_project.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[23].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[24].Value = ((int)(Original_project.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[23].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[24].Value = global::System.DBNull.Value;
+ }
if ((Original_gcode == null)) {
throw new global::System.ArgumentNullException("Original_gcode");
}
else {
- this.Adapter.UpdateCommand.Parameters[19].Value = ((string)(Original_gcode));
+ this.Adapter.UpdateCommand.Parameters[25].Value = ((string)(Original_gcode));
}
if ((Original_cate == null)) {
- this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
- }
- else {
- this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[21].Value = ((string)(Original_cate));
- }
- if ((Original_pdate == null)) {
- this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[23].Value = global::System.DBNull.Value;
- }
- else {
- this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[23].Value = ((string)(Original_pdate));
- }
- if ((Original_SendOK.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[25].Value = ((bool)(Original_SendOK.Value));
- }
- else {
- this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[25].Value = global::System.DBNull.Value;
- }
- if ((Original_SendMsg == null)) {
this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[27].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[27].Value = ((string)(Original_SendMsg));
+ this.Adapter.UpdateCommand.Parameters[27].Value = ((string)(Original_cate));
}
- if ((Original_aidx.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[29].Value = ((int)(Original_aidx.Value));
- }
- else {
+ if ((Original_pdate == null)) {
this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[29].Value = global::System.DBNull.Value;
}
- if ((Original_atime == null)) {
+ else {
+ this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[29].Value = ((string)(Original_pdate));
+ }
+ if ((Original_SendOK.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[31].Value = ((bool)(Original_SendOK.Value));
+ }
+ else {
this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[31].Value = global::System.DBNull.Value;
}
+ if ((Original_SendMsg == null)) {
+ this.Adapter.UpdateCommand.Parameters[32].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[33].Value = global::System.DBNull.Value;
+ }
else {
- this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[31].Value = ((string)(Original_atime));
+ this.Adapter.UpdateCommand.Parameters[32].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[33].Value = ((string)(Original_SendMsg));
+ }
+ if ((Original_aidx.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[34].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[35].Value = ((int)(Original_aidx.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[34].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[35].Value = global::System.DBNull.Value;
+ }
+ if ((Original_atime == null)) {
+ this.Adapter.UpdateCommand.Parameters[36].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[37].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[36].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[37].Value = ((string)(Original_atime));
}
if ((Original_wuid == null)) {
throw new global::System.ArgumentNullException("Original_wuid");
}
else {
- this.Adapter.UpdateCommand.Parameters[32].Value = ((string)(Original_wuid));
- }
- this.Adapter.UpdateCommand.Parameters[33].Value = ((System.DateTime)(Original_wdate));
- if ((idx == null)) {
- throw new global::System.ArgumentNullException("idx");
- }
- else {
- this.Adapter.UpdateCommand.Parameters[34].Value = ((object)(idx));
+ this.Adapter.UpdateCommand.Parameters[38].Value = ((string)(Original_wuid));
}
+ this.Adapter.UpdateCommand.Parameters[39].Value = ((System.DateTime)(Original_wdate));
+ this.Adapter.UpdateCommand.Parameters[40].Value = ((int)(idx));
global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
@@ -11408,7 +11512,7 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)";
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -12090,7 +12194,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -12286,7 +12390,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -12535,7 +12639,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -12785,7 +12889,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -12967,7 +13071,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -13112,7 +13216,7 @@ WHERE (enable = 1) AND (ISNULL(fromlist, '') <> '') AND (ISNULL(tolist, '') <>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
private void InitConnection() {
this._connection = new global::System.Data.SqlClient.SqlConnection();
- this._connection.ConnectionString = global::Console_SendMail.Properties.Settings.Default.gwcs;
+ this._connection.ConnectionString = global::Console_SendMail.Properties.Settings.Default.cs;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -13473,7 +13577,7 @@ ORDER BY pdate";
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -13918,7 +14022,7 @@ SELECT idx, pdate, free, memo, wuid, wdate FROM HolidayLIst WHERE (idx = @idx)";
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
@@ -14178,7 +14282,7 @@ SELECT idx, pdate, free, memo, wuid, wdate FROM HolidayLIst WHERE (idx = @idx)";
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- internal global::System.Data.SqlClient.SqlConnection Connection {
+ public global::System.Data.SqlClient.SqlConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
diff --git a/Sub/Console_SendMail/DSMail.xsd b/Sub/Console_SendMail/DSMail.xsd
index d15acbb..a742d33 100644
--- a/Sub/Console_SendMail/DSMail.xsd
+++ b/Sub/Console_SendMail/DSMail.xsd
@@ -4,7 +4,7 @@
-
+
@@ -166,26 +166,34 @@ SELECT idx, gcode, cate, title, tolist, bcc, cc, subject, tail, body, selfTo, se
-
- INSERT INTO [MailData] ([project], [gcode], [cate], [pdate], [subject], [fromlist], [tolist], [bcc], [cc], [body], [SendOK], [SendMsg], [aidx], [atime], [wuid], [wdate]) VALUES (@project, @gcode, @cate, @pdate, @subject, @fromlist, @tolist, @bcc, @cc, @body, @SendOK, @SendMsg, @aidx, @atime, @wuid, @wdate);
+
+ INSERT INTO MailData
+ (project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate, suid, sdate, SendOK2, SendMsg2, suid2, sdate2)
+VALUES (@project,@gcode,@cate,@pdate,@subject,@fromlist,@tolist,@bcc,@cc,@body,@SendOK,@SendMsg,@aidx,@atime,@wuid,@wdate,@suid,@sdate,@SendOK2,@SendMsg2,@suid2,@sdate2);
SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate FROM MailData WHERE (idx = SCOPE_IDENTITY())
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -202,45 +210,62 @@ WHERE (gcode = @gcode) AND (pdate = @pdate) AND (cate = @cate)
-
- UPDATE [MailData] SET [project] = @project, [gcode] = @gcode, [cate] = @cate, [pdate] = @pdate, [subject] = @subject, [fromlist] = @fromlist, [tolist] = @tolist, [bcc] = @bcc, [cc] = @cc, [body] = @body, [SendOK] = @SendOK, [SendMsg] = @SendMsg, [aidx] = @aidx, [atime] = @atime, [wuid] = @wuid, [wdate] = @wdate WHERE (([idx] = @Original_idx) AND ((@IsNull_project = 1 AND [project] IS NULL) OR ([project] = @Original_project)) AND ([gcode] = @Original_gcode) AND ((@IsNull_cate = 1 AND [cate] IS NULL) OR ([cate] = @Original_cate)) AND ((@IsNull_pdate = 1 AND [pdate] IS NULL) OR ([pdate] = @Original_pdate)) AND ((@IsNull_SendOK = 1 AND [SendOK] IS NULL) OR ([SendOK] = @Original_SendOK)) AND ((@IsNull_SendMsg = 1 AND [SendMsg] IS NULL) OR ([SendMsg] = @Original_SendMsg)) AND ((@IsNull_aidx = 1 AND [aidx] IS NULL) OR ([aidx] = @Original_aidx)) AND ((@IsNull_atime = 1 AND [atime] IS NULL) OR ([atime] = @Original_atime)) AND ([wuid] = @Original_wuid) AND ([wdate] = @Original_wdate));
+
+ UPDATE MailData
+SET project = @project, gcode = @gcode, cate = @cate, pdate = @pdate, subject = @subject, fromlist = @fromlist, tolist = @tolist, bcc = @bcc, cc = @cc, body = @body, SendOK = @SendOK,
+ SendMsg = @SendMsg, aidx = @aidx, atime = @atime, wuid = @wuid, wdate = @wdate, suid = @suid, sdate = @sdate, SendOK2 = @SendOK2, SendMsg2 = @SendMsg2, suid2 = @suid2,
+ sdate2 = @sdate2
+WHERE (idx = @Original_idx) AND (@IsNull_project = 1 AND project IS NULL OR
+ project = @Original_project) AND (gcode = @Original_gcode) AND (@IsNull_cate = 1 AND cate IS NULL OR
+ cate = @Original_cate) AND (@IsNull_pdate = 1 AND pdate IS NULL OR
+ pdate = @Original_pdate) AND (@IsNull_SendOK = 1 AND SendOK IS NULL OR
+ SendOK = @Original_SendOK) AND (@IsNull_SendMsg = 1 AND SendMsg IS NULL OR
+ SendMsg = @Original_SendMsg) AND (@IsNull_aidx = 1 AND aidx IS NULL OR
+ aidx = @Original_aidx) AND (@IsNull_atime = 1 AND atime IS NULL OR
+ atime = @Original_atime) AND (wuid = @Original_wuid) AND (wdate = @Original_wdate);
SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, body, SendOK, SendMsg, aidx, atime, wuid, wdate FROM MailData WHERE (idx = @idx)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
+
-
+
-
+
-
+
-
+
-
-
-
-
+
+
+
+
@@ -272,7 +297,7 @@ SELECT idx, project, gcode, cate, pdate, subject, fromlist, tolist, bcc, cc, bod
-
+
SELECT COUNT(*) AS Expr1
@@ -287,7 +312,7 @@ WHERE (aidx = @aidx) AND (pdate = @pdate) AND (atime = @atime) AND (cate = @cat
-
+
SELECT COUNT(*) AS cnt
@@ -1015,8 +1040,8 @@ ORDER BY pdate
-
-
+
+
diff --git a/Sub/Console_SendMail/DSMail.xss b/Sub/Console_SendMail/DSMail.xss
index 2a51d55..19e7d8b 100644
--- a/Sub/Console_SendMail/DSMail.xss
+++ b/Sub/Console_SendMail/DSMail.xss
@@ -4,16 +4,16 @@
Changes to this file may cause incorrect behavior and will be lost if
the code is regenerated.
-->
-
+
-
-
+
+
-
+
-
+
-
+
diff --git a/Sub/Console_SendMail/DataBaseManager.cs b/Sub/Console_SendMail/DataBaseManager.cs
index bca64f6..769216f 100644
--- a/Sub/Console_SendMail/DataBaseManager.cs
+++ b/Sub/Console_SendMail/DataBaseManager.cs
@@ -15,6 +15,28 @@ namespace Console_SendMail
cn.ConnectionString = cs;
return cn;
}
+
+ public static bool GetGroupEnableMail(string GroupColumn)
+ {
+ List retval = new List();
+ var cn = getCn();
+ cn.Open();
+ var sql = "select isnull(usemail,'False') " +
+ " from UserGroup WITH (nolock) " +
+ $" where gcode='{GroupColumn}' ";
+
+
+ var cmd = new SqlCommand(sql, cn);
+ var value = cmd.ExecuteScalar().ToString().ToUpper();
+
+ cmd.Dispose();
+ cn.Close();
+ cn.Dispose();
+ return value == "TRUE";
+ }
+
+
+
public static List getGroupListWithoutGcode(string GroupColumn, string table, string where = "", Boolean desc = false, Boolean useColumncover = true)
{
List retval = new List();
diff --git a/Sub/Console_SendMail/Properties/AssemblyInfo.cs b/Sub/Console_SendMail/Properties/AssemblyInfo.cs
index 477de69..7e2cedb 100644
--- a/Sub/Console_SendMail/Properties/AssemblyInfo.cs
+++ b/Sub/Console_SendMail/Properties/AssemblyInfo.cs
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// 모든 값을 지정하거나 아래와 같이 '*'를 사용하여 빌드 번호 및 수정 번호를
// 기본값으로 할 수 있습니다.
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("1.0.0.0")]
+[assembly: AssemblyVersion("25.06.16.1530")]
+[assembly: AssemblyFileVersion("25.06.16.1530")]
diff --git a/Sub/Console_SendMail/_MailService.cs b/Sub/Console_SendMail/_MailService.cs
index dccdebb..bfaaced 100644
--- a/Sub/Console_SendMail/_MailService.cs
+++ b/Sub/Console_SendMail/_MailService.cs
@@ -38,6 +38,10 @@ namespace Console_SendMail
foreach (var vGcode in gcodelist)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//메일정보가 등록되지 않았다면 처리하지 않는다
var MailForm = taMailForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailForm == null) continue;
@@ -139,7 +143,7 @@ namespace Console_SendMail
mail_body = mail_body.Replace("{사번}", userinfo.Value.id);
//메일본문을 생성해서 진행해야함
- var mail_content = "일자별 정보
";
+ var mail_content = $"일자별 정보({vGcode})
";
mail_content += $"
조회기간 : {str_sd}~{str_ed}";
mail_content += "
| 날짜 | 요일 | 시간 |
";
foreach (var warnitem in WarnList)
@@ -258,6 +262,11 @@ namespace Console_SendMail
var gcodelist = DatabaseManager.getGroupListWithoutGcode("gcode", "MailForm", "gcode is not null and gcode <> 'DEV'");
foreach (var vGcode in gcodelist)
{
+
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//메일양식이 지정되어있는지 체크
var MailForm = taMailForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailForm == null) continue;
@@ -443,6 +452,10 @@ namespace Console_SendMail
var gcodelist = DatabaseManager.getGroupListWithoutGcode("gcode", "MailForm", "gcode is not null and gcode <> 'DEV'");
foreach (var vGcode in gcodelist)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//메일양식이 지정되어있는지 체크
var MailForm = taForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailForm == null) continue;
@@ -542,7 +555,7 @@ namespace Console_SendMail
}
newdr.EndEdit();
dt.AddMailDataRow(newdr);
- taMailData.Update(dt);
+ var CNT = taMailData.Update(newdr);
}
}
@@ -605,6 +618,10 @@ namespace Console_SendMail
var gcodelist = DatabaseManager.getGroupListWithoutGcode("gcode", "MailForm", "gcode is not null and gcode <> 'DEV'");
foreach (var vGcode in gcodelist)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//메일양식이 지정되어있는지 체크
var MailForm = taForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailForm == null) continue;
@@ -790,6 +807,10 @@ namespace Console_SendMail
foreach (var vGcode in gcodelist)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//메일양식이 지정되어있는지 체크
var MailJD = taForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailJD == null) continue;
@@ -1137,6 +1158,11 @@ namespace Console_SendMail
foreach (DSMail.MailAutoRow dr in dtList)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var vGcode = dr.gcode;
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
//시간정보가 없는 애들은 처리 하지 않음
if (dr.stime.IndexOf(":") == -1) continue;
if (dr.sday == null || dr.sday.Length < 2) continue;
@@ -1248,6 +1274,11 @@ namespace Console_SendMail
foreach (var vGcode in gcodelist)
{
+ //메일기능이 꺼져있다면 처리하지 않는다.
+ var usemail = DatabaseManager.GetGroupEnableMail(vGcode);
+ if (usemail == false) continue;
+
+
//메일양식이 지정되어있는지 체크
var MailJD = taForm.GetData(vGcode, vCate).FirstOrDefault();
if (MailJD == null) continue;
diff --git a/SubProject/FCM0000/DSUser.Designer.cs b/SubProject/FCM0000/DSUser.Designer.cs
index d768e48..aad9f90 100644
--- a/SubProject/FCM0000/DSUser.Designer.cs
+++ b/SubProject/FCM0000/DSUser.Designer.cs
@@ -365,6 +365,8 @@ namespace FCM0000 {
private global::System.Data.DataColumn columndevinfo;
+ private global::System.Data.DataColumn columnusemail;
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
public UserGroupDataTable() {
@@ -462,6 +464,14 @@ namespace FCM0000 {
}
}
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
+ public global::System.Data.DataColumn usemailColumn {
+ get {
+ return this.columnusemail;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
[global::System.ComponentModel.Browsable(false)]
@@ -499,7 +509,7 @@ namespace FCM0000 {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
- public UserGroupRow AddUserGroupRow(string dept, string gcode, string path_kj, int permission, bool advpurchase, bool advkisul, string managerinfo, string devinfo) {
+ public UserGroupRow AddUserGroupRow(string dept, string gcode, string path_kj, int permission, bool advpurchase, bool advkisul, string managerinfo, string devinfo, bool usemail) {
UserGroupRow rowUserGroupRow = ((UserGroupRow)(this.NewRow()));
object[] columnValuesArray = new object[] {
dept,
@@ -509,7 +519,8 @@ namespace FCM0000 {
advpurchase,
advkisul,
managerinfo,
- devinfo};
+ devinfo,
+ usemail};
rowUserGroupRow.ItemArray = columnValuesArray;
this.Rows.Add(rowUserGroupRow);
return rowUserGroupRow;
@@ -547,6 +558,7 @@ namespace FCM0000 {
this.columnadvkisul = base.Columns["advkisul"];
this.columnmanagerinfo = base.Columns["managerinfo"];
this.columndevinfo = base.Columns["devinfo"];
+ this.columnusemail = base.Columns["usemail"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -568,6 +580,8 @@ namespace FCM0000 {
base.Columns.Add(this.columnmanagerinfo);
this.columndevinfo = new global::System.Data.DataColumn("devinfo", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columndevinfo);
+ this.columnusemail = new global::System.Data.DataColumn("usemail", typeof(bool), null, global::System.Data.MappingType.Element);
+ base.Columns.Add(this.columnusemail);
this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
this.columndept}, true));
this.columndept.AllowDBNull = false;
@@ -1895,6 +1909,22 @@ namespace FCM0000 {
}
}
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
+ public bool usemail {
+ get {
+ if (this.IsusemailNull()) {
+ return false;
+ }
+ else {
+ return ((bool)(this[this.tableUserGroup.usemailColumn]));
+ }
+ }
+ set {
+ this[this.tableUserGroup.usemailColumn] = value;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
public bool IsgcodeNull() {
@@ -1978,6 +2008,18 @@ namespace FCM0000 {
public void SetdevinfoNull() {
this[this.tableUserGroup.devinfoColumn] = global::System.Convert.DBNull;
}
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
+ public bool IsusemailNull() {
+ return this.IsNull(this.tableUserGroup.usemailColumn);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
+ public void SetusemailNull() {
+ this[this.tableUserGroup.usemailColumn] = global::System.Convert.DBNull;
+ }
}
///
@@ -3196,10 +3238,11 @@ namespace FCM0000.DSUserTableAdapters {
tableMapping.ColumnMappings.Add("advkisul", "advkisul");
tableMapping.ColumnMappings.Add("managerinfo", "managerinfo");
tableMapping.ColumnMappings.Add("devinfo", "devinfo");
+ tableMapping.ColumnMappings.Add("usemail", "usemail");
this._adapter.TableMappings.Add(tableMapping);
this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
this._adapter.DeleteCommand.Connection = this.Connection;
- this._adapter.DeleteCommand.CommandText = @"DELETE FROM [UserGroup] WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)))";
+ this._adapter.DeleteCommand.CommandText = @"DELETE FROM [UserGroup] WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)) AND ((@IsNull_usemail = 1 AND [usemail] IS NULL) OR ([usemail] = @Original_usemail)))";
this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_dept", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "dept", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_gcode", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
@@ -3216,10 +3259,12 @@ namespace FCM0000.DSUserTableAdapters {
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_managerinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "managerinfo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_devinfo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_devinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_usemail", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_usemail", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
this._adapter.InsertCommand.Connection = this.Connection;
- this._adapter.InsertCommand.CommandText = @"INSERT INTO [UserGroup] ([dept], [gcode], [path_kj], [permission], [advpurchase], [advkisul], [managerinfo], [devinfo]) VALUES (@dept, @gcode, @path_kj, @permission, @advpurchase, @advkisul, @managerinfo, @devinfo);
-SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo FROM UserGroup WHERE (dept = @dept)";
+ this._adapter.InsertCommand.CommandText = @"INSERT INTO [UserGroup] ([dept], [gcode], [path_kj], [permission], [advpurchase], [advkisul], [managerinfo], [devinfo], [usemail]) VALUES (@dept, @gcode, @path_kj, @permission, @advpurchase, @advkisul, @managerinfo, @devinfo, @usemail);
+SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail FROM UserGroup WITH (nolock) WHERE (dept = @dept)";
this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@dept", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "dept", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
@@ -3229,10 +3274,11 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@advkisul", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "advkisul", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@managerinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "managerinfo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@devinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@usemail", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
this._adapter.UpdateCommand.Connection = this.Connection;
- this._adapter.UpdateCommand.CommandText = @"UPDATE [UserGroup] SET [dept] = @dept, [gcode] = @gcode, [path_kj] = @path_kj, [permission] = @permission, [advpurchase] = @advpurchase, [advkisul] = @advkisul, [managerinfo] = @managerinfo, [devinfo] = @devinfo WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)));
-SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo FROM UserGroup WHERE (dept = @dept)";
+ this._adapter.UpdateCommand.CommandText = @"UPDATE [UserGroup] SET [dept] = @dept, [gcode] = @gcode, [path_kj] = @path_kj, [permission] = @permission, [advpurchase] = @advpurchase, [advkisul] = @advkisul, [managerinfo] = @managerinfo, [devinfo] = @devinfo, [usemail] = @usemail WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)) AND ((@IsNull_usemail = 1 AND [usemail] IS NULL) OR ([usemail] = @Original_usemail)));
+SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail FROM UserGroup WITH (nolock) WHERE (dept = @dept)";
this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@dept", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "dept", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
@@ -3242,6 +3288,7 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@advkisul", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "advkisul", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@managerinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "managerinfo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@devinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@usemail", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_dept", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "dept", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_gcode", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_gcode", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
@@ -3257,6 +3304,8 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_managerinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "managerinfo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_devinfo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_devinfo", global::System.Data.SqlDbType.VarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "devinfo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_usemail", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_usemail", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "usemail", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -3273,12 +3322,12 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev" +
- "info\r\nFROM UserGroup WITH (nolock)";
+ "info, usemail\r\nFROM UserGroup WITH (nolock)";
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand();
this._commandCollection[1].Connection = this.Connection;
this._commandCollection[1].CommandText = "SELECT advkisul, advpurchase, dept, devinfo, gcode, managerinfo, path_kj, permis" +
- "sion\r\nFROM UserGroup WITH (nolock)\r\nWHERE (gcode = @gcode)";
+ "sion, usemail\r\nFROM UserGroup WITH (nolock)\r\nWHERE (gcode = @gcode)";
this._commandCollection[1].CommandType = global::System.Data.CommandType.Text;
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
}
@@ -3376,7 +3425,7 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
- public virtual int Delete(string Original_dept, string Original_gcode, string Original_path_kj, global::System.Nullable Original_permission, global::System.Nullable Original_advpurchase, global::System.Nullable Original_advkisul, string Original_managerinfo, string Original_devinfo) {
+ public virtual int Delete(string Original_dept, string Original_gcode, string Original_path_kj, global::System.Nullable Original_permission, global::System.Nullable Original_advpurchase, global::System.Nullable Original_advkisul, string Original_managerinfo, string Original_devinfo, global::System.Nullable Original_usemail) {
if ((Original_dept == null)) {
throw new global::System.ArgumentNullException("Original_dept");
}
@@ -3439,6 +3488,14 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[14].Value = ((string)(Original_devinfo));
}
+ if ((Original_usemail.HasValue == true)) {
+ this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(0));
+ this.Adapter.DeleteCommand.Parameters[16].Value = ((bool)(Original_usemail.Value));
+ }
+ else {
+ this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(1));
+ this.Adapter.DeleteCommand.Parameters[16].Value = global::System.DBNull.Value;
+ }
global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
@@ -3459,7 +3516,7 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
- public virtual int Insert(string dept, string gcode, string path_kj, global::System.Nullable permission, global::System.Nullable advpurchase, global::System.Nullable advkisul, string managerinfo, string devinfo) {
+ public virtual int Insert(string dept, string gcode, string path_kj, global::System.Nullable permission, global::System.Nullable advpurchase, global::System.Nullable advkisul, string managerinfo, string devinfo, global::System.Nullable usemail) {
if ((dept == null)) {
throw new global::System.ArgumentNullException("dept");
}
@@ -3508,6 +3565,12 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
else {
this.Adapter.InsertCommand.Parameters[7].Value = ((string)(devinfo));
}
+ if ((usemail.HasValue == true)) {
+ this.Adapter.InsertCommand.Parameters[8].Value = ((bool)(usemail.Value));
+ }
+ else {
+ this.Adapter.InsertCommand.Parameters[8].Value = global::System.DBNull.Value;
+ }
global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
@@ -3537,6 +3600,7 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
global::System.Nullable advkisul,
string managerinfo,
string devinfo,
+ global::System.Nullable usemail,
string Original_dept,
string Original_gcode,
string Original_path_kj,
@@ -3544,7 +3608,8 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
global::System.Nullable Original_advpurchase,
global::System.Nullable Original_advkisul,
string Original_managerinfo,
- string Original_devinfo) {
+ string Original_devinfo,
+ global::System.Nullable Original_usemail) {
if ((dept == null)) {
throw new global::System.ArgumentNullException("dept");
}
@@ -3593,67 +3658,81 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
else {
this.Adapter.UpdateCommand.Parameters[7].Value = ((string)(devinfo));
}
+ if ((usemail.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[8].Value = ((bool)(usemail.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[8].Value = global::System.DBNull.Value;
+ }
if ((Original_dept == null)) {
throw new global::System.ArgumentNullException("Original_dept");
}
else {
- this.Adapter.UpdateCommand.Parameters[8].Value = ((string)(Original_dept));
+ this.Adapter.UpdateCommand.Parameters[9].Value = ((string)(Original_dept));
}
if ((Original_gcode == null)) {
- this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[10].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[10].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[11].Value = global::System.DBNull.Value;
}
else {
- this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[10].Value = ((string)(Original_gcode));
+ this.Adapter.UpdateCommand.Parameters[10].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[11].Value = ((string)(Original_gcode));
}
if ((Original_path_kj == null)) {
- this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[12].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[12].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[13].Value = global::System.DBNull.Value;
}
else {
- this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[12].Value = ((string)(Original_path_kj));
+ this.Adapter.UpdateCommand.Parameters[12].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[13].Value = ((string)(Original_path_kj));
}
if ((Original_permission.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[14].Value = ((int)(Original_permission.Value));
+ this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[15].Value = ((int)(Original_permission.Value));
}
else {
- this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[14].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[15].Value = global::System.DBNull.Value;
}
if ((Original_advpurchase.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[16].Value = ((bool)(Original_advpurchase.Value));
+ this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[17].Value = ((bool)(Original_advpurchase.Value));
}
else {
- this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[16].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[17].Value = global::System.DBNull.Value;
}
if ((Original_advkisul.HasValue == true)) {
- this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[18].Value = ((bool)(Original_advkisul.Value));
+ this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[19].Value = ((bool)(Original_advkisul.Value));
}
else {
- this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[18].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[19].Value = global::System.DBNull.Value;
}
if ((Original_managerinfo == null)) {
- this.Adapter.UpdateCommand.Parameters[19].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[20].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
}
else {
- this.Adapter.UpdateCommand.Parameters[19].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[20].Value = ((string)(Original_managerinfo));
+ this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[21].Value = ((string)(Original_managerinfo));
}
if ((Original_devinfo == null)) {
- this.Adapter.UpdateCommand.Parameters[21].Value = ((object)(1));
- this.Adapter.UpdateCommand.Parameters[22].Value = global::System.DBNull.Value;
+ this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[23].Value = global::System.DBNull.Value;
}
else {
- this.Adapter.UpdateCommand.Parameters[21].Value = ((object)(0));
- this.Adapter.UpdateCommand.Parameters[22].Value = ((string)(Original_devinfo));
+ this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[23].Value = ((string)(Original_devinfo));
+ }
+ if ((Original_usemail.HasValue == true)) {
+ this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(0));
+ this.Adapter.UpdateCommand.Parameters[25].Value = ((bool)(Original_usemail.Value));
+ }
+ else {
+ this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(1));
+ this.Adapter.UpdateCommand.Parameters[25].Value = global::System.DBNull.Value;
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
@@ -3675,8 +3754,25 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
- public virtual int Update(string gcode, string path_kj, global::System.Nullable permission, global::System.Nullable advpurchase, global::System.Nullable advkisul, string managerinfo, string devinfo, string Original_dept, string Original_gcode, string Original_path_kj, global::System.Nullable Original_permission, global::System.Nullable Original_advpurchase, global::System.Nullable Original_advkisul, string Original_managerinfo, string Original_devinfo) {
- return this.Update(Original_dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, Original_dept, Original_gcode, Original_path_kj, Original_permission, Original_advpurchase, Original_advkisul, Original_managerinfo, Original_devinfo);
+ public virtual int Update(
+ string gcode,
+ string path_kj,
+ global::System.Nullable permission,
+ global::System.Nullable advpurchase,
+ global::System.Nullable advkisul,
+ string managerinfo,
+ string devinfo,
+ global::System.Nullable usemail,
+ string Original_dept,
+ string Original_gcode,
+ string Original_path_kj,
+ global::System.Nullable Original_permission,
+ global::System.Nullable Original_advpurchase,
+ global::System.Nullable Original_advkisul,
+ string Original_managerinfo,
+ string Original_devinfo,
+ global::System.Nullable Original_usemail) {
+ return this.Update(Original_dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail, Original_dept, Original_gcode, Original_path_kj, Original_permission, Original_advpurchase, Original_advkisul, Original_managerinfo, Original_devinfo, Original_usemail);
}
}
diff --git a/SubProject/FCM0000/DSUser.xsd b/SubProject/FCM0000/DSUser.xsd
index 5f89cc9..6068d5c 100644
--- a/SubProject/FCM0000/DSUser.xsd
+++ b/SubProject/FCM0000/DSUser.xsd
@@ -12,7 +12,7 @@
- DELETE FROM [UserGroup] WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)))
+ DELETE FROM [UserGroup] WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)) AND ((@IsNull_usemail = 1 AND [usemail] IS NULL) OR ([usemail] = @Original_usemail)))
@@ -29,13 +29,15 @@
+
+
- INSERT INTO [UserGroup] ([dept], [gcode], [path_kj], [permission], [advpurchase], [advkisul], [managerinfo], [devinfo]) VALUES (@dept, @gcode, @path_kj, @permission, @advpurchase, @advkisul, @managerinfo, @devinfo);
-SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo FROM UserGroup WHERE (dept = @dept)
+ INSERT INTO [UserGroup] ([dept], [gcode], [path_kj], [permission], [advpurchase], [advkisul], [managerinfo], [devinfo], [usemail]) VALUES (@dept, @gcode, @path_kj, @permission, @advpurchase, @advkisul, @managerinfo, @devinfo, @usemail);
+SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail FROM UserGroup WITH (nolock) WHERE (dept = @dept)
@@ -45,20 +47,21 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
+
- SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo
+ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail
FROM UserGroup WITH (nolock)
- UPDATE [UserGroup] SET [dept] = @dept, [gcode] = @gcode, [path_kj] = @path_kj, [permission] = @permission, [advpurchase] = @advpurchase, [advkisul] = @advkisul, [managerinfo] = @managerinfo, [devinfo] = @devinfo WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)));
-SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo FROM UserGroup WHERE (dept = @dept)
+ UPDATE [UserGroup] SET [dept] = @dept, [gcode] = @gcode, [path_kj] = @path_kj, [permission] = @permission, [advpurchase] = @advpurchase, [advkisul] = @advkisul, [managerinfo] = @managerinfo, [devinfo] = @devinfo, [usemail] = @usemail WHERE (([dept] = @Original_dept) AND ((@IsNull_gcode = 1 AND [gcode] IS NULL) OR ([gcode] = @Original_gcode)) AND ((@IsNull_path_kj = 1 AND [path_kj] IS NULL) OR ([path_kj] = @Original_path_kj)) AND ((@IsNull_permission = 1 AND [permission] IS NULL) OR ([permission] = @Original_permission)) AND ((@IsNull_advpurchase = 1 AND [advpurchase] IS NULL) OR ([advpurchase] = @Original_advpurchase)) AND ((@IsNull_advkisul = 1 AND [advkisul] IS NULL) OR ([advkisul] = @Original_advkisul)) AND ((@IsNull_managerinfo = 1 AND [managerinfo] IS NULL) OR ([managerinfo] = @Original_managerinfo)) AND ((@IsNull_devinfo = 1 AND [devinfo] IS NULL) OR ([devinfo] = @Original_devinfo)) AND ((@IsNull_usemail = 1 AND [usemail] IS NULL) OR ([usemail] = @Original_usemail)));
+SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, devinfo, usemail FROM UserGroup WITH (nolock) WHERE (dept = @dept)
@@ -68,6 +71,7 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
+
@@ -83,6 +87,8 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
+
+
@@ -97,12 +103,13 @@ SELECT dept, gcode, path_kj, permission, advpurchase, advkisul, managerinfo, dev
+
- SELECT advkisul, advpurchase, dept, devinfo, gcode, managerinfo, path_kj, permission
+ SELECT advkisul, advpurchase, dept, devinfo, gcode, managerinfo, path_kj, permission, usemail
FROM UserGroup WITH (nolock)
WHERE (gcode = @gcode)
@@ -456,10 +463,10 @@ SELECT idx, [user], gcode, purchase, holyday, project, jobreport, savecost, sche
-
+
-
+
@@ -497,13 +504,14 @@ SELECT idx, [user], gcode, purchase, holyday, project, jobreport, savecost, sche
+
-
+
-
+
@@ -623,15 +631,15 @@ SELECT idx, [user], gcode, purchase, holyday, project, jobreport, savecost, sche
-
-
+
+
-
+
@@ -641,10 +649,10 @@ SELECT idx, [user], gcode, purchase, holyday, project, jobreport, savecost, sche
-
+
-
+
diff --git a/SubProject/FCM0000/DSUser.xss b/SubProject/FCM0000/DSUser.xss
index b49349d..d8df724 100644
--- a/SubProject/FCM0000/DSUser.xss
+++ b/SubProject/FCM0000/DSUser.xss
@@ -4,7 +4,7 @@
Changes to this file may cause incorrect behavior and will be lost if
the code is regenerated.
-->
-
+
diff --git a/SubProject/FCM0000/User/fUserGroupDev.Designer.cs b/SubProject/FCM0000/User/fUserGroupDev.Designer.cs
index 5524ad9..ac88708 100644
--- a/SubProject/FCM0000/User/fUserGroupDev.Designer.cs
+++ b/SubProject/FCM0000/User/fUserGroupDev.Designer.cs
@@ -30,14 +30,6 @@
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fUserGroupDev));
- FarPoint.Win.Spread.CellType.TextCellType textCellType6 = new FarPoint.Win.Spread.CellType.TextCellType();
- FarPoint.Win.Spread.CellType.TextCellType textCellType7 = new FarPoint.Win.Spread.CellType.TextCellType();
- FarPoint.Win.Spread.CellType.TextCellType textCellType8 = new FarPoint.Win.Spread.CellType.TextCellType();
- FarPoint.Win.Spread.CellType.NumberCellType numberCellType2 = new FarPoint.Win.Spread.CellType.NumberCellType();
- FarPoint.Win.Spread.CellType.CheckBoxCellType checkBoxCellType3 = new FarPoint.Win.Spread.CellType.CheckBoxCellType();
- FarPoint.Win.Spread.CellType.CheckBoxCellType checkBoxCellType4 = new FarPoint.Win.Spread.CellType.CheckBoxCellType();
- FarPoint.Win.Spread.CellType.TextCellType textCellType9 = new FarPoint.Win.Spread.CellType.TextCellType();
- FarPoint.Win.Spread.CellType.TextCellType textCellType10 = new FarPoint.Win.Spread.CellType.TextCellType();
this.bs = new System.Windows.Forms.BindingSource(this.components);
this.dSUser = new FCM0000.DSUser();
this.taStaff = new FCM0000.dsMSSQLTableAdapters.StaffTableAdapter();
@@ -64,18 +56,25 @@
this.loadToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripSeparator();
this.권한설정ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
- this.fpSpread1 = new FarPoint.Win.Spread.FpSpread();
- this.fpSpread1_Sheet1 = new FarPoint.Win.Spread.SheetView();
this.bsStaff = new System.Windows.Forms.BindingSource(this.components);
this.ta = new FCM0000.DSUserTableAdapters.UserGroupTableAdapter();
+ this.dv1 = new System.Windows.Forms.DataGridView();
+ this.deptDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.gcodeDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.pathkjDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.permissionDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.advpurchaseDataGridViewCheckBoxColumn = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+ this.advkisulDataGridViewCheckBoxColumn = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+ this.managerinfoDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.devinfoDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.usemailDataGridViewCheckBoxColumn = new System.Windows.Forms.DataGridViewCheckBoxColumn();
((System.ComponentModel.ISupportInitialize)(this.bs)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dSUser)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.bn)).BeginInit();
this.bn.SuspendLayout();
this.cm1.SuspendLayout();
- ((System.ComponentModel.ISupportInitialize)(this.fpSpread1)).BeginInit();
- ((System.ComponentModel.ISupportInitialize)(this.fpSpread1_Sheet1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.bsStaff)).BeginInit();
+ ((System.ComponentModel.ISupportInitialize)(this.dv1)).BeginInit();
this.SuspendLayout();
//
// bs
@@ -117,14 +116,14 @@
this.toolStripLabel2,
this.tbFind,
this.btFind});
- this.bn.Location = new System.Drawing.Point(0, 570);
+ this.bn.Location = new System.Drawing.Point(0, 614);
this.bn.MoveFirstItem = this.bindingNavigatorMoveFirstItem;
this.bn.MoveLastItem = this.bindingNavigatorMoveLastItem;
this.bn.MoveNextItem = this.bindingNavigatorMoveNextItem;
this.bn.MovePreviousItem = this.bindingNavigatorMovePreviousItem;
this.bn.Name = "bn";
this.bn.PositionItem = this.bindingNavigatorPositionItem;
- this.bn.Size = new System.Drawing.Size(910, 25);
+ this.bn.Size = new System.Drawing.Size(999, 25);
this.bn.TabIndex = 0;
this.bn.Text = "bindingNavigator1";
//
@@ -297,83 +296,95 @@
this.권한설정ToolStripMenuItem.Text = "권한설정";
this.권한설정ToolStripMenuItem.Click += new System.EventHandler(this.권한설정ToolStripMenuItem_Click);
//
- // fpSpread1
- //
- this.fpSpread1.AccessibleDescription = "";
- this.fpSpread1.Dock = System.Windows.Forms.DockStyle.Fill;
- this.fpSpread1.Location = new System.Drawing.Point(0, 0);
- this.fpSpread1.Name = "fpSpread1";
- this.fpSpread1.Sheets.AddRange(new FarPoint.Win.Spread.SheetView[] {
- this.fpSpread1_Sheet1});
- this.fpSpread1.Size = new System.Drawing.Size(910, 570);
- this.fpSpread1.TabIndex = 2;
- //
- // fpSpread1_Sheet1
- //
- this.fpSpread1_Sheet1.Reset();
- this.fpSpread1_Sheet1.SheetName = "Sheet1";
- // Formulas and custom names must be loaded with R1C1 reference style
- this.fpSpread1_Sheet1.ReferenceStyle = FarPoint.Win.Spread.Model.ReferenceStyle.R1C1;
- this.fpSpread1_Sheet1.ColumnCount = 8;
- this.fpSpread1_Sheet1.ActiveColumnIndex = -1;
- this.fpSpread1_Sheet1.ActiveRowIndex = -1;
- this.fpSpread1_Sheet1.ColumnHeader.Cells.Get(0, 0).Value = "부서명";
- this.fpSpread1_Sheet1.ColumnHeader.Cells.Get(0, 1).Value = "부서코드";
- this.fpSpread1_Sheet1.ColumnHeader.Cells.Get(0, 3).Value = "권한";
- this.fpSpread1_Sheet1.ColumnHeader.Rows.Get(0).Height = 38F;
- this.fpSpread1_Sheet1.Columns.Get(0).CellType = textCellType6;
- this.fpSpread1_Sheet1.Columns.Get(0).DataField = "dept";
- this.fpSpread1_Sheet1.Columns.Get(0).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(0).Label = "부서명";
- this.fpSpread1_Sheet1.Columns.Get(0).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(0).Width = 151F;
- this.fpSpread1_Sheet1.Columns.Get(1).CellType = textCellType7;
- this.fpSpread1_Sheet1.Columns.Get(1).DataField = "gcode";
- this.fpSpread1_Sheet1.Columns.Get(1).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(1).Label = "부서코드";
- this.fpSpread1_Sheet1.Columns.Get(1).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(1).Width = 151F;
- this.fpSpread1_Sheet1.Columns.Get(2).CellType = textCellType8;
- this.fpSpread1_Sheet1.Columns.Get(2).DataField = "path_kj";
- this.fpSpread1_Sheet1.Columns.Get(2).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(2).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(2).Visible = false;
- this.fpSpread1_Sheet1.Columns.Get(2).Width = 151F;
- this.fpSpread1_Sheet1.Columns.Get(3).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
- numberCellType2.DecimalPlaces = 0;
- numberCellType2.LeadingZero = FarPoint.Win.Spread.CellType.LeadingZero.Yes;
- numberCellType2.MaximumValue = 2147483647D;
- numberCellType2.MinimumValue = -2147483648D;
- this.fpSpread1_Sheet1.Columns.Get(3).CellType = numberCellType2;
- this.fpSpread1_Sheet1.Columns.Get(3).DataField = "permission";
- this.fpSpread1_Sheet1.Columns.Get(3).HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(3).Label = "권한";
- this.fpSpread1_Sheet1.Columns.Get(3).VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center;
- this.fpSpread1_Sheet1.Columns.Get(3).Width = 88F;
- this.fpSpread1_Sheet1.Columns.Get(4).CellType = checkBoxCellType3;
- this.fpSpread1_Sheet1.Columns.Get(4).DataField = "advpurchase";
- this.fpSpread1_Sheet1.Columns.Get(5).CellType = checkBoxCellType4;
- this.fpSpread1_Sheet1.Columns.Get(5).DataField = "advkisul";
- this.fpSpread1_Sheet1.Columns.Get(6).CellType = textCellType9;
- this.fpSpread1_Sheet1.Columns.Get(6).DataField = "managerinfo";
- this.fpSpread1_Sheet1.Columns.Get(7).CellType = textCellType10;
- this.fpSpread1_Sheet1.Columns.Get(7).DataField = "devinfo";
- this.fpSpread1_Sheet1.DataAutoSizeColumns = false;
- this.fpSpread1_Sheet1.DataSource = this.bs;
- this.fpSpread1_Sheet1.RowHeader.Columns.Default.Resizable = false;
- this.fpSpread1_Sheet1.ReferenceStyle = FarPoint.Win.Spread.Model.ReferenceStyle.A1;
- //
// ta
//
this.ta.ClearBeforeFill = true;
//
+ // dv1
+ //
+ this.dv1.AllowUserToAddRows = false;
+ this.dv1.AutoGenerateColumns = false;
+ this.dv1.ColumnHeadersHeight = 35;
+ this.dv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+ this.deptDataGridViewTextBoxColumn,
+ this.gcodeDataGridViewTextBoxColumn,
+ this.pathkjDataGridViewTextBoxColumn,
+ this.permissionDataGridViewTextBoxColumn,
+ this.advpurchaseDataGridViewCheckBoxColumn,
+ this.advkisulDataGridViewCheckBoxColumn,
+ this.managerinfoDataGridViewTextBoxColumn,
+ this.devinfoDataGridViewTextBoxColumn,
+ this.usemailDataGridViewCheckBoxColumn});
+ this.dv1.ContextMenuStrip = this.cm1;
+ this.dv1.DataSource = this.bs;
+ this.dv1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.dv1.Location = new System.Drawing.Point(0, 0);
+ this.dv1.Name = "dv1";
+ this.dv1.RowTemplate.Height = 23;
+ this.dv1.Size = new System.Drawing.Size(999, 614);
+ this.dv1.TabIndex = 1;
+ //
+ // deptDataGridViewTextBoxColumn
+ //
+ this.deptDataGridViewTextBoxColumn.DataPropertyName = "dept";
+ this.deptDataGridViewTextBoxColumn.HeaderText = "dept";
+ this.deptDataGridViewTextBoxColumn.Name = "deptDataGridViewTextBoxColumn";
+ //
+ // gcodeDataGridViewTextBoxColumn
+ //
+ this.gcodeDataGridViewTextBoxColumn.DataPropertyName = "gcode";
+ this.gcodeDataGridViewTextBoxColumn.HeaderText = "gcode";
+ this.gcodeDataGridViewTextBoxColumn.Name = "gcodeDataGridViewTextBoxColumn";
+ //
+ // pathkjDataGridViewTextBoxColumn
+ //
+ this.pathkjDataGridViewTextBoxColumn.DataPropertyName = "path_kj";
+ this.pathkjDataGridViewTextBoxColumn.HeaderText = "path_kj";
+ this.pathkjDataGridViewTextBoxColumn.Name = "pathkjDataGridViewTextBoxColumn";
+ //
+ // permissionDataGridViewTextBoxColumn
+ //
+ this.permissionDataGridViewTextBoxColumn.DataPropertyName = "permission";
+ this.permissionDataGridViewTextBoxColumn.HeaderText = "permission";
+ this.permissionDataGridViewTextBoxColumn.Name = "permissionDataGridViewTextBoxColumn";
+ //
+ // advpurchaseDataGridViewCheckBoxColumn
+ //
+ this.advpurchaseDataGridViewCheckBoxColumn.DataPropertyName = "advpurchase";
+ this.advpurchaseDataGridViewCheckBoxColumn.HeaderText = "advpurchase";
+ this.advpurchaseDataGridViewCheckBoxColumn.Name = "advpurchaseDataGridViewCheckBoxColumn";
+ //
+ // advkisulDataGridViewCheckBoxColumn
+ //
+ this.advkisulDataGridViewCheckBoxColumn.DataPropertyName = "advkisul";
+ this.advkisulDataGridViewCheckBoxColumn.HeaderText = "advkisul";
+ this.advkisulDataGridViewCheckBoxColumn.Name = "advkisulDataGridViewCheckBoxColumn";
+ //
+ // managerinfoDataGridViewTextBoxColumn
+ //
+ this.managerinfoDataGridViewTextBoxColumn.DataPropertyName = "managerinfo";
+ this.managerinfoDataGridViewTextBoxColumn.HeaderText = "managerinfo";
+ this.managerinfoDataGridViewTextBoxColumn.Name = "managerinfoDataGridViewTextBoxColumn";
+ //
+ // devinfoDataGridViewTextBoxColumn
+ //
+ this.devinfoDataGridViewTextBoxColumn.DataPropertyName = "devinfo";
+ this.devinfoDataGridViewTextBoxColumn.HeaderText = "devinfo";
+ this.devinfoDataGridViewTextBoxColumn.Name = "devinfoDataGridViewTextBoxColumn";
+ //
+ // usemailDataGridViewCheckBoxColumn
+ //
+ this.usemailDataGridViewCheckBoxColumn.DataPropertyName = "usemail";
+ this.usemailDataGridViewCheckBoxColumn.HeaderText = "usemail";
+ this.usemailDataGridViewCheckBoxColumn.Name = "usemailDataGridViewCheckBoxColumn";
+ //
// fUserGroupDev
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(910, 595);
+ this.ClientSize = new System.Drawing.Size(999, 639);
this.ContextMenuStrip = this.cm1;
- this.Controls.Add(this.fpSpread1);
+ this.Controls.Add(this.dv1);
this.Controls.Add(this.bn);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.Name = "fUserGroupDev";
@@ -385,9 +396,8 @@
this.bn.ResumeLayout(false);
this.bn.PerformLayout();
this.cm1.ResumeLayout(false);
- ((System.ComponentModel.ISupportInitialize)(this.fpSpread1)).EndInit();
- ((System.ComponentModel.ISupportInitialize)(this.fpSpread1_Sheet1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.bsStaff)).EndInit();
+ ((System.ComponentModel.ISupportInitialize)(this.dv1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
@@ -410,7 +420,6 @@
private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator2;
private System.Windows.Forms.ToolStripButton customsBindingNavigatorSaveItem;
private System.Windows.Forms.ContextMenuStrip cm1;
- private FarPoint.Win.Spread.FpSpread fpSpread1;
private System.Windows.Forms.ToolStripSeparator toolStripSeparator1;
private System.Windows.Forms.ToolStripLabel toolStripLabel2;
private System.Windows.Forms.ToolStripTextBox tbFind;
@@ -422,8 +431,17 @@
private dsMSSQLTableAdapters.StaffTableAdapter taStaff;
private DSUser dSUser;
private DSUserTableAdapters.UserGroupTableAdapter ta;
- private FarPoint.Win.Spread.SheetView fpSpread1_Sheet1;
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem1;
private System.Windows.Forms.ToolStripMenuItem 권한설정ToolStripMenuItem;
+ private System.Windows.Forms.DataGridView dv1;
+ private System.Windows.Forms.DataGridViewTextBoxColumn deptDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewTextBoxColumn gcodeDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewTextBoxColumn pathkjDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewTextBoxColumn permissionDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewCheckBoxColumn advpurchaseDataGridViewCheckBoxColumn;
+ private System.Windows.Forms.DataGridViewCheckBoxColumn advkisulDataGridViewCheckBoxColumn;
+ private System.Windows.Forms.DataGridViewTextBoxColumn managerinfoDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewTextBoxColumn devinfoDataGridViewTextBoxColumn;
+ private System.Windows.Forms.DataGridViewCheckBoxColumn usemailDataGridViewCheckBoxColumn;
}
}
\ No newline at end of file
diff --git a/SubProject/FCM0000/User/fUserGroupDev.cs b/SubProject/FCM0000/User/fUserGroupDev.cs
index 88d20aa..629911e 100644
--- a/SubProject/FCM0000/User/fUserGroupDev.cs
+++ b/SubProject/FCM0000/User/fUserGroupDev.cs
@@ -25,7 +25,7 @@ namespace FCM0000
refreshData();
this.dSUser.UserGroup.TableNewRow += Customs_TableNewRow;
}
-
+
void Customs_TableNewRow(object sender, DataTableNewRowEventArgs e)
{
//e.Row["wuid"] = FCOMMON.info.Login.no;
@@ -39,14 +39,15 @@ namespace FCM0000
try
{
this.ta.Fill(this.dSUser.UserGroup);
- FPUtil.ColSizeLoad(ref this.fpSpread1, fn_fpcolsize1);
-
- }catch (Exception ex)
+ dv1.AutoResizeColumns();
+
+ }
+ catch (Exception ex)
{
FCOMMON.Util.MsgE(ex.Message);
}
}
-
+
private void customsBindingNavigatorSaveItem_Click(object sender, EventArgs e)
{
this.Validate();
@@ -56,7 +57,7 @@ namespace FCM0000
{
FCOMMON.Util.MsgI("변경된 내역이 없습니다.");
}
- else FCOMMON.Util.MsgI(string.Format("{0} 건의 자료가 업데이트 되었습니다.",cnt));
+ else FCOMMON.Util.MsgI(string.Format("{0} 건의 자료가 업데이트 되었습니다.", cnt));
}
@@ -67,10 +68,7 @@ namespace FCM0000
private void autoResizeColummsToolStripMenuItem_Click(object sender, EventArgs e)
{
- this.fpSpread1.ActiveSheet.DataAutoSizeColumns = true;
-
- for (int i = 0; i < this.fpSpread1.ActiveSheet.Rows.Count; i++)
- this.fpSpread1.ActiveSheet.SetRowHeight(i, 25);
+ dv1.AutoResizeColumns();
}
private void btFind_Click(object sender, EventArgs e)
@@ -107,31 +105,15 @@ namespace FCM0000
{
if (e.KeyCode == Keys.Enter) btFind.PerformClick();
}
-
- private void autoToolStripMenuItem_Click(object sender, EventArgs e)
- {
- this.fpSpread1.ActiveSheet.DataAutoSizeColumns = true;
-
- for (int i = 0; i < this.fpSpread1.ActiveSheet.Rows.Count; i++)
- this.fpSpread1.ActiveSheet.SetRowHeight(i, 25);
- }
-
- private void resetToolStripMenuItem_Click(object sender, EventArgs e)
- {
- foreach (FarPoint.Win.Spread.Column col in this.fpSpread1.ActiveSheet.Columns)
- {
- col.Width = 100;
- }
- }
-
+
private void saveToolStripMenuItem_Click(object sender, EventArgs e)
{
- FCOMMON.Util.FPColsizeSave(this.fpSpread1, fn_fpcolsize1);
+ //FCOMMON.Util.FPColsizeSave(this.fpSpread1, fn_fpcolsize1);
}
private void loadToolStripMenuItem_Click(object sender, EventArgs e)
{
- FCOMMON.Util.FPColSizeLoad(ref this.fpSpread1, fn_fpcolsize1);
+ //FCOMMON.Util.FPColSizeLoad(ref this.fpSpread1, fn_fpcolsize1);
}
@@ -142,8 +124,8 @@ namespace FCM0000
var dr = drv.Row as DSUser.UserGroupRow;
if (dr.RowState == DataRowState.Added || dr.RowState == DataRowState.Detached || dr.RowState == DataRowState.Deleted) this.bs.RemoveCurrent();
- var dlg =FCOMMON.Util.MsgQ("다음 자료를 삭제하시겠습니까?");
- if(dlg == System.Windows.Forms.DialogResult.Yes)
+ var dlg = FCOMMON.Util.MsgQ("다음 자료를 삭제하시겠습니까?");
+ if (dlg == System.Windows.Forms.DialogResult.Yes)
{
this.bs.RemoveCurrent();
}
@@ -152,7 +134,7 @@ namespace FCM0000
//private int selcectIDX = -1;
private void bs_CurrentChanged(object sender, EventArgs e)
{
-
+
}
private void 권한설정ToolStripMenuItem_Click(object sender, EventArgs e)
@@ -161,13 +143,13 @@ namespace FCM0000
if (drv == null) return;
var dr = drv.Row as DSUser.UserGroupRow;
var f = new fUserGroupPermission(dr.permission);
- if(f.ShowDialog() == System.Windows.Forms.DialogResult.OK)
+ if (f.ShowDialog() == System.Windows.Forms.DialogResult.OK)
{
dr.permission = f.permission;
dr.EndEdit();
}
}
-
+
}
}
diff --git a/SubProject/FCM0000/User/fUserGroupDev.resx b/SubProject/FCM0000/User/fUserGroupDev.resx
index 5488722..ba22aa8 100644
--- a/SubProject/FCM0000/User/fUserGroupDev.resx
+++ b/SubProject/FCM0000/User/fUserGroupDev.resx
@@ -136,7 +136,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAAUpJREFUOE9jGLzg7gL2/7fmcf6/Oofr/8UZvP+hwsSD60CNfx41/v/zsOH/yckC
+ wgAADsIBFShKgAAAAUpJREFUOE9jGLzg7gL2/7fmcf6/Oofr/8UZvP+hwsSD60CNfx41/v/zsOH/yckC
pBtwfjov3ICDPSKkG3B8kiBQc93/Pw+q/u9oFydswKWZPP/PTuX7fxKo8Ui/0P993SJAzeX//94r+r++
Qeb/qhq5/0srFf/PL1X+P6tIFdPAU0B//nlYD9RUC8SV///cKwHivP9/72b+/3sn+f/f23H//92MAOKQ
/5NyNDENONQrDHbu3/ulQI0FQI3ZQI2pQI0J///digZqDPv/70bQ/3/X/f53peliGrCzXeL/lmap/+vA
@@ -148,7 +148,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAASpJREFUOE9jGDygcNbz/00Lnv/PnPj4P1QIA4S3P8Apx5A789n/VUfe/8elKL77
+ wgAADsIBFShKgAAAASpJREFUOE9jGDygcNbz/00Lnv/PnPj4P1QIA4S3P8Apx5A789n/VUfe/8elKL77
wf/ghmu4DciY8vT/wn0fsCqK73n4f+n+///9qy/gNiCh58n/aVveYyiKaL8P1pw56/9/r9ITuA2I7Hr0
v3f1BxRFoa33wJpb1wFt7/z73yX/AG4DApsf/q+b/w6uKLjl7v9Fe///7wBqzpjz879d3c//9hnbcRvg
UXX/f/60NyiK7Ipv/0+f8/u/f9e3/zqF7/5bJKzHbYB96d3/2ZNfYyjSTzn/36ToxX+VrE//jSOX4TbA
@@ -159,7 +159,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAALZJREFUOE9jGDogvP3BfyiTdBDf/eB/cMM18gyI73n4f+n+///9qy+QbkBE+32w
+ wgAADsIBFShKgAAAALZJREFUOE9jGDogvP3BfyiTdBDf/eB/cMM18gyI73n4f+n+///9qy+QbkBE+32w
5sxZ//97lZ4gzYDQ1ntgza3rgLZ3/v3vkn+AeAOCW+7+X7T3//8OoOaMOT//29X9/G+fsZ00F9gV3/6f
Puf3f/+ub/91Ct/9t0hYT3oY6Kec/29S9OK/Stan/8aRy0g3AAQMkk78l037+l83eB55BoCAfurl/xq+
08g3AARUPCZQZsBgBQwMANAUYJgEulBVAAAAAElFTkSuQmCC
@@ -168,7 +168,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAAKNJREFUOE9jGHygcNbz/1AmeSB35rP/Cd33yDckY8rT//P2//6f0HWHPEMSep78
+ wgAADsIBFShKgAAAAKNJREFUOE9jGHygcNbz/1AmeSB35rP/Cd33yDckY8rT//P2//6f0HWHPEMSep78
n73v1//OrX//u5VeJt2QyK5H/6ds+/W/ZOnf/wnT//63yT1LmiGBzQ//t659D9ZsXPLlv3T0tf/GkcuI
N8Sj6v7/krnv4JoVXXpIc4F96d3/gS3PyNMMAhZ5d/7bFFwhTzMIGGbdJl8zCOik3SBf81AEDAwAoH5f
oAc0QjgAAAAASUVORK5CYII=
@@ -177,7 +177,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAASxJREFUOE9jGFygcNbz/1AmBgDJNS14/j9z4mOcahhyZz77n9B9D6sCkNyqI+//
+ wgAADsIBFShKgAAAASxJREFUOE9jGFygcNbz/1AmBgDJNS14/j9z4mOcahhyZz77n9B9D6sCkNyqI+//
h7c/wG1AxpSn/+ft//0/oesOhiKQ3MJ9H/4HN1zDbUBCz5P/s/f9+t+59e9/t9LLKApBctO2vP/vX30B
twGRXY/+T9n263/J0r//E6b//W+TexauGCTXu/rDf6/SE7gNCGx++L917XuwZuOSL/+lo6/9N45cBtYA
kqub/+6/S/4B3AZ4VN3/XzL3HVyzoksPXDFILn/am//2GdtxG2Bfevd/YMszDM0gAJLLnvz6v0XCetwG
@@ -188,7 +188,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAAW9JREFUOE+1kE0ow2Ecx3dV3krt4oJaOSCTvIRkMqSxyITIzCQHDouEdnFwIOVC
+ wgAADsIBFShKgAAAAW9JREFUOE+1kE0ow2Ecx3dV3krt4oJaOSCTvIRkMqSxyITIzCQHDouEdnFwIOVC
DrhIDiQl5UTiNG/z2ppafy1S2gX/uDwfY6i1v7Hie3nqeb7fz+/7/FR/Ilwn0G0Exw4fV5GJlXlEZxXC
rIet9bAQvB5Ymgn2sLYAvSZEux7RUQFzE4qQt4bCXAYjPaHvnDoCkLpsRGMB2JqCTGLIijDlwqQ9bEMV
i9OIytR3EMNWcJ/BWH8A6j8/bOGFxwXNxYEvGbMQ9XnQ1/K78KfY3/VXzkMY0qFGG2H4RoLGQshJQNbG
@@ -200,7 +200,7 @@
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
- wwAADsMBx2+oZAAAAExJREFUOE9joAr49u3bf1IxVCsEgAWC58Dxh/cf4RhZDETHTNiHaQgpBoAwzBCo
+ wgAADsIBFShKgAAAAExJREFUOE9joAr49u3bf1IxVCsEgAWC58Dxh/cf4RhZDETHTNiHaQgpBoAwzBCo
dtINAGGiDUDGyGpoawAxeNSAQWkAORiqnRLAwAAA9EMMU8Daa3MAAAAASUVORK5CYII=
@@ -238,9 +238,6 @@
vmv/Akgg2IMBDgsSdJwcAEICDhoECjDAmQIFBQouXNiwQYPOgqgLBgQAOw==
-
- 551, 17
-
222, 17
diff --git a/SubProject/FPJ0000/JobReport_/rJobReportUser.cs b/SubProject/FPJ0000/JobReport_/rJobReportUser.cs
index 25ce263..5195ee2 100644
--- a/SubProject/FPJ0000/JobReport_/rJobReportUser.cs
+++ b/SubProject/FPJ0000/JobReport_/rJobReportUser.cs
@@ -1,5 +1,7 @@
using FarPoint.Win;
using FCOMMON;
+using GrapeCity.Win.Spread.InputMan.CellType;
+using NetOffice.Attributes;
using System;
using System.Collections.Generic;
using System.ComponentModel;
@@ -243,14 +245,30 @@ namespace FPJ0000.JobReport_
col = 2;
var orTypeName = baseData.Where(t => t.svalue != "휴가" && string.IsNullOrEmpty(t.svalue) == false).OrderBy(t => t.svalue).GroupBy(t => t.svalue);
this.fpSpread1.ActiveSheetIndex = 0;
+ var maxcol = 6;
+ bool useOther = false;
foreach (var item in orTypeName)
{
var dr = item.FirstOrDefault();
- this.fpSpread1.Sheets[0].Cells[6, col++].Value = dr.svalue;
- //col += 1;
+
+ if (col == maxcol + 1) //엑셀파일 특성상 5개가 최고이다
+ {
+ this.fpSpread1.Sheets[0].Cells[6, col - 1].Value = "[ Other ]";
+ useOther = true;
+ }
+ else if (col > maxcol + 1)
+ {
+ useOther = true;
+ }
+ else
+ {
+ this.fpSpread1.Sheets[0].Cells[6, col].Value = dr.svalue;
+ }
+ col++;
}
- for (int i = col; i <= 6; i++)
+ //항목이 6개 미만일 경우 제목을 * 로 변경해준다
+ for (int i = col; i <= maxcol; i++)
this.fpSpread1.Sheets[0].Cells[6, i].Value = "*";
System.Globalization.CultureInfo cultureInfo = new System.Globalization.CultureInfo("ko-KR", false);
@@ -272,75 +290,84 @@ namespace FPJ0000.JobReport_
foreach (var prcitem in prclist)
{
this.progressBar2.Value += 1;
- var item = baseData.Where(t => t.type == prcitem.memo); //해당 프로세스에 해당하는 아이템을 가져온다
- //}
- if (prcitem.memo == null) prcitem.memo = string.Empty;
- if (prcitem.memo.StartsWith("ASM Feeder Center"))
- Console.WriteLine("sdf");
+ var item = baseData.Where(t => t.type.Replace(" ","") == prcitem.memo.Replace(" ","")); //해당 프로세스에 해당하는 아이템을 가져온다
- //foreach (var item in orProcess)
- //{
- var processName = prcitem.memo; // item.FirstOrDefault().process;
+ //프로세스 이름 확인
+ if (prcitem.memo == null) prcitem.memo = string.Empty;
+ var processName = prcitem.memo.Trim();
this.fpSpread1.Sheets[0].Cells[row, 1].Value = processName;
+ if(processName== "Documentation (문서작업)")
+ {
+
+ }
+
//2번부터는 데이터를 넣어야 한다
double sumOt = 0.0;
- //double holytime = 0.0;
- int coldata = 2;
- for (int i = 2; i <= 6; i++)
+ var sumvalue_hrs = 0.0;
+ var sumvalue_ot = 0.0;
+
+ for (int i = 2; i <= (useOther ? maxcol - 1 : maxcol); i++) //외부엑셀을 쓰다보니 열갯수가 5개로 제한되어있다.
{
- if (item.Any() == false)
+ if (item.Any() == false) //자료가없다면 0으로 채운다
{
- //자료가없다면 0으로 채운다
- fpSpread1.Sheets[0].Cells[row, coldata].Value = null;
+ fpSpread1.Sheets[0].Cells[row, i].Value = null;
}
else
{
- var colData = fpSpread1.Sheets[0].Cells[6, i].Value;
- var colName = string.Empty;// fpSpread1.Sheets[0].Cells[6, i].Value.ToString();
- if (colData != null) colName = colData.ToString();
+ var colData = fpSpread1.Sheets[0].Cells[6, i].Value; //해당 열의 제목을 취함
+ var colName = colData?.ToString() ?? string.Empty;// string.Empty;// fpSpread1.Sheets[0].Cells[6, i].Value.ToString();
//이 이름에 해당하는 데이터의 시간을 가져온다
double ot = 0.0;
double hrs = 0.0;
- if (colName != "*" && String.IsNullOrEmpty(colName) == false)
+ if (colName != "*" && colName.isEmpty() == false)
{
- //double holytime = 0.0;
- var timeList = item.Where(t => t.svalue == colName);
+ //해당 이름에 해당하는 데이트 취합
+ var timeList = item.Where(t => t.svalue.Replace(" ","") == colName.Replace(" ",""));
if (timeList != null)
{
hrs = (double)timeList.Sum(t => t.hrs);
ot = (double)timeList.Sum(t => t.ot);
sumOt += ot;
+ sumvalue_hrs += hrs;
+ sumvalue_ot += ot;
}
}
- if (ot + hrs == 0.0) fpSpread1.Sheets[0].Cells[row, coldata].Value = null;
- else fpSpread1.Sheets[0].Cells[row, coldata].Value = ot + hrs; //없음으로한다
+ if (ot + hrs == 0.0) fpSpread1.Sheets[0].Cells[row, i].Value = null; //값이 없는 경우는 nul 처리
+ else fpSpread1.Sheets[0].Cells[row, i].Value = ot + hrs;
}
-
-
- coldata += 1;
}
+ //other 칸이 활성화되었다면 총량에서 뺴야한다 (lee jong myoung)
+ if (useOther)
+ {
+ var tot_hr = item.Sum(t => t.hrs);
+ var tot_ot = item.Sum(t => t.ot);
+ var othervalue = (tot_hr + tot_ot) - (sumvalue_hrs + sumvalue_ot); //total - displayvalue
+ if (othervalue == 0.0) fpSpread1.Sheets[0].Cells[row, maxcol].Value = null; //값이 없는 경우는 nul 처리
+ else fpSpread1.Sheets[0].Cells[row, maxcol].Value = othervalue;
+ }
+ sumOt = item.Sum(t => t.ot);
fpSpread1.Sheets[0].Cells[row, 7].CellType = numberCellType1;
fpSpread1.Sheets[0].Cells[row, 7].ParseFormatString = "N1";
fpSpread1.Sheets[0].Cells[row, 8].CellType = numberCellType1;
fpSpread1.Sheets[0].Cells[row, 8].ParseFormatString = "N1";
-
-
- fpSpread1.Sheets[0].Cells[row, 7].Formula = string.Format("SUM(C{0}:G{0})+K{0}+J{0}", row + 1);
+ fpSpread1.Sheets[0].Cells[row, 7].Formula = string.Format("SUM(C{0}:G{0})+K{0}", row + 1);
fpSpread1.Sheets[0].Cells[row, 8].Formula = string.Format("H{0}/$I$4", row + 1);
- //H8 /$I$4
+
if (sumOt == 0.0) fpSpread1.Sheets[0].Cells[row, 9].Value = null; //OT합계
else fpSpread1.Sheets[0].Cells[row, 9].Value = sumOt; //OT합계
-
-
// process 의 휴가시간을 다시 계산한다.
- var 휴가데이터 = baseData.Where(t => t.process == processName && t.svalue == "휴가");
+ if(processName == "휴가")
+ {
+
+ }
+ var 휴가데이터 = baseData.Where(t => t.process.Replace(" ","") == processName.Replace(" ","") && t.svalue.Replace(" ", "") == "휴가");
if (휴가데이터 == null || 휴가데이터.Count() < 1)
{
fpSpread1.Sheets[0].Cells[row, 10].Value = null;// 0.0; //휴가시간
@@ -354,11 +381,12 @@ namespace FPJ0000.JobReport_
fpSpread1.Sheets[0].Cells[row, i].HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Center;
fpSpread1.Sheets[0].Cells[row, i].VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Center;
}
-
-
row += 1;
}
+ var total_value = baseData.Sum(t => t.hrs) + baseData.Sum(t => t.ot);
+
+
//합계데이터
fpSpread1.Sheets[0].Cells[row, 1].Value = "합계";
fpSpread1.Sheets[0].Cells[row, 1].BackColor = Color.LightGray;
@@ -388,110 +416,6 @@ namespace FPJ0000.JobReport_
this.fpSpread1.Sheets[0].RowCount = row + 1;
-
-
-
- // this.ta.Fill(this.dsReport.JobReportDay, tbMon.Text, FCOMMON.info.Login.gcode);
- // //this.reportViewer1.SetDisplayMode(Microsoft.Reporting.WinForms.DisplayMode.PrintLayout);
- // //this.reportViewer1.ZoomMode = Microsoft.Reporting.WinForms.ZoomMode.PageWidth;
- // //this.reportViewer1.RefreshReport();
-
- // //그리드뷰 생성
- // this.dataGridView1.Rows.Clear();
- // this.dataGridView1.Columns.Clear();
-
- // var Process = tbProcess.Text.Trim();
- // if (Process == "%" || tbProcess.SelectedIndex == 0) Process = "";
-
- // var wekklist = new string[] { "일","월","화","수","목","금","토" };
-
- // //날짜에 해당하는 열을 먼저 생성한다
- // dataGridView1.Columns.Add("dvcu_damdang", "사원명");
- //// dataGridView1.Columns.Add("dvcu_process", "공정");
- // var daylist = dsReport.JobReportDay.OrderBy(t=>t.pdate).GroupBy(t => t.pdate);
- // foreach (var dayitem in daylist)
- // {
- // var dtValue = DateTime.Parse(dayitem.Key);
- // if(dtValue.DayOfWeek == DayOfWeek.Saturday || dtValue.DayOfWeek == DayOfWeek.Sunday)
- // {
- // var week = wekklist[(int)dtValue.DayOfWeek];
- // this.dataGridView1.Columns.Add("dvcu_pdate", dayitem.Key.Substring(8, 2) + "(" + week.ToString() + ")");
- // }
- // else
- // {
- // this.dataGridView1.Columns.Add("dvcu_pdate", dayitem.Key.Substring(8, 2) );
- // }
-
- // this.dataGridView1.Columns[this.dataGridView1.Columns.Count -1].DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
- // }
- // dataGridView1.Columns.Add("dvcu_sum", "합계");
- // this.dataGridView1.Columns[this.dataGridView1.Columns.Count - 1].DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
-
-
- // foreach (var item in dsReport.JobReportDay.Where(t=>t.processs.Contains(Process)).OrderBy(t => t.uname + t.uid).GroupBy(t => t.uname))
- // {
- // //사용자별로 데이터를 가져온다.
- // var username = item.Key;
- // var userid = item.FirstOrDefault().uid;
- // List rowdata = new List();
- // rowdata.Add(username);
- // // rowdata.Add(item.FirstOrDefault().processs);
-
- // //이 사용자의 데이터를 날짜별로 정렬해서 가져온다.
- // var sum = 0.0;
- // var sumOT = 0.0;
- // for (int i = 1; i < this.dataGridView1.Columns.Count-1; i++)
- // {
- // var col = this.dataGridView1.Columns[i];
- // var dayStr = col.HeaderText.Substring(0, 2);
- // var daydata = dsReport.JobReportDay.Where(t => t.uid == userid && t.pdate.EndsWith(dayStr)).FirstOrDefault();
- // if (daydata != null)
- // {
- // sum += daydata.hrs;
- // sumOT += daydata.ot;
- // rowdata.Add((daydata.hrs.ToString() + "+" + daydata.ot.ToString()));
- // }
- // else rowdata.Add("--");
- // }
- // rowdata.Add(sum.ToString() + "+" + sumOT.ToString());
- // this.dataGridView1.Rows.Add(rowdata.ToArray());
- // }
- // foreach(DataGridViewRow dvrow in this.dataGridView1.Rows)
- // {
- // for(int i = 1;i < this.dataGridView1.ColumnCount-1;i++)
- // {
- // var cellvalue = "--";
- // if(dvrow.Cells[i].Value != null) cellvalue= dvrow.Cells[i].Value.ToString();
- // if (cellvalue == "--") dvrow.Cells[i].Style.ForeColor = Color.Gray;
- // else
- // {
- // var datasplbu = cellvalue.Split('+');
- // double hrs;
- // double ot;
- // if (double.TryParse(datasplbu[1], out ot) == false) ot = 0;
-
- // if(double.TryParse(datasplbu[0],out hrs))
- // {
- // if (hrs > 8.0) dvrow.Cells[i].Style.ForeColor = Color.Blue;
- // else if (hrs < 8.0) dvrow.Cells[i].Style.ForeColor = Color.Red;
- // else
- // {
- // if (ot == 0)
- // dvrow.Cells[i].Style.ForeColor = Color.Black;
- // else
- // dvrow.Cells[i].Style.ForeColor = Color.Magenta;
- // }
- // }
- // else
- // {
- // FCOMMON.Util.MsgE("숫자변경실패 " + cellvalue);
- // dvrow.Cells[i].Style.ForeColor = Color.Red;
- // }
- // }
- // }
-
- // }
- // this.dataGridView1.AutoResizeColumns();
}
private void button1_Click(object sender, EventArgs e)
{