=====* ISBN 조회 *=====

Yes24 - 가격 검색 추가.
DateTime 버그 수정.
검색시 몇개가 검색됬는지 표출.

=====* unimarc *=====
- 목록등록 -
머리글에 맞춰 숫자 입력기능 추가

- 목록조회 -
거래처 엔터시 명단이 출력되고 그 상태에서 엔터 입력 시 해당 데이터 선택으로 간주. 데이터 조회창으로 이관.

- 목록집계 -
필터링 테스트 코드 삭제
엔터 입력시 검색기능 추가
납품처명 필터링 추가

- 주문관리 -
주문할 때 선택 내용 엑셀로 임시저장 추가 + 양식수정, 엑셀 내용 수정.
임시저장된 파일을 미리 설정된 거래처 주문방법에 따라 팩스/메일로 나뉘어져 보내게 됨.
팩스시 FTP업로드, 바로빌 FAX 전송, 전송결과와 주문수량 주문일자 등 자체 DB에 저장됨.
전송결과를 알아볼수있는 창도 리뉴얼.
This commit is contained in:
SeungHo Yang
2021-07-09 16:56:13 +09:00
parent f860054b7f
commit a93843bf5f
48 changed files with 3930 additions and 377 deletions

3
.gitignore vendored
View File

@@ -13,4 +13,5 @@ Skill.cs
## 폴더 무시
unimarc/Factory_Client/
ISBN_Client/
ISBN_Client/
Test_Project/

View File

@@ -1,62 +0,0 @@

namespace Test_Project
{
partial class Form1
{
/// <summary>
/// 필수 디자이너 변수입니다.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 사용 중인 모든 리소스를 정리합니다.
/// </summary>
/// <param name="disposing">관리되는 리소스를 삭제해야 하면 true이고, 그렇지 않으면 false입니다.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form
/// <summary>
/// 디자이너 지원에 필요한 메서드입니다.
/// 이 메서드의 내용을 코드 편집기로 수정하지 마세요.
/// </summary>
private void InitializeComponent()
{
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
this.SuspendLayout();
//
// richTextBox1
//
this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox1.Location = new System.Drawing.Point(0, 0);
this.richTextBox1.Name = "richTextBox1";
this.richTextBox1.Size = new System.Drawing.Size(1056, 450);
this.richTextBox1.TabIndex = 0;
this.richTextBox1.Text = "";
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1056, 450);
this.Controls.Add(this.richTextBox1);
this.Name = "Form1";
this.Text = "Form1";
this.Load += new System.EventHandler(this.Form1_Load);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.RichTextBox richTextBox1;
}
}

View File

@@ -1,65 +0,0 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Management;
namespace Test_Project
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
var usbDevices = GetUSBDevices();
foreach(var usbDevice in usbDevices)
{
string msg = string.Format("Device ID: {0}, PNP Device ID: {1}, Description: {2}\n",
usbDevice.DeviceID, usbDevice.PnpDeviceID, usbDevice.Description);
richTextBox1.Text += msg;
}
}
static List<USBDeviceInfo> GetUSBDevices()
{
List<USBDeviceInfo> devices = new List<USBDeviceInfo>();
ManagementObjectCollection collection;
using (var searcher = new ManagementObjectSearcher(@"Select * From Win32_USBHub"))
collection = searcher.Get();
foreach(var device in collection)
{
devices.Add(new USBDeviceInfo(
(string)device.GetPropertyValue("DeviceID"),
(string)device.GetPropertyValue("PNPDeviceID"),
(string)device.GetPropertyValue("Description")
));
}
collection.Dispose();
return devices;
}
}
class USBDeviceInfo
{
public USBDeviceInfo(string deviceID, string pnpDeviceID, string description)
{
this.DeviceID = deviceID;
this.PnpDeviceID = pnpDeviceID;
this.Description = description;
}
public string DeviceID { get; private set; }
public string PnpDeviceID { get; private set; }
public string Description { get; private set; }
}
}

View File

@@ -16,7 +16,7 @@ namespace Test_Project
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
Application.Run(new Test());
}
}
}

View File

@@ -1 +1 @@
fdefe9bfdc3ac6442df724e1b8b8d8f6ce92a914
aed5a697ba539078456cd1085bbdd23ab52c0666

View File

@@ -2,9 +2,9 @@ C:\Users\Administrator\Desktop\unimarc\Test_Project\bin\Debug\Test_Project.exe.c
C:\Users\Administrator\Desktop\unimarc\Test_Project\bin\Debug\Test_Project.exe
C:\Users\Administrator\Desktop\unimarc\Test_Project\bin\Debug\Test_Project.pdb
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.csproj.AssemblyReference.cache
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.Form1.resources
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.Properties.Resources.resources
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.csproj.GenerateResource.cache
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.csproj.CoreCompileInputs.cache
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.exe
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.pdb
C:\Users\Administrator\Desktop\unimarc\Test_Project\obj\Debug\Test_Project.Test.resources

Binary file not shown.

Binary file not shown.

View File

@@ -15,26 +15,26 @@
{
"Entry"
{
"MsmKey" = "8:_753344FE1F09410C9D0F442B1279C21F"
"MsmKey" = "8:_C0D91E30A1E44E66A4EEA4BF161D7237"
"OwnerKey" = "8:_UNDEFINED"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_E78196A0B332402DB05AB7FEB1E4F799"
"MsmKey" = "8:_C9E9660E517B4B2EBF42BDAD9C6DB38D"
"OwnerKey" = "8:_UNDEFINED"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_F0CD886B86254771BEA61BF625DE2CE1"
"MsmKey" = "8:_EC6E313CD6974E298DD274D14C737326"
"OwnerKey" = "8:_UNDEFINED"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_UNDEFINED"
"OwnerKey" = "8:_753344FE1F09410C9D0F442B1279C21F"
"OwnerKey" = "8:_C9E9660E517B4B2EBF42BDAD9C6DB38D"
"MsmSig" = "8:_UNDEFINED"
}
}
@@ -132,9 +132,9 @@
}
"File"
{
"{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_E78196A0B332402DB05AB7FEB1E4F799"
"{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_C0D91E30A1E44E66A4EEA4BF161D7237"
{
"SourcePath" = "8:C:\\Update\\Update.inf"
"SourcePath" = "8:..\\UniMarc\\Update.inf"
"TargetName" = "8:Update.inf"
"Tag" = "8:"
"Folder" = "8:_5AFD85B9101B47DB9537A694229E7941"
@@ -152,10 +152,10 @@
"IsDependency" = "11:FALSE"
"IsolateTo" = "8:"
}
"{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_F0CD886B86254771BEA61BF625DE2CE1"
"{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_EC6E313CD6974E298DD274D14C737326"
{
"SourcePath" = "8:..\\..\\..\\..\\Downloads\\UniMarcIcon.ico"
"TargetName" = "8:UniMarcIcon.ico"
"SourcePath" = "8:..\\..\\..\\..\\Downloads\\3700474-address-agenda-book-bookmark-business-interface-notebook_108749.ico"
"TargetName" = "8:3700474-address-agenda-book-bookmark-business-interface-notebook_108749.ico"
"Tag" = "8:"
"Folder" = "8:_5AFD85B9101B47DB9537A694229E7941"
"Condition" = "8:"
@@ -349,7 +349,7 @@
}
"Shortcut"
{
"{970C0BB2-C7D0-45D7-ABFA-7EC378858BC0}:_1D92A7BDFE934874B5946396343F58EA"
"{970C0BB2-C7D0-45D7-ABFA-7EC378858BC0}:_4E728D6345A04482BB3C40FF8A5FC5DD"
{
"Name" = "8:UniMarc"
"Arguments" = "8:"
@@ -357,24 +357,24 @@
"ShowCmd" = "3:1"
"IconIndex" = "3:0"
"Transitive" = "11:FALSE"
"Target" = "8:_753344FE1F09410C9D0F442B1279C21F"
"Folder" = "8:_C702D9CCA84A4CB990260A30151CE064"
"WorkingFolder" = "8:_5AFD85B9101B47DB9537A694229E7941"
"Icon" = "8:_F0CD886B86254771BEA61BF625DE2CE1"
"Feature" = "8:"
}
"{970C0BB2-C7D0-45D7-ABFA-7EC378858BC0}:_C05FDEA084D04D1A859017F1814945E5"
{
"Name" = "8:UniMarc"
"Arguments" = "8:"
"Description" = "8:"
"ShowCmd" = "3:1"
"IconIndex" = "3:0"
"Transitive" = "11:FALSE"
"Target" = "8:_753344FE1F09410C9D0F442B1279C21F"
"Target" = "8:_C9E9660E517B4B2EBF42BDAD9C6DB38D"
"Folder" = "8:_74D25C29FA384AD0AAE9D733594F6B6A"
"WorkingFolder" = "8:_5AFD85B9101B47DB9537A694229E7941"
"Icon" = "8:_F0CD886B86254771BEA61BF625DE2CE1"
"Icon" = "8:_EC6E313CD6974E298DD274D14C737326"
"Feature" = "8:"
}
"{970C0BB2-C7D0-45D7-ABFA-7EC378858BC0}:_8596342268F74CD084556BCA65072910"
{
"Name" = "8:UniMarc"
"Arguments" = "8:"
"Description" = "8:"
"ShowCmd" = "3:1"
"IconIndex" = "3:0"
"Transitive" = "11:FALSE"
"Target" = "8:_C9E9660E517B4B2EBF42BDAD9C6DB38D"
"Folder" = "8:_C702D9CCA84A4CB990260A30151CE064"
"WorkingFolder" = "8:_5AFD85B9101B47DB9537A694229E7941"
"Icon" = "8:_EC6E313CD6974E298DD274D14C737326"
"Feature" = "8:"
}
}
@@ -776,7 +776,7 @@
}
"ProjectOutput"
{
"{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_753344FE1F09410C9D0F442B1279C21F"
"{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_C9E9660E517B4B2EBF42BDAD9C6DB38D"
{
"SourcePath" = "8:..\\Factory_Client\\obj\\Debug\\Factory_Client.exe"
"TargetName" = "8:"

View File

@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup>
<system.serviceModel>
<bindings>
@@ -10,7 +9,7 @@
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://testws.baroservice.com/FAX.asmx" binding="basicHttpBinding" bindingConfiguration="BaroService_FAXSoap" contract="BaroService_API.BaroService_FAXSoap" name="BaroService_FAXSoap"/>
<endpoint address="http://testws.baroservice.com/FAX.asmx" binding="basicHttpBinding" bindingConfiguration="BaroService_FAXSoap" contract="BaroService_API.BaroService_FAXSoap" name="BaroService_FAXSoap" />
</client>
</system.serviceModel>
<runtime>

View File

@@ -119,9 +119,10 @@
this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.toolStrip1 = new System.Windows.Forms.ToolStrip();
this.toolStripLabel2 = new System.Windows.Forms.ToolStripLabel();
this.toolStripLabel1 = new System.Windows.Forms.ToolStripLabel();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.toolStripLabel2 = new System.Windows.Forms.ToolStripLabel();
this.ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.menuStrip1.SuspendLayout();
this.panel1.SuspendLayout();
this.toolStrip1.SuspendLayout();
@@ -225,49 +226,49 @@
// 물품등록ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "물품등록ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "물품등록";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 목록등록편의ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "목록등록편의ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "목록조회";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 목록집계ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "목록집계ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "목록집계";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 주문입력ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "주문입력ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "주문입력";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 매입ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "매입ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "입고작업";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 재고입력및조회ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "재고입력및조회ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "재고입력 및 조회";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 반품처리ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "반품처리ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(166, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "반품처리";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
@@ -277,7 +278,8 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem,
this.ToolStripMenuItem,
this.ToolStripMenuItem});
this.ToolStripMenuItem,
this.ToolStripMenuItem});
this.ToolStripMenuItem.Name = "회계ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(59, 20);
this.ToolStripMenuItem.Text = "회계(&A)";
@@ -285,14 +287,14 @@
// 송금내역조회ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "송금내역조회ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(154, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "송금 내역 조회";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 송금등록ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "송금등록ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(154, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "송금 등록";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
@@ -303,7 +305,7 @@
this.ToolStripMenuItem1,
this.ToolStripMenuItem});
this.ToolStripMenuItem.Name = "매입장부ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(154, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "매입";
//
// 매입집계ToolStripMenuItem
@@ -336,7 +338,7 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem1});
this.ToolStripMenuItem.Name = "매출입력ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(154, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "매출";
//
// 매출입력ToolStripMenuItem1
@@ -389,34 +391,34 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem});
this.ToolStripMenuItem.Name = "설정ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "설정";
//
// 단축키설정ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "단축키설정ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(138, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "단축키";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 매크로문구설정ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "매크로문구설정ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(138, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "매크로 문구";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 불용어ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "불용어ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(138, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "불용어";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 작업지시서ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "작업지시서ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(138, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "작업지시서";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
@@ -428,34 +430,34 @@
this.ToolStripMenuItem,
this.iSBN조회ToolStripMenuItem});
this.ToolStripMenuItem.Name = "마크작업ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "마크 작업";
//
// 마크목록ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "마크목록ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "마크 목록";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 소장자료검색ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "소장자료검색ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "소장자료검색";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 엑셀작성ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "엑셀작성ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "엑셀 작성";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// iSBN조회ToolStripMenuItem
//
this.iSBN조회ToolStripMenuItem.Name = "iSBN조회ToolStripMenuItem";
this.iSBN조회ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.iSBN조회ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.iSBN조회ToolStripMenuItem.Text = "ISBN 조회";
this.iSBN조회ToolStripMenuItem.Click += new System.EventHandler(this.iSBN조회ToolStripMenuItem_Click);
//
@@ -465,20 +467,20 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem});
this.ToolStripMenuItem.Name = "반입및반출ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "반입 및 반출";
//
// 반입ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "반입ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(98, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "반입";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 반출ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "반출ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(98, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "반출";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
@@ -488,20 +490,20 @@
this.ToolStripMenuItem1,
this.dLS복본조사ToolStripMenuItem});
this.ToolStripMenuItem.Name = "복본조사ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "복본 조사";
//
// 복본조사ToolStripMenuItem1
//
this.ToolStripMenuItem1.Name = "복본조사ToolStripMenuItem1";
this.ToolStripMenuItem1.Size = new System.Drawing.Size(148, 22);
this.ToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem1.Text = "복본조사";
this.ToolStripMenuItem1.Click += new System.EventHandler(this.ToolStripMenuItem1_Click);
//
// dLS복본조사ToolStripMenuItem
//
this.dLS복본조사ToolStripMenuItem.Name = "dLS복본조사ToolStripMenuItem";
this.dLS복본조사ToolStripMenuItem.Size = new System.Drawing.Size(148, 22);
this.dLS복본조사ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.dLS복본조사ToolStripMenuItem.Text = "DLS 복본조사";
this.dLS복본조사ToolStripMenuItem.Click += new System.EventHandler(this.dLS복본조사ToolStripMenuItem_Click);
//
@@ -513,34 +515,34 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem});
this.ToolStripMenuItem.Name = "부가기능ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "부가기능";
//
// 마크수집ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "마크수집ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(122, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "마크수집";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 전집관리ToolStripMenuItem1
//
this.ToolStripMenuItem1.Name = "전집관리ToolStripMenuItem1";
this.ToolStripMenuItem1.Size = new System.Drawing.Size(122, 22);
this.ToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem1.Text = "전집관리";
this.ToolStripMenuItem1.Click += new System.EventHandler(this.ToolStripMenuItem1_Click);
//
// 검수ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "검수ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(122, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "검수";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 저자기호ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "저자기호ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(122, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "저자기호";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
@@ -550,7 +552,7 @@
this.dLS조회ToolStripMenuItem,
this.dLS입력ToolStripMenuItem});
this.dLSToolStripMenuItem.Name = "dLSToolStripMenuItem";
this.dLSToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.dLSToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.dLSToolStripMenuItem.Text = "DLS";
//
// dLS조회ToolStripMenuItem
@@ -574,7 +576,7 @@
this.ToolStripMenuItem,
this.ToolStripMenuItem1});
this.ToolStripMenuItem.Name = "기타ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "기타";
//
// 서류작성ToolStripMenuItem
@@ -890,17 +892,24 @@
this.toolStrip1.TabIndex = 4;
this.toolStrip1.Text = "toolStrip1";
//
// toolStripLabel2
//
this.toolStripLabel2.Name = "toolStripLabel2";
this.toolStripLabel2.Size = new System.Drawing.Size(43, 22);
this.toolStripLabel2.Text = "회사명";
//
// toolStripLabel1
//
this.toolStripLabel1.Name = "toolStripLabel1";
this.toolStripLabel1.Size = new System.Drawing.Size(43, 22);
this.toolStripLabel1.Text = "이용자";
//
// toolStripLabel2
// 파트타임관리ToolStripMenuItem
//
this.toolStripLabel2.Name = "toolStripLabel2";
this.toolStripLabel2.Size = new System.Drawing.Size(43, 22);
this.toolStripLabel2.Text = "회사명";
this.ToolStripMenuItem.Name = "파트타임관리ToolStripMenuItem";
this.ToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.ToolStripMenuItem.Text = "파트타임 관리";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// Main
//
@@ -1022,5 +1031,6 @@
private System.Windows.Forms.ToolStripMenuItem toolStripMenuItem1;
private System.Windows.Forms.ToolStripMenuItem ToolStripMenuItem;
public System.Windows.Forms.ToolStripLabel toolStripLabel2;
private System.Windows.Forms.ToolStripMenuItem ToolStripMenuItem;
}
}

View File

@@ -21,6 +21,7 @@ using WindowsFormsApp1.Work_log;
using WindowsFormsApp1.;
using WindowsFormsApp1.;
using WindowsFormsApp1.;
using UniMarc.;
namespace WindowsFormsApp1
{
@@ -328,8 +329,24 @@ namespace WindowsFormsApp1
Sales_Not_Pay Acc_sales_Not_Pay;
Sales_Book Acc_sales_book;
Bill_manage Acc_bill_Manage;
Part_time Acc_part_time;
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{
if (Acc_part_time != null)
{
Acc_part_time.Focus();
}
else
{
Acc_part_time = new Part_time(this);
Acc_part_time.MdiParent = this;
// Acc_part_time.WindowState = FormWindowState.Maximized;
Acc_part_time.FormClosed += (o, ea) => Acc_part_time = null;
Acc_part_time.Show();
}
}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{
if (Acc_remit_Reg2 != null)
@@ -1118,5 +1135,6 @@ namespace WindowsFormsApp1
}
}
#endregion
}
}

View File

@@ -193,6 +193,12 @@
<Compile Include="회계\Bill_manage.Designer.cs">
<DependentUpon>Bill_manage.cs</DependentUpon>
</Compile>
<Compile Include="회계\Part_time.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="회계\Part_time.Designer.cs">
<DependentUpon>Part_time.cs</DependentUpon>
</Compile>
<Compile Include="회계\Purchase_Book.cs">
<SubType>Form</SubType>
</Compile>
@@ -666,6 +672,9 @@
<EmbeddedResource Include="회계\Bill_manage.resx">
<DependentUpon>Bill_manage.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="회계\Part_time.resx">
<DependentUpon>Part_time.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="회계\Purchase_Aggregation.resx">
<DependentUpon>Purchase_Aggregation.cs</DependentUpon>
</EmbeddedResource>

View File

@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/></startup>
<system.serviceModel>
<bindings>
@@ -10,7 +9,7 @@
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://testws.baroservice.com/FAX.asmx" binding="basicHttpBinding" bindingConfiguration="BaroService_FAXSoap" contract="BaroService_API.BaroService_FAXSoap" name="BaroService_FAXSoap"/>
<endpoint address="http://testws.baroservice.com/FAX.asmx" binding="basicHttpBinding" bindingConfiguration="BaroService_FAXSoap" contract="BaroService_API.BaroService_FAXSoap" name="BaroService_FAXSoap" />
</client>
</system.serviceModel>
<runtime>

View File

@@ -1 +1 @@
5a3001620e15fcaa616989d7d1f184f6088a5007
d2731517ce60a3dc8b8c6b18b3ba868b48ad75db

View File

@@ -113,5 +113,6 @@ C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.pdb
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.마크.Marc_memo.resources
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.마크.Zoom_Picture.resources
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.마크.Mac_Preview.resources
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.csproj.AssemblyReference.cache
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.마크.Check_ISBN_Yes24.resources
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.csproj.AssemblyReference.cache
C:\Users\Administrator\Desktop\unimarc\unimarc\UniMarc\obj\Debug\UniMarc.회계.Part_time.resources

View File

@@ -134,7 +134,7 @@ namespace WindowsFormsApp1.Delivery
if (chk_Save_DB() == -1) { MessageBox.Show("작업 대상을 선택해 주세요."); return; }
if (db.DB_Select_Search("name", "User_Data", "name", tb_UserName.Text) == "")
{ MessageBox.Show("담당자를 확인해주세요."); return; }
if (db.DB_Search("Obj_List", "list_name", "[" + tb_clt1.Text + "]" + tb_dvy1.Text, "comp_num", comp_idx) != "")
if (db.DB_Search("Obj_List", "list_name", "[" + tb_dvy1.Text + "]" + tb_clt1.Text, "comp_num", comp_idx) != "")
{ MessageBox.Show("DB의 납품목록과 중복됩니다."); return; }
bool MsgOk = false;
int Marc_ton = chk_Save_DB();
@@ -189,7 +189,7 @@ namespace WindowsFormsApp1.Delivery
}
data[0] = start_date.Value.ToString().Substring(0,10);
if (end_date.Checked == true) { data[1] = end_date.Value.ToString().Substring(0, 10); }
data[2] = "[" + tb_clt1.Text + "]" + tb_dvy1.Text;
data[2] = "[" + tb_dvy1.Text + "]" + tb_clt1.Text;
data[3] = tb_clt1.Text;
data[4] = tb_dvy1.Text;
data[5] = tb_UserName.Text;
@@ -375,25 +375,27 @@ namespace WindowsFormsApp1.Delivery
string[] DB_col_name = { "compidx", "list_name", "header", "num", "book_name",
"author", "book_comp", "count", "pay", "total",
"etc", "isbn", "order", "date" };
string[] setData = { comp_idx, "[" + tb_clt1.Text + "]" + tb_dvy1.Text, "", "", "",
string[] setData = { comp_idx, "[" + tb_dvy1.Text + "]" + tb_clt1.Text, "", "", "",
"", "", "", "", "",
"", "", "", start_date.Value.ToString().Substring(0,10) };
for(int a = 0; a < dataGridView1.Rows.Count; a++)
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
if (dataGridView1.Rows[a].Cells[2].Value == null ||
if (dataGridView1.Rows[a].Cells[2].Value == null ||
dataGridView1.Rows[a].Cells[2].Value.ToString() == "") { break; }
for(int ea = 0; ea < 12; ea++)
for (int ea = 0; ea < 12; ea++)
{
if (ea == 11) { break; }
if (dataGridView1.Rows[a].Cells[ea].Value == null)
{
dataGridView1.Rows[a].Cells[ea].Value = "";
}
if (dataGridView1.Columns[ea].Name == "unit" || dataGridView1.Columns[ea].Name == "total") {
if (dataGridView1.Columns[ea].Name == "unit" || dataGridView1.Columns[ea].Name == "total")
{
setData[ea + 2] = dataGridView1.Rows[a].Cells[ea].Value.ToString().Replace(",", "");
}
else {
else
{
setData[ea + 2] = dataGridView1.Rows[a].Cells[ea].Value.ToString();
}
}

View File

@@ -46,7 +46,7 @@ namespace WindowsFormsApp1.Delivery
string[] years = {"2009", "2010", "2011", "2012", "2013",
"2014", "2015", "2016", "2017", "2018",
"2019", "2020"};
"2019", "2020", "2021"};
combo_year.Items.AddRange(years);
combo_year.SelectedIndex = 11;
combo_year.Visible = false;
@@ -97,9 +97,10 @@ namespace WindowsFormsApp1.Delivery
{
dataGridView1.Rows.Clear();
string[] db_data = tmp.Split('|');
string[] grid = {"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "", "" };
string[] grid = {
"", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "", "" };
for (int a = 0; a < db_data.Length; a++)
{
if (a % 14 == 0) { grid[0] = db_data[a]; }
@@ -112,10 +113,8 @@ namespace WindowsFormsApp1.Delivery
else { grid[1] = db_data[a].Substring(0, 10); }
grid[1] = db_data[a];
}
if (a % 14 == 2)
{
if (db_data[a].Length < 3)
{
if (a % 14 == 2) {
if (db_data[a].Length < 3) {
grid[2] = db_data[a];
}
else { grid[2] = db_data[a].Substring(0, 10); }

View File

@@ -167,7 +167,7 @@ namespace WindowsFormsApp1.납품관리
}
try
{
Process.Start(Application.StartupPath + "/Excel\\" + filename + ".xlsx");
Process.Start(Application.StartupPath + "\\Excel\\" + filename + ".xlsx");
}
catch { }
}

View File

@@ -66,6 +66,17 @@
this.btn_order_list_change = new System.Windows.Forms.Button();
this.btn_order_chk = new System.Windows.Forms.Button();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.panel1 = new System.Windows.Forms.Panel();
this.label14 = new System.Windows.Forms.Label();
this.label13 = new System.Windows.Forms.Label();
this.tb_search_book_comp = new System.Windows.Forms.TextBox();
this.tb_search_book_name = new System.Windows.Forms.TextBox();
this.panel2 = new System.Windows.Forms.Panel();
this.tb_search_book_list = new System.Windows.Forms.TextBox();
this.btn_order_empty = new System.Windows.Forms.Button();
this.btn_close = new System.Windows.Forms.Button();
this.btn_Excel = new System.Windows.Forms.Button();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.chk = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.order = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.M = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -82,17 +93,7 @@
this.order_date = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.send_date = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.num = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.panel1 = new System.Windows.Forms.Panel();
this.label14 = new System.Windows.Forms.Label();
this.label13 = new System.Windows.Forms.Label();
this.tb_search_book_comp = new System.Windows.Forms.TextBox();
this.tb_search_book_name = new System.Windows.Forms.TextBox();
this.panel2 = new System.Windows.Forms.Panel();
this.tb_search_book_list = new System.Windows.Forms.TextBox();
this.btn_order_empty = new System.Windows.Forms.Button();
this.btn_close = new System.Windows.Forms.Button();
this.btn_Excel = new System.Windows.Forms.Button();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.idx = new System.Windows.Forms.DataGridViewTextBoxColumn();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
@@ -441,7 +442,8 @@
this.list_name,
this.order_date,
this.send_date,
this.num});
this.num,
this.idx});
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle2.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
@@ -471,100 +473,6 @@
this.dataGridView1.DataError += new System.Windows.Forms.DataGridViewDataErrorEventHandler(this.dataGridView1_DataError);
this.dataGridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView1_KeyDown);
//
// chk
//
this.chk.HeaderText = "주문선택";
this.chk.Name = "chk";
this.chk.Width = 60;
//
// order
//
this.order.HeaderText = "주문처";
this.order.Name = "order";
this.order.Width = 80;
//
// M
//
this.M.HeaderText = "M";
this.M.Name = "M";
this.M.Width = 25;
//
// isbn
//
this.isbn.HeaderText = "ISBN13";
this.isbn.Name = "isbn";
//
// book_name
//
this.book_name.HeaderText = "도서명";
this.book_name.Name = "book_name";
this.book_name.Width = 200;
//
// author
//
this.author.HeaderText = "저자";
this.author.Name = "author";
this.author.Width = 80;
//
// book_comp
//
this.book_comp.HeaderText = "출판사";
this.book_comp.Name = "book_comp";
//
// order_count
//
this.order_count.HeaderText = "주문\n수";
this.order_count.Name = "order_count";
this.order_count.Width = 50;
//
// count
//
this.count.HeaderText = "원주\n문";
this.count.Name = "count";
this.count.Width = 50;
//
// pay
//
this.pay.HeaderText = "정가";
this.pay.Name = "pay";
this.pay.Width = 80;
//
// total
//
this.total.HeaderText = "합계";
this.total.Name = "total";
this.total.Width = 75;
//
// etc
//
this.etc.HeaderText = "비 고";
this.etc.Name = "etc";
//
// list_name
//
this.list_name.HeaderText = "구분";
this.list_name.Name = "list_name";
this.list_name.Width = 80;
//
// order_date
//
this.order_date.HeaderText = "주문일자";
this.order_date.Name = "order_date";
this.order_date.Width = 80;
//
// send_date
//
this.send_date.HeaderText = "송금일자";
this.send_date.Name = "send_date";
this.send_date.Visible = false;
this.send_date.Width = 80;
//
// num
//
this.num.HeaderText = "번호";
this.num.Name = "num";
this.num.Width = 50;
//
// panel1
//
this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
@@ -677,6 +585,106 @@
this.btn_Excel.UseVisualStyleBackColor = true;
this.btn_Excel.Click += new System.EventHandler(this.btn_Excel_Click);
//
// chk
//
this.chk.HeaderText = "주문선택";
this.chk.Name = "chk";
this.chk.Width = 60;
//
// order
//
this.order.HeaderText = "주문처";
this.order.Name = "order";
this.order.Width = 80;
//
// M
//
this.M.HeaderText = "M";
this.M.Name = "M";
this.M.Width = 25;
//
// isbn
//
this.isbn.HeaderText = "ISBN13";
this.isbn.Name = "isbn";
//
// book_name
//
this.book_name.HeaderText = "도서명";
this.book_name.Name = "book_name";
this.book_name.Width = 200;
//
// author
//
this.author.HeaderText = "저자";
this.author.Name = "author";
this.author.Width = 80;
//
// book_comp
//
this.book_comp.HeaderText = "출판사";
this.book_comp.Name = "book_comp";
//
// order_count
//
this.order_count.HeaderText = "주문\n수";
this.order_count.Name = "order_count";
this.order_count.Width = 50;
//
// count
//
this.count.HeaderText = "원주\n문";
this.count.Name = "count";
this.count.Width = 50;
//
// pay
//
this.pay.HeaderText = "정가";
this.pay.Name = "pay";
this.pay.Width = 80;
//
// total
//
this.total.HeaderText = "합계";
this.total.Name = "total";
this.total.Width = 75;
//
// etc
//
this.etc.HeaderText = "비 고";
this.etc.Name = "etc";
//
// list_name
//
this.list_name.HeaderText = "구분";
this.list_name.Name = "list_name";
this.list_name.Width = 80;
//
// order_date
//
this.order_date.HeaderText = "주문일자";
this.order_date.Name = "order_date";
this.order_date.Width = 80;
//
// send_date
//
this.send_date.HeaderText = "송금일자";
this.send_date.Name = "send_date";
this.send_date.Visible = false;
this.send_date.Width = 80;
//
// num
//
this.num.HeaderText = "번호";
this.num.Name = "num";
this.num.Width = 50;
//
// idx
//
this.idx.HeaderText = "idx";
this.idx.Name = "idx";
this.idx.Visible = false;
//
// Order_input
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
@@ -763,6 +771,7 @@
public System.Windows.Forms.TextBox tb_orderText;
private System.Windows.Forms.Button btn_Excel;
private System.Windows.Forms.OpenFileDialog openFileDialog1;
public System.Windows.Forms.ComboBox cb_ordersend;
private System.Windows.Forms.DataGridViewCheckBoxColumn chk;
private System.Windows.Forms.DataGridViewTextBoxColumn order;
private System.Windows.Forms.DataGridViewTextBoxColumn M;
@@ -779,6 +788,6 @@
private System.Windows.Forms.DataGridViewTextBoxColumn order_date;
private System.Windows.Forms.DataGridViewTextBoxColumn send_date;
private System.Windows.Forms.DataGridViewTextBoxColumn num;
public System.Windows.Forms.ComboBox cb_ordersend;
private System.Windows.Forms.DataGridViewTextBoxColumn idx;
}
}

View File

@@ -90,7 +90,7 @@ namespace WindowsFormsApp1.Delivery
string takedata = "`order`, `order_stat`, `isbn`, `book_name`, `author`, " +
"`book_comp`, `order_count`, `count`, `pay`, `total`, " +
"`etc`, `list_name`, `order_date`, `send_date`, `header`, " +
"`num`";
"`num`, `idx`";
string cmd = db.More_DB_Search("Obj_List_Book", tmp_col, tmp_data, takedata);
made_grid(cmd, true);
date_Substring();
@@ -103,7 +103,7 @@ namespace WindowsFormsApp1.Delivery
string[] mkgrid = { "false", "", "", "", "",
"", "", "", "", "",
"", "", "", "", "",
"" };
"", "" };
/* 선택 / o주문처 / oM / o도서명 / o저자 /
* o출판사 / o주문수 / o원주문 / o정가 / o합계 /
* o비고 / o납품처 / o주문일자 / o송금일자 / oo번호 /
@@ -111,29 +111,29 @@ namespace WindowsFormsApp1.Delivery
*/
for (int a = 0; a < data.Length; a++)
{
if (a % 16 == 0) { mkgrid[1] = data[a]; } // 주문처
if (a % 16 == 1)
if (a % 17 == 0) { mkgrid[1] = data[a]; } // 주문처
if (a % 17 == 1)
{ // M
if (data[a] == "0") { data[a] = data[a].Replace("0", ""); }
if (data[a] == "1") { data[a] = data[a].Replace("1", "V"); }
mkgrid[2] = data[a];
}
if (a % 16 == 2) { mkgrid[3] = data[a]; } // ISBN
if (a % 16 == 3) { mkgrid[4] = data[a]; } // 도서명
if (a % 16 == 4) { mkgrid[5] = data[a]; } // 저자
if (a % 16 == 5) { mkgrid[6] = data[a]; } // 출판사
if (a % 16 == 6) { mkgrid[7] = data[a]; } // 주문수
if (a % 16 == 7) { mkgrid[8] = data[a]; } // 원주문
if (a % 16 == 8) { mkgrid[9] = data[a]; } // 정가
if (a % 16 == 9) { mkgrid[10] = data[a]; } // 합계
if (a % 16 == 10) { mkgrid[11] = data[a]; } // 비고
if (a % 16 == 11) { mkgrid[12] = data[a]; } // 납품처
if (a % 16 == 12) { mkgrid[13] = data[a]; } // 주문일자
if (a % 16 == 13) { mkgrid[14] = data[a]; } // 송금일자
if (a % 16 == 14) { mkgrid[15] = data[a]; } // 번호
if (a % 16 == 15)
{ // 번호
mkgrid[15] += " " + data[a];
if (a % 17 == 2) { mkgrid[3] = data[a]; } // ISBN
if (a % 17 == 3) { mkgrid[4] = data[a]; } // 도서명
if (a % 17 == 4) { mkgrid[5] = data[a]; } // 저자
if (a % 17 == 5) { mkgrid[6] = data[a]; } // 출판사
if (a % 17 == 6) { mkgrid[7] = data[a]; } // 주문수
if (a % 17 == 7) { mkgrid[8] = data[a]; } // 원주문
if (a % 17 == 8) { mkgrid[9] = data[a]; } // 정가
if (a % 17 == 9) { mkgrid[10] = data[a]; } // 합계
if (a % 17 == 10) { mkgrid[11] = data[a]; } // 비고
if (a % 17 == 11) { mkgrid[12] = data[a]; } // 납품처
if (a % 17 == 12) { mkgrid[13] = data[a]; } // 주문일자
if (a % 17 == 13) { mkgrid[14] = data[a]; } // 송금일자
if (a % 17 == 14) { mkgrid[15] = data[a]; } // 번호
if (a % 17 == 15) { mkgrid[15] += " " + data[a]; } // 번호
if (a % 17 == 16) {
mkgrid[16] = data[a];
if (chk == false) { dataGridView1.Rows.Add(mkgrid); }
else
{
@@ -223,7 +223,38 @@ namespace WindowsFormsApp1.Delivery
}
private void btn_Save_Click(object sender, EventArgs e)
{
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
string[] sear_col = { "idx", "compidx" };
string[] sear_data = { dataGridView1.Rows[a].Cells["idx"].Value.ToString(), compidx };
string[] edit_col =
{
"order", "order_stat", "isbn", "book_name", "author",
"book_comp", "order_count", "count", "pay", "total",
"etc", "list_name", "order_date", "send_date"
};
string[] edit_data =
{
dataGridView1.Rows[a].Cells["order"].Value.ToString(),
"",
dataGridView1.Rows[a].Cells["isbn"].Value.ToString(),
dataGridView1.Rows[a].Cells["book_name"].Value.ToString(),
dataGridView1.Rows[a].Cells["author"].Value.ToString(),
dataGridView1.Rows[a].Cells["book_comp"].Value.ToString(),
dataGridView1.Rows[a].Cells["order_count"].Value.ToString(),
dataGridView1.Rows[a].Cells["count"].Value.ToString(),
dataGridView1.Rows[a].Cells["pay"].Value.ToString(),
dataGridView1.Rows[a].Cells["total"].Value.ToString(),
dataGridView1.Rows[a].Cells["etc"].Value.ToString(),
dataGridView1.Rows[a].Cells["list_name"].Value.ToString(),
dataGridView1.Rows[a].Cells["order_date"].Value.ToString(),
dataGridView1.Rows[a].Cells["send_date"].Value.ToString()
};
if (edit_data[1] == "") { edit_data[1] = "0"; }
else if (edit_data[1] == "V") { edit_data[1] = "1"; }
db.More_Update("Obj_List_Book", edit_col, edit_data, sear_col, sear_data);
}
MessageBox.Show("저장되었습니다!");
}
private void btn_close_Click(object sender, EventArgs e)
{
@@ -332,13 +363,14 @@ namespace WindowsFormsApp1.Delivery
private string Excel_sub()
{
List<int> chkIdx = new List<int>();
int total = 0;
int[] total = { 0, 0 };
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
if (dataGridView1.Rows[a].Cells["chk"].Value.ToString() == "true")
{
chkIdx.Add(a);
total += Convert.ToInt32(dataGridView1.Rows[a].Cells["count"].Value.ToString());
total[0] += Convert.ToInt32(dataGridView1.Rows[a].Cells["count"].Value.ToString());
total[1] += Convert.ToInt32(dataGridView1.Rows[a].Cells["pay"].Value.ToString());
}
}
if (chkIdx.Count < 1) { MessageBox.Show("선택된 도서가 없습니다!"); return "false"; }
@@ -378,7 +410,7 @@ namespace WindowsFormsApp1.Delivery
}
else if (dataGridView1.Rows[a].Cells["chk"].Value.ToString() == "true")
{
if (dataGridView1.Rows[a].Cells["order"].Value.ToString() == over_lab)
if (dataGridView1.Rows[a].Cells["order"].Value.ToString() != over_lab)
{
MessageBox.Show("주문처가 동일하지 않습니다!", "Error");
return "false";
@@ -398,7 +430,7 @@ namespace WindowsFormsApp1.Delivery
// 엑셀파일 생성
string filename = Excel_sub();
string filePath = Application.StartupPath + "/Excel" + filename;
string filePath = Application.StartupPath + "\\Excel";
switch (emchk)
{

View File

@@ -162,6 +162,9 @@
<metadata name="num.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="idx.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="openFileDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>5, 1</value>
</metadata>

View File

@@ -136,7 +136,7 @@ namespace WindowsFormsApp1.Delivery
string takedata = "`order`, `order_stat`, `isbn`, `book_name`, `author`, " +
"`book_comp`, `order_count`, `count`, `pay`, `total`, " +
"`etc`, `list_name`, `order_date`, `send_date`, `header`, " +
"`num`";
"`num`, `idx`";
string cmd = db.More_DB_Search("Obj_List_Book", tmp_col, tmp_data, takedata);
oin.made_grid(cmd, false);
oin.tb_search_book_list.Text = tmp_data[1];
@@ -148,7 +148,11 @@ namespace WindowsFormsApp1.Delivery
dataGridView1.Rows[grididx].Cells["list_name"].Value.ToString();
}
else {
oin.tb_orderText.Text = dataGridView1.Rows[grididx].Cells["list_name"].Value.ToString();
try
{
oin.tb_orderText.Text = dataGridView1.Rows[grididx].Cells["list_name"].Value.ToString();
}
catch { }
}
}
}

View File

@@ -398,7 +398,13 @@ namespace WindowsFormsApp1.Mac
grid[3] = tmp_isbn[1];
grid[4] = data[4];
grid[5] = data[5].Substring(0, 10);
if (data[5].Length < 10)
grid[5] = data[5];
else
grid[5] = data[5].Substring(0, 10);
grid[7] = data[6];
grid[8] = data[7];
@@ -502,18 +508,20 @@ namespace WindowsFormsApp1.Mac
{
for(int a = 0; a < dataGridView1.Columns.Count; a++)
{
if(dataGridView1.Columns[a].HeaderText != "ISBN13")
dataGridView1.Columns[a].ReadOnly = true;
if (dataGridView1.Columns[a].HeaderText == "ISBN13" ||
dataGridView1.Columns[a].Name == "book_name" ||
dataGridView1.Columns[a].Name == "author" ||
dataGridView1.Columns[a].Name == "book_comp") {
dataGridView1.Columns[a].ReadOnly = false;
}
else { dataGridView1.Columns[a].ReadOnly = true; }
}
}
private void btn_Save_Click(object sender, EventArgs e)
{
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
if (dataGridView1.Rows[a].Cells["isbn"].Value.ToString() == "" ||
dataGridView1.Rows[a].Cells["price"].Value.ToString() == "" ||
dataGridView1.Rows[a].Cells["pubDate"].Value.ToString() == "") { continue; }
if (dataGridView1.Rows[a].Cells["isbn"].Value.ToString() == "") { continue; }
string[] Edit_tbl = { "isbn", "price", "pubDate", "category", "image_url" };
string[] Edit_Col = { dataGridView1.Rows[a].Cells["isbn"].Value.ToString(),
dataGridView1.Rows[a].Cells["price"].Value.ToString(),

File diff suppressed because it is too large Load Diff

View File

@@ -12,11 +12,276 @@ namespace WindowsFormsApp1.Convenience
{
public partial class Calendar : Form
{
string compidx = "";
Helper_DB db = new Helper_DB();
Main main;
public Calendar(Main _main)
{
InitializeComponent();
main = _main;
compidx = main.com_idx;
}
private void Calendar_Load(object sender, EventArgs e)
{
db.DBcon();
rb_all.Checked = true;
Grep_Data();
Day_Setting();
}
/// <summary>
/// 오늘을 기준으로 달력을 출력하기 때문에 오늘의 요일을 구하여 해당 요일에 오늘 날짜를 입력함
/// </summary>
private void Day_Setting()
{
Reset_richBox();
string day_now = dateTimePicker1.Value.ToString("dd");
string week_now = dateTimePicker1.Value.DayOfWeek.ToString();
switch (week_now)
{
case "Sunday":
lbl_Day_2_1.Text = day_now;
Cal_Setting(day_now, 7);
break;
case "Monday":
lbl_Day_2_2.Text = day_now;
Cal_Setting(day_now, 8);
break;
case "Tuesday":
lbl_Day_2_3.Text = day_now;
Cal_Setting(day_now, 9);
break;
case "Wednesday":
lbl_Day_2_4.Text = day_now;
Cal_Setting(day_now, 10);
break;
case "Thursday":
lbl_Day_2_5.Text = day_now;
Cal_Setting(day_now, 11);
break;
case "Friday":
lbl_Day_2_6.Text = day_now;
Cal_Setting(day_now, 12);
break;
case "Saturday":
lbl_Day_2_7.Text = day_now;
Cal_Setting(day_now, 13);
break;
default:
break;
}
}
/// <summary>
/// 달력 날짜 세팅
/// </summary>
/// <param name="day_now"></param>
/// <param name="idx"></param>
private void Cal_Setting(string day_now, int idx)
{
int day = Convert.ToInt32(day_now);
int year = dateTimePicker1.Value.Year;
int months = dateTimePicker1.Value.Month;
lbl_Year.Text = year.ToString();
lbl_Month.Text = months.ToString();
if (lbl_Month.Text.Length < 2)
lbl_Month.Text = "0" + lbl_Month.Text;
Label[] month = {
lbl_Day_1_1, lbl_Day_1_2, lbl_Day_1_3, lbl_Day_1_4, lbl_Day_1_5, lbl_Day_1_6, lbl_Day_1_7,
lbl_Day_2_1, lbl_Day_2_2, lbl_Day_2_3, lbl_Day_2_4, lbl_Day_2_5, lbl_Day_2_6, lbl_Day_2_7,
lbl_Day_3_1, lbl_Day_3_2, lbl_Day_3_3, lbl_Day_3_4, lbl_Day_3_5, lbl_Day_3_6, lbl_Day_3_7,
lbl_Day_4_1, lbl_Day_4_2, lbl_Day_4_3, lbl_Day_4_4, lbl_Day_4_5, lbl_Day_4_6, lbl_Day_4_7,
lbl_Day_5_1, lbl_Day_5_2, lbl_Day_5_3, lbl_Day_5_4, lbl_Day_5_5, lbl_Day_5_6, lbl_Day_5_7
};
Label[] lbl_tmp = {
lbl_1_1, lbl_1_2, lbl_1_3, lbl_1_4, lbl_1_5, lbl_1_6, lbl_1_7,
lbl_2_1, lbl_2_2, lbl_2_3, lbl_2_4, lbl_2_5, lbl_2_6, lbl_2_7,
lbl_3_1, lbl_3_2, lbl_3_3, lbl_3_4, lbl_3_5, lbl_3_6, lbl_3_7,
lbl_4_1, lbl_4_2, lbl_4_3, lbl_4_4, lbl_4_5, lbl_4_6, lbl_4_7,
lbl_5_1, lbl_5_2, lbl_5_3, lbl_5_4, lbl_5_5, lbl_5_6, lbl_5_7
};
// 오늘을 포함한 이후의 달력을 만듬
for (int a = idx; a < month.Length; a++)
{
if (day - 1 == DateTime.DaysInMonth(year, months)) { day = 1; }
month[a].Text = day.ToString();
if (month[a].Text.Length < 2)
month[a].Text = "0" + month[a].Text;
day++;
lbl_tmp[a].Text = string.Format("{0}-{1}-{2}",year, months, month[a].Text);
}
// 오늘 이전의 달력을 만듬
bool ago = false;
day = Convert.ToInt32(day_now);
for (int a = idx; a > -1; a--)
{
if (day < 1)
{
months--;
day = DateTime.DaysInMonth(year, months);
ago = true;
}
if (ago) {
month[a].ForeColor = Color.Gray;
}
else {
month[a].ForeColor = Color.Black;
}
month[a].Text = day.ToString();
if (month[a].Text.Length < 2)
month[a].Text = "0" + month[a].Text;
day--;
lbl_tmp[a].Text = string.Format("{0}-{1}-{2}",year, months, month[a].Text);
}
// 토요일 일요일 색을 입힘
for (int a = 0; a < month.Length; a++)
{
if (month[a].Name[10] == '1')
month[a].ForeColor = Color.Red;
if (month[a].Name[10] == '7')
month[a].ForeColor = Color.Blue;
input_List(a);
}
}
private void Reset_richBox()
{
RichTextBox[] rbBox = {
rb_1_1, rb_1_2, rb_1_3, rb_1_4, rb_1_5, rb_1_6, rb_1_7,
rb_2_1, rb_2_2, rb_2_3, rb_2_4, rb_2_5, rb_2_6, rb_2_7,
rb_3_1, rb_3_2, rb_3_3, rb_3_4, rb_3_5, rb_3_6, rb_3_7,
rb_4_1, rb_4_2, rb_4_3, rb_4_4, rb_4_5, rb_4_6, rb_4_7,
rb_5_1, rb_5_2, rb_5_3, rb_5_4, rb_5_5, rb_5_6, rb_5_7
};
for(int a = 0; a < rbBox.Length; a++)
{
rbBox[a].Text = "";
}
}
List<string> date_res = new List<string>();
List<string> list_name = new List<string>();
List<string> chk_marc = new List<string>();
private void Grep_Data()
{
string Area = "`date_res`, `list_name`, `chk_marc`";
string tmp_data = db.DB_Select_Search(Area, "Obj_List", "comp_num", compidx);
string[] ary_tmp = tmp_data.Split('|');
bool chk = false;
for(int a = 0; a < ary_tmp.Length; a++)
{
if (a % 3 == 0) {
if (ary_tmp[a].Length > 4) {
chk = true;
date_res.Add(ary_tmp[a]);
}
else { chk = false; }
}
if (a % 3 == 1)
{
if (chk) { list_name.Add(ary_tmp[a]); chk_marc.Add(ary_tmp[a + 1]); }
else { chk = true; }
}
}
}
private void input_List(int idx)
{
Label[] lbl_tmp = {
lbl_1_1, lbl_1_2, lbl_1_3, lbl_1_4, lbl_1_5, lbl_1_6, lbl_1_7,
lbl_2_1, lbl_2_2, lbl_2_3, lbl_2_4, lbl_2_5, lbl_2_6, lbl_2_7,
lbl_3_1, lbl_3_2, lbl_3_3, lbl_3_4, lbl_3_5, lbl_3_6, lbl_3_7,
lbl_4_1, lbl_4_2, lbl_4_3, lbl_4_4, lbl_4_5, lbl_4_6, lbl_4_7,
lbl_5_1, lbl_5_2, lbl_5_3, lbl_5_4, lbl_5_5, lbl_5_6, lbl_5_7
};
RichTextBox[] rbBox = {
rb_1_1, rb_1_2, rb_1_3, rb_1_4, rb_1_5, rb_1_6, rb_1_7,
rb_2_1, rb_2_2, rb_2_3, rb_2_4, rb_2_5, rb_2_6, rb_2_7,
rb_3_1, rb_3_2, rb_3_3, rb_3_4, rb_3_5, rb_3_6, rb_3_7,
rb_4_1, rb_4_2, rb_4_3, rb_4_4, rb_4_5, rb_4_6, rb_4_7,
rb_5_1, rb_5_2, rb_5_3, rb_5_4, rb_5_5, rb_5_6, rb_5_7
};
bool print = false;
string mk_date = lbl_tmp[idx].Text;
DateTime mkd = DateTime.Parse(mk_date);
for(int a = 0; a < date_res.Count; a++)
{
DateTime res = DateTime.Parse(date_res[a]);
if (mkd == res) {
if (rb_all.Checked) print = true;
else if (rb_dly.Checked) {
if (chk_marc[a] == "0" || chk_marc[a] == "2") {
print = true;
}
}
else if (rb_marc.Checked) {
if (chk_marc[a] == "1" || chk_marc[a] == "2") {
print = true;
}
}
if (print)
rbBox[idx].Text += list_name[a] + "\n";
}
}
}
private void dateTimePicker1_ValueChanged(object sender, EventArgs e)
{
Day_Setting();
}
private void Btn_Before_Click(object sender, EventArgs e)
{
int year, month, day;
DateTime picker = dateTimePicker1.Value;
year = picker.Year;
month = picker.Month - 1;
if (month < 1)
{
year--;
month = 12;
}
day = picker.Day;
string date = string.Format("{0}-{1}-{2}", year, month, day);
dateTimePicker1.Value = DateTime.Parse(date);
}
private void Btn_After_Click(object sender, EventArgs e)
{
int year, month, day;
DateTime picker = dateTimePicker1.Value;
year = picker.Year;
month = picker.Month + 1;
if (month > 12)
{
year++;
month = 1;
}
day = picker.Day;
string date = string.Format("{0}-{1}-{2}", year, month, day);
dateTimePicker1.Value = DateTime.Parse(date);
}
private void btn_close_Click(object sender, EventArgs e)
{
this.Close();
}
private void rb_all_CheckedChanged(object sender, EventArgs e)
{
Day_Setting();
}
}
}

View File

@@ -194,10 +194,10 @@ namespace WindowsFormsApp1.Home
string gu = "";
if (chk_send.Checked == true) { send_chk = "1"; }
if (chk_email.Checked == true) { emchk = "1"; }
if(cb_gubun.SelectedIndex == 0) { gu = "출판"; }
if(cb_gubun.SelectedIndex == 1) { gu = "도매"; }
if(cb_gubun.SelectedIndex == 2) { gu = "기타"; }
if(cb_gubun.SelectedIndex == 3) { gu = "경비"; }
if(cb_gubun.SelectedIndex == 0) { gu = "0"; } // 출판
if(cb_gubun.SelectedIndex == 1) { gu = "1"; } // 도매
if(cb_gubun.SelectedIndex == 2) { gu = "2"; } // 기타
if(cb_gubun.SelectedIndex == 3) { gu = "3"; } // 경비
string[] Insert_Table = {"send_chk", "sangho", "boss", "bubin", "uptae",
"jongmok", "zip", "addr", "tel", "fax",
"bank_no", "bank_comp", "bank_name", "gu", "barea",
@@ -209,12 +209,13 @@ namespace WindowsFormsApp1.Home
if (insert)
{
db.DB_INSERT("Purchase", Insert_Table, Insert_Data);
MessageBox.Show(tb_sangho.Text + " 저장 완료");
}
else
{
db.More_Update(Table, Insert_Data, Insert_Table, Search_Data, Search_Table);
db.More_Update(Table, Insert_Table, Insert_Data, Search_Table, Search_Data);
MessageBox.Show(tb_sangho.Text + " 수정 완료");
}
MessageBox.Show(tb_sangho.Text + " 저장 완료");
}
private void btn_Delete_Click(object sender, EventArgs e) // 삭제
{

View File

@@ -0,0 +1,600 @@

namespace UniMarc.
{
partial class Part_time
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
this.panel1 = new System.Windows.Forms.Panel();
this.rb_pay = new System.Windows.Forms.RadioButton();
this.rb_minpay = new System.Windows.Forms.RadioButton();
this.end_30min = new System.Windows.Forms.CheckBox();
this.start_30min = new System.Windows.Forms.CheckBox();
this.btn_Add = new System.Windows.Forms.Button();
this.btn_Save = new System.Windows.Forms.Button();
this.btn_Close = new System.Windows.Forms.Button();
this.cb_work_time = new System.Windows.Forms.ComboBox();
this.label2 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.cb_end_hour = new System.Windows.Forms.ComboBox();
this.cb_start_hour = new System.Windows.Forms.ComboBox();
this.set_date = new System.Windows.Forms.DateTimePicker();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.dataGridView2 = new System.Windows.Forms.DataGridView();
this.start_date = new System.Windows.Forms.DateTimePicker();
this.end_date = new System.Windows.Forms.DateTimePicker();
this.label4 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.cb_name = new System.Windows.Forms.ComboBox();
this.btn_Lookup = new System.Windows.Forms.Button();
this.panel2 = new System.Windows.Forms.Panel();
this.lbl_pay = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.tb_pay = new System.Windows.Forms.TextBox();
this.btn_Delete = new System.Windows.Forms.Button();
this.date = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Per_name = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.start = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.end = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.minus = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.today = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.pay = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.work = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.del_chk = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.work_date = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.name1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.start2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.end2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.all_time = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.time_pay = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.total = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.work2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dataGridView2)).BeginInit();
this.panel2.SuspendLayout();
this.SuspendLayout();
//
// panel1
//
this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel1.Controls.Add(this.tb_pay);
this.panel1.Controls.Add(this.rb_pay);
this.panel1.Controls.Add(this.rb_minpay);
this.panel1.Controls.Add(this.end_30min);
this.panel1.Controls.Add(this.start_30min);
this.panel1.Controls.Add(this.cb_work_time);
this.panel1.Controls.Add(this.label2);
this.panel1.Controls.Add(this.label1);
this.panel1.Controls.Add(this.cb_end_hour);
this.panel1.Controls.Add(this.cb_start_hour);
this.panel1.Controls.Add(this.set_date);
this.panel1.Location = new System.Drawing.Point(12, 12);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(908, 42);
this.panel1.TabIndex = 0;
//
// rb_pay
//
this.rb_pay.AutoSize = true;
this.rb_pay.Location = new System.Drawing.Point(678, 12);
this.rb_pay.Name = "rb_pay";
this.rb_pay.Size = new System.Drawing.Size(71, 16);
this.rb_pay.TabIndex = 2;
this.rb_pay.TabStop = true;
this.rb_pay.Text = "직접입력";
this.rb_pay.UseVisualStyleBackColor = true;
this.rb_pay.CheckedChanged += new System.EventHandler(this.rb_pay_CheckedChanged);
//
// rb_minpay
//
this.rb_minpay.AutoSize = true;
this.rb_minpay.Location = new System.Drawing.Point(601, 6);
this.rb_minpay.Name = "rb_minpay";
this.rb_minpay.Size = new System.Drawing.Size(71, 28);
this.rb_minpay.TabIndex = 2;
this.rb_minpay.TabStop = true;
this.rb_minpay.Text = "최저시급\n8,720원";
this.rb_minpay.UseVisualStyleBackColor = true;
this.rb_minpay.CheckedChanged += new System.EventHandler(this.rb_pay_CheckedChanged);
//
// end_30min
//
this.end_30min.AutoSize = true;
this.end_30min.Location = new System.Drawing.Point(335, 12);
this.end_30min.Name = "end_30min";
this.end_30min.Size = new System.Drawing.Size(48, 16);
this.end_30min.TabIndex = 2;
this.end_30min.Text = "30분";
this.end_30min.UseVisualStyleBackColor = true;
//
// start_30min
//
this.start_30min.AutoSize = true;
this.start_30min.Location = new System.Drawing.Point(192, 12);
this.start_30min.Name = "start_30min";
this.start_30min.Size = new System.Drawing.Size(48, 16);
this.start_30min.TabIndex = 2;
this.start_30min.Text = "30분";
this.start_30min.UseVisualStyleBackColor = true;
//
// btn_Add
//
this.btn_Add.Location = new System.Drawing.Point(597, 60);
this.btn_Add.Name = "btn_Add";
this.btn_Add.Size = new System.Drawing.Size(75, 23);
this.btn_Add.TabIndex = 23;
this.btn_Add.Text = "추 가";
this.btn_Add.UseVisualStyleBackColor = true;
this.btn_Add.Click += new System.EventHandler(this.btn_Add_Click);
//
// btn_Save
//
this.btn_Save.Location = new System.Drawing.Point(759, 60);
this.btn_Save.Name = "btn_Save";
this.btn_Save.Size = new System.Drawing.Size(75, 23);
this.btn_Save.TabIndex = 23;
this.btn_Save.Text = "저 장";
this.btn_Save.UseVisualStyleBackColor = true;
this.btn_Save.Click += new System.EventHandler(this.btn_Save_Click);
//
// btn_Close
//
this.btn_Close.Location = new System.Drawing.Point(840, 60);
this.btn_Close.Name = "btn_Close";
this.btn_Close.Size = new System.Drawing.Size(75, 23);
this.btn_Close.TabIndex = 23;
this.btn_Close.Text = "닫 기";
this.btn_Close.UseVisualStyleBackColor = true;
this.btn_Close.Click += new System.EventHandler(this.btn_Close_Click);
//
// cb_work_time
//
this.cb_work_time.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cb_work_time.FormattingEnabled = true;
this.cb_work_time.Location = new System.Drawing.Point(458, 9);
this.cb_work_time.Name = "cb_work_time";
this.cb_work_time.Size = new System.Drawing.Size(121, 20);
this.cb_work_time.TabIndex = 22;
this.cb_work_time.SelectedIndexChanged += new System.EventHandler(this.cb_work_time_SelectedIndexChanged);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(395, 13);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(57, 12);
this.label2.TabIndex = 1;
this.label2.Text = "업무 구분";
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label1.Location = new System.Drawing.Point(241, 15);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(15, 12);
this.label1.TabIndex = 1;
this.label1.Text = "~";
//
// cb_end_hour
//
this.cb_end_hour.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cb_end_hour.FormattingEnabled = true;
this.cb_end_hour.Location = new System.Drawing.Point(258, 9);
this.cb_end_hour.Name = "cb_end_hour";
this.cb_end_hour.Size = new System.Drawing.Size(71, 20);
this.cb_end_hour.TabIndex = 21;
//
// cb_start_hour
//
this.cb_start_hour.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cb_start_hour.FormattingEnabled = true;
this.cb_start_hour.Location = new System.Drawing.Point(115, 9);
this.cb_start_hour.Name = "cb_start_hour";
this.cb_start_hour.Size = new System.Drawing.Size(71, 20);
this.cb_start_hour.TabIndex = 21;
//
// set_date
//
this.set_date.CustomFormat = "yyyy-MM-dd";
this.set_date.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.set_date.Location = new System.Drawing.Point(12, 9);
this.set_date.Name = "set_date";
this.set_date.Size = new System.Drawing.Size(85, 21);
this.set_date.TabIndex = 20;
//
// dataGridView1
//
this.dataGridView1.AllowUserToAddRows = false;
this.dataGridView1.AllowUserToDeleteRows = false;
this.dataGridView1.BackgroundColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle1.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.date,
this.Per_name,
this.start,
this.end,
this.minus,
this.today,
this.pay,
this.work,
this.del_chk});
this.dataGridView1.Location = new System.Drawing.Point(12, 89);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 30;
this.dataGridView1.RowTemplate.Height = 23;
this.dataGridView1.Size = new System.Drawing.Size(908, 146);
this.dataGridView1.TabIndex = 1;
this.dataGridView1.CellValidated += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellValidated);
//
// dataGridView2
//
this.dataGridView2.AllowUserToAddRows = false;
this.dataGridView2.AllowUserToDeleteRows = false;
this.dataGridView2.BackgroundColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle7.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle7.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
dataGridViewCellStyle7.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle7.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle7.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
this.dataGridView2.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle7;
this.dataGridView2.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dataGridView2.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.work_date,
this.name1,
this.start2,
this.end2,
this.all_time,
this.time_pay,
this.total,
this.work2});
this.dataGridView2.Location = new System.Drawing.Point(12, 315);
this.dataGridView2.Name = "dataGridView2";
this.dataGridView2.ReadOnly = true;
this.dataGridView2.RowHeadersWidth = 30;
this.dataGridView2.RowTemplate.Height = 23;
this.dataGridView2.Size = new System.Drawing.Size(908, 151);
this.dataGridView2.TabIndex = 1;
//
// start_date
//
this.start_date.CustomFormat = "yyyy-MM-01";
this.start_date.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.start_date.Location = new System.Drawing.Point(12, 9);
this.start_date.Name = "start_date";
this.start_date.Size = new System.Drawing.Size(85, 21);
this.start_date.TabIndex = 20;
//
// end_date
//
this.end_date.CustomFormat = "yyyy-MM-dd";
this.end_date.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.end_date.Location = new System.Drawing.Point(116, 9);
this.end_date.Name = "end_date";
this.end_date.Size = new System.Drawing.Size(85, 21);
this.end_date.TabIndex = 20;
//
// label4
//
this.label4.AutoSize = true;
this.label4.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label4.Location = new System.Drawing.Point(99, 15);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(15, 12);
this.label4.TabIndex = 1;
this.label4.Text = "~";
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(252, 15);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(33, 12);
this.label3.TabIndex = 1;
this.label3.Text = "이 름";
//
// cb_name
//
this.cb_name.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cb_name.FormattingEnabled = true;
this.cb_name.Location = new System.Drawing.Point(296, 10);
this.cb_name.Name = "cb_name";
this.cb_name.Size = new System.Drawing.Size(121, 20);
this.cb_name.TabIndex = 22;
//
// btn_Lookup
//
this.btn_Lookup.Location = new System.Drawing.Point(479, 9);
this.btn_Lookup.Name = "btn_Lookup";
this.btn_Lookup.Size = new System.Drawing.Size(75, 23);
this.btn_Lookup.TabIndex = 23;
this.btn_Lookup.Text = "조 회";
this.btn_Lookup.UseVisualStyleBackColor = true;
this.btn_Lookup.Click += new System.EventHandler(this.btn_Lookup_Click);
//
// panel2
//
this.panel2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel2.Controls.Add(this.lbl_pay);
this.panel2.Controls.Add(this.label5);
this.panel2.Controls.Add(this.btn_Lookup);
this.panel2.Controls.Add(this.cb_name);
this.panel2.Controls.Add(this.label3);
this.panel2.Controls.Add(this.label4);
this.panel2.Controls.Add(this.end_date);
this.panel2.Controls.Add(this.start_date);
this.panel2.Location = new System.Drawing.Point(12, 266);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(908, 41);
this.panel2.TabIndex = 0;
//
// lbl_pay
//
this.lbl_pay.AutoSize = true;
this.lbl_pay.Location = new System.Drawing.Point(714, 14);
this.lbl_pay.Name = "lbl_pay";
this.lbl_pay.Size = new System.Drawing.Size(11, 12);
this.lbl_pay.TabIndex = 24;
this.lbl_pay.Text = "0";
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(648, 14);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(69, 12);
this.label5.TabIndex = 2;
this.label5.Text = "총 지급액 : ";
//
// tb_pay
//
this.tb_pay.Location = new System.Drawing.Point(751, 9);
this.tb_pay.Name = "tb_pay";
this.tb_pay.Size = new System.Drawing.Size(107, 21);
this.tb_pay.TabIndex = 24;
this.tb_pay.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.tb_pay_KeyPress);
//
// btn_Delete
//
this.btn_Delete.Location = new System.Drawing.Point(678, 60);
this.btn_Delete.Name = "btn_Delete";
this.btn_Delete.Size = new System.Drawing.Size(75, 23);
this.btn_Delete.TabIndex = 25;
this.btn_Delete.Text = "삭 제";
this.btn_Delete.UseVisualStyleBackColor = true;
this.btn_Delete.Click += new System.EventHandler(this.btn_Delete_Click);
//
// date
//
this.date.HeaderText = "날짜";
this.date.Name = "date";
this.date.Width = 80;
//
// Per_name
//
this.Per_name.HeaderText = "이름";
this.Per_name.Name = "Per_name";
this.Per_name.Width = 200;
//
// start
//
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.start.DefaultCellStyle = dataGridViewCellStyle2;
this.start.HeaderText = "근무시작";
this.start.Name = "start";
this.start.Width = 65;
//
// end
//
dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.end.DefaultCellStyle = dataGridViewCellStyle3;
this.end.HeaderText = "근무종료";
this.end.Name = "end";
this.end.Width = 65;
//
// minus
//
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.minus.DefaultCellStyle = dataGridViewCellStyle4;
this.minus.HeaderText = "업무제외";
this.minus.Name = "minus";
this.minus.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// today
//
dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.today.DefaultCellStyle = dataGridViewCellStyle5;
this.today.HeaderText = "금일근무";
this.today.Name = "today";
//
// pay
//
dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
this.pay.DefaultCellStyle = dataGridViewCellStyle6;
this.pay.HeaderText = "시급";
this.pay.Name = "pay";
this.pay.Width = 60;
//
// work
//
this.work.HeaderText = "작업내용";
this.work.Name = "work";
this.work.Width = 150;
//
// del_chk
//
this.del_chk.HeaderText = "삭제";
this.del_chk.Name = "del_chk";
this.del_chk.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.del_chk.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
this.del_chk.Width = 40;
//
// work_date
//
this.work_date.HeaderText = "날짜";
this.work_date.Name = "work_date";
this.work_date.ReadOnly = true;
this.work_date.Width = 80;
//
// name1
//
this.name1.HeaderText = "이름";
this.name1.Name = "name1";
this.name1.ReadOnly = true;
this.name1.Width = 200;
//
// start2
//
this.start2.HeaderText = "근무시작";
this.start2.Name = "start2";
this.start2.ReadOnly = true;
this.start2.Width = 65;
//
// end2
//
this.end2.HeaderText = "근무종료";
this.end2.Name = "end2";
this.end2.ReadOnly = true;
this.end2.Width = 65;
//
// all_time
//
this.all_time.HeaderText = "총 근무시간";
this.all_time.Name = "all_time";
this.all_time.ReadOnly = true;
//
// time_pay
//
this.time_pay.HeaderText = "시급";
this.time_pay.Name = "time_pay";
this.time_pay.ReadOnly = true;
this.time_pay.Width = 80;
//
// total
//
this.total.HeaderText = "지급금액";
this.total.Name = "total";
this.total.ReadOnly = true;
//
// work2
//
this.work2.HeaderText = "작업내용";
this.work2.Name = "work2";
this.work2.ReadOnly = true;
this.work2.Width = 150;
//
// Part_time
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(932, 478);
this.Controls.Add(this.btn_Delete);
this.Controls.Add(this.dataGridView2);
this.Controls.Add(this.dataGridView1);
this.Controls.Add(this.panel2);
this.Controls.Add(this.panel1);
this.Controls.Add(this.btn_Add);
this.Controls.Add(this.btn_Close);
this.Controls.Add(this.btn_Save);
this.Name = "Part_time";
this.Text = "파트타임 직원관리";
this.Load += new System.EventHandler(this.Part_time_Load);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dataGridView2)).EndInit();
this.panel2.ResumeLayout(false);
this.panel2.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.DateTimePicker set_date;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.ComboBox cb_end_hour;
private System.Windows.Forms.ComboBox cb_start_hour;
private System.Windows.Forms.Button btn_Close;
private System.Windows.Forms.Button btn_Save;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.ComboBox cb_work_time;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Button btn_Add;
private System.Windows.Forms.DataGridView dataGridView2;
private System.Windows.Forms.CheckBox end_30min;
private System.Windows.Forms.CheckBox start_30min;
private System.Windows.Forms.DateTimePicker start_date;
private System.Windows.Forms.DateTimePicker end_date;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.ComboBox cb_name;
private System.Windows.Forms.Button btn_Lookup;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Label lbl_pay;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.RadioButton rb_minpay;
private System.Windows.Forms.RadioButton rb_pay;
private System.Windows.Forms.TextBox tb_pay;
private System.Windows.Forms.Button btn_Delete;
private System.Windows.Forms.DataGridViewTextBoxColumn date;
private System.Windows.Forms.DataGridViewTextBoxColumn Per_name;
private System.Windows.Forms.DataGridViewTextBoxColumn start;
private System.Windows.Forms.DataGridViewTextBoxColumn end;
private System.Windows.Forms.DataGridViewTextBoxColumn minus;
private System.Windows.Forms.DataGridViewTextBoxColumn today;
private System.Windows.Forms.DataGridViewTextBoxColumn pay;
private System.Windows.Forms.DataGridViewTextBoxColumn work;
private System.Windows.Forms.DataGridViewCheckBoxColumn del_chk;
private System.Windows.Forms.DataGridViewTextBoxColumn work_date;
private System.Windows.Forms.DataGridViewTextBoxColumn name1;
private System.Windows.Forms.DataGridViewTextBoxColumn start2;
private System.Windows.Forms.DataGridViewTextBoxColumn end2;
private System.Windows.Forms.DataGridViewTextBoxColumn all_time;
private System.Windows.Forms.DataGridViewTextBoxColumn time_pay;
private System.Windows.Forms.DataGridViewTextBoxColumn total;
private System.Windows.Forms.DataGridViewTextBoxColumn work2;
}
}

View File

@@ -0,0 +1,318 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows.Forms;
// 추가 참조
using WindowsFormsApp1;
namespace UniMarc.
{
public partial class Part_time : Form
{
string compidx;
Main main;
Helper_DB db = new Helper_DB();
public Part_time(Main _main)
{
InitializeComponent();
main = _main;
compidx = main.com_idx;
}
private void Part_time_Load(object sender, EventArgs e)
{
db.DBcon();
Setting_combo();
Setting_Date();
Setting_Etc();
}
#region Load_Sub
/// <summary>
/// 콤보박스 초기 세팅
/// </summary>
private void Setting_combo()
{
string[] start = {
"8시", "9시", "10시", "11시", "12시",
"13시", "14시", "15시", "16시", "17시",
"18시", "19시", "20시", "21시", "22시"
};
cb_start_hour.Items.AddRange(start);
string[] end = {
"8시", "9시", "10시", "11시", "12시",
"13시", "14시", "15시", "16시", "17시",
"18시", "19시", "20시", "21시", "22시"
};
cb_end_hour.Items.AddRange(end);
string[] set_time = { "직접입력", "풀타임 (9시~18시)", "오전 (9시~12시)", "오후 (13시~18시)" };
cb_work_time.Items.AddRange(set_time);
//string tmp_db = db.search
}
/// <summary>
/// 조회창 datepicker 세팅
/// </summary>
private void Setting_Date()
{
int year = DateTime.Now.Year;
int month = DateTime.Now.Month;
int day = DateTime.Now.Day;
if (day < 10)
{
if (month - 1 <= 0)
{
year--;
month = 12;
}
month--;
}
day = 10;
string set_start = string.Format("{0}-{1}-{2}", year, month, day);
start_date.Value = DateTime.Parse(set_start);
}
/// <summary>
/// 기타 세팅
/// </summary>
private void Setting_Etc()
{
rb_minpay.Checked = true;
for(int a = 0; a < dataGridView1.Columns.Count; a++)
{
if (a == 0 || a == 2 || a == 3) {
dataGridView1.Columns[a].ReadOnly = true;
}
}
string tmp_name = db.DB_Select_Search("`name`", "Part_Time", "compidx", compidx);
string[] ary_name = tmp_name.Split('|');
for (int a = 0; a < ary_name.Length - 1; a++)
{
cb_name.Items.Add(ary_name[a]);
}
}
#endregion
private void btn_Add_Click(object sender, EventArgs e)
{
#region
string date = set_date.Value.ToString().Substring(0, 10);
#endregion
#region
if (cb_start_hour.SelectedIndex > cb_end_hour.SelectedIndex) {
int tmp = cb_start_hour.SelectedIndex;
cb_start_hour.SelectedIndex = cb_end_hour.SelectedIndex;
cb_end_hour.SelectedIndex = tmp;
}
string start_time = Regex.Replace(cb_start_hour.Text, @"\D", "");
if (cb_start_hour.SelectedIndex < 0) { MessageBox.Show("시간이 선택되지 않았습니다!"); return; }
else if (start_30min.Checked) { start_time += ":30"; }
else { start_time += ":00"; }
string end_time = Regex.Replace(cb_end_hour.Text, @"\D", "");
if (cb_end_hour.SelectedIndex < 0) { MessageBox.Show("시간이 선택되지 않았습니다!"); return; }
else if (end_30min.Checked) { end_time += ":30"; }
else { end_time += ":00"; }
#endregion
#region
double start_work = cb_start_hour.SelectedIndex;
if (start_30min.Checked) { start_work += 0.5; }
double end_work = cb_end_hour.SelectedIndex;
if (end_30min.Checked) { end_work += 0.5; }
double work = end_work - start_work;
#endregion
#region
string pay = "";
if (rb_minpay.Checked) { pay = "8720"; }
else { pay = tb_pay.Text; }
#endregion
string[] grid = { date, "", start_time, end_time, "0", work.ToString(), pay, "", "False" };
dataGridView1.Rows.Add(grid);
}
private void btn_Save_Click(object sender, EventArgs e)
{
string[] input_area = { "compidx", "date", "name", "start", "end",
"work_time", "pay", "work" };
if (!chk_name()) return;
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
string[] input_data = {
compidx,
dataGridView1.Rows[a].Cells["date"].Value.ToString(),
dataGridView1.Rows[a].Cells["Per_name"].Value.ToString(),
dataGridView1.Rows[a].Cells["start"].Value.ToString(),
dataGridView1.Rows[a].Cells["end"].Value.ToString(),
dataGridView1.Rows[a].Cells["today"].Value.ToString(),
dataGridView1.Rows[a].Cells["pay"].Value.ToString(),
dataGridView1.Rows[a].Cells["work"].Value.ToString()
};
db.DB_INSERT("Part_Time", input_area, input_data);
}
MessageBox.Show("저장되었습니다!");
}
#region Save_Sub
/// <summary>
/// 이름에 빈칸이 있는지 확인
/// </summary>
/// <returns></returns>
private bool chk_name()
{
for(int a = 0; a < dataGridView1.Rows.Count; a++)
{
if (dataGridView1.Rows[a].Cells["per_name"].Value.ToString() == "")
{
MessageBox.Show("이름이 빈칸입니다!");
return false;
}
}
return true;
}
#endregion
private void btn_Delete_Click(object sender, EventArgs e)
{
for (int a = 0; a < dataGridView1.Rows.Count; a++)
{
if (dataGridView1.Rows[a].Cells["del_chk"].Value.ToString() == "True") {
dataGridView1.Rows.RemoveAt(a);
}
}
MessageBox.Show("삭제되었습니다!");
}
private void btn_Close_Click(object sender, EventArgs e)
{
this.Close();
}
private void btn_Lookup_Click(object sender, EventArgs e)
{
dataGridView2.Rows.Clear();
string Area = "`date`, `name`, `start`, `end`, `work_time`, `pay`, `work`";
string[] s_date = { start_date.Value.ToString("yyyy-MM-dd"), end_date.Value.ToString("yyyy-MM-dd") };
string data = db.Search_Date("Part_Time", Area, "date", s_date[0], s_date[1], compidx);
input_Grid(data.Split('|'));
total_pay();
}
#region Lookup_Sub
private void input_Grid(string[] data)
{
string[] grid = { "", "", "", "", "", "", "", "" };
for(int a = 0; a < data.Length; a++)
{
if (a % 7 == 0) { grid[0] = data[a]; }
if (a % 7 == 1) { grid[1] = data[a]; }
if (a % 7 == 2) { grid[2] = data[a]; }
if (a % 7 == 3) { grid[3] = data[a]; }
if (a % 7 == 4) { grid[4] = data[a]; }
if (a % 7 == 5) { grid[5] = data[a]; }
if (a % 7 == 6) {
grid[6] = res_pay(grid);
grid[7] = data[a];
if (filter_name(grid)) { dataGridView2.Rows.Add(grid); }
}
}
}
private string res_pay(string[] grid)
{
double time = Convert.ToDouble(grid[4]);
double pay = Convert.ToDouble(grid[5]);
double res = time * pay;
return res.ToString();
}
private void total_pay()
{
double total = 0;
for(int a = 0; a < dataGridView2.Rows.Count; a++)
{
double pay = Convert.ToDouble(dataGridView2.Rows[a].Cells["total"].Value.ToString());
total += pay;
}
lbl_pay.Text = string.Format("{0:#,###}", total);
}
private bool filter_name(string[] grid)
{
if (cb_name.SelectedIndex == -1) return true;
if (grid[1] == cb_name.Text) return true;
return false;
}
#endregion
private void dataGridView1_CellValidated(object sender, DataGridViewCellEventArgs e)
{
int col = e.ColumnIndex;
int row = e.RowIndex;
string name = dataGridView1.Columns[col].Name;
if (name == "minus")
{
string str_start = dataGridView1.Rows[row].Cells["start"].Value.ToString();
if (str_start.Contains(":30")) { str_start = str_start.Replace(":30", ".5"); }
else { str_start = str_start.Replace(":00", ""); }
double start_work = Convert.ToDouble(str_start);
string str_end = dataGridView1.Rows[row].Cells["end"].Value.ToString();
if (str_end.Contains(":30")) { str_end = str_end.Replace(":30", ".5"); }
else { str_end = str_end.Replace(":00", ""); }
double end_work = Convert.ToDouble(str_end);
string value = dataGridView1.Rows[row].Cells[col].Value.ToString();
value = Regex.Replace(value, @"\D", "");
double minus = Convert.ToDouble(value);
double total = end_work - start_work - minus;
dataGridView1.Rows[row].Cells["today"].Value = total.ToString();
}
}
private void cb_work_time_SelectedIndexChanged(object sender, EventArgs e)
{
switch (cb_work_time.SelectedIndex)
{
case 0:
break;
case 1:
cb_start_hour.SelectedIndex = 1;
cb_end_hour.SelectedIndex = 10;
break;
case 2:
cb_start_hour.SelectedIndex = 1;
cb_end_hour.SelectedIndex = 4;
break;
case 3:
cb_start_hour.SelectedIndex = 5;
cb_end_hour.SelectedIndex = 10;
break;
default:
break;
}
}
private void rb_pay_CheckedChanged(object sender, EventArgs e)
{
if (rb_pay.Checked) { tb_pay.Enabled = true; }
else { tb_pay.Enabled = false; }
}
private void tb_pay_KeyPress(object sender, KeyPressEventArgs e)
{
String_Text st = new String_Text();
st.Only_Int(sender, e);
}
}
}

View File

@@ -117,4 +117,55 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="date.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Per_name.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="start.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="end.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="minus.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="today.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="pay.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="work.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="del_chk.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="work_date.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="name1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="start2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="end2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="all_time.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="time_pay.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="total.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="work2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>