마크편집기를 공용으로 분리작업(90%)
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Web.UI.WebControls.WebParts;
|
||||
using System.Windows.Forms;
|
||||
using UniMarc.Properties;
|
||||
|
||||
@@ -29,12 +30,42 @@ namespace UniMarc
|
||||
PUB.log.SubDirectory = logsubdir;
|
||||
PUB.log.FileNameFormat = "{yyMMdd}";
|
||||
#endregion
|
||||
|
||||
|
||||
setting = new UserSetting();
|
||||
setting.Load();
|
||||
|
||||
user = new LoginInfo();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 빈 MARC String 을 생성한다
|
||||
/// </summary>
|
||||
/// <param name="ISBN13"></param>
|
||||
/// <param name="BookName"></param>
|
||||
/// <param name="Author"></param>
|
||||
/// <param name="Publisher"></param>
|
||||
/// <param name="Price"></param>
|
||||
/// <returns></returns>
|
||||
public static string MakeEmptyMarc(string ISBN13, string BookName, string Author, string Publisher, string Price)
|
||||
{
|
||||
string yyMMdd = DateTime.Now.ToString("yyMMdd");
|
||||
string yyyy = DateTime.Now.ToString("yyyy");
|
||||
string Empty_008 = yyMMdd + "s" + yyyy + " 000 kor ▲";
|
||||
var tag_008 = Empty_008.Replace("▲", "");
|
||||
string Empty_text = string.Format(
|
||||
"020\t \t▼a{1}▼c\\{5}▲\n" +
|
||||
"056\t \t▼a▼25▲\n" +
|
||||
"100\t \t▼a▲\n" +
|
||||
"245\t \t▼a{2}▼d{3}▲\n" +
|
||||
"260\t \t▼b{4}▲\n" +
|
||||
"300\t \t▼a▼c▲\n" +
|
||||
"653\t \t▼a▲\n" +
|
||||
"700\t \t▼a▲\n" +
|
||||
"950\t \t▼b\\{5}▲\n",
|
||||
Empty_008, ISBN13, BookName, Author, Publisher, Price);
|
||||
return Empty_text;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -385,6 +385,12 @@
|
||||
<DependentUpon>Check_ISBN_Yes242.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\FillBlankItem.cs" />
|
||||
<Compile Include="마크\fMarc_Editor.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="마크\fMarc_Editor.Designer.cs">
|
||||
<DependentUpon>fMarc_Editor.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\Help_007.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
@@ -588,11 +594,11 @@
|
||||
<Compile Include="마크\Marc_Plan_PrintLabel.Designer.cs">
|
||||
<DependentUpon>Marc_Plan_PrintLabel.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\Marc_Plan_Sub_MarcEdit2.cs">
|
||||
<Compile Include="마크\fMarc_Editor_Spec.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="마크\Marc_Plan_Sub_MarcEdit2.Designer.cs">
|
||||
<DependentUpon>Marc_Plan_Sub_MarcEdit2.cs</DependentUpon>
|
||||
<Compile Include="마크\fMarc_Editor_Spec.Designer.cs">
|
||||
<DependentUpon>fMarc_Editor_Spec.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\Marc_Plan_Sub_MarcEdit.cs">
|
||||
<SubType>Form</SubType>
|
||||
@@ -649,12 +655,6 @@
|
||||
<Compile Include="마크\Search_Infor2.Designer.cs">
|
||||
<DependentUpon>Search_Infor2.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\Search_Infor_Sub.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="마크\Search_Infor_Sub.Designer.cs">
|
||||
<DependentUpon>Search_Infor_Sub.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="마크\SHDocVw.cs" />
|
||||
<Compile Include="마크\ShowDeleteMarc.cs">
|
||||
<SubType>Form</SubType>
|
||||
@@ -1166,6 +1166,9 @@
|
||||
<EmbeddedResource Include="마크\Check_ISBN_Yes242.resx">
|
||||
<DependentUpon>Check_ISBN_Yes242.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\fMarc_Editor.resx">
|
||||
<DependentUpon>fMarc_Editor.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Help_007.resx">
|
||||
<DependentUpon>Help_007.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
@@ -1193,6 +1196,9 @@
|
||||
<EmbeddedResource Include="마크\MarcEditorControl.resx">
|
||||
<DependentUpon>MarcEditorControl.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Marc_CopyForm.resx">
|
||||
<DependentUpon>Marc_CopyForm.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Marc_FillBlank.resx">
|
||||
<DependentUpon>Marc_FillBlank.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
@@ -1262,8 +1268,8 @@
|
||||
<EmbeddedResource Include="마크\Marc_Plan_PrintLabel.resx">
|
||||
<DependentUpon>Marc_Plan_PrintLabel.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Marc_Plan_Sub_MarcEdit2.resx">
|
||||
<DependentUpon>Marc_Plan_Sub_MarcEdit2.cs</DependentUpon>
|
||||
<EmbeddedResource Include="마크\fMarc_Editor_Spec.resx">
|
||||
<DependentUpon>fMarc_Editor_Spec.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Marc_Plan_Sub_MarcEdit.resx">
|
||||
<DependentUpon>Marc_Plan_Sub_MarcEdit.cs</DependentUpon>
|
||||
@@ -1292,9 +1298,6 @@
|
||||
<EmbeddedResource Include="마크\Search_Infor2.resx">
|
||||
<DependentUpon>Search_Infor2.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\Search_Infor_Sub.resx">
|
||||
<DependentUpon>Search_Infor_Sub.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="마크\ShowDeleteMarc.resx">
|
||||
<DependentUpon>ShowDeleteMarc.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
|
||||
@@ -101,10 +101,13 @@ namespace UniMarc
|
||||
|
||||
private void Btn_Memo_Click(object sender, EventArgs e)
|
||||
{
|
||||
Marc_memo memo = new Marc_memo(this);
|
||||
Marc_memo memo = new Marc_memo();
|
||||
memo.StartPosition = FormStartPosition.Manual;
|
||||
memo.TopMost = true;
|
||||
memo.Location = new Point(1018, 8);
|
||||
memo.OnSave += (s1, e1) => {
|
||||
this.richTextBox1.Text = e1.Data;
|
||||
};
|
||||
memo.Show();
|
||||
}
|
||||
|
||||
|
||||
209
unimarc/unimarc/마크/AddMarc2.Designer.cs
generated
209
unimarc/unimarc/마크/AddMarc2.Designer.cs
generated
@@ -30,20 +30,30 @@ namespace UniMarc
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.btn_close = new System.Windows.Forms.Button();
|
||||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
this.btn_Save = new System.Windows.Forms.Button();
|
||||
this.Btn_SearchKolis = new System.Windows.Forms.Button();
|
||||
this.cb_SearchCol = new System.Windows.Forms.ComboBox();
|
||||
this.btn_Empty = new System.Windows.Forms.Button();
|
||||
this.tb_Search = new System.Windows.Forms.TextBox();
|
||||
this.panel2 = new System.Windows.Forms.Panel();
|
||||
this.Btn_SearchKolis = new System.Windows.Forms.Button();
|
||||
this.btn_Empty = new System.Windows.Forms.Button();
|
||||
this.marcEditorControl1 = new MarcEditorControl();
|
||||
this.panel1.SuspendLayout();
|
||||
this.marcEditorControl1 = new UniMarc.MarcEditorControl();
|
||||
this.panel5 = new System.Windows.Forms.Panel();
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.rtEtc1 = new System.Windows.Forms.RichTextBox();
|
||||
this.rtEtc2 = new System.Windows.Forms.RichTextBox();
|
||||
this.panel6 = new System.Windows.Forms.Panel();
|
||||
this.lbl_SaveData = new System.Windows.Forms.Label();
|
||||
this.cb_grade = new System.Windows.Forms.ComboBox();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.panel2.SuspendLayout();
|
||||
this.panel5.SuspendLayout();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.panel6.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// btn_close
|
||||
//
|
||||
this.btn_close.Location = new System.Drawing.Point(1168, 3);
|
||||
this.btn_close.Location = new System.Drawing.Point(102, 156);
|
||||
this.btn_close.Name = "btn_close";
|
||||
this.btn_close.Size = new System.Drawing.Size(77, 23);
|
||||
this.btn_close.TabIndex = 381;
|
||||
@@ -51,19 +61,25 @@ namespace UniMarc
|
||||
this.btn_close.UseVisualStyleBackColor = true;
|
||||
this.btn_close.Click += new System.EventHandler(this.btn_close_Click);
|
||||
//
|
||||
// panel1
|
||||
// btn_Save
|
||||
//
|
||||
this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||
this.panel1.Controls.Add(this.Btn_SearchKolis);
|
||||
this.panel1.Controls.Add(this.cb_SearchCol);
|
||||
this.panel1.Controls.Add(this.btn_Empty);
|
||||
this.panel1.Controls.Add(this.tb_Search);
|
||||
this.panel1.Controls.Add(this.btn_close);
|
||||
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.panel1.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel1.Name = "panel1";
|
||||
this.panel1.Size = new System.Drawing.Size(1324, 32);
|
||||
this.panel1.TabIndex = 393;
|
||||
this.btn_Save.Location = new System.Drawing.Point(19, 185);
|
||||
this.btn_Save.Name = "btn_Save";
|
||||
this.btn_Save.Size = new System.Drawing.Size(77, 23);
|
||||
this.btn_Save.TabIndex = 398;
|
||||
this.btn_Save.Text = "저장(F9)";
|
||||
this.btn_Save.UseVisualStyleBackColor = true;
|
||||
this.btn_Save.Click += new System.EventHandler(this.btn_Save_Click);
|
||||
//
|
||||
// Btn_SearchKolis
|
||||
//
|
||||
this.Btn_SearchKolis.Location = new System.Drawing.Point(102, 185);
|
||||
this.Btn_SearchKolis.Name = "Btn_SearchKolis";
|
||||
this.Btn_SearchKolis.Size = new System.Drawing.Size(77, 23);
|
||||
this.Btn_SearchKolis.TabIndex = 397;
|
||||
this.Btn_SearchKolis.Text = "코리스 검색";
|
||||
this.Btn_SearchKolis.UseVisualStyleBackColor = true;
|
||||
this.Btn_SearchKolis.Click += new System.EventHandler(this.Btn_SearchKolis_Click);
|
||||
//
|
||||
// cb_SearchCol
|
||||
//
|
||||
@@ -74,14 +90,24 @@ namespace UniMarc
|
||||
"서명",
|
||||
"저자",
|
||||
"출판사"});
|
||||
this.cb_SearchCol.Location = new System.Drawing.Point(8, 5);
|
||||
this.cb_SearchCol.Location = new System.Drawing.Point(19, 15);
|
||||
this.cb_SearchCol.Name = "cb_SearchCol";
|
||||
this.cb_SearchCol.Size = new System.Drawing.Size(121, 20);
|
||||
this.cb_SearchCol.TabIndex = 395;
|
||||
//
|
||||
// btn_Empty
|
||||
//
|
||||
this.btn_Empty.Location = new System.Drawing.Point(19, 156);
|
||||
this.btn_Empty.Name = "btn_Empty";
|
||||
this.btn_Empty.Size = new System.Drawing.Size(77, 23);
|
||||
this.btn_Empty.TabIndex = 396;
|
||||
this.btn_Empty.Text = "비 우 기";
|
||||
this.btn_Empty.UseVisualStyleBackColor = true;
|
||||
this.btn_Empty.Click += new System.EventHandler(this.btn_Empty_Click);
|
||||
//
|
||||
// tb_Search
|
||||
//
|
||||
this.tb_Search.Location = new System.Drawing.Point(135, 5);
|
||||
this.tb_Search.Location = new System.Drawing.Point(11, 41);
|
||||
this.tb_Search.Name = "tb_Search";
|
||||
this.tb_Search.Size = new System.Drawing.Size(205, 21);
|
||||
this.tb_Search.TabIndex = 0;
|
||||
@@ -90,41 +116,121 @@ namespace UniMarc
|
||||
// panel2
|
||||
//
|
||||
this.panel2.Controls.Add(this.marcEditorControl1);
|
||||
this.panel2.Controls.Add(this.panel5);
|
||||
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel2.Location = new System.Drawing.Point(0, 32);
|
||||
this.panel2.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel2.Name = "panel2";
|
||||
this.panel2.Size = new System.Drawing.Size(1324, 907);
|
||||
this.panel2.Size = new System.Drawing.Size(1059, 751);
|
||||
this.panel2.TabIndex = 394;
|
||||
//
|
||||
// Btn_SearchKolis
|
||||
//
|
||||
this.Btn_SearchKolis.Location = new System.Drawing.Point(1002, 3);
|
||||
this.Btn_SearchKolis.Name = "Btn_SearchKolis";
|
||||
this.Btn_SearchKolis.Size = new System.Drawing.Size(77, 23);
|
||||
this.Btn_SearchKolis.TabIndex = 397;
|
||||
this.Btn_SearchKolis.Text = "코리스 검색";
|
||||
this.Btn_SearchKolis.UseVisualStyleBackColor = true;
|
||||
this.Btn_SearchKolis.Click += new System.EventHandler(this.Btn_SearchKolis_Click);
|
||||
//
|
||||
// btn_Empty
|
||||
//
|
||||
this.btn_Empty.Location = new System.Drawing.Point(1085, 3);
|
||||
this.btn_Empty.Name = "btn_Empty";
|
||||
this.btn_Empty.Size = new System.Drawing.Size(77, 23);
|
||||
this.btn_Empty.TabIndex = 396;
|
||||
this.btn_Empty.Text = "비 우 기";
|
||||
this.btn_Empty.UseVisualStyleBackColor = true;
|
||||
this.btn_Empty.Click += new System.EventHandler(this.btn_Empty_Click);
|
||||
//
|
||||
// marcEditorControl1
|
||||
//
|
||||
this.marcEditorControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.marcEditorControl1.Font = new System.Drawing.Font("돋움", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.marcEditorControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.marcEditorControl1.Name = "marcEditorControl1";
|
||||
this.marcEditorControl1.Size = new System.Drawing.Size(1324, 907);
|
||||
this.marcEditorControl1.Size = new System.Drawing.Size(793, 751);
|
||||
this.marcEditorControl1.TabIndex = 394;
|
||||
//
|
||||
// panel5
|
||||
//
|
||||
this.panel5.Controls.Add(this.tableLayoutPanel1);
|
||||
this.panel5.Controls.Add(this.panel6);
|
||||
this.panel5.Dock = System.Windows.Forms.DockStyle.Right;
|
||||
this.panel5.Location = new System.Drawing.Point(793, 0);
|
||||
this.panel5.Name = "panel5";
|
||||
this.panel5.Size = new System.Drawing.Size(266, 751);
|
||||
this.panel5.TabIndex = 395;
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 1;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.rtEtc1, 0, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.rtEtc2, 0, 1);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 308);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(266, 443);
|
||||
this.tableLayoutPanel1.TabIndex = 0;
|
||||
//
|
||||
// rtEtc1
|
||||
//
|
||||
this.rtEtc1.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.rtEtc1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.rtEtc1.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.rtEtc1.Location = new System.Drawing.Point(3, 3);
|
||||
this.rtEtc1.Name = "rtEtc1";
|
||||
this.rtEtc1.Size = new System.Drawing.Size(260, 215);
|
||||
this.rtEtc1.TabIndex = 32;
|
||||
this.rtEtc1.Text = "Remark1";
|
||||
//
|
||||
// rtEtc2
|
||||
//
|
||||
this.rtEtc2.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.rtEtc2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.rtEtc2.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.rtEtc2.Location = new System.Drawing.Point(3, 224);
|
||||
this.rtEtc2.Name = "rtEtc2";
|
||||
this.rtEtc2.Size = new System.Drawing.Size(260, 216);
|
||||
this.rtEtc2.TabIndex = 32;
|
||||
this.rtEtc2.Text = "Remark2";
|
||||
//
|
||||
// panel6
|
||||
//
|
||||
this.panel6.Controls.Add(this.tb_Search);
|
||||
this.panel6.Controls.Add(this.cb_SearchCol);
|
||||
this.panel6.Controls.Add(this.btn_Save);
|
||||
this.panel6.Controls.Add(this.Btn_SearchKolis);
|
||||
this.panel6.Controls.Add(this.lbl_SaveData);
|
||||
this.panel6.Controls.Add(this.cb_grade);
|
||||
this.panel6.Controls.Add(this.label6);
|
||||
this.panel6.Controls.Add(this.btn_Empty);
|
||||
this.panel6.Controls.Add(this.btn_close);
|
||||
this.panel6.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.panel6.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel6.Name = "panel6";
|
||||
this.panel6.Size = new System.Drawing.Size(266, 308);
|
||||
this.panel6.TabIndex = 1;
|
||||
//
|
||||
// lbl_SaveData
|
||||
//
|
||||
this.lbl_SaveData.AutoSize = true;
|
||||
this.lbl_SaveData.Font = new System.Drawing.Font("굴림체", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.lbl_SaveData.ForeColor = System.Drawing.Color.PaleTurquoise;
|
||||
this.lbl_SaveData.Location = new System.Drawing.Point(32, 119);
|
||||
this.lbl_SaveData.Name = "lbl_SaveData";
|
||||
this.lbl_SaveData.Size = new System.Drawing.Size(64, 19);
|
||||
this.lbl_SaveData.TabIndex = 319;
|
||||
this.lbl_SaveData.Text = "[] []";
|
||||
//
|
||||
// cb_grade
|
||||
//
|
||||
this.cb_grade.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cb_grade.FormattingEnabled = true;
|
||||
this.cb_grade.Items.AddRange(new object[] {
|
||||
"A (F9)",
|
||||
"B (F10)",
|
||||
"C (F11)",
|
||||
"D (F12)"});
|
||||
this.cb_grade.Location = new System.Drawing.Point(19, 96);
|
||||
this.cb_grade.Name = "cb_grade";
|
||||
this.cb_grade.Size = new System.Drawing.Size(75, 20);
|
||||
this.cb_grade.TabIndex = 222;
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.label6.Location = new System.Drawing.Point(16, 78);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(62, 12);
|
||||
this.label6.TabIndex = 223;
|
||||
this.label6.Text = "마크 등급";
|
||||
//
|
||||
// AddMarc2
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
@@ -132,26 +238,35 @@ namespace UniMarc
|
||||
this.BackColor = System.Drawing.Color.Gray;
|
||||
this.ClientSize = new System.Drawing.Size(1324, 939);
|
||||
this.Controls.Add(this.panel2);
|
||||
this.Controls.Add(this.panel1);
|
||||
this.Name = "AddMarc2";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "마크 작성(2-New)";
|
||||
this.Load += new System.EventHandler(this.AddMarc_Load);
|
||||
this.panel1.ResumeLayout(false);
|
||||
this.panel1.PerformLayout();
|
||||
this.panel2.ResumeLayout(false);
|
||||
this.panel5.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.panel6.ResumeLayout(false);
|
||||
this.panel6.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
private System.Windows.Forms.Button btn_close;
|
||||
private System.Windows.Forms.Panel panel1;
|
||||
private System.Windows.Forms.Panel panel2;
|
||||
private System.Windows.Forms.TextBox tb_Search;
|
||||
private System.Windows.Forms.ComboBox cb_SearchCol;
|
||||
private System.Windows.Forms.Button btn_Empty;
|
||||
private System.Windows.Forms.Button Btn_SearchKolis;
|
||||
private MarcEditorControl marcEditorControl1;
|
||||
private System.Windows.Forms.Button btn_Save;
|
||||
private System.Windows.Forms.Panel panel5;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
public System.Windows.Forms.RichTextBox rtEtc1;
|
||||
public System.Windows.Forms.RichTextBox rtEtc2;
|
||||
private System.Windows.Forms.Panel panel6;
|
||||
private System.Windows.Forms.Label lbl_SaveData;
|
||||
private System.Windows.Forms.ComboBox cb_grade;
|
||||
private System.Windows.Forms.Label label6;
|
||||
}
|
||||
}
|
||||
@@ -18,6 +18,7 @@ namespace UniMarc
|
||||
String_Text st = new String_Text();
|
||||
Help008Tag tag008 = new Help008Tag();
|
||||
private string mOldMarc = string.Empty;
|
||||
private MacEditorParameter _param;
|
||||
Main m;
|
||||
public AddMarc2(Main _m)
|
||||
{
|
||||
@@ -32,42 +33,48 @@ namespace UniMarc
|
||||
TextReset();
|
||||
|
||||
marcEditorControl1.db = this.db;
|
||||
marcEditorControl1.BookSaved += MarcEditorControl1_BookSaved;
|
||||
marcEditorControl1.CloseButton += (s1,e1)=> { this.Close(); };
|
||||
marcEditorControl1.SetButtonKolist(false);
|
||||
marcEditorControl1.SetButtonNext(false);
|
||||
marcEditorControl1.SetButtonPrev(false);
|
||||
this.KeyPreview = true;
|
||||
}
|
||||
|
||||
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
|
||||
{
|
||||
if (keyData == Keys.F9)
|
||||
{
|
||||
btn_Save_Click(this, EventArgs.Empty);
|
||||
return true;
|
||||
}
|
||||
return base.ProcessCmdKey(ref msg, keyData);
|
||||
}
|
||||
public void SetKolisValueApply(string marc)
|
||||
{
|
||||
this.marcEditorControl1.SetMarcString(marc);
|
||||
}
|
||||
private void MarcEditorControl1_BookSaved(object sender, MarcEditorControl.BookSavedEventArgs e)
|
||||
private void btn_Save_Click(object sender, EventArgs e)
|
||||
{
|
||||
string tag056 = Tag056(e.DBMarc, e.Param);
|
||||
if (marcEditorControl1.CheckValidation() == false) return;
|
||||
|
||||
string dbMarc = marcEditorControl1.MakeMarcString();
|
||||
|
||||
string tag056 = Tag056(dbMarc, _param);
|
||||
string date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
string orimarc = st.made_Ori_marc(e.DBMarc).Replace(@"\", "₩");
|
||||
string orimarc = st.made_Ori_marc(dbMarc).Replace(@"\", "₩");
|
||||
|
||||
if (!isMustTag(orimarc))
|
||||
{
|
||||
|
||||
return;
|
||||
}
|
||||
var MarcText = e.DBMarc;
|
||||
var MarcText = dbMarc;
|
||||
string midx = this.lbl_Midx;
|
||||
string[] BookData = GetBookData(MarcText);
|
||||
bool IsCoverDate = false;
|
||||
|
||||
if (e.Param.SaveDate != "")
|
||||
if (_param != null && _param.SaveDate != "")
|
||||
{
|
||||
// 마지막 수정일로부터 2일이 지났는지, 마지막 저장자가 사용자인지 확인
|
||||
TimeSpan sp = CheckDate(e.Param.SaveDate, date);
|
||||
IsCoverDate = IsCoverData(sp.Days, e.Param.User);
|
||||
//if (IsCoverDate)
|
||||
// etc2.Text = etc2.Text.Replace(SaveData[0], date);
|
||||
TimeSpan sp = CheckDate(_param.SaveDate, date);
|
||||
IsCoverDate = IsCoverData(sp.Days, _param.User);
|
||||
}
|
||||
//else
|
||||
// etc2.Text += string.Format("{0}\t{1}\n", date, mUserName);
|
||||
|
||||
string Table = "Marc";
|
||||
bool isUpdate;
|
||||
if (lbl_Midx != "")
|
||||
@@ -75,16 +82,21 @@ namespace UniMarc
|
||||
else
|
||||
isUpdate = false;
|
||||
|
||||
var grade = int.Parse(e.Param.Grade);
|
||||
var grade = this.cb_grade.SelectedIndex;// int.Parse(param.Grade);
|
||||
|
||||
if (isUpdate)
|
||||
UpdateMarc(Table, midx, orimarc, grade, tag056, date, IsCoverDate,e.Param);
|
||||
UpdateMarc(Table, midx, orimarc, grade, tag056, date, IsCoverDate, _param);
|
||||
else
|
||||
InsertMarc(Table, BookData, orimarc, grade, tag056, date, e.Param);
|
||||
InsertMarc(Table, BookData, orimarc, grade, tag056, date, _param);
|
||||
|
||||
MessageBox.Show("저장되었습니다.", "저장");
|
||||
}
|
||||
|
||||
private void MarcEditorControl1_BookSaved(object sender, EventArgs e)
|
||||
{
|
||||
// Removed - logic moved to btn_Save_Click
|
||||
}
|
||||
|
||||
|
||||
private void tb_ISBN_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
@@ -115,15 +127,15 @@ namespace UniMarc
|
||||
/// 6:LineMarc</param>
|
||||
public void SelectMarc_Sub(string Marc, string ISBN, string[] GridData)
|
||||
{
|
||||
this.marcEditorControl1.LoadBookData(Marc, new MacEditorParameter
|
||||
_param = new MacEditorParameter
|
||||
{
|
||||
ISBN13 = ISBN,
|
||||
SaveDate = string.Format("[{0}] [{1}]", GridData[2], GridData[3]),
|
||||
Grade = GridData[4],
|
||||
Remark1 = string.Empty,
|
||||
Remark2 = string.Empty,
|
||||
NewMake = true
|
||||
});
|
||||
User = GridData[2],
|
||||
NewMake = true,
|
||||
text008 = GridData[5]
|
||||
};
|
||||
this.marcEditorControl1.LoadBookData(Marc, ISBN);
|
||||
mOldMarc = GridData[6];
|
||||
lbl_Midx = GridData[0];
|
||||
}
|
||||
@@ -149,14 +161,14 @@ namespace UniMarc
|
||||
{
|
||||
if (isDelete)
|
||||
{
|
||||
marcEditorControl1.LoadBookData(string.Empty, new MacEditorParameter
|
||||
var emptymarc = TextResetSub();
|
||||
_param = new MacEditorParameter
|
||||
{
|
||||
ISBN13 = string.Empty,
|
||||
SaveDate = string.Empty,
|
||||
Remark1 = string.Empty,
|
||||
Remark2 = string.Empty,
|
||||
NewMake=true,
|
||||
});
|
||||
NewMake = true,
|
||||
};
|
||||
marcEditorControl1.LoadBookData(emptymarc, string.Empty);
|
||||
}
|
||||
|
||||
|
||||
@@ -202,7 +214,7 @@ namespace UniMarc
|
||||
"700\t \t▼a▲\n" +
|
||||
"950\t \t▼b▲\n");
|
||||
|
||||
this.marcEditorControl1.SetRemark(string.Empty, string.Empty);
|
||||
|
||||
return Empty_text;
|
||||
}
|
||||
|
||||
@@ -221,6 +233,8 @@ namespace UniMarc
|
||||
/// <param name="IsCovertDate">덮어씌울지 유무</param>
|
||||
void UpdateMarc(string Table, string MarcIndex, string oriMarc, int grade, string tag056, string date, bool IsCovertDate, MacEditorParameter param)
|
||||
{
|
||||
var etc1 = rtEtc1.Text.Trim();
|
||||
var etc2 = rtEtc2.Text.Trim();
|
||||
string[] EditTable =
|
||||
{
|
||||
"compidx", "marc", "marc_chk","marc1", "marc_chk1", "비고1",
|
||||
@@ -229,8 +243,8 @@ namespace UniMarc
|
||||
};
|
||||
string[] EditColumn =
|
||||
{
|
||||
PUB.user.CompanyIdx, oriMarc, "1",mOldMarc, "0", param.Remark1,
|
||||
param.Remark2, tag056, param.text008, date, PUB.user.UserName,
|
||||
PUB.user.CompanyIdx, oriMarc, "1",mOldMarc, "0", etc1,
|
||||
etc2, tag056, param.text008, date, PUB.user.UserName,
|
||||
grade.ToString()
|
||||
};
|
||||
string[] SearchTable = { "idx", "compidx" };
|
||||
@@ -279,16 +293,20 @@ namespace UniMarc
|
||||
/// <param name="date">저장시각 yyyy-MM-dd HH:mm:ss</param>
|
||||
void InsertMarc(string Table, string[] BookData, string oriMarc, int grade, string tag056, string date, MacEditorParameter param)
|
||||
{
|
||||
var etc1 = rtEtc1.Text.Trim();
|
||||
var etc2 = rtEtc2.Text.Trim();
|
||||
string[] InsertTable =
|
||||
{
|
||||
"ISBN", "서명", "저자", "출판사", "가격",
|
||||
"marc", "비고1", "비고2", "grade", "marc_chk",
|
||||
"user", "division", "008tag", "date", "compidx"
|
||||
};
|
||||
|
||||
|
||||
string[] InsertColumn =
|
||||
{
|
||||
BookData[0], BookData[1], BookData[2], BookData[3], BookData[4],
|
||||
oriMarc, param.Remark1, param.Remark2, grade.ToString(), "1",
|
||||
oriMarc, etc1, etc2, grade.ToString(), "1",
|
||||
PUB.user.UserName, tag056, param.text008, date, PUB.user.CompanyIdx
|
||||
};
|
||||
|
||||
|
||||
@@ -7,7 +7,6 @@ namespace UniMarc
|
||||
public string ISBN13 { get; set; }
|
||||
public string URL { get; set; }
|
||||
public string MarcIdx { get; set; }
|
||||
public string Grade { get; set; }
|
||||
public string User { get; set; }
|
||||
public string SaveDate { get; set; }
|
||||
public string ListIdx { get; set; }
|
||||
@@ -17,9 +16,7 @@ namespace UniMarc
|
||||
public string Publisher { get; set; }
|
||||
public string Price { get; set; }
|
||||
|
||||
public string Remark1 { get; set; }
|
||||
public string Remark2 { get; set; }
|
||||
|
||||
|
||||
public string text008 { get; set; }
|
||||
public string tag056 { get; set; }
|
||||
public bool NewMake { get; set; }
|
||||
|
||||
@@ -403,10 +403,13 @@ namespace UniMarc
|
||||
}
|
||||
private void Btn_Memo_Click(object sender, EventArgs e)
|
||||
{
|
||||
Marc_memo memo = new Marc_memo(this);
|
||||
Marc_memo memo = new Marc_memo();
|
||||
memo.StartPosition = FormStartPosition.Manual;
|
||||
memo.TopMost = true;
|
||||
memo.Location = new Point(1018, 8);
|
||||
memo.OnSave += (s1,e1) => {
|
||||
richTextBox1.Text = e1.Data;
|
||||
};
|
||||
memo.Show();
|
||||
}
|
||||
private void Btn_preview_Click(object sender, EventArgs e)
|
||||
@@ -1300,9 +1303,9 @@ namespace UniMarc
|
||||
{
|
||||
int row = List_Book.CurrentCell.RowIndex;
|
||||
|
||||
Zoom_Picture zp = new Zoom_Picture();
|
||||
zp.url = pictureBox1.ImageLocation;
|
||||
zp.ISBN = List_Book.Rows[row].Cells["ISBN13"].Value.ToString();
|
||||
var url = pictureBox1.ImageLocation;
|
||||
var isbn = List_Book.Rows[row].Cells["ISBN13"].Value.ToString();
|
||||
Zoom_Picture zp = new Zoom_Picture(url, isbn);
|
||||
zp.Show();
|
||||
}
|
||||
|
||||
|
||||
@@ -11,8 +11,10 @@ using System.Net;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls.WebParts;
|
||||
using System.Windows.Forms;
|
||||
using UniMarc.ListOfValue;
|
||||
using static UniMarc.MarcEditorControl;
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
@@ -40,6 +42,7 @@ namespace UniMarc
|
||||
String_Text st = new String_Text();
|
||||
Mac_List ml;
|
||||
public SortableBindingList<MarcBookItem> dataList = new SortableBindingList<MarcBookItem>();
|
||||
public MacEditorParameter Param;
|
||||
MacListItem pItem = null;
|
||||
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
|
||||
{
|
||||
@@ -67,11 +70,6 @@ namespace UniMarc
|
||||
ml = _ml;
|
||||
mUserName = PUB.user.UserName;
|
||||
marcEditorControl1.db = this.db;
|
||||
marcEditorControl1.BookSaved += MarcEditorControl_BookSaved;
|
||||
marcEditorControl1.FillBlankClicked += MarcEditorControl_FillBlankClicked;
|
||||
marcEditorControl1.PrevButton += MarcEditorControl1_PrevButton;
|
||||
marcEditorControl1.NextButton += MarcEditorControl1_NextButton;
|
||||
marcEditorControl1.CloseButton += (s1, e1) => { this.Close(); };
|
||||
}
|
||||
|
||||
|
||||
@@ -380,11 +378,10 @@ namespace UniMarc
|
||||
string listIdx = List_Book.Rows[row_idx].Cells["list_idx"].Value?.ToString() ?? ""; // verify this column name in input_list
|
||||
this.lbListIdx.Text = $"Row:{SaveRowIdx},List:{listIdx}";
|
||||
var remark = ReadRemark(row_idx);
|
||||
var p = new MacEditorParameter
|
||||
this.Param = new MacEditorParameter
|
||||
{
|
||||
ISBN13 = isbn13,
|
||||
URL = url,
|
||||
Grade = grade,
|
||||
ListIdx = listIdx,
|
||||
MarcIdx = marcIdx,
|
||||
SaveDate = saveDate,
|
||||
@@ -393,11 +390,40 @@ namespace UniMarc
|
||||
Author = author,
|
||||
Publisher = publisher,
|
||||
Price = price,
|
||||
Remark1 = remark.remark1,
|
||||
Remark2 = remark.remark2,
|
||||
OriginalMarc = dbMarc,
|
||||
};
|
||||
marcEditorControl1.LoadBookData(dbMarc, p);
|
||||
var defMarc = PUB.MakeEmptyMarc(isbn13, bookName, author, publisher, price);
|
||||
marcEditorControl1.LoadBookData(dbMarc, isbn13, defMarc);
|
||||
|
||||
//등급선택 (dbMarc 데이터를 확인하여. 등급을 결정한다)
|
||||
int gradeNo;
|
||||
bool check_Marc = dbMarc.Length >= 3;
|
||||
if (!check_Marc)
|
||||
{
|
||||
//richTextBox1.Text = Make_Empty();
|
||||
gradeNo = 3; //마크가 없는것은 D등급으로 한다
|
||||
}
|
||||
else
|
||||
{
|
||||
etc1.Text = remark.remark1;
|
||||
etc2.Text = remark.remark2;
|
||||
|
||||
//자료의 등급 다시 선택
|
||||
if (int.TryParse(grade, out gradeNo) == false)
|
||||
gradeNo = 2;
|
||||
}
|
||||
|
||||
if (gradeNo == 0 )
|
||||
radA.Checked = true;
|
||||
else if(gradeNo == 1)
|
||||
radB.Checked = true;
|
||||
else if(gradeNo == 3)
|
||||
radD.Checked = true;
|
||||
else
|
||||
radC.Checked = true;
|
||||
|
||||
lbl_SaveData.Text = $"[{user}] [{saveDate}]";
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -535,58 +561,6 @@ namespace UniMarc
|
||||
}
|
||||
}
|
||||
|
||||
private void MarcEditorControl_BookSaved(object sender, MarcEditorControl.BookSavedEventArgs e)
|
||||
{
|
||||
// [신규 방식: 데이터 객체(Item) 중심 로직]
|
||||
var item = this.dataList.Where(t => t.ListIdx == e.Param.ListIdx).FirstOrDefault();
|
||||
if (item == null) return;
|
||||
|
||||
string table_name = "Marc";
|
||||
string date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
string newsavedMarc = e.DBMarc;
|
||||
//string Midx = item.MarcIdx;
|
||||
|
||||
// 1. DB 작업 (저장 전략 결정: Status 기준)
|
||||
if (item.Status == MarcRecordStatus.OtherCompany || item.Status == MarcRecordStatus.None)
|
||||
{
|
||||
string[] Insert_tbl = { "ISBN", "서명", "저자", "출판사", "가격", "marc", "비고1", "비고2", "url", "grade", "marc_chk", "user", "division", "008tag", "date", "compidx" };
|
||||
string[] Insert_col = { e.Param.ISBN13, e.Param.BookName, e.Param.Author, e.Param.Publisher, e.Param.Price, newsavedMarc, e.Param.Remark1, e.Param.Remark2, e.Param.URL, e.Param.Grade, "1", mUserName, e.Param.tag056, e.Param.text008, date, mCompidx };
|
||||
|
||||
string Incmd = db.DB_INSERT(table_name, Insert_tbl, Insert_col);
|
||||
PUB.log.Add("INSERT", string.Format("{0}({1},{2}) : {3}", mUserName, mCompidx, item.Status, Incmd));
|
||||
|
||||
long newIdx = db.DB_Send_CMD_Insert_GetIdx(Incmd);
|
||||
if (newIdx > 0)
|
||||
{
|
||||
item.MarcIdx = newIdx.ToString();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
string[] Edit_tbl = { "compidx", "marc", "marc_chk", "marc1", "marc_chk1", "비고1", "비고2", "url", "division", "008tag", "date", "user", "grade" };
|
||||
string[] Edit_col = { mCompidx, newsavedMarc, "1", e.Param.OriginalMarc, "0", e.Param.Remark1, e.Param.Remark2, e.Param.URL, e.Param.tag056, e.Param.text008, date, mUserName, e.Param.Grade };
|
||||
string[] Sear_tbl = { "idx", "compidx" };
|
||||
string[] Sear_col = { item.MarcIdx, mCompidx };
|
||||
|
||||
if (string.IsNullOrEmpty(e.Param.ISBN13)) { MessageBox.Show("ISBN 데이터가 없습니다."); return; }
|
||||
|
||||
string U_cmd = db.More_Update(table_name, Edit_tbl, Edit_col, Sear_tbl, Sear_col);
|
||||
PUB.log.Add("Update", string.Format("{0}({1},{2}) : {3}", mUserName, mCompidx, item.Status, U_cmd.Replace("\r", " ").Replace("\n", " ")));
|
||||
Helper_DB.ExcuteNonQuery(U_cmd);
|
||||
}
|
||||
|
||||
// 2. 객체 데이터 업데이트 및 시각적 상태 계산
|
||||
item.Status = MarcRecordStatus.MyCompany;
|
||||
item.BackColor = GetSaveDateColor(date);
|
||||
|
||||
// 3. 목록 인덱스 연동 업데이트 (Obj_List_Book)
|
||||
string UpdateListIndex = string.Format("UPDATE `Obj_List_Book` SET `m_idx` = {0} WHERE `idx` = {1} AND `compidx` ={2};", item.MarcIdx, item.ListIdx, mCompidx);
|
||||
Helper_DB.ExcuteNonQuery(UpdateListIndex);
|
||||
|
||||
// 4. BindingSource 갱신으로 UI 자동 업데이트
|
||||
bs1.ResetCurrentItem();
|
||||
MessageBox.Show("저장되었습니다!");
|
||||
}
|
||||
|
||||
#region Save_Click_Sub
|
||||
|
||||
@@ -619,62 +593,7 @@ namespace UniMarc
|
||||
|
||||
private void MarcEditorControl_FillBlankClicked(object sender, EventArgs e)
|
||||
{
|
||||
if (List_Book.CurrentRow == null) return;
|
||||
int row = List_Book.CurrentRow.Index;
|
||||
string ISBN = List_Book.Rows[row].Cells["ISBN13"].Value?.ToString();
|
||||
|
||||
if (string.IsNullOrEmpty(ISBN))
|
||||
{
|
||||
MessageBox.Show("ISBN이 존재하지않습니다!");
|
||||
return;
|
||||
}
|
||||
|
||||
var fb = new Marc_FillBlank();
|
||||
for (int a = 0; a < bs1.Count; a++)
|
||||
{
|
||||
var item = bs1.List[a] as MarcBookItem;
|
||||
if (item != null && item.Status == MarcRecordStatus.None)
|
||||
{
|
||||
var fbItem = new FillBlankItem
|
||||
{
|
||||
Idx = item.ListIdx,
|
||||
Isbn = item.ISBN13 ?? "",
|
||||
BookName = item.BookName ?? "",
|
||||
Author = item.Author ?? "",
|
||||
Publisher = item.BookComp ?? "",
|
||||
Price = item.Pay ?? ""
|
||||
};
|
||||
fb.InitFillBlank(fbItem);
|
||||
}
|
||||
}
|
||||
fb.ISBN = ISBN;
|
||||
if (fb.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
String_Text st = new String_Text();
|
||||
if (fb.FillBlankItems.Any(t => !string.IsNullOrEmpty(t.BookMarc)))
|
||||
{
|
||||
foreach (var fbItem in fb.FillBlankItems)
|
||||
{
|
||||
if (string.IsNullOrEmpty(fbItem.BookMarc)) continue;
|
||||
|
||||
int targetListIdx = int.Parse(fbItem.Idx);
|
||||
foreach (MarcBookItem item in this.dataList)
|
||||
{
|
||||
if (item.ListIdx != null && Convert.ToInt32(item.ListIdx) == targetListIdx)
|
||||
{
|
||||
item.DbMarc = fbItem.BookMarc;
|
||||
item.Status = MarcRecordStatus.NewFetched;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(fb.SingleMarcResult))
|
||||
{
|
||||
// Update current Editor
|
||||
marcEditorControl1.SetMarcString(fb.SingleMarcResult);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -890,6 +809,34 @@ namespace UniMarc
|
||||
if (UTIL.MsgQ("현재 화면을 닫을까요?") != DialogResult.Yes) return;
|
||||
this.Close();
|
||||
}
|
||||
else
|
||||
SaveGrade(e.KeyCode);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// F9~F12로 등급별 저장
|
||||
/// </summary>
|
||||
/// <param name="key">F9~F12</param>
|
||||
private void SaveGrade(Keys key)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case Keys.F9:
|
||||
radA.Checked = true;// cb_grade.SelectedIndex = 0;// = "A (F9)";
|
||||
break;
|
||||
case Keys.F10:
|
||||
radB.Checked = true;// cb_grade.SelectedIndex = 1;// = "B (F10)";
|
||||
//Btn_Save_Click(null, null);
|
||||
break;
|
||||
case Keys.F11:
|
||||
radC.Checked = true;// cb_grade.SelectedIndex = 2;// = "C (F11)";
|
||||
//Btn_Save_Click(null, null);
|
||||
break;
|
||||
case Keys.F12:
|
||||
radD.Checked = true;// cb_grade.SelectedIndex = 3;//.SelectedItem = "D (F12)";
|
||||
//Btn_Save_Click(null, null);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
@@ -978,5 +925,188 @@ namespace UniMarc
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void btn_close_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
|
||||
private void btPrev_Click(object sender, EventArgs e)
|
||||
{
|
||||
bs1.MovePrevious();
|
||||
}
|
||||
|
||||
private void btNext_Click(object sender, EventArgs e)
|
||||
{
|
||||
bs1.MoveNext();
|
||||
}
|
||||
|
||||
private void button2_Click(object sender, EventArgs e)
|
||||
{
|
||||
marcEditorControl1.Tag056(); // 008 태그가 richTextBox1에 포함되도록 갱신
|
||||
var orimarc = st.made_Ori_marc(marcEditorControl1.richTextBox1).Replace(@"\", "₩");
|
||||
var fb = new Marc_CopyForm( orimarc);
|
||||
fb.ShowDialog();
|
||||
}
|
||||
|
||||
private void btn_Save_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Param.NewMake == false && string.IsNullOrEmpty(Param.ISBN13))
|
||||
{
|
||||
MessageBox.Show("마크가 선택되지않았습니다.");
|
||||
return;
|
||||
}
|
||||
|
||||
// 중앙 집중식 유효성 검사 수행
|
||||
if (!marcEditorControl1.CheckValidation())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
var v_isbn = marcEditorControl1.lbl_ISBN.Text.Trim();
|
||||
|
||||
// ISBN 중복체크
|
||||
var exist = DB_Utils.ExistISBN(v_isbn);
|
||||
if (exist)
|
||||
{
|
||||
if (UTIL.MsgQ($"입력하신 ISBN({v_isbn})은 이미 등록된 데이터가 존재합니다.\n그래도 저장하시겠습니까?") != DialogResult.Yes)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
string date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
string orimarc = marcEditorControl1.MakeMarcString();// st.made_Ori_marc(marcEditorControl1.richTextBox1).Replace(@"\", "₩");
|
||||
|
||||
|
||||
|
||||
this.Param.text008 = marcEditorControl1.text008.Text.Trim();
|
||||
this.Param.tag056 = marcEditorControl1.Tag056();
|
||||
|
||||
|
||||
//아래는 실제 폼에서의 저장코드
|
||||
// [신규 방식: 데이터 객체(Item) 중심 로직]
|
||||
var item = this.dataList.Where(t => t.ListIdx == this.Param.ListIdx).FirstOrDefault();
|
||||
if (item == null) return;
|
||||
|
||||
string table_name = "Marc";
|
||||
string newsavedMarc = orimarc;
|
||||
var v_grade = "";// cb_grade.SelectedIndex.ToString(); // 등급은 0~3의 숫자로 저장된다고 가정
|
||||
if(radA.Checked) v_grade = "0";
|
||||
else if(radB.Checked) v_grade = "1";
|
||||
else if(radC.Checked) v_grade = "2";
|
||||
else if(radD.Checked) v_grade = "3";
|
||||
|
||||
var v_etc1 = this.etc1.Text.Trim();
|
||||
var v_etc2 = this.etc2.Text.Trim();
|
||||
|
||||
// 1. DB 작업 (저장 전략 결정: Status 기준)
|
||||
if (item.Status == MarcRecordStatus.OtherCompany || item.Status == MarcRecordStatus.None)
|
||||
{
|
||||
string[] Insert_tbl = { "ISBN", "서명", "저자", "출판사", "가격", "marc", "비고1", "비고2", "url", "grade", "marc_chk", "user", "division", "008tag", "date", "compidx" };
|
||||
string[] Insert_col = { this.Param.ISBN13, this.Param.BookName, this.Param.Author, this.Param.Publisher, this.Param.Price, newsavedMarc, this.etc1.Text, this.etc2.Text, this.Param.URL, v_grade, "1", mUserName, this.Param.tag056, this.Param.text008, date, mCompidx };
|
||||
|
||||
string Incmd = db.DB_INSERT(table_name, Insert_tbl, Insert_col);
|
||||
PUB.log.Add("INSERT", string.Format("{0}({1},{2}) : {3}", mUserName, mCompidx, item.Status, Incmd));
|
||||
|
||||
long newIdx = db.DB_Send_CMD_Insert_GetIdx(Incmd);
|
||||
if (newIdx > 0)
|
||||
{
|
||||
item.MarcIdx = newIdx.ToString();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
string[] Edit_tbl = { "compidx", "marc", "marc_chk", "marc1", "marc_chk1", "비고1", "비고2", "url", "division", "008tag", "date", "user", "grade" };
|
||||
string[] Edit_col = { mCompidx, newsavedMarc, "1", this.Param.OriginalMarc, "0", v_etc1, v_etc2, this.Param.URL, this.Param.tag056, this.Param.text008, date, mUserName, v_grade };
|
||||
string[] Sear_tbl = { "idx", "compidx" };
|
||||
string[] Sear_col = { item.MarcIdx, mCompidx };
|
||||
|
||||
if (string.IsNullOrEmpty(this.Param.ISBN13)) { MessageBox.Show("ISBN 데이터가 없습니다."); return; }
|
||||
|
||||
string U_cmd = db.More_Update(table_name, Edit_tbl, Edit_col, Sear_tbl, Sear_col);
|
||||
PUB.log.Add("Update", string.Format("{0}({1},{2}) : {3}", mUserName, mCompidx, item.Status, U_cmd.Replace("\r", " ").Replace("\n", " ")));
|
||||
Helper_DB.ExcuteNonQuery(U_cmd);
|
||||
}
|
||||
|
||||
|
||||
// 2. 객체 데이터 업데이트 및 시각적 상태 계산
|
||||
item.Status = MarcRecordStatus.MyCompany;
|
||||
item.BackColor = GetSaveDateColor(date);
|
||||
|
||||
// 3. 목록 인덱스 연동 업데이트 (Obj_List_Book)
|
||||
string UpdateListIndex = string.Format("UPDATE `Obj_List_Book` SET `m_idx` = {0} WHERE `idx` = {1} AND `compidx` ={2};", item.MarcIdx, item.ListIdx, mCompidx);
|
||||
Helper_DB.ExcuteNonQuery(UpdateListIndex);
|
||||
|
||||
// 4. BindingSource 갱신으로 UI 자동 업데이트
|
||||
bs1.ResetCurrentItem();
|
||||
MessageBox.Show("저장되었습니다!");
|
||||
}
|
||||
|
||||
private void btn_FillBlank_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (List_Book.CurrentRow == null) return;
|
||||
int row = List_Book.CurrentRow.Index;
|
||||
string ISBN = List_Book.Rows[row].Cells["ISBN13"].Value?.ToString();
|
||||
|
||||
if (string.IsNullOrEmpty(ISBN))
|
||||
{
|
||||
MessageBox.Show("ISBN이 존재하지않습니다!");
|
||||
return;
|
||||
}
|
||||
|
||||
var fb = new Marc_FillBlank();
|
||||
for (int a = 0; a < bs1.Count; a++)
|
||||
{
|
||||
var item = bs1.List[a] as MarcBookItem;
|
||||
if (item != null && item.Status == MarcRecordStatus.None)
|
||||
{
|
||||
var fbItem = new FillBlankItem
|
||||
{
|
||||
Idx = item.ListIdx,
|
||||
Isbn = item.ISBN13 ?? "",
|
||||
BookName = item.BookName ?? "",
|
||||
Author = item.Author ?? "",
|
||||
Publisher = item.BookComp ?? "",
|
||||
Price = item.Pay ?? ""
|
||||
};
|
||||
fb.InitFillBlank(fbItem);
|
||||
}
|
||||
}
|
||||
fb.ISBN = ISBN;
|
||||
if (fb.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
String_Text st = new String_Text();
|
||||
if (fb.FillBlankItems.Any(t => !string.IsNullOrEmpty(t.BookMarc)))
|
||||
{
|
||||
foreach (var fbItem in fb.FillBlankItems)
|
||||
{
|
||||
if (string.IsNullOrEmpty(fbItem.BookMarc)) continue;
|
||||
|
||||
int targetListIdx = int.Parse(fbItem.Idx);
|
||||
foreach (MarcBookItem item in this.dataList)
|
||||
{
|
||||
if (item.ListIdx != null && Convert.ToInt32(item.ListIdx) == targetListIdx)
|
||||
{
|
||||
item.DbMarc = fbItem.BookMarc;
|
||||
item.Status = MarcRecordStatus.NewFetched;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(fb.SingleMarcResult))
|
||||
{
|
||||
// Update current Editor
|
||||
marcEditorControl1.SetMarcString(fb.SingleMarcResult);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void panel6_Paint(object sender, PaintEventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
936
unimarc/unimarc/마크/Marc2.designer.cs
generated
936
unimarc/unimarc/마크/Marc2.designer.cs
generated
File diff suppressed because it is too large
Load Diff
@@ -193,10 +193,10 @@
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="bn1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>273, 17</value>
|
||||
<value>218, 13</value>
|
||||
</metadata>
|
||||
<metadata name="bs1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>134, 17</value>
|
||||
<value>108, 13</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="bindingNavigatorMoveFirstItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
|
||||
@@ -375,8 +375,8 @@ namespace UniMarc
|
||||
|
||||
private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
|
||||
{
|
||||
int row = e.RowIndex;
|
||||
SelectMarc(row);
|
||||
if (e.RowIndex < 0) return;
|
||||
SelectMarc(e.RowIndex);
|
||||
}
|
||||
|
||||
void SelectMarc(int row)
|
||||
|
||||
577
unimarc/unimarc/마크/MarcEditorControl.Designer.cs
generated
577
unimarc/unimarc/마크/MarcEditorControl.Designer.cs
generated
File diff suppressed because it is too large
Load Diff
@@ -36,29 +36,7 @@ namespace UniMarc
|
||||
String_Text st = new String_Text();
|
||||
string l_idx = string.Empty;
|
||||
string c_idx = string.Empty;
|
||||
MacEditorParameter Param = null;
|
||||
|
||||
public event EventHandler FillBlankClicked;
|
||||
public event EventHandler PrevButton;
|
||||
public event EventHandler NextButton;
|
||||
public event EventHandler CloseButton;
|
||||
public void SetButtonKolist(bool enable)
|
||||
{
|
||||
btn_FillBlank.Enabled = enable;
|
||||
btn_FillBlank.ForeColor = enable ? Color.Black : Color.DimGray;
|
||||
|
||||
}
|
||||
public void SetButtonPrev(bool enable)
|
||||
{
|
||||
btPrev.Enabled = enable;
|
||||
btPrev.ForeColor = enable ? Color.Black : Color.DimGray;
|
||||
}
|
||||
public void SetButtonNext(bool enable)
|
||||
{
|
||||
btNext.Enabled = enable;
|
||||
btNext.ForeColor = enable ? Color.Black : Color.DimGray;
|
||||
}
|
||||
|
||||
|
||||
public MarcEditorControl()
|
||||
{
|
||||
InitializeComponent();
|
||||
@@ -102,7 +80,7 @@ namespace UniMarc
|
||||
#endregion
|
||||
}
|
||||
|
||||
void ShowImage(string isbn,string url)
|
||||
void ShowImage(string isbn)
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -119,7 +97,6 @@ namespace UniMarc
|
||||
{
|
||||
pictureBox1.Image = null;
|
||||
pictureBox1.ImageLocation = null;
|
||||
pictureBox1.Tag = url;
|
||||
}
|
||||
}
|
||||
catch
|
||||
@@ -145,52 +122,46 @@ namespace UniMarc
|
||||
/// <param name="user"></param>
|
||||
/// <param name="saveDate"></param>
|
||||
/// <param name="listIdx"></param>
|
||||
public void LoadBookData(string dbMarc, MacEditorParameter _param)
|
||||
public void LoadBookData(string dbMarc,string isbn = "",string defaultMarc="")
|
||||
{
|
||||
mLoadCompleted = false;
|
||||
Param = _param;
|
||||
|
||||
|
||||
lbl_SaveData.Text = $"[{Param.User}] [{Param.SaveDate}]";
|
||||
lbl_ISBN.Text = $"{Param.ISBN13}";
|
||||
richTextBox1.Text = "";
|
||||
|
||||
LoadMarc(dbMarc); //여기에서도 008을 설정한다
|
||||
|
||||
ShowImage(_param.ISBN13,_param.URL);
|
||||
|
||||
//그레이드값이 없다면 비활성화.
|
||||
cb_grade.Enabled = Param.Grade != null;
|
||||
label6.Enabled = cb_grade.Enabled;
|
||||
|
||||
|
||||
richTextBox1.Text = "";
|
||||
|
||||
bool check_Marc = click_Marc(dbMarc); //여기안에서 또 008을 설정한다
|
||||
|
||||
|
||||
int gradeNo ;
|
||||
if (!check_Marc)
|
||||
string extractedIsbn = isbn;
|
||||
if (extractedIsbn.isEmpty())
|
||||
{
|
||||
richTextBox1.Text = Make_Empty();
|
||||
gradeNo = 3; //마크가 없는것은 D등급으로 한다
|
||||
//마크데이터에서 ISBN(020a)을 찾아서 설정한다.
|
||||
string[] isbnTags = st.Take_Tag(dbMarc, new string[] { "020a" });
|
||||
if (isbnTags.Length > 0 && !isbnTags[0].isEmpty())
|
||||
{
|
||||
extractedIsbn = isbnTags[0].Trim();
|
||||
}
|
||||
}
|
||||
|
||||
lbl_ISBN.Text = $"{extractedIsbn}";
|
||||
if (!extractedIsbn.isEmpty())
|
||||
{
|
||||
lbl_ISBN.Tag = extractedIsbn;
|
||||
}
|
||||
else
|
||||
{
|
||||
etc1.Text = Param.Remark1;
|
||||
etc2.Text = Param.Remark2;
|
||||
|
||||
//자료의 등급 다시 선택
|
||||
if(int.TryParse(this.Param.Grade, out gradeNo) == false)
|
||||
gradeNo = 2;
|
||||
lbl_ISBN.Tag = null;
|
||||
}
|
||||
|
||||
ShowImage(extractedIsbn);
|
||||
|
||||
bool check_Marc = click_Marc(dbMarc); //여기안에서 또 008을 설정한다
|
||||
if (!check_Marc)
|
||||
{
|
||||
richTextBox1.Text = defaultMarc;
|
||||
}
|
||||
|
||||
Create_008();
|
||||
st.Color_change("▼", richTextBox1);
|
||||
st.Color_change("▲", richTextBox1);
|
||||
|
||||
|
||||
cb_grade.SelectedIndex = gradeNo;
|
||||
mLoadCompleted = true;
|
||||
}
|
||||
|
||||
@@ -243,15 +214,15 @@ namespace UniMarc
|
||||
}
|
||||
|
||||
|
||||
if (e.KeyCode == Keys.F9)
|
||||
SaveGrade(Keys.F9);
|
||||
else if (e.KeyCode == Keys.F10)
|
||||
SaveGrade(Keys.F10);
|
||||
else if (e.KeyCode == Keys.F11)
|
||||
SaveGrade(Keys.F11);
|
||||
else if (e.KeyCode == Keys.F12)
|
||||
SaveGrade(Keys.F12);
|
||||
else if (e.KeyCode == Keys.F3)
|
||||
//if (e.KeyCode == Keys.F9)
|
||||
// SaveGrade(Keys.F9);
|
||||
//else if (e.KeyCode == Keys.F10)
|
||||
// SaveGrade(Keys.F10);
|
||||
//else if (e.KeyCode == Keys.F11)
|
||||
// SaveGrade(Keys.F11);
|
||||
//else if (e.KeyCode == Keys.F12)
|
||||
// SaveGrade(Keys.F12);
|
||||
if (e.KeyCode == Keys.F3)
|
||||
{
|
||||
rt.SelectionColor = Color.Blue;
|
||||
rt.SelectedText = "▼";
|
||||
@@ -263,37 +234,42 @@ namespace UniMarc
|
||||
rt.SelectedText = "▲";
|
||||
rt.SelectionColor = rt.ForeColor;
|
||||
}
|
||||
else if (e.KeyCode == Keys.F8) //next
|
||||
btNext.PerformClick();
|
||||
else if (e.KeyCode == Keys.F7) //prev
|
||||
btPrev.PerformClick();
|
||||
}
|
||||
|
||||
///// <summary>
|
||||
///// F9~F12로 등급별 저장
|
||||
///// </summary>
|
||||
///// <param name="key">F9~F12</param>
|
||||
//private void SaveGrade(Keys key)
|
||||
//{
|
||||
// switch (key)
|
||||
// {
|
||||
// case Keys.F9:
|
||||
// cb_grade.SelectedItem = "A (F9)";
|
||||
// Btn_Save_Click(null, null);
|
||||
// break;
|
||||
// case Keys.F10:
|
||||
// cb_grade.SelectedItem = "B (F10)";
|
||||
// Btn_Save_Click(null, null);
|
||||
// break;
|
||||
// case Keys.F11:
|
||||
// cb_grade.SelectedItem = "C (F11)";
|
||||
// Btn_Save_Click(null, null);
|
||||
// break;
|
||||
// case Keys.F12:
|
||||
// cb_grade.SelectedItem = "D (F12)";
|
||||
// Btn_Save_Click(null, null);
|
||||
// break;
|
||||
// }
|
||||
//}
|
||||
|
||||
/// <summary>
|
||||
/// F9~F12로 등급별 저장
|
||||
/// 마크문자열을 반환 합니다
|
||||
/// </summary>
|
||||
/// <param name="key">F9~F12</param>
|
||||
private void SaveGrade(Keys key)
|
||||
/// <returns></returns>
|
||||
public string MakeMarcString()
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case Keys.F9:
|
||||
cb_grade.SelectedItem = "A (F9)";
|
||||
Btn_Save_Click(null, null);
|
||||
break;
|
||||
case Keys.F10:
|
||||
cb_grade.SelectedItem = "B (F10)";
|
||||
Btn_Save_Click(null, null);
|
||||
break;
|
||||
case Keys.F11:
|
||||
cb_grade.SelectedItem = "C (F11)";
|
||||
Btn_Save_Click(null, null);
|
||||
break;
|
||||
case Keys.F12:
|
||||
cb_grade.SelectedItem = "D (F12)";
|
||||
Btn_Save_Click(null, null);
|
||||
break;
|
||||
}
|
||||
return st.made_Ori_marc(richTextBox1).Replace(@"\", "₩");
|
||||
}
|
||||
|
||||
private void etc_KeyDown(object sender, KeyEventArgs e)
|
||||
@@ -322,7 +298,11 @@ namespace UniMarc
|
||||
}
|
||||
private void Btn_Memo_Click(object sender, EventArgs e)
|
||||
{
|
||||
Marc_memo memo = new Marc_memo(this);
|
||||
Marc_memo memo = new Marc_memo();
|
||||
memo.OnSave += (s1, e1) =>
|
||||
{
|
||||
this.richTextBox1.Text = e1.Data;
|
||||
};
|
||||
memo.StartPosition = FormStartPosition.Manual;
|
||||
memo.TopMost = true;
|
||||
memo.Location = new Point(1018, 8);
|
||||
@@ -339,7 +319,7 @@ namespace UniMarc
|
||||
private void Btn_preview_Click(object sender, EventArgs e)
|
||||
{
|
||||
var mp = new Marc_Preview();
|
||||
mp.isbn = Param.ISBN13;
|
||||
mp.isbn = lbl_ISBN.Text.Trim();// Param.ISBN13;
|
||||
mp.richTextBox1.Text = richTextBox1.Text;
|
||||
mp.ButtonSave += (s, ev) =>
|
||||
{
|
||||
@@ -348,88 +328,8 @@ namespace UniMarc
|
||||
};
|
||||
mp.Show();
|
||||
}
|
||||
public class BookSavedEventArgs : EventArgs
|
||||
{
|
||||
public string SaveDate { get; set; }
|
||||
public string DBMarc { get; set; }
|
||||
|
||||
|
||||
public MacEditorParameter Param { get; set; }
|
||||
}
|
||||
|
||||
public event EventHandler<BookSavedEventArgs> BookSaved;
|
||||
|
||||
private void Btn_Save_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Param.NewMake == false && string.IsNullOrEmpty(Param.ISBN13))
|
||||
{
|
||||
MessageBox.Show("마크가 선택되지않았습니다.");
|
||||
return;
|
||||
}
|
||||
int TabIndex = tabControl1.SelectedIndex;
|
||||
|
||||
if (TabIndex == 1)
|
||||
{
|
||||
MessageBox.Show("[칸채우기]가 아닌 [마크 편집] 탭에서 저장해주세요!");
|
||||
return;
|
||||
}
|
||||
|
||||
string BaseText = richTextBox1.Text.Replace("▲▲", "▲").Replace("▼▼", "▼");
|
||||
string isbn = Param.ISBN13; // lbl_ISBN.Text.Replace("[", "").Replace("]", "");
|
||||
|
||||
if (!BaseText.EndsWith("\n"))
|
||||
BaseText += "\n";
|
||||
|
||||
if (!isPass(BaseText))
|
||||
{
|
||||
MessageBox.Show("입력된 마크의 상태를 확인해주세요.");
|
||||
return;
|
||||
}
|
||||
|
||||
//ISBN이 변경되었다면 저장하지 못하게 한다 (경고 후 저장 가능하게 한다 26010?)
|
||||
if (BaseText.IndexOf(isbn) < 0)
|
||||
{
|
||||
var dlg = UTIL.MsgQ("저장된 ISBN이 마크데이터에 없습니다.\nISBN값이 변경되었습니다.\n그래도 저장 할까요?");
|
||||
if (dlg != DialogResult.Yes)
|
||||
return;
|
||||
}
|
||||
|
||||
// ISBN 중복체크
|
||||
var exist = DB_Utils.ExistISBN(isbn);
|
||||
if (exist)
|
||||
{
|
||||
if (UTIL.MsgQ($"입력하신 ISBN({isbn})은 이미 등록된 데이터가 존재합니다.\n그래도 저장하시겠습니까?") != DialogResult.Yes)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
string tag056 = Tag056();
|
||||
string date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
string orimarc = st.made_Ori_marc(richTextBox1).Replace(@"\", "₩");
|
||||
|
||||
// 필수태그 확인
|
||||
if (!isMustTag(orimarc))
|
||||
{
|
||||
richTextBox1.Text = BaseText;
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
|
||||
this.Param.Grade = cb_grade.SelectedIndex.ToString();
|
||||
this.Param.Remark1 = etc1.Text;
|
||||
this.Param.Remark2 = etc2.Text;
|
||||
this.Param.text008 = this.text008.Text.Trim();
|
||||
this.Param.tag056 = tag056;
|
||||
// Raise Event to Update List_Book in Parent
|
||||
BookSaved?.Invoke(this, new BookSavedEventArgs
|
||||
{
|
||||
SaveDate = date,
|
||||
DBMarc = orimarc,
|
||||
Param = this.Param
|
||||
});
|
||||
}
|
||||
|
||||
#region Save_Click_Sub
|
||||
|
||||
@@ -439,7 +339,7 @@ namespace UniMarc
|
||||
/// </summary>
|
||||
/// <param name="BaseData">richTextBox에 들어가있는 텍스트</param>
|
||||
/// <returns>True / False</returns>
|
||||
private bool isPass(string BaseData)
|
||||
public bool isPass(string BaseData)
|
||||
{
|
||||
string[] EnterSplit = BaseData.Split('\n');
|
||||
|
||||
@@ -468,7 +368,51 @@ namespace UniMarc
|
||||
return true;
|
||||
}
|
||||
|
||||
private bool isMustTag(string orimarc)
|
||||
/// <summary>
|
||||
/// 마크 에디터의 유효성을 검사합니다.
|
||||
/// </summary>
|
||||
/// <param name="errorMessage">오류 발생 시 상세 메시지</param>
|
||||
/// <param name="isbnWarning">ISBN이 마크 데이터에 포함되지 않은 경우 true</param>
|
||||
/// <returns>저장 가능 여부</returns>
|
||||
public bool CheckValidation()
|
||||
{
|
||||
// 1. 탭 확인 (Index 1은 [칸채우기] 탭임)
|
||||
if (this.tabControl1.SelectedIndex == 1)
|
||||
{
|
||||
AR.UTIL.MsgE("[칸채우기]가 아닌 [마크 편집] 탭에서 저장해주세요!");
|
||||
return false;
|
||||
}
|
||||
|
||||
// 2. 텍스트 정규화 및 마크 형식 검사
|
||||
string BaseText = richTextBox1.Text.Replace("▲▲", "▲").Replace("▼▼", "▼");
|
||||
if (!BaseText.EndsWith("\n")) BaseText += "\n";
|
||||
richTextBox1.Text = BaseText; // 정규화된 텍스트 반영
|
||||
|
||||
if (!isPass(BaseText))
|
||||
{
|
||||
UTIL.MsgE( "입력된 마크의 상태를 확인해주세요.");
|
||||
return false;
|
||||
}
|
||||
|
||||
// 필수태그 확인
|
||||
var orimarc = this.MakeMarcString();
|
||||
if (!isMustTag(orimarc))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// 3. ISBN 포함 여부 확인 (경고성)
|
||||
var v_ISBN = this.lbl_ISBN.Text.Trim();
|
||||
if (BaseText.IndexOf(v_ISBN) < 0)
|
||||
{
|
||||
var dlg = UTIL.MsgQ("저장된 ISBN이 마크데이터에 없습니다.\nISBN값이 변경되었습니다.\n그래도 저장 할까요?");
|
||||
if (dlg != DialogResult.Yes) return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public bool isMustTag(string orimarc)
|
||||
{
|
||||
String_Text st = new String_Text();
|
||||
string[] SearchTag = {
|
||||
@@ -537,7 +481,7 @@ namespace UniMarc
|
||||
/// 분류기호(056)추출 & 008태그 마크에 삽입
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
string Tag056()
|
||||
public string Tag056()
|
||||
{
|
||||
string marc = richTextBox1.Text;
|
||||
string[] temp = marc.Split('\n');
|
||||
@@ -576,78 +520,8 @@ namespace UniMarc
|
||||
return tag056;
|
||||
}
|
||||
|
||||
private int Sub_marc_chk(string isbn)
|
||||
{
|
||||
string Area = "`marc_chk`, `marc_chk1`, `marc_chk2`";
|
||||
string cmd = db.DB_Select_Search(Area, "Marc", "ISBN", isbn);
|
||||
string db_res = db.DB_Send_CMD_Search(cmd);
|
||||
string[] chk_ary = db_res.Split('|');
|
||||
|
||||
for (int a = 0; a < chk_ary.Length; a++)
|
||||
{
|
||||
if (chk_ary[a] == "1")
|
||||
{
|
||||
return a;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
#endregion
|
||||
|
||||
//private void List_Book_CellClick(object sender, DataGridViewCellEventArgs e)
|
||||
//{
|
||||
// //if (e.RowIndex == -1) { return; }
|
||||
// //int row_idx = e.RowIndex;
|
||||
// //SaveRowIdx = row_idx;
|
||||
// //int col_idx = e.ColumnIndex;
|
||||
|
||||
// //string isbn = List_Book.Rows[row_idx].Cells["ISBN13"].Value.ToString();
|
||||
// //if (isbn != "") {
|
||||
// // string CountQuery = string.Format("SELECT Count(isbn) FROM Marc WHERE isbn = {0} GROUP BY isbn;", isbn);
|
||||
// // string CountResult = db.self_Made_Cmd(CountQuery).Replace("|", "");
|
||||
|
||||
// // if (CountResult == "")
|
||||
// // btn_CopySelect.Text = "0";
|
||||
|
||||
// // if (CountResult == "0") {
|
||||
// // btn_CopySelect.Enabled = false;
|
||||
// // btn_CopySelect.BackColor = Color.Silver;
|
||||
// // }
|
||||
// // else {
|
||||
// // btn_CopySelect.Enabled = true;
|
||||
// // btn_CopySelect.BackColor = Color.Khaki;
|
||||
// // }
|
||||
|
||||
// // btn_CopySelect.Text = CountResult;
|
||||
// //}
|
||||
|
||||
// //tabControl1.SelectedIndex = 0;
|
||||
|
||||
// //if (check_V(row_idx, col_idx))
|
||||
// // return;
|
||||
|
||||
// //Save_data(row_idx);
|
||||
// //richTextBox1.Text = "";
|
||||
|
||||
// //bool check_Marc = click_Marc(row_idx);
|
||||
|
||||
// //if (!check_Marc)
|
||||
// // richTextBox1.Text = Make_Empty();
|
||||
// //else
|
||||
// // ReadRemark(row_idx);
|
||||
|
||||
// //input_picture(row_idx);
|
||||
// //Create_008();
|
||||
// //st.Color_change("▼", richTextBox1);
|
||||
// //st.Color_change("▲", richTextBox1);
|
||||
|
||||
// //int grade = 2;
|
||||
// //if (List_Book.Rows[row_idx].Cells["grade"].Value != null || List_Book.Rows[row_idx].Cells["grade"].Value.ToString() != "") {
|
||||
// // grade = Convert.ToInt32(List_Book.Rows[row_idx].Cells["grade"].Value.ToString());
|
||||
// //}
|
||||
// //cb_grade.SelectedIndex = grade;
|
||||
// //OnSaveData(row_idx);
|
||||
//}
|
||||
#region CellClick_Sub
|
||||
|
||||
/// <summary>
|
||||
@@ -709,37 +583,8 @@ namespace UniMarc
|
||||
richTextBox1.Text = result;
|
||||
return true;
|
||||
}
|
||||
public void SetRemark(string remark1, string remark2)
|
||||
{
|
||||
etc1.Text = remark1;
|
||||
etc2.Text = remark2;
|
||||
}
|
||||
|
||||
void ReadRemark()
|
||||
{
|
||||
var CurrentMarcIdx = Param.MarcIdx;
|
||||
if (string.IsNullOrEmpty(CurrentMarcIdx) || CurrentMarcIdx == "0")
|
||||
{
|
||||
etc1.Text = "";
|
||||
etc2.Text = "";
|
||||
return;
|
||||
}
|
||||
|
||||
string[] sear_tbl = { "idx" };
|
||||
string[] sear_col = { CurrentMarcIdx };
|
||||
string cmd = db.More_DB_Search("Marc", sear_tbl, sear_col, "`비고1`, `비고2`");
|
||||
string res = db.DB_Send_CMD_Search(cmd);
|
||||
|
||||
string[] ary = res.Split('|');
|
||||
if (res.Length < 1)
|
||||
{
|
||||
etc1.Text = res;
|
||||
etc2.Text = "";
|
||||
return;
|
||||
}
|
||||
etc1.Text = ary[0];
|
||||
etc2.Text = ary[1];
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 마크데이터가 있는지 확인하고 메모장으로 출력
|
||||
/// </summary>
|
||||
@@ -802,28 +647,6 @@ namespace UniMarc
|
||||
}
|
||||
|
||||
|
||||
private string Make_Empty()
|
||||
{
|
||||
string yyMMdd = DateTime.Now.ToString("yyMMdd");
|
||||
string yyyy = DateTime.Now.ToString("yyyy");
|
||||
string Empty_008 = yyMMdd + "s" + yyyy + " 000 kor ▲";
|
||||
text008.Text = Empty_008.Replace("▲", "");
|
||||
data008 = text008.Text;
|
||||
string Empty_text = string.Format(
|
||||
"020\t \t▼a{1}▼c\\{5}▲\n" +
|
||||
"056\t \t▼a▼25▲\n" +
|
||||
"100\t \t▼a▲\n" +
|
||||
"245\t \t▼a{2}▼d{3}▲\n" +
|
||||
"260\t \t▼b{4}▲\n" +
|
||||
"300\t \t▼a▼c▲\n" +
|
||||
"653\t \t▼a▲\n" +
|
||||
"700\t \t▼a▲\n" +
|
||||
"950\t \t▼b\\{5}▲\n",
|
||||
Empty_008, Param.ISBN13, Param.BookName, Param.Author, Param.Publisher, Param.Price);
|
||||
etc1.Text = "";
|
||||
etc2.Text = "";
|
||||
return Empty_text;
|
||||
}
|
||||
/// <summary>
|
||||
/// 008 각각의 박스에 대입하는 함수
|
||||
/// </summary>
|
||||
@@ -1161,24 +984,8 @@ namespace UniMarc
|
||||
//}
|
||||
#endregion
|
||||
|
||||
private void Btn_Close_Click(object sender, EventArgs e)
|
||||
{
|
||||
CloseButton?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
|
||||
private void pictureBox1_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
var zp = new Zoom_Picture();
|
||||
if(pictureBox1.Tag == null)
|
||||
{
|
||||
UTIL.MsgE("이미지 URL이 없습니다");
|
||||
return;
|
||||
}
|
||||
var CurrentURL = pictureBox1.Tag.ToString();
|
||||
zp.url = pictureBox1.ImageLocation ?? CurrentURL;
|
||||
zp.ISBN = Param.ISBN13;
|
||||
zp.Show();
|
||||
}
|
||||
|
||||
|
||||
private void FillTextBox_KeyDown(object sender, KeyEventArgs e)
|
||||
@@ -1197,7 +1004,7 @@ namespace UniMarc
|
||||
{
|
||||
tb.InvokeInsertText(";");
|
||||
}
|
||||
else if(e.KeyCode == Keys.OemSemicolon)
|
||||
else if (e.KeyCode == Keys.OemSemicolon)
|
||||
{
|
||||
tb.InvokeInsertText("▽");
|
||||
e.SuppressKeyPress = true;
|
||||
@@ -1210,13 +1017,6 @@ namespace UniMarc
|
||||
|
||||
|
||||
|
||||
|
||||
private void btn_FillBlank_Click(object sender, EventArgs e)
|
||||
{
|
||||
FillBlankClicked?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
|
||||
private void tabControl1_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
int TabIndex = tabControl1.SelectedIndex;
|
||||
@@ -2295,7 +2095,7 @@ namespace UniMarc
|
||||
else
|
||||
v440Txt = dgv.Rows[a].Cells["text440vTxt"].Value.ToString();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
result += string.Format("440\t \t▼a{0}", a440);
|
||||
@@ -2304,7 +2104,7 @@ namespace UniMarc
|
||||
if (n440 != "") result += "▼n" + n440;
|
||||
if (p440 != "") result += "▼p" + p440;
|
||||
if (v440Num != "") result += "▼v" + v440Num + v440Txt;
|
||||
|
||||
|
||||
|
||||
result += "▲\n";
|
||||
}
|
||||
@@ -2543,7 +2343,7 @@ namespace UniMarc
|
||||
foreach (string text in splitText245b)
|
||||
result += "▼b" + text;
|
||||
}
|
||||
|
||||
|
||||
if (boxText[5] != "") result += "▼d" + boxText[5];
|
||||
if (boxText[6] != "") result += "▼e" + boxText[6].Replace("▽", "▼e");
|
||||
|
||||
@@ -3153,69 +2953,64 @@ namespace UniMarc
|
||||
sg.DataGrid_to_Delete(sender, e);
|
||||
}
|
||||
|
||||
private void MarcEditorControl_SizeChanged(object sender, EventArgs e)
|
||||
{
|
||||
//this.groupBox5.Text = this.Size.ToString();
|
||||
}
|
||||
|
||||
private void btPrev_Click(object sender, EventArgs e)
|
||||
{
|
||||
PrevButton?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void btNext_Click(object sender, EventArgs e)
|
||||
{
|
||||
NextButton?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
string value = lbl_ISBN.Text;
|
||||
if (search_Text.InputBox("변경할 ISBN을 입력해주세요.", "ISBN 변경", ref value) == DialogResult.OK)
|
||||
string oldIsbn = lbl_ISBN.Tag?.ToString() ?? lbl_ISBN.Text.Trim();
|
||||
|
||||
// ISBN 중복체크
|
||||
var rlt = UTIL.InputBox("변경할 ISBN을 입력해주세요.", lbl_ISBN.Text);
|
||||
if (rlt.Item1 == false) return;
|
||||
|
||||
var newisbn = rlt.Item2;//
|
||||
if (newisbn.isEmpty())
|
||||
{
|
||||
if (string.IsNullOrEmpty(value)) return;
|
||||
|
||||
// ISBN 중복체크
|
||||
var exist = DB_Utils.ExistISBN(value);
|
||||
if (exist)
|
||||
{
|
||||
if (UTIL.MsgQ($"입력하신 ISBN({value})은 해당 기관에 이미 등록된 데이터가 존재합니다.\n그래도 변경하시겠습니까?") != DialogResult.Yes)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
string oldIsbn = lbl_ISBN.Text;
|
||||
lbl_ISBN.Text = value;
|
||||
Param.ISBN13 = value;
|
||||
|
||||
// 1. RichTextBox (마크 편집) 동기화
|
||||
if (!string.IsNullOrEmpty(oldIsbn))
|
||||
{
|
||||
richTextBox1.Text = richTextBox1.Text.Replace(oldIsbn, value);
|
||||
}
|
||||
|
||||
// 2. GridView020 (칸채우기) 동기화
|
||||
for (int i = 0; i < GridView020.Rows.Count; i++)
|
||||
{
|
||||
var cell = GridView020.Rows[i].Cells["Text020a"];
|
||||
if (cell.Value != null && cell.Value.ToString() == oldIsbn)
|
||||
{
|
||||
cell.Value = value;
|
||||
}
|
||||
}
|
||||
|
||||
// 3. 이미지 업데이트
|
||||
ShowImage(Param.ISBN13, Param.URL);
|
||||
UTIL.MsgE("ISBN값이 입력되지 않았습니다");
|
||||
return;
|
||||
}
|
||||
|
||||
var exist = DB_Utils.ExistISBN(newisbn);
|
||||
if (exist)
|
||||
{
|
||||
if (UTIL.MsgQ($"입력하신 ISBN({newisbn})은 이미 등록된 데이터가 존재합니다.\n그래도 변경하시겠습니까?") != DialogResult.Yes)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
lbl_ISBN.Text = newisbn;
|
||||
|
||||
// 1. RichTextBox (마크 편집) 동기화
|
||||
if (!string.IsNullOrEmpty(oldIsbn))
|
||||
{
|
||||
richTextBox1.Text = richTextBox1.Text.Replace(oldIsbn, newisbn);
|
||||
}
|
||||
|
||||
// 2. GridView020 (칸채우기) 동기화
|
||||
for (int i = 0; i < GridView020.Rows.Count; i++)
|
||||
{
|
||||
var cell = GridView020.Rows[i].Cells["Text020a"];
|
||||
if (cell.Value != null && cell.Value.ToString() == oldIsbn)
|
||||
{
|
||||
cell.Value = newisbn;
|
||||
}
|
||||
}
|
||||
|
||||
// 3. 이미지 업데이트
|
||||
ShowImage(newisbn);
|
||||
}
|
||||
|
||||
private void btCopy_Click(object sender, EventArgs e)
|
||||
private void pictureBox1_Click(object sender, EventArgs e)
|
||||
{
|
||||
Tag056(); // 008 태그가 richTextBox1에 포함되도록 갱신
|
||||
var orimarc = st.made_Ori_marc(richTextBox1).Replace(@"\", "₩");
|
||||
var fb = new Marc_CopyForm(this.Param.ISBN13, orimarc, this.Param);
|
||||
fb.ShowDialog();
|
||||
var url = pictureBox1.Tag?.ToString() ?? string.Empty;
|
||||
if (url.isEmpty())
|
||||
{
|
||||
UTIL.MsgE("이미지 URL이 없습니다");
|
||||
return;
|
||||
}
|
||||
|
||||
var zp = new Zoom_Picture(url,lbl_ISBN.Text.Trim());
|
||||
zp.Show();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -16,64 +16,139 @@ namespace UniMarc
|
||||
MarcEditorControl marcEditorControl1;
|
||||
Helper_DB db = new Helper_DB();
|
||||
String_Text st = new String_Text();
|
||||
string baseISBN = "";
|
||||
private ToolStrip toolStrip1;
|
||||
private ToolStripButton btSave;
|
||||
private StatusStrip statusStrip1;
|
||||
string base_midx = "";
|
||||
|
||||
public Marc_CopyForm(string isbn, string marcstring, MacEditorParameter param)
|
||||
public Marc_CopyForm(string marcstring,string m_idx = "0")
|
||||
{
|
||||
InitializeComponent();
|
||||
base_midx = m_idx;
|
||||
db.DBcon();
|
||||
|
||||
this.baseISBN =param.ISBN13;
|
||||
marcEditorControl1 = new MarcEditorControl();
|
||||
marcEditorControl1.db = this.db;
|
||||
marcEditorControl1.Dock = DockStyle.Fill;
|
||||
|
||||
|
||||
// Wire up events
|
||||
marcEditorControl1.BookSaved += MarcEditorControl_BookSaved;
|
||||
marcEditorControl1.CloseButton += (s, e) => { this.Close(); };
|
||||
|
||||
|
||||
this.Controls.Add(marcEditorControl1);
|
||||
this.StartPosition = FormStartPosition.CenterScreen;
|
||||
this.Text = $"마크 복제 - {param.BookName}";
|
||||
|
||||
|
||||
// Load data as NEW (MarcIdx = 0)
|
||||
var cloneParam = new MacEditorParameter
|
||||
{
|
||||
ISBN13 = param.ISBN13,
|
||||
BookName = param.BookName,
|
||||
Author = param.Author,
|
||||
Publisher = param.Publisher,
|
||||
Price = param.Price,
|
||||
URL = param.URL,
|
||||
MarcIdx = "0", // CRITICAL: This makes it an INSERT
|
||||
Grade = param.Grade,
|
||||
Remark1 = param.Remark1,
|
||||
Remark2 = param.Remark2,
|
||||
User = PUB.user.UserName
|
||||
};
|
||||
|
||||
marcEditorControl1.LoadBookData(marcstring, cloneParam);
|
||||
marcEditorControl1.LoadBookData(marcstring, null);
|
||||
var tags = st.Take_Tag(marcstring, new string[] { "245a" });
|
||||
var BookName = tags.Length > 0 ? tags[0] : "";
|
||||
this.Text = $"마크 복제 - {BookName}";
|
||||
}
|
||||
|
||||
private void MarcEditorControl_BookSaved(object sender, MarcEditorControl.BookSavedEventArgs e)
|
||||
private void InitializeComponent()
|
||||
{
|
||||
// The actual saving logic for a NEW record
|
||||
string Table = "Marc";
|
||||
string date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
string savedMarc = e.DBMarc;
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Marc_CopyForm));
|
||||
this.toolStrip1 = new System.Windows.Forms.ToolStrip();
|
||||
this.btSave = new System.Windows.Forms.ToolStripButton();
|
||||
this.statusStrip1 = new System.Windows.Forms.StatusStrip();
|
||||
this.toolStrip1.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// toolStrip1
|
||||
//
|
||||
this.toolStrip1.ImageScalingSize = new System.Drawing.Size(20, 20);
|
||||
this.toolStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.btSave});
|
||||
this.toolStrip1.Location = new System.Drawing.Point(0, 0);
|
||||
this.toolStrip1.Name = "toolStrip1";
|
||||
this.toolStrip1.Size = new System.Drawing.Size(1316, 27);
|
||||
this.toolStrip1.TabIndex = 0;
|
||||
this.toolStrip1.Text = "toolStrip1";
|
||||
//
|
||||
// btSave
|
||||
//
|
||||
this.btSave.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
|
||||
this.btSave.Image = ((System.Drawing.Image)(resources.GetObject("btSave.Image")));
|
||||
this.btSave.ImageTransparentColor = System.Drawing.Color.Magenta;
|
||||
this.btSave.Name = "btSave";
|
||||
this.btSave.Size = new System.Drawing.Size(55, 24);
|
||||
this.btSave.Text = "저장";
|
||||
this.btSave.Click += new System.EventHandler(this.btSave_Click);
|
||||
//
|
||||
// statusStrip1
|
||||
//
|
||||
this.statusStrip1.ImageScalingSize = new System.Drawing.Size(20, 20);
|
||||
this.statusStrip1.Location = new System.Drawing.Point(0, 893);
|
||||
this.statusStrip1.Name = "statusStrip1";
|
||||
this.statusStrip1.Size = new System.Drawing.Size(1316, 22);
|
||||
this.statusStrip1.TabIndex = 1;
|
||||
this.statusStrip1.Text = "statusStrip1";
|
||||
//
|
||||
// Marc_CopyForm
|
||||
//
|
||||
this.ClientSize = new System.Drawing.Size(1316, 915);
|
||||
this.Controls.Add(this.statusStrip1);
|
||||
this.Controls.Add(this.toolStrip1);
|
||||
this.Name = "Marc_CopyForm";
|
||||
this.Text = "마크 복제";
|
||||
this.Load += new System.EventHandler(this.Marc_CopyForm_Load);
|
||||
this.toolStrip1.ResumeLayout(false);
|
||||
this.toolStrip1.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
private void Marc_CopyForm_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void btSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
string errMsg = string.Empty;
|
||||
bool isbnWarning = false;
|
||||
|
||||
// 중앙 집중식 유효성 검사 수행
|
||||
if (!marcEditorControl1.CheckValidation())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
var v_ISBN = this.marcEditorControl1.lbl_ISBN.Text.Trim();
|
||||
|
||||
// ISBN 미포함 경고 처리
|
||||
if (isbnWarning)
|
||||
{
|
||||
var dlg = UTIL.MsgQ("저장된 ISBN이 마크데이터에 없습니다.\nISBN값이 변경되었습니다.\n그래도 저장 할까요?");
|
||||
if (dlg != DialogResult.Yes) return;
|
||||
}
|
||||
|
||||
// ISBN 중복 체크 (DB 관련이므로 폼에서 처리)
|
||||
if (DB_Utils.ExistISBN(v_ISBN))
|
||||
{
|
||||
if (UTIL.MsgQ($"입력하신 ISBN({v_ISBN})은 이미 등록된 데이터가 존재합니다.\n그래도 저장하시겠습니까?") != DialogResult.Yes)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// 008 태그 최신화 및 056 추출
|
||||
string tag056 = marcEditorControl1.Tag056();
|
||||
var savedMarc = this.marcEditorControl1.MakeMarcString();
|
||||
var date = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
var v_008 = this.marcEditorControl1.text008.Text;
|
||||
|
||||
string[] insert_col = {
|
||||
"ISBN", "compidx", "marc", "marc_chk",
|
||||
"grade", "008tag", "user", "date","비고2"
|
||||
"grade", "008tag", "user", "date","비고1", "division"
|
||||
};
|
||||
string[] insert_data = {
|
||||
e.Param.ISBN13, PUB.user.CompanyIdx.ToString(), savedMarc, "1",
|
||||
e.Param.Grade, e.Param.text008, PUB.user.UserName, date,$"복제({baseISBN})"
|
||||
v_ISBN, PUB.user.CompanyIdx.ToString(), savedMarc, "1",
|
||||
"3", v_008, PUB.user.UserName, date,$"복제(m_idx:{this.base_midx})", tag056
|
||||
};
|
||||
|
||||
string cmd = db.DB_INSERT(Table, insert_col, insert_data);
|
||||
string cmd = db.DB_INSERT("Marc", insert_col, insert_data);
|
||||
var rlt = Helper_DB.ExcuteNonQuery(cmd);
|
||||
if ( rlt.applyCount == 1)
|
||||
if (rlt.applyCount == 1)
|
||||
{
|
||||
UTIL.MsgI("저장되었습니다.");
|
||||
this.DialogResult = DialogResult.OK;
|
||||
@@ -84,14 +159,5 @@ namespace UniMarc
|
||||
UTIL.MsgE(rlt.errorMessage);
|
||||
}
|
||||
}
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.SuspendLayout();
|
||||
this.ClientSize = new System.Drawing.Size(1200, 800);
|
||||
this.Name = "Marc_CopyForm";
|
||||
this.Text = "마크 복제";
|
||||
this.ResumeLayout(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
142
unimarc/unimarc/마크/Marc_CopyForm.resx
Normal file
142
unimarc/unimarc/마크/Marc_CopyForm.resx
Normal file
@@ -0,0 +1,142 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="toolStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="btSave.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAIFSURBVDhPpZLtS1NhGMbPPxJmmlYSgqHiKzGU1EDxg4iK
|
||||
YKyG2WBogqMYJQOtCEVRFBGdTBCJfRnkS4VaaWNT5sqx1BUxRXxDHYxAJLvkusEeBaPAB+5z4Jzn+t3X
|
||||
/aLhnEfjo8m+dCoa+7/C3O2Hqe0zDC+8KG+cRZHZhdzaaWTVTCLDMIY0vfM04Nfh77/G/sEhwpEDbO3t
|
||||
I7TxE8urEVy99fT/AL5gWDLrTB/hnF4XsW0khCu5ln8DmJliT2AXrcNBsU1gj/MH4nMeKwBrPktM28xM
|
||||
cX79DFKrHHD5d9D26hvicx4pABt2lpg10zYzU0zr7+e3xXGcrkEB2O2TNec9nJFwB3alZn5jZorfeDZh
|
||||
6Q3g8s06BeCoKF4MRURoH1+BY2oNCbeb0TIclIYxOhzf8frTOuo7FxCbbVIAzpni0iceEc8vhzEwGkJD
|
||||
lx83ymxifejdKjRNk/8PWnyIyTQqAJek0jqHwfEVscu31baIu8+90sTE4nY025dQ2/5FIPpnXlzKuK8A
|
||||
HBUzHot52djqQ6HZhfR7IwK4mKpHtvEDMqvfCiQ6zaAAXM8x94aIWTNrLLG4kVUzgaTSPlzLtyJOZxbb
|
||||
1wtfyg4Q+AfA3aZlButjSfxGcUJBk4g5tuP3haQKRKXcUQDOmbvNTpPOJeFFjordZmbWTNvMTHFUcpUC
|
||||
nOccAdABIDXXE1nzAAAAAElFTkSuQmCC
|
||||
</value>
|
||||
</data>
|
||||
<metadata name="statusStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>124, 17</value>
|
||||
</metadata>
|
||||
</root>
|
||||
45
unimarc/unimarc/마크/Marc_Plan.Designer.cs
generated
45
unimarc/unimarc/마크/Marc_Plan.Designer.cs
generated
@@ -146,7 +146,6 @@
|
||||
this.bn1 = new System.Windows.Forms.BindingNavigator(this.components);
|
||||
this.bs1 = new System.Windows.Forms.BindingSource(this.components);
|
||||
this.bindingNavigatorCountItem = new System.Windows.Forms.ToolStripLabel();
|
||||
this.btDelete = new System.Windows.Forms.ToolStripButton();
|
||||
this.bindingNavigatorMoveFirstItem = new System.Windows.Forms.ToolStripButton();
|
||||
this.bindingNavigatorMovePreviousItem = new System.Windows.Forms.ToolStripButton();
|
||||
this.bindingNavigatorSeparator = new System.Windows.Forms.ToolStripSeparator();
|
||||
@@ -155,8 +154,10 @@
|
||||
this.bindingNavigatorMoveNextItem = new System.Windows.Forms.ToolStripButton();
|
||||
this.bindingNavigatorMoveLastItem = new System.Windows.Forms.ToolStripButton();
|
||||
this.bindingNavigatorSeparator2 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.btDelete = new System.Windows.Forms.ToolStripButton();
|
||||
this.printDocument1 = new System.Drawing.Printing.PrintDocument();
|
||||
this.printPreviewDialog1 = new System.Windows.Forms.PrintPreviewDialog();
|
||||
this.btn_FillBlank = new System.Windows.Forms.Button();
|
||||
this.panel1.SuspendLayout();
|
||||
this.panel4.SuspendLayout();
|
||||
this.panel3.SuspendLayout();
|
||||
@@ -520,6 +521,7 @@
|
||||
//
|
||||
// panel5
|
||||
//
|
||||
this.panel5.Controls.Add(this.btn_FillBlank);
|
||||
this.panel5.Controls.Add(this.chkEditorTest);
|
||||
this.panel5.Controls.Add(this.cbTag008_32);
|
||||
this.panel5.Controls.Add(this.btnTag008);
|
||||
@@ -532,7 +534,7 @@
|
||||
this.panel5.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.panel5.Location = new System.Drawing.Point(0, 35);
|
||||
this.panel5.Name = "panel5";
|
||||
this.panel5.Size = new System.Drawing.Size(1730, 55);
|
||||
this.panel5.Size = new System.Drawing.Size(1730, 56);
|
||||
this.panel5.TabIndex = 9;
|
||||
//
|
||||
// chkEditorTest
|
||||
@@ -1040,9 +1042,9 @@
|
||||
this.panel7.Controls.Add(this.bn1);
|
||||
this.panel7.Controls.Add(this.checkBox1);
|
||||
this.panel7.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel7.Location = new System.Drawing.Point(0, 90);
|
||||
this.panel7.Location = new System.Drawing.Point(0, 91);
|
||||
this.panel7.Name = "panel7";
|
||||
this.panel7.Size = new System.Drawing.Size(1730, 763);
|
||||
this.panel7.Size = new System.Drawing.Size(1730, 762);
|
||||
this.panel7.TabIndex = 11;
|
||||
//
|
||||
// dataGridView1
|
||||
@@ -1090,7 +1092,7 @@
|
||||
this.dataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||
this.dataGridView1.Name = "dataGridView1";
|
||||
this.dataGridView1.RowTemplate.Height = 23;
|
||||
this.dataGridView1.Size = new System.Drawing.Size(1730, 738);
|
||||
this.dataGridView1.Size = new System.Drawing.Size(1730, 737);
|
||||
this.dataGridView1.TabIndex = 1;
|
||||
this.dataGridView1.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellClick);
|
||||
this.dataGridView1.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick);
|
||||
@@ -1290,7 +1292,7 @@
|
||||
this.bindingNavigatorMoveLastItem,
|
||||
this.bindingNavigatorSeparator2,
|
||||
this.btDelete});
|
||||
this.bn1.Location = new System.Drawing.Point(0, 738);
|
||||
this.bn1.Location = new System.Drawing.Point(0, 737);
|
||||
this.bn1.MoveFirstItem = this.bindingNavigatorMoveFirstItem;
|
||||
this.bn1.MoveLastItem = this.bindingNavigatorMoveLastItem;
|
||||
this.bn1.MoveNextItem = this.bindingNavigatorMoveNextItem;
|
||||
@@ -1308,16 +1310,6 @@
|
||||
this.bindingNavigatorCountItem.Text = "/{0}";
|
||||
this.bindingNavigatorCountItem.ToolTipText = "전체 항목 수";
|
||||
//
|
||||
// btDelete
|
||||
//
|
||||
this.btDelete.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
|
||||
this.btDelete.Image = ((System.Drawing.Image)(resources.GetObject("btDelete.Image")));
|
||||
this.btDelete.Name = "btDelete";
|
||||
this.btDelete.RightToLeftAutoMirrorImage = true;
|
||||
this.btDelete.Size = new System.Drawing.Size(23, 22);
|
||||
this.btDelete.Text = "삭제";
|
||||
this.btDelete.Click += new System.EventHandler(this.bindingNavigatorDeleteItem_Click);
|
||||
//
|
||||
// bindingNavigatorMoveFirstItem
|
||||
//
|
||||
this.bindingNavigatorMoveFirstItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
|
||||
@@ -1379,6 +1371,16 @@
|
||||
this.bindingNavigatorSeparator2.Name = "bindingNavigatorSeparator2";
|
||||
this.bindingNavigatorSeparator2.Size = new System.Drawing.Size(6, 25);
|
||||
//
|
||||
// btDelete
|
||||
//
|
||||
this.btDelete.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
|
||||
this.btDelete.Image = ((System.Drawing.Image)(resources.GetObject("btDelete.Image")));
|
||||
this.btDelete.Name = "btDelete";
|
||||
this.btDelete.RightToLeftAutoMirrorImage = true;
|
||||
this.btDelete.Size = new System.Drawing.Size(23, 22);
|
||||
this.btDelete.Text = "삭제";
|
||||
this.btDelete.Click += new System.EventHandler(this.bindingNavigatorDeleteItem_Click);
|
||||
//
|
||||
// printDocument1
|
||||
//
|
||||
this.printDocument1.BeginPrint += new System.Drawing.Printing.PrintEventHandler(this.printDocument1_BeginPrint);
|
||||
@@ -1394,6 +1396,16 @@
|
||||
this.printPreviewDialog1.Name = "printPreviewDialog1";
|
||||
this.printPreviewDialog1.Visible = false;
|
||||
//
|
||||
// btn_FillBlank
|
||||
//
|
||||
this.btn_FillBlank.Location = new System.Drawing.Point(1332, 31);
|
||||
this.btn_FillBlank.Name = "btn_FillBlank";
|
||||
this.btn_FillBlank.Size = new System.Drawing.Size(338, 22);
|
||||
this.btn_FillBlank.TabIndex = 229;
|
||||
this.btn_FillBlank.Text = "미소장 마크 코리스 칸채우기";
|
||||
this.btn_FillBlank.UseVisualStyleBackColor = true;
|
||||
this.btn_FillBlank.Click += new System.EventHandler(this.btn_FillBlank_Click);
|
||||
//
|
||||
// Marc_Plan
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
@@ -1551,5 +1563,6 @@
|
||||
private System.Windows.Forms.ToolStripButton bindingNavigatorMoveLastItem;
|
||||
private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator2;
|
||||
private System.Windows.Forms.BindingSource bs1;
|
||||
private System.Windows.Forms.Button btn_FillBlank;
|
||||
}
|
||||
}
|
||||
@@ -246,18 +246,6 @@ namespace UniMarc
|
||||
}
|
||||
}
|
||||
|
||||
private (string marc, MacEditorParameter p) GetBookData(int row)
|
||||
{
|
||||
// Fallback or deprecated, ideally redirect to item based or remove if possible.
|
||||
// BUT existing non-bound usage calls might exist? No, this is private and used in editor opening.
|
||||
// Let's keep for safety but implement new one.
|
||||
if (row >= 0 && row < bs1.Count)
|
||||
{
|
||||
return GetBookData((MarcPlanItem)bs1.List[row]);
|
||||
}
|
||||
return ("", new MacEditorParameter());
|
||||
}
|
||||
|
||||
private (string marc, MacEditorParameter p) GetBookData(MarcPlanItem item)
|
||||
{
|
||||
string bookName = item.BookName;
|
||||
@@ -292,9 +280,6 @@ namespace UniMarc
|
||||
Author = author,
|
||||
Publisher = publisher,
|
||||
Price = price,
|
||||
Remark1 = remark1,
|
||||
Remark2 = remark2,
|
||||
Grade = null,
|
||||
};
|
||||
return (marc, p);
|
||||
}
|
||||
@@ -337,7 +322,7 @@ namespace UniMarc
|
||||
string isbn = currentItem.Isbn;
|
||||
string marcData = currentItem.Marc;
|
||||
|
||||
var f = new Marc_Plan_Sub_MarcEdit2(isbn, marcData);
|
||||
var f = new fMarc_Editor_Spec(isbn, marcData);
|
||||
var data = GetBookData(currentItem);
|
||||
f.LoadBook(data.marc, data.p);
|
||||
|
||||
@@ -1681,5 +1666,65 @@ namespace UniMarc
|
||||
MessageBox.Show($"삭제 중 오류가 발생했습니다.\n{ex.Message}", "오류", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
|
||||
private void btn_FillBlank_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (List_Book.CurrentRow == null) return;
|
||||
int row = List_Book.CurrentRow.Index;
|
||||
string ISBN = List_Book.Rows[row].Cells["ISBN13"].Value?.ToString();
|
||||
|
||||
if (string.IsNullOrEmpty(ISBN))
|
||||
{
|
||||
MessageBox.Show("ISBN이 존재하지않습니다!");
|
||||
return;
|
||||
}
|
||||
|
||||
var fb = new Marc_FillBlank();
|
||||
for (int a = 0; a < bs1.Count; a++)
|
||||
{
|
||||
var item = bs1.List[a] as MarcBookItem;
|
||||
if (item != null && item.Status == MarcRecordStatus.None)
|
||||
{
|
||||
var fbItem = new FillBlankItem
|
||||
{
|
||||
Idx = item.ListIdx,
|
||||
Isbn = item.ISBN13 ?? "",
|
||||
BookName = item.BookName ?? "",
|
||||
Author = item.Author ?? "",
|
||||
Publisher = item.BookComp ?? "",
|
||||
Price = item.Pay ?? ""
|
||||
};
|
||||
fb.InitFillBlank(fbItem);
|
||||
}
|
||||
}
|
||||
fb.ISBN = ISBN;
|
||||
if (fb.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
String_Text st = new String_Text();
|
||||
if (fb.FillBlankItems.Any(t => !string.IsNullOrEmpty(t.BookMarc)))
|
||||
{
|
||||
foreach (var fbItem in fb.FillBlankItems)
|
||||
{
|
||||
if (string.IsNullOrEmpty(fbItem.BookMarc)) continue;
|
||||
|
||||
int targetListIdx = int.Parse(fbItem.Idx);
|
||||
foreach (MarcBookItem item in this.dataList)
|
||||
{
|
||||
if (item.ListIdx != null && Convert.ToInt32(item.ListIdx) == targetListIdx)
|
||||
{
|
||||
item.DbMarc = fbItem.BookMarc;
|
||||
item.Status = MarcRecordStatus.NewFetched;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(fb.SingleMarcResult))
|
||||
{
|
||||
// Update current Editor
|
||||
marcEditorControl1.SetMarcString(fb.SingleMarcResult);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -117,23 +117,20 @@
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="bn1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>437, 11</value>
|
||||
</metadata>
|
||||
<metadata name="search_tag2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="bn1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>437, 11</value>
|
||||
<value>323, 17</value>
|
||||
</metadata>
|
||||
<metadata name="bs1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>517, 10</value>
|
||||
<value>398, 17</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="bindingNavigatorMoveFirstItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAATFJREFUOE9jYBg0oHDW8/9NC57/z5z4+D+6HAyEtz/AKceQO/PZ/1VH3v/HpSi+
|
||||
wAAADsABataJCQAAATFJREFUOE9jYBg0oHDW8/9NC57/z5z4+D+6HAyEtz/AKceQO/PZ/1VH3v/HpSi+
|
||||
+8H/4IZrWOXAIGPK0/8L933Aqii+5+H/pfv///evvoAhBwcJPU/+T9vyHkNRRPt9sObMWf//e5WewG1A
|
||||
ZNej/72rP6AoCm29B9bcuu7/f//Ov/9d8g/gNiCw+eH/uvnv4IqCW+7+X7T3//+Odf//Z8z5+d+u7ud/
|
||||
+4ztuA3wqLr/P3/aGxRFdsW3/6fP+f3fv+vbf53Cd/8tEtbjNsC+9O7/7MmvMRTpp5z/b1L04r9K1qf/
|
||||
@@ -144,7 +141,7 @@
|
||||
<data name="bindingNavigatorMovePreviousItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAALtJREFUOE9jYBgyILz9wX90MaJBfPeD/8EN18gzIL7n4f+l+///96++QLoBEe33
|
||||
wAAADsABataJCQAAALtJREFUOE9jYBgyILz9wX90MaJBfPeD/8EN18gzIL7n4f+l+///96++QLoBEe33
|
||||
wZozZ/3/71V6gjQDQlvvgTW3rvv/37/z73+X/APEGxDccvf/or3//3es+/8/Y87P/3Z1P//bZ2wn3gAQ
|
||||
sCu+/T99zu///l3f/usUvvtvkbCeNANAQD/l/H+Tohf/VbI+/TeOXEa6ASBgkHTiv2za1/+6wfPIMwAE
|
||||
9FMv/9fwnUa+ASCg4jGBMgMGLwAA0BRgmCws/7cAAAAASUVORK5CYII=
|
||||
@@ -153,7 +150,7 @@
|
||||
<data name="bindingNavigatorMoveNextItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAAKRJREFUOE9jYBh0oHDW8//oYiSB3JnP/id03yPfkIwpT//P2//7f0LXHfIMSeh5
|
||||
wAAADsABataJCQAAAKRJREFUOE9jYBh0oHDW8//oYiSB3JnP/id03yPfkIwpT//P2//7f0LXHfIMSeh5
|
||||
8n/2vl//O7f+/e9Wepl0QyK7Hv2fsu3X/5Klf/8nTP/73yb3LGmGBDY//N+69j1Ys3HJl//S0df+G0cu
|
||||
I94Qj6r7/0vmvoNrVnTpIV4zCNiX3v0f2PKMPM0gYJF3579NwRXyNIOAYdZt8jWDgE7aDfI1D00AAKB+
|
||||
X6Bjq5qXAAAAAElFTkSuQmCC
|
||||
@@ -162,7 +159,7 @@
|
||||
<data name="bindingNavigatorMoveLastItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAAStJREFUOE9jYBhUoHDW8//oYjAAkmta8Px/5sTHONUw5M589j+h+x5WBSC5VUfe
|
||||
wAAADsABataJCQAAAStJREFUOE9jYBhUoHDW8//oYjAAkmta8Px/5sTHONUw5M589j+h+x5WBSC5VUfe
|
||||
/w9vf4BVHgwypjz9P2//7/8JXXcwFIHkFu778D+44RqGHBwk9Dz5P3vfr/+dW//+dyu9jKIQJDdty/v/
|
||||
/tUXcBsQ2fXo/5Rtv/6XLP37P2H63/82uWfhikFyvas//PcqPYHbgMDmh/9b174HazYu+fJfOvraf+PI
|
||||
ZWANILm6+e/+u+QfwG2AR9X9/yVz38E1K7r0wBWD5PKnvflvn7EdtwH2pXf/B7Y8w9AMk8ue/Pq/RcJ6
|
||||
@@ -173,7 +170,7 @@
|
||||
<data name="btDelete.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAAWtJREFUOE+1kE0ow2Ecx/9X5a2UiwtKOSCTmJBMhuQlMo3IvCUHDouEXHZwIOVC
|
||||
wAAADsABataJCQAAAWtJREFUOE+1kE0ow2Ecx/9X5a2UiwtKOSCTmJBMhuQlMo3IvCUHDouEXHZwIOVC
|
||||
DrhIDiQl5USy07zNa2tKf2laaRf84/J8xBCetab4XL/f76fn+SnKX4DrGLqrwbHDzywkWJlHdJYjLEbY
|
||||
Wg8q4eYKlma+d1hbgF4TotWIaC+FuYmAktcXCksx2HrknBOHX1KbiTDngrXhW0kMdSBM2TA5Io+/wuI0
|
||||
oiz5TcRwB7hPYazfLx3rDz7+gCsXNBb4v1SdgajTQ19TaOMP2NtFmPSIilSo0v1y7FHBnAdZMWi6aO51
|
||||
@@ -186,7 +183,7 @@
|
||||
<value>18, 17</value>
|
||||
</metadata>
|
||||
<metadata name="printPreviewDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>193, 17</value>
|
||||
<value>161, 17</value>
|
||||
</metadata>
|
||||
<data name="printPreviewDialog1.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
|
||||
@@ -1,48 +0,0 @@
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
partial class Marc_Plan_Sub_MarcEdit2
|
||||
{
|
||||
/// <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()
|
||||
{
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// Marc_Plan_Sub_MarcEdit2
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1337, 768);
|
||||
this.Name = "Marc_Plan_Sub_MarcEdit2";
|
||||
this.Text = "마크편집";
|
||||
this.Load += new System.EventHandler(this.Marc_Plan_Sub_MarcEdit2_Load);
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -12,31 +12,26 @@ namespace UniMarc
|
||||
{
|
||||
public partial class Marc_memo : Form
|
||||
{
|
||||
Marc marc;
|
||||
AddMarc am;
|
||||
MarcEditorControl mae2;
|
||||
public Marc_memo(MarcEditorControl _mae)
|
||||
public class MarcMemoArgs : EventArgs
|
||||
{
|
||||
public string Data { get; set; }
|
||||
public MarcMemoArgs(string message)
|
||||
{
|
||||
this.Data = message;
|
||||
}
|
||||
}
|
||||
public event EventHandler<MarcMemoArgs> OnSave;
|
||||
public Marc_memo()
|
||||
{
|
||||
InitializeComponent();
|
||||
mae2 = _mae;
|
||||
}
|
||||
|
||||
public Marc_memo(Marc _marc)
|
||||
{
|
||||
InitializeComponent();
|
||||
marc = _marc;
|
||||
}
|
||||
public Marc_memo(AddMarc _am)
|
||||
{
|
||||
InitializeComponent();
|
||||
am = _am;
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void Marc_memo_Load(object sender, EventArgs e)
|
||||
{
|
||||
string[] com_List =
|
||||
{
|
||||
"하나막", "코리스"
|
||||
"하나막", "코리스"
|
||||
};
|
||||
cb_List.Items.AddRange(com_List);
|
||||
}
|
||||
@@ -66,12 +61,13 @@ namespace UniMarc
|
||||
|
||||
richTextBox1.Text = "";
|
||||
|
||||
if (marc != null)
|
||||
marc.richTextBox1.Text = result.Replace("↔", "");
|
||||
else if(mae2 != null)
|
||||
mae2.richTextBox1.Text = result.Replace("↔", "");
|
||||
else if (am != null)
|
||||
am.richTextBox1.Text = result.Replace("↔", "");
|
||||
//if (marc != null)
|
||||
// marc.richTextBox1.Text = result.Replace("↔", "");
|
||||
//else if(mae2 != null)
|
||||
// mae2.richTextBox1.Text = result.Replace("↔", "");
|
||||
//else if (am != null)
|
||||
// am.richTextBox1.Text = result.Replace("↔", "");
|
||||
OnSave?.Invoke(this, new MarcMemoArgs(result.Replace("↔", "")));
|
||||
}
|
||||
#region UniMarc 양식에 맞춰 변경
|
||||
string Hana(string text)
|
||||
|
||||
18
unimarc/unimarc/마크/Search_Infor2.Designer.cs
generated
18
unimarc/unimarc/마크/Search_Infor2.Designer.cs
generated
@@ -29,7 +29,7 @@
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Search_Infor2));
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.dataGridView1 = new System.Windows.Forms.DataGridView();
|
||||
@@ -118,14 +118,14 @@
|
||||
//
|
||||
this.dataGridView1.AllowUserToAddRows = false;
|
||||
this.dataGridView1.AllowUserToDeleteRows = false;
|
||||
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
|
||||
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control;
|
||||
dataGridViewCellStyle2.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText;
|
||||
dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
|
||||
dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
|
||||
dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
|
||||
this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2;
|
||||
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.idx,
|
||||
|
||||
@@ -337,12 +337,13 @@ namespace UniMarc
|
||||
#endregion
|
||||
private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
|
||||
{
|
||||
//에디트 창을 연다
|
||||
if (e.RowIndex < 0) return;
|
||||
|
||||
SearchInforItem item = (SearchInforItem)bs1[e.RowIndex];
|
||||
if (item == null) return;
|
||||
|
||||
var me = new Marc_Plan_Sub_MarcEdit2(item.ISBN, item.Marc);
|
||||
var me = new fMarc_Editor_Spec(item.ISBN, item.Marc);
|
||||
me.row = e.RowIndex;
|
||||
me.UserName = main.botUserLabel.Text;
|
||||
|
||||
@@ -358,13 +359,10 @@ namespace UniMarc
|
||||
BookName = currentItem.book_name,
|
||||
ISBN13 = currentItem.ISBN,
|
||||
MarcIdx = currentItem.idx,
|
||||
Grade = Change_Grade(currentItem.grade),
|
||||
User = currentItem.User,
|
||||
SaveDate = currentItem.date,
|
||||
Publisher = currentItem.book_comp,
|
||||
Price = currentItem.price,
|
||||
Remark1 = currentItem.etc1,
|
||||
Remark2 = currentItem.etc2,
|
||||
text008 = "",
|
||||
tag056 = "",
|
||||
NewMake = false,
|
||||
@@ -453,7 +451,6 @@ namespace UniMarc
|
||||
|
||||
me.Show();
|
||||
|
||||
|
||||
// Search_Infor_Sub sis = new Search_Infor_Sub(this);
|
||||
// sis.isbn = dataGridView1.Rows[row].Cells["ISBN"].Value.ToString();
|
||||
// sis.marc = dataGridView1.Rows[row].Cells["Marc"].Value.ToString();
|
||||
@@ -579,7 +576,7 @@ namespace UniMarc
|
||||
return;
|
||||
}
|
||||
|
||||
var me = new Marc_Plan_Sub_MarcEdit2(item.ISBN, item.marc2);
|
||||
var me = new fMarc_Editor_Spec(item.ISBN, item.marc2);
|
||||
|
||||
me.row = row;
|
||||
me.UserName = main.botUserLabel.Text;
|
||||
@@ -596,13 +593,10 @@ namespace UniMarc
|
||||
BookName = currentItem.book_name,
|
||||
ISBN13 = currentItem.ISBN,
|
||||
MarcIdx = currentItem.idx,
|
||||
Grade = currentItem.grade,
|
||||
User = currentItem.User,
|
||||
SaveDate = currentItem.date,
|
||||
Publisher = currentItem.book_comp,
|
||||
Price = currentItem.price,
|
||||
Remark1 = currentItem.etc1,
|
||||
Remark2 = currentItem.etc2,
|
||||
text008 = "",
|
||||
tag056 = "",
|
||||
NewMake = false,
|
||||
|
||||
@@ -165,9 +165,6 @@
|
||||
<metadata name="bindingNavigator1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="bindingNavigator1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="bs1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>171, 17</value>
|
||||
</metadata>
|
||||
@@ -175,7 +172,7 @@
|
||||
<data name="bindingNavigatorMoveFirstItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAATFJREFUOE9jYBg0oHDW8/9NC57/z5z4+D+6HAyEtz/AKceQO/PZ/1VH3v/HpSi+
|
||||
wAAADsABataJCQAAATFJREFUOE9jYBg0oHDW8/9NC57/z5z4+D+6HAyEtz/AKceQO/PZ/1VH3v/HpSi+
|
||||
+8H/4IZrWOXAIGPK0/8L933Aqii+5+H/pfv///evvoAhBwcJPU/+T9vyHkNRRPt9sObMWf//e5WewG1A
|
||||
ZNej/72rP6AoCm29B9bcuu7/f//Ov/9d8g/gNiCw+eH/uvnv4IqCW+7+X7T3//+Odf//Z8z5+d+u7ud/
|
||||
+4ztuA3wqLr/P3/aGxRFdsW3/6fP+f3fv+vbf53Cd/8tEtbjNsC+9O7/7MmvMRTpp5z/b1L04r9K1qf/
|
||||
@@ -186,7 +183,7 @@
|
||||
<data name="bindingNavigatorMovePreviousItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAALtJREFUOE9jYBgyILz9wX90MaJBfPeD/8EN18gzIL7n4f+l+///96++QLoBEe33
|
||||
wAAADsABataJCQAAALtJREFUOE9jYBgyILz9wX90MaJBfPeD/8EN18gzIL7n4f+l+///96++QLoBEe33
|
||||
wZozZ/3/71V6gjQDQlvvgTW3rvv/37/z73+X/APEGxDccvf/or3//3es+/8/Y87P/3Z1P//bZ2wn3gAQ
|
||||
sCu+/T99zu///l3f/usUvvtvkbCeNANAQD/l/H+Tohf/VbI+/TeOXEa6ASBgkHTiv2za1/+6wfPIMwAE
|
||||
9FMv/9fwnUa+ASCg4jGBMgMGLwAA0BRgmCws/7cAAAAASUVORK5CYII=
|
||||
@@ -195,7 +192,7 @@
|
||||
<data name="bindingNavigatorMoveNextItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAAKRJREFUOE9jYBh0oHDW8//oYiSB3JnP/id03yPfkIwpT//P2//7f0LXHfIMSeh5
|
||||
wAAADsABataJCQAAAKRJREFUOE9jYBh0oHDW8//oYiSB3JnP/id03yPfkIwpT//P2//7f0LXHfIMSeh5
|
||||
8n/2vl//O7f+/e9Wepl0QyK7Hv2fsu3X/5Klf/8nTP/73yb3LGmGBDY//N+69j1Ys3HJl//S0df+G0cu
|
||||
I94Qj6r7/0vmvoNrVnTpIV4zCNiX3v0f2PKMPM0gYJF3579NwRXyNIOAYdZt8jWDgE7aDfI1D00AAKB+
|
||||
X6Bjq5qXAAAAAElFTkSuQmCC
|
||||
@@ -204,7 +201,7 @@
|
||||
<data name="bindingNavigatorMoveLastItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wQAADsEBuJFr7QAAAStJREFUOE9jYBhUoHDW8//oYjAAkmta8Px/5sTHONUw5M589j+h+x5WBSC5VUfe
|
||||
wAAADsABataJCQAAAStJREFUOE9jYBhUoHDW8//oYjAAkmta8Px/5sTHONUw5M589j+h+x5WBSC5VUfe
|
||||
/w9vf4BVHgwypjz9P2//7/8JXXcwFIHkFu778D+44RqGHBwk9Dz5P3vfr/+dW//+dyu9jKIQJDdty/v/
|
||||
/tUXcBsQ2fXo/5Rtv/6XLP37P2H63/82uWfhikFyvas//PcqPYHbgMDmh/9b174HazYu+fJfOvraf+PI
|
||||
ZWANILm6+e/+u+QfwG2AR9X9/yVz38E1K7r0wBWD5PKnvflvn7EdtwH2pXf/B7Y8w9AMk8ue/Pq/RcJ6
|
||||
|
||||
75
unimarc/unimarc/마크/Search_Infor_Sub.Designer.cs
generated
75
unimarc/unimarc/마크/Search_Infor_Sub.Designer.cs
generated
@@ -1,75 +0,0 @@
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
partial class Search_Infor_Sub
|
||||
{
|
||||
/// <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()
|
||||
{
|
||||
this.pictureBox1 = new System.Windows.Forms.PictureBox();
|
||||
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// pictureBox1
|
||||
//
|
||||
this.pictureBox1.Location = new System.Drawing.Point(864, 12);
|
||||
this.pictureBox1.Name = "pictureBox1";
|
||||
this.pictureBox1.Size = new System.Drawing.Size(318, 403);
|
||||
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
|
||||
this.pictureBox1.TabIndex = 0;
|
||||
this.pictureBox1.TabStop = false;
|
||||
this.pictureBox1.DoubleClick += new System.EventHandler(this.pictureBox1_DoubleClick);
|
||||
//
|
||||
// richTextBox1
|
||||
//
|
||||
this.richTextBox1.Location = new System.Drawing.Point(12, 12);
|
||||
this.richTextBox1.Name = "richTextBox1";
|
||||
this.richTextBox1.Size = new System.Drawing.Size(846, 578);
|
||||
this.richTextBox1.TabIndex = 1;
|
||||
this.richTextBox1.Text = "";
|
||||
//
|
||||
// Search_Infor_Sub
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1194, 604);
|
||||
this.Controls.Add(this.richTextBox1);
|
||||
this.Controls.Add(this.pictureBox1);
|
||||
this.Name = "Search_Infor_Sub";
|
||||
this.Text = "마크편집";
|
||||
this.Load += new System.EventHandler(this.Search_Infor_Sub_Load);
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.PictureBox pictureBox1;
|
||||
private System.Windows.Forms.RichTextBox richTextBox1;
|
||||
}
|
||||
}
|
||||
@@ -1,41 +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;
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
public partial class Search_Infor_Sub : Form
|
||||
{
|
||||
Search_Infor si;
|
||||
public string isbn = "";
|
||||
public string marc = "";
|
||||
public Search_Infor_Sub(Search_Infor _si)
|
||||
{
|
||||
InitializeComponent();
|
||||
si = _si;
|
||||
}
|
||||
private void Search_Infor_Sub_Load(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
string pic_url = "http://image.kyobobook.co.kr/images/book/xlarge/" + isbn.Substring(isbn.Length - 3, 3) + "/x" + isbn + ".jpg";
|
||||
pictureBox1.ImageLocation = pic_url;
|
||||
|
||||
richTextBox1.Text = marc.Replace("", "\n");
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
private void pictureBox1_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
Zoom_Picture zp = new Zoom_Picture();
|
||||
zp.url = pictureBox1.ImageLocation;
|
||||
zp.Show();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -12,11 +12,13 @@ namespace UniMarc
|
||||
{
|
||||
public partial class Zoom_Picture : Form
|
||||
{
|
||||
public string url = "";
|
||||
public string ISBN = "";
|
||||
public Zoom_Picture()
|
||||
string url = "";
|
||||
string ISBN = "";
|
||||
public Zoom_Picture(string _url,string _isbn)
|
||||
{
|
||||
InitializeComponent();
|
||||
url = _url;
|
||||
ISBN = _isbn;
|
||||
}
|
||||
|
||||
private void Zoom_Picture_Load(object sender, EventArgs e)
|
||||
|
||||
231
unimarc/unimarc/마크/fMarc_Editor.Designer.cs
generated
Normal file
231
unimarc/unimarc/마크/fMarc_Editor.Designer.cs
generated
Normal file
@@ -0,0 +1,231 @@
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
partial class fMarc_Editor
|
||||
{
|
||||
/// <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()
|
||||
{
|
||||
this.panel5 = new System.Windows.Forms.Panel();
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.etc1 = new System.Windows.Forms.RichTextBox();
|
||||
this.etc2 = new System.Windows.Forms.RichTextBox();
|
||||
this.panel6 = new System.Windows.Forms.Panel();
|
||||
this.lbl_SaveData = new System.Windows.Forms.Label();
|
||||
this.btNext = new System.Windows.Forms.Button();
|
||||
this.btPrev = new System.Windows.Forms.Button();
|
||||
this.btn_Save = new System.Windows.Forms.Button();
|
||||
this.btn_close = new System.Windows.Forms.Button();
|
||||
this.cb_grade = new System.Windows.Forms.ComboBox();
|
||||
this.btn_FillBlank = new System.Windows.Forms.Button();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.panel5.SuspendLayout();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.panel6.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// panel5
|
||||
//
|
||||
this.panel5.Controls.Add(this.tableLayoutPanel1);
|
||||
this.panel5.Controls.Add(this.panel6);
|
||||
this.panel5.Dock = System.Windows.Forms.DockStyle.Right;
|
||||
this.panel5.Location = new System.Drawing.Point(1071, 0);
|
||||
this.panel5.Name = "panel5";
|
||||
this.panel5.Size = new System.Drawing.Size(266, 768);
|
||||
this.panel5.TabIndex = 328;
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 1;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.etc1, 0, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.etc2, 0, 1);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 308);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(266, 460);
|
||||
this.tableLayoutPanel1.TabIndex = 0;
|
||||
//
|
||||
// etc1
|
||||
//
|
||||
this.etc1.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.etc1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.etc1.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.etc1.Location = new System.Drawing.Point(3, 3);
|
||||
this.etc1.Name = "etc1";
|
||||
this.etc1.Size = new System.Drawing.Size(260, 224);
|
||||
this.etc1.TabIndex = 32;
|
||||
this.etc1.Text = "Remark1";
|
||||
//
|
||||
// etc2
|
||||
//
|
||||
this.etc2.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.etc2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.etc2.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.etc2.Location = new System.Drawing.Point(3, 233);
|
||||
this.etc2.Name = "etc2";
|
||||
this.etc2.Size = new System.Drawing.Size(260, 224);
|
||||
this.etc2.TabIndex = 32;
|
||||
this.etc2.Text = "Remark2";
|
||||
//
|
||||
// panel6
|
||||
//
|
||||
this.panel6.Controls.Add(this.lbl_SaveData);
|
||||
this.panel6.Controls.Add(this.btNext);
|
||||
this.panel6.Controls.Add(this.btPrev);
|
||||
this.panel6.Controls.Add(this.btn_Save);
|
||||
this.panel6.Controls.Add(this.btn_close);
|
||||
this.panel6.Controls.Add(this.cb_grade);
|
||||
this.panel6.Controls.Add(this.btn_FillBlank);
|
||||
this.panel6.Controls.Add(this.label6);
|
||||
this.panel6.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.panel6.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel6.Name = "panel6";
|
||||
this.panel6.Size = new System.Drawing.Size(266, 308);
|
||||
this.panel6.TabIndex = 1;
|
||||
//
|
||||
// lbl_SaveData
|
||||
//
|
||||
this.lbl_SaveData.AutoSize = true;
|
||||
this.lbl_SaveData.Font = new System.Drawing.Font("굴림체", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.lbl_SaveData.ForeColor = System.Drawing.Color.PaleTurquoise;
|
||||
this.lbl_SaveData.Location = new System.Drawing.Point(45, 109);
|
||||
this.lbl_SaveData.Name = "lbl_SaveData";
|
||||
this.lbl_SaveData.Size = new System.Drawing.Size(64, 19);
|
||||
this.lbl_SaveData.TabIndex = 319;
|
||||
this.lbl_SaveData.Text = "[] []";
|
||||
//
|
||||
// btNext
|
||||
//
|
||||
this.btNext.Location = new System.Drawing.Point(147, 219);
|
||||
this.btNext.Name = "btNext";
|
||||
this.btNext.Size = new System.Drawing.Size(107, 33);
|
||||
this.btNext.TabIndex = 230;
|
||||
this.btNext.Text = "다 음(F8)";
|
||||
this.btNext.UseVisualStyleBackColor = true;
|
||||
this.btNext.Click += new System.EventHandler(this.btNext_Click);
|
||||
//
|
||||
// btPrev
|
||||
//
|
||||
this.btPrev.Location = new System.Drawing.Point(98, 258);
|
||||
this.btPrev.Name = "btPrev";
|
||||
this.btPrev.Size = new System.Drawing.Size(107, 33);
|
||||
this.btPrev.TabIndex = 229;
|
||||
this.btPrev.Text = "이 전(F7)";
|
||||
this.btPrev.UseVisualStyleBackColor = true;
|
||||
this.btPrev.Click += new System.EventHandler(this.btPrev_Click);
|
||||
//
|
||||
// btn_Save
|
||||
//
|
||||
this.btn_Save.Location = new System.Drawing.Point(32, 180);
|
||||
this.btn_Save.Name = "btn_Save";
|
||||
this.btn_Save.Size = new System.Drawing.Size(77, 33);
|
||||
this.btn_Save.TabIndex = 215;
|
||||
this.btn_Save.Text = "저장(F9)";
|
||||
this.btn_Save.UseVisualStyleBackColor = true;
|
||||
this.btn_Save.Click += new System.EventHandler(this.btn_Save_Click_1);
|
||||
//
|
||||
// btn_close
|
||||
//
|
||||
this.btn_close.Location = new System.Drawing.Point(21, 258);
|
||||
this.btn_close.Name = "btn_close";
|
||||
this.btn_close.Size = new System.Drawing.Size(77, 33);
|
||||
this.btn_close.TabIndex = 215;
|
||||
this.btn_close.Text = "닫 기";
|
||||
this.btn_close.UseVisualStyleBackColor = true;
|
||||
this.btn_close.Click += new System.EventHandler(this.btn_close_Click);
|
||||
//
|
||||
// cb_grade
|
||||
//
|
||||
this.cb_grade.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||
this.cb_grade.FormattingEnabled = true;
|
||||
this.cb_grade.Items.AddRange(new object[] {
|
||||
"A (F9)",
|
||||
"B (F10)",
|
||||
"C (F11)",
|
||||
"D (F12)"});
|
||||
this.cb_grade.Location = new System.Drawing.Point(15, 33);
|
||||
this.cb_grade.Name = "cb_grade";
|
||||
this.cb_grade.Size = new System.Drawing.Size(75, 20);
|
||||
this.cb_grade.TabIndex = 222;
|
||||
//
|
||||
// btn_FillBlank
|
||||
//
|
||||
this.btn_FillBlank.Location = new System.Drawing.Point(115, 153);
|
||||
this.btn_FillBlank.Name = "btn_FillBlank";
|
||||
this.btn_FillBlank.Size = new System.Drawing.Size(77, 60);
|
||||
this.btn_FillBlank.TabIndex = 228;
|
||||
this.btn_FillBlank.Text = "미소장 마크 코리스\r\n칸채우기";
|
||||
this.btn_FillBlank.UseVisualStyleBackColor = true;
|
||||
this.btn_FillBlank.Click += new System.EventHandler(this.btn_FillBlank_Click);
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.label6.Location = new System.Drawing.Point(12, 15);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(62, 12);
|
||||
this.label6.TabIndex = 223;
|
||||
this.label6.Text = "마크 등급";
|
||||
//
|
||||
// fMarc_Editor
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1337, 768);
|
||||
this.Controls.Add(this.panel5);
|
||||
this.Name = "fMarc_Editor";
|
||||
this.Text = "마크편집";
|
||||
this.Load += new System.EventHandler(this.Marc_Plan_Sub_MarcEdit2_Load);
|
||||
this.panel5.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.panel6.ResumeLayout(false);
|
||||
this.panel6.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Panel panel5;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
public System.Windows.Forms.RichTextBox etc1;
|
||||
public System.Windows.Forms.RichTextBox etc2;
|
||||
private System.Windows.Forms.Panel panel6;
|
||||
private System.Windows.Forms.Label lbl_SaveData;
|
||||
private System.Windows.Forms.Button btNext;
|
||||
private System.Windows.Forms.Button btPrev;
|
||||
private System.Windows.Forms.Button btn_Save;
|
||||
private System.Windows.Forms.Button btn_close;
|
||||
private System.Windows.Forms.ComboBox cb_grade;
|
||||
private System.Windows.Forms.Button btn_FillBlank;
|
||||
private System.Windows.Forms.Label label6;
|
||||
}
|
||||
}
|
||||
253
unimarc/unimarc/마크/fMarc_Editor.cs
Normal file
253
unimarc/unimarc/마크/fMarc_Editor.cs
Normal file
@@ -0,0 +1,253 @@
|
||||
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.Drawing.Drawing2D;
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
public partial class fMarc_Editor : Form
|
||||
{
|
||||
string idx;
|
||||
public int row;
|
||||
public string UserName = "";
|
||||
Marc_Plan mp;
|
||||
Helper_DB db = new Helper_DB();
|
||||
String_Text st = new String_Text();
|
||||
Search_Infor si;
|
||||
Help008Tag tag008 = new Help008Tag();
|
||||
MarcEditorControl marcEditorControl1;
|
||||
private MacEditorParameter _param;
|
||||
string mCompidx = PUB.user.CompanyIdx;
|
||||
public fMarc_Editor(string isbn,string marcstring)
|
||||
{
|
||||
InitializeComponent();
|
||||
db.DBcon();
|
||||
marcEditorControl1 = new MarcEditorControl();
|
||||
marcEditorControl1.db = this.db;
|
||||
marcEditorControl1.Dock = DockStyle.Fill;
|
||||
this.StartPosition = FormStartPosition.CenterScreen;
|
||||
this.Controls.Add(marcEditorControl1);
|
||||
|
||||
// Add Save Button programmatically (alternatively, could be done in Designer)
|
||||
Button btn_Save = new Button();
|
||||
btn_Save.Text = "저장(F9)";
|
||||
btn_Save.Dock = DockStyle.Bottom;
|
||||
btn_Save.Height = 40;
|
||||
btn_Save.Click += btn_Save_Click;
|
||||
this.Controls.Add(btn_Save);
|
||||
|
||||
this.KeyPreview = true;
|
||||
}
|
||||
|
||||
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
|
||||
{
|
||||
if (keyData == Keys.F9)
|
||||
{
|
||||
btn_Save_Click(this, EventArgs.Empty);
|
||||
return true;
|
||||
}
|
||||
if (keyData == Keys.Escape)
|
||||
{
|
||||
this.Close();
|
||||
return true;
|
||||
}
|
||||
return base.ProcessCmdKey(ref msg, keyData);
|
||||
}
|
||||
|
||||
private void btn_Save_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public event EventHandler RequestNext;
|
||||
public event EventHandler RequestPrev;
|
||||
|
||||
public class BookUpdatedEventArgs : EventArgs
|
||||
{
|
||||
public string BookName { get; set; }
|
||||
public string Marc { get; set; }
|
||||
public string ISBN { get; set; }
|
||||
public string Author { get; set; }
|
||||
public string Publisher { get; set; }
|
||||
public string Price { get; set; }
|
||||
public int Grade { get; set; }
|
||||
public string Etc1 { get; set; }
|
||||
public string Etc2 { get; set; }
|
||||
public string SaveDate { get; set; }
|
||||
public string User { get; set; }
|
||||
}
|
||||
|
||||
public event EventHandler RequestFillBlankData;
|
||||
|
||||
public void OpenFillBlank(List<FillBlankItem> gridData, string currentIsbn)
|
||||
{
|
||||
var fb = new UniMarc.Marc_FillBlank();
|
||||
foreach (var item in gridData)
|
||||
{
|
||||
fb.InitFillBlank(item);
|
||||
}
|
||||
fb.ISBN = currentIsbn;
|
||||
|
||||
if (fb.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
BulkBooksUpdated?.Invoke(this, new BulkBookUpdatedEventArgs { Updates = fb.FillBlankItems });
|
||||
}
|
||||
}
|
||||
|
||||
public class BulkBookUpdatedEventArgs : EventArgs
|
||||
{
|
||||
public List<FillBlankItem> Updates { get; set; }
|
||||
}
|
||||
|
||||
public event EventHandler<BulkBookUpdatedEventArgs> BulkBooksUpdated;
|
||||
|
||||
private void MarcEditorControl_FillBlankClicked(object sender, EventArgs e)
|
||||
{
|
||||
RequestFillBlankData?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public event EventHandler<BookUpdatedEventArgs> BookUpdated;
|
||||
|
||||
private void MarcEditorControl_BookSaved(object sender, EventArgs e)
|
||||
{
|
||||
// Removed - Logic moved to btn_Save_Click
|
||||
}
|
||||
|
||||
private string mk_BookName(string[] book_name)
|
||||
{
|
||||
string a245 = book_name[0]; // 도서명
|
||||
string x245 = book_name[1]; // 대동서명
|
||||
string b245 = book_name[2]; // 부서명
|
||||
|
||||
string result = a245;
|
||||
|
||||
if (x245 != "")
|
||||
result += " = " + x245;
|
||||
|
||||
if (b245 != "")
|
||||
result += " : " + b245;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
private void MarcEditorControl1_PrevButton(object sender, EventArgs e)
|
||||
{
|
||||
RequestPrev?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void MarcEditorControl1_NextButton(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void LoadBook(string dbMarc, MacEditorParameter p)
|
||||
{
|
||||
this._param = p;
|
||||
this.Text = $"마크편집({p.ISBN13})-{p.BookName}";
|
||||
marcEditorControl1.LoadBookData(dbMarc, p.ISBN13);
|
||||
}
|
||||
|
||||
private void Marc_Plan_Sub_MarcEdit2_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.Show();
|
||||
Application.DoEvents();
|
||||
}
|
||||
|
||||
private void btn_close_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
|
||||
private void btPrev_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestPrev?.Invoke(this, EventArgs.Empty);
|
||||
|
||||
}
|
||||
|
||||
private void btNext_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestNext?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void btn_Save_Click_1(object sender, EventArgs e)
|
||||
{
|
||||
if (marcEditorControl1.CheckValidation() == false) return;
|
||||
|
||||
// Update Specs_Marc table
|
||||
string oriMarc = marcEditorControl1.MakeMarcString();
|
||||
string etc1 = this.etc1.Text.Trim();
|
||||
string etc2 = this.etc2.Text.Trim();
|
||||
string tag008 = marcEditorControl1.text008.Text;
|
||||
var v_grade = cb_grade.SelectedIndex.ToString();
|
||||
|
||||
// 등록번호 분류기호 저자기호 볼륨 복본
|
||||
// 별치 총서명 총서번호 저자 출판사
|
||||
// 정가 ISBN
|
||||
string[] Search_Tag = {
|
||||
"049l", "090a", "090b", "049v", "049c",
|
||||
"049f", "440a", "440v", "245d", "260b",
|
||||
"950b", "020a"
|
||||
};
|
||||
string[] SearchBookTag = st.Take_Tag(oriMarc, Search_Tag);
|
||||
|
||||
// 도서명 (본서명 = 대등서명 : 부서명)
|
||||
string[] BookTag = { "245a", "245x", "245b" };
|
||||
string[] BookNameTag = st.Take_Tag(oriMarc, BookTag);
|
||||
string BookName = mk_BookName(BookNameTag);
|
||||
|
||||
string Table = "Specs_Marc";
|
||||
string[] Search_Col = { "idx" };
|
||||
|
||||
// Current ListIdx (Wait, idx in Marc_Plan corresponds to ListIdx in Parameter?)
|
||||
// In Marc_Plan: ListIdx = idx.
|
||||
string listIdx = _param.ListIdx;
|
||||
string[] Search_data = { listIdx };
|
||||
|
||||
string[] Update_Col = {
|
||||
"marc", "book_name", "etc1", "etc2",
|
||||
"r_num", "class_symbol", "author_symbol", "prefix", "s_book_name1",
|
||||
"s_book_num1", "author", "book_comp", "price", "ISBN", "tag008","grade"
|
||||
};
|
||||
|
||||
string[] Update_data = {
|
||||
oriMarc, BookName, etc1, etc2,
|
||||
SearchBookTag[0], SearchBookTag[1], SearchBookTag[2], SearchBookTag[5], SearchBookTag[6],
|
||||
SearchBookTag[7], SearchBookTag[8], SearchBookTag[9], SearchBookTag[10], SearchBookTag[11], tag008,v_grade
|
||||
};
|
||||
|
||||
string cmd = db.More_Update(Table, Update_Col, Update_data, Search_Col, Search_data);
|
||||
Helper_DB.ExcuteNonQuery(cmd);
|
||||
|
||||
// Notify Parent
|
||||
BookUpdated?.Invoke(this, new BookUpdatedEventArgs
|
||||
{
|
||||
BookName = BookName,
|
||||
Marc = oriMarc,
|
||||
ISBN = SearchBookTag[11],
|
||||
Author = SearchBookTag[8],
|
||||
Publisher = SearchBookTag[9],
|
||||
Price = SearchBookTag[10],
|
||||
Grade = cb_grade.SelectedIndex,
|
||||
Etc1 = etc1,
|
||||
Etc2 = etc2,
|
||||
SaveDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
|
||||
User = UserName
|
||||
});
|
||||
|
||||
MessageBox.Show("저장되었습니다!");
|
||||
}
|
||||
|
||||
private void btn_FillBlank_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestFillBlankData?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
}
|
||||
}
|
||||
248
unimarc/unimarc/마크/fMarc_Editor_Spec.Designer.cs
generated
Normal file
248
unimarc/unimarc/마크/fMarc_Editor_Spec.Designer.cs
generated
Normal file
@@ -0,0 +1,248 @@
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
partial class fMarc_Editor_Spec
|
||||
{
|
||||
/// <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()
|
||||
{
|
||||
this.panel5 = new System.Windows.Forms.Panel();
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.etc1 = new System.Windows.Forms.RichTextBox();
|
||||
this.etc2 = new System.Windows.Forms.RichTextBox();
|
||||
this.panel6 = new System.Windows.Forms.Panel();
|
||||
this.radD = new System.Windows.Forms.RadioButton();
|
||||
this.radC = new System.Windows.Forms.RadioButton();
|
||||
this.radB = new System.Windows.Forms.RadioButton();
|
||||
this.radA = new System.Windows.Forms.RadioButton();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.lbl_SaveData = new System.Windows.Forms.TextBox();
|
||||
this.btNext = new System.Windows.Forms.Button();
|
||||
this.btPrev = new System.Windows.Forms.Button();
|
||||
this.btn_Save = new System.Windows.Forms.Button();
|
||||
this.panel5.SuspendLayout();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.panel6.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// panel5
|
||||
//
|
||||
this.panel5.Controls.Add(this.tableLayoutPanel1);
|
||||
this.panel5.Controls.Add(this.panel6);
|
||||
this.panel5.Dock = System.Windows.Forms.DockStyle.Right;
|
||||
this.panel5.Location = new System.Drawing.Point(1071, 0);
|
||||
this.panel5.Name = "panel5";
|
||||
this.panel5.Size = new System.Drawing.Size(266, 768);
|
||||
this.panel5.TabIndex = 327;
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 1;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.etc1, 0, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.etc2, 0, 1);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 308);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(266, 460);
|
||||
this.tableLayoutPanel1.TabIndex = 0;
|
||||
//
|
||||
// etc1
|
||||
//
|
||||
this.etc1.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.etc1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.etc1.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.etc1.Location = new System.Drawing.Point(3, 3);
|
||||
this.etc1.Name = "etc1";
|
||||
this.etc1.Size = new System.Drawing.Size(260, 224);
|
||||
this.etc1.TabIndex = 32;
|
||||
this.etc1.Text = "Remark1";
|
||||
//
|
||||
// etc2
|
||||
//
|
||||
this.etc2.BackColor = System.Drawing.SystemColors.ScrollBar;
|
||||
this.etc2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.etc2.Font = new System.Drawing.Font("굴림체", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.etc2.Location = new System.Drawing.Point(3, 233);
|
||||
this.etc2.Name = "etc2";
|
||||
this.etc2.Size = new System.Drawing.Size(260, 224);
|
||||
this.etc2.TabIndex = 32;
|
||||
this.etc2.Text = "Remark2";
|
||||
//
|
||||
// panel6
|
||||
//
|
||||
this.panel6.Controls.Add(this.radD);
|
||||
this.panel6.Controls.Add(this.radC);
|
||||
this.panel6.Controls.Add(this.radB);
|
||||
this.panel6.Controls.Add(this.radA);
|
||||
this.panel6.Controls.Add(this.label6);
|
||||
this.panel6.Controls.Add(this.lbl_SaveData);
|
||||
this.panel6.Controls.Add(this.btNext);
|
||||
this.panel6.Controls.Add(this.btPrev);
|
||||
this.panel6.Controls.Add(this.btn_Save);
|
||||
this.panel6.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.panel6.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel6.Name = "panel6";
|
||||
this.panel6.Size = new System.Drawing.Size(266, 308);
|
||||
this.panel6.TabIndex = 1;
|
||||
//
|
||||
// radD
|
||||
//
|
||||
this.radD.AutoSize = true;
|
||||
this.radD.Font = new System.Drawing.Font("Tahoma", 14F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.radD.Location = new System.Drawing.Point(210, 12);
|
||||
this.radD.Name = "radD";
|
||||
this.radD.Size = new System.Drawing.Size(42, 27);
|
||||
this.radD.TabIndex = 328;
|
||||
this.radD.TabStop = true;
|
||||
this.radD.Text = "D";
|
||||
this.radD.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// radC
|
||||
//
|
||||
this.radC.AutoSize = true;
|
||||
this.radC.Font = new System.Drawing.Font("Tahoma", 14F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.radC.Location = new System.Drawing.Point(163, 12);
|
||||
this.radC.Name = "radC";
|
||||
this.radC.Size = new System.Drawing.Size(41, 27);
|
||||
this.radC.TabIndex = 327;
|
||||
this.radC.TabStop = true;
|
||||
this.radC.Text = "C";
|
||||
this.radC.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// radB
|
||||
//
|
||||
this.radB.AutoSize = true;
|
||||
this.radB.Font = new System.Drawing.Font("Tahoma", 14F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.radB.Location = new System.Drawing.Point(116, 12);
|
||||
this.radB.Name = "radB";
|
||||
this.radB.Size = new System.Drawing.Size(41, 27);
|
||||
this.radB.TabIndex = 326;
|
||||
this.radB.TabStop = true;
|
||||
this.radB.Text = "B";
|
||||
this.radB.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// radA
|
||||
//
|
||||
this.radA.AutoSize = true;
|
||||
this.radA.Font = new System.Drawing.Font("Tahoma", 14F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.radA.Location = new System.Drawing.Point(69, 12);
|
||||
this.radA.Name = "radA";
|
||||
this.radA.Size = new System.Drawing.Size(41, 27);
|
||||
this.radA.TabIndex = 325;
|
||||
this.radA.TabStop = true;
|
||||
this.radA.Text = "A";
|
||||
this.radA.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.label6.Location = new System.Drawing.Point(28, 22);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(31, 12);
|
||||
this.label6.TabIndex = 324;
|
||||
this.label6.Text = "등급";
|
||||
//
|
||||
// lbl_SaveData
|
||||
//
|
||||
this.lbl_SaveData.Font = new System.Drawing.Font("굴림체", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
|
||||
this.lbl_SaveData.ForeColor = System.Drawing.Color.PaleTurquoise;
|
||||
this.lbl_SaveData.Location = new System.Drawing.Point(9, 45);
|
||||
this.lbl_SaveData.Multiline = true;
|
||||
this.lbl_SaveData.Name = "lbl_SaveData";
|
||||
this.lbl_SaveData.Size = new System.Drawing.Size(245, 179);
|
||||
this.lbl_SaveData.TabIndex = 319;
|
||||
this.lbl_SaveData.Text = "[] []";
|
||||
//
|
||||
// btNext
|
||||
//
|
||||
this.btNext.Location = new System.Drawing.Point(147, 269);
|
||||
this.btNext.Name = "btNext";
|
||||
this.btNext.Size = new System.Drawing.Size(107, 33);
|
||||
this.btNext.TabIndex = 230;
|
||||
this.btNext.Text = "다 음(F8)";
|
||||
this.btNext.UseVisualStyleBackColor = true;
|
||||
this.btNext.Click += new System.EventHandler(this.btNext_Click);
|
||||
//
|
||||
// btPrev
|
||||
//
|
||||
this.btPrev.Location = new System.Drawing.Point(14, 269);
|
||||
this.btPrev.Name = "btPrev";
|
||||
this.btPrev.Size = new System.Drawing.Size(107, 33);
|
||||
this.btPrev.TabIndex = 229;
|
||||
this.btPrev.Text = "이 전(F7)";
|
||||
this.btPrev.UseVisualStyleBackColor = true;
|
||||
this.btPrev.Click += new System.EventHandler(this.btPrev_Click);
|
||||
//
|
||||
// btn_Save
|
||||
//
|
||||
this.btn_Save.Location = new System.Drawing.Point(147, 230);
|
||||
this.btn_Save.Name = "btn_Save";
|
||||
this.btn_Save.Size = new System.Drawing.Size(107, 33);
|
||||
this.btn_Save.TabIndex = 215;
|
||||
this.btn_Save.Text = "저장(F9)";
|
||||
this.btn_Save.UseVisualStyleBackColor = true;
|
||||
this.btn_Save.Click += new System.EventHandler(this.btn_Save_Click);
|
||||
//
|
||||
// fMarc_Editor_Spec
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1337, 768);
|
||||
this.Controls.Add(this.panel5);
|
||||
this.Name = "fMarc_Editor_Spec";
|
||||
this.Text = "마크편집";
|
||||
this.Load += new System.EventHandler(this.Marc_Plan_Sub_MarcEdit2_Load);
|
||||
this.panel5.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.panel6.ResumeLayout(false);
|
||||
this.panel6.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Panel panel5;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
public System.Windows.Forms.RichTextBox etc1;
|
||||
public System.Windows.Forms.RichTextBox etc2;
|
||||
private System.Windows.Forms.Panel panel6;
|
||||
private System.Windows.Forms.TextBox lbl_SaveData;
|
||||
private System.Windows.Forms.Button btNext;
|
||||
private System.Windows.Forms.Button btPrev;
|
||||
private System.Windows.Forms.Button btn_Save;
|
||||
private System.Windows.Forms.RadioButton radD;
|
||||
private System.Windows.Forms.RadioButton radC;
|
||||
private System.Windows.Forms.RadioButton radB;
|
||||
private System.Windows.Forms.RadioButton radA;
|
||||
private System.Windows.Forms.Label label6;
|
||||
}
|
||||
}
|
||||
@@ -11,7 +11,7 @@ using System.Drawing.Drawing2D;
|
||||
|
||||
namespace UniMarc
|
||||
{
|
||||
public partial class Marc_Plan_Sub_MarcEdit2 : Form
|
||||
public partial class fMarc_Editor_Spec : Form
|
||||
{
|
||||
string idx;
|
||||
public int row;
|
||||
@@ -22,23 +22,21 @@ namespace UniMarc
|
||||
Search_Infor si;
|
||||
Help008Tag tag008 = new Help008Tag();
|
||||
MarcEditorControl marcEditorControl1;
|
||||
public Marc_Plan_Sub_MarcEdit2(string isbn,string marcstring)
|
||||
private MacEditorParameter _param;
|
||||
|
||||
public fMarc_Editor_Spec(string isbn, string marcstring)
|
||||
{
|
||||
InitializeComponent();
|
||||
db.DBcon();
|
||||
marcEditorControl1 = new MarcEditorControl();
|
||||
marcEditorControl1.db = this.db;
|
||||
marcEditorControl1.FillBlankClicked += MarcEditorControl_FillBlankClicked;
|
||||
marcEditorControl1.BookSaved += MarcEditorControl_BookSaved;
|
||||
marcEditorControl1.NextButton += MarcEditorControl1_NextButton;
|
||||
marcEditorControl1.PrevButton += MarcEditorControl1_PrevButton;
|
||||
marcEditorControl1.CloseButton += (s1, e1) => { this.Close(); };
|
||||
marcEditorControl1.Dock = DockStyle.Fill;
|
||||
this.StartPosition = FormStartPosition.CenterScreen;
|
||||
this.Controls.Add(marcEditorControl1);
|
||||
this.KeyPreview = true;
|
||||
this.KeyDown += (s1, e1) => {
|
||||
if(e1.KeyCode == Keys.Escape)
|
||||
this.KeyDown += (s1, e1) =>
|
||||
{
|
||||
if (e1.KeyCode == Keys.Escape)
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
@@ -73,36 +71,80 @@ namespace UniMarc
|
||||
fb.InitFillBlank(item);
|
||||
}
|
||||
fb.ISBN = currentIsbn;
|
||||
|
||||
|
||||
if (fb.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
BulkBooksUpdated?.Invoke(this, new BulkBookUpdatedEventArgs { Updates = fb.FillBlankItems });
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public class BulkBookUpdatedEventArgs : EventArgs
|
||||
{
|
||||
public List<FillBlankItem> Updates { get; set; }
|
||||
}
|
||||
|
||||
public event EventHandler<BulkBookUpdatedEventArgs> BulkBooksUpdated;
|
||||
|
||||
private void MarcEditorControl_FillBlankClicked(object sender, EventArgs e)
|
||||
{
|
||||
RequestFillBlankData?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
public event EventHandler<BulkBookUpdatedEventArgs> BulkBooksUpdated;
|
||||
|
||||
|
||||
|
||||
public event EventHandler<BookUpdatedEventArgs> BookUpdated;
|
||||
|
||||
private void MarcEditorControl_BookSaved(object sender, MarcEditorControl.BookSavedEventArgs e)
|
||||
|
||||
private string mk_BookName(string[] book_name)
|
||||
{
|
||||
string a245 = book_name[0]; // 도서명
|
||||
string x245 = book_name[1]; // 대동서명
|
||||
string b245 = book_name[2]; // 부서명
|
||||
|
||||
string result = a245;
|
||||
|
||||
if (x245 != "")
|
||||
result += " = " + x245;
|
||||
|
||||
if (b245 != "")
|
||||
result += " : " + b245;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public void LoadBook(string dbMarc, MacEditorParameter p)
|
||||
{
|
||||
this._param = p;
|
||||
this.Text = $"마크편집({p.ISBN13})-{p.BookName}";
|
||||
marcEditorControl1.LoadBookData(dbMarc, p.ISBN13);
|
||||
}
|
||||
|
||||
private void Marc_Plan_Sub_MarcEdit2_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.Show();
|
||||
Application.DoEvents();
|
||||
}
|
||||
|
||||
private void btn_FillBlank_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestFillBlankData?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void btPrev_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestPrev?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void btNext_Click(object sender, EventArgs e)
|
||||
{
|
||||
RequestNext?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void btn_Save_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (marcEditorControl1.CheckValidation() == false) return;
|
||||
|
||||
// Update Specs_Marc table
|
||||
string oriMarc = e.DBMarc;
|
||||
string etc1 = e.Param.Remark1 ?? "";
|
||||
string etc2 = e.Param.Remark2 ?? "";
|
||||
string tag008 = e.Param.text008;
|
||||
string oriMarc = marcEditorControl1.MakeMarcString();
|
||||
string etc1 = this.etc1.Text.Trim();
|
||||
string etc2 = this.etc2.Text.Trim();
|
||||
string tag008 = marcEditorControl1.text008.Text;
|
||||
var v_grade = cb_grade.SelectedIndex.ToString();
|
||||
|
||||
// 등록번호 분류기호 저자기호 볼륨 복본
|
||||
// 별치 총서명 총서번호 저자 출판사
|
||||
@@ -124,18 +166,19 @@ namespace UniMarc
|
||||
|
||||
// Current ListIdx (Wait, idx in Marc_Plan corresponds to ListIdx in Parameter?)
|
||||
// In Marc_Plan: ListIdx = idx.
|
||||
string listIdx = e.Param.ListIdx;
|
||||
string listIdx = _param.ListIdx;
|
||||
string[] Search_data = { listIdx };
|
||||
|
||||
string[] Update_Col = {
|
||||
string[] Update_Col = {
|
||||
"marc", "book_name", "etc1", "etc2",
|
||||
"r_num", "class_symbol", "author_symbol", "prefix", "s_book_name1",
|
||||
"s_book_num1", "author", "book_comp", "price", "ISBN", "tag008"
|
||||
"s_book_num1", "author", "book_comp", "price", "ISBN", "tag008","grade"
|
||||
};
|
||||
|
||||
string[] Update_data = {
|
||||
oriMarc, BookName, etc1, etc2,
|
||||
SearchBookTag[0], SearchBookTag[1], SearchBookTag[2], SearchBookTag[5], SearchBookTag[6],
|
||||
SearchBookTag[7], SearchBookTag[8], SearchBookTag[9], SearchBookTag[10], SearchBookTag[11], tag008
|
||||
SearchBookTag[7], SearchBookTag[8], SearchBookTag[9], SearchBookTag[10], SearchBookTag[11], tag008,v_grade
|
||||
};
|
||||
|
||||
string cmd = db.More_Update(Table, Update_Col, Update_data, Search_Col, Search_data);
|
||||
@@ -150,53 +193,19 @@ namespace UniMarc
|
||||
Author = SearchBookTag[8],
|
||||
Publisher = SearchBookTag[9],
|
||||
Price = SearchBookTag[10],
|
||||
Grade = e.Param.Grade,
|
||||
Grade = v_grade,
|
||||
Etc1 = etc1,
|
||||
Etc2 = etc2,
|
||||
SaveDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
|
||||
User = UserName
|
||||
});
|
||||
|
||||
|
||||
MessageBox.Show("저장되었습니다!");
|
||||
}
|
||||
|
||||
private string mk_BookName(string[] book_name)
|
||||
private void btn_close_Click(object sender, EventArgs e)
|
||||
{
|
||||
string a245 = book_name[0]; // 도서명
|
||||
string x245 = book_name[1]; // 대동서명
|
||||
string b245 = book_name[2]; // 부서명
|
||||
|
||||
string result = a245;
|
||||
|
||||
if (x245 != "")
|
||||
result += " = " + x245;
|
||||
|
||||
if (b245 != "")
|
||||
result += " : " + b245;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
private void MarcEditorControl1_PrevButton(object sender, EventArgs e)
|
||||
{
|
||||
RequestPrev?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
private void MarcEditorControl1_NextButton(object sender, EventArgs e)
|
||||
{
|
||||
RequestNext?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
|
||||
public void LoadBook(string dbMarc, MacEditorParameter p)
|
||||
{
|
||||
this.Text = $"마크편집({p.ISBN13})-{p.BookName}";
|
||||
marcEditorControl1.LoadBookData(dbMarc, p);
|
||||
}
|
||||
|
||||
private void Marc_Plan_Sub_MarcEdit2_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.Show();
|
||||
Application.DoEvents();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user