diff --git a/unimarc/.vs/unimarc/v16/.suo b/unimarc/.vs/unimarc/v16/.suo index d08aa96..efa33bc 100644 Binary files a/unimarc/.vs/unimarc/v16/.suo and b/unimarc/.vs/unimarc/v16/.suo differ diff --git a/unimarc/unimarc/Skill.cs b/unimarc/unimarc/Skill.cs index a40fa9a..8368b52 100644 --- a/unimarc/unimarc/Skill.cs +++ b/unimarc/unimarc/Skill.cs @@ -3008,7 +3008,7 @@ namespace WindowsFormsApp1 // url생성 string url = "https://dapi.kakao.com/v3/search/book"; - string query = string.Format("{0}?query={1}&target={2}&", url, Query, Type); + string query = string.Format("{0}?query={1}&target={2}&size={3}", url, Query, Type, 30); WebRequest request = WebRequest.Create(query); string rKey = "e3935565b731a2a6f32880c90d76403a"; diff --git a/unimarc/unimarc/bin/Debug/UniMarc.exe b/unimarc/unimarc/bin/Debug/UniMarc.exe index 34bc77b..d281686 100644 Binary files a/unimarc/unimarc/bin/Debug/UniMarc.exe and b/unimarc/unimarc/bin/Debug/UniMarc.exe differ diff --git a/unimarc/unimarc/bin/Debug/UniMarc.pdb b/unimarc/unimarc/bin/Debug/UniMarc.pdb index 7d72089..a3200e1 100644 Binary files a/unimarc/unimarc/bin/Debug/UniMarc.pdb and b/unimarc/unimarc/bin/Debug/UniMarc.pdb differ diff --git a/unimarc/unimarc/bin/Debug/ko/UniMarc.resources.dll b/unimarc/unimarc/bin/Debug/ko/UniMarc.resources.dll index 8a9372f..f2ac50e 100644 Binary files a/unimarc/unimarc/bin/Debug/ko/UniMarc.resources.dll and b/unimarc/unimarc/bin/Debug/ko/UniMarc.resources.dll differ diff --git a/unimarc/unimarc/obj/Debug/UniMarc.csproj.GenerateResource.cache b/unimarc/unimarc/obj/Debug/UniMarc.csproj.GenerateResource.cache index 28de3dd..e7fffb7 100644 Binary files a/unimarc/unimarc/obj/Debug/UniMarc.csproj.GenerateResource.cache and b/unimarc/unimarc/obj/Debug/UniMarc.csproj.GenerateResource.cache differ diff --git a/unimarc/unimarc/obj/Debug/UniMarc.exe b/unimarc/unimarc/obj/Debug/UniMarc.exe index 34bc77b..d281686 100644 Binary files a/unimarc/unimarc/obj/Debug/UniMarc.exe and b/unimarc/unimarc/obj/Debug/UniMarc.exe differ diff --git a/unimarc/unimarc/obj/Debug/UniMarc.pdb b/unimarc/unimarc/obj/Debug/UniMarc.pdb index 7d72089..a3200e1 100644 Binary files a/unimarc/unimarc/obj/Debug/UniMarc.pdb and b/unimarc/unimarc/obj/Debug/UniMarc.pdb differ diff --git a/unimarc/unimarc/obj/Debug/ko/UniMarc.resources.dll b/unimarc/unimarc/obj/Debug/ko/UniMarc.resources.dll index 8a9372f..f2ac50e 100644 Binary files a/unimarc/unimarc/obj/Debug/ko/UniMarc.resources.dll and b/unimarc/unimarc/obj/Debug/ko/UniMarc.resources.dll differ diff --git a/unimarc/unimarc/마크/Check_ISBN.Designer.cs b/unimarc/unimarc/마크/Check_ISBN.Designer.cs index 89136e6..72519bc 100644 --- a/unimarc/unimarc/마크/Check_ISBN.Designer.cs +++ b/unimarc/unimarc/마크/Check_ISBN.Designer.cs @@ -28,9 +28,9 @@ /// private void InitializeComponent() { - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle(); this.dataGridView1 = new System.Windows.Forms.DataGridView(); this.idx = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.num = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -66,7 +66,14 @@ this.richTextBox1 = new System.Windows.Forms.RichTextBox(); this.btn_yes24 = new System.Windows.Forms.Button(); this.Check_Marc = new System.Windows.Forms.CheckBox(); + this.panel1 = new System.Windows.Forms.Panel(); + this.panel2 = new System.Windows.Forms.Panel(); + this.panel3 = new System.Windows.Forms.Panel(); + this.btn_ComparePrice = new System.Windows.Forms.Button(); ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); + this.panel1.SuspendLayout(); + this.panel2.SuspendLayout(); + this.panel3.SuspendLayout(); this.SuspendLayout(); // // dataGridView1 @@ -75,13 +82,13 @@ this.dataGridView1.AllowUserToDeleteRows = false; this.dataGridView1.BackgroundColor = System.Drawing.SystemColors.Control; this.dataGridView1.BorderStyle = System.Windows.Forms.BorderStyle.None; - 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; - this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1; + dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle10.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle10.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); + dataGridViewCellStyle10.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle10.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle10; this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.idx, @@ -105,22 +112,23 @@ this.sold_out, this.image, this.api_data}); + this.dataGridView1.Dock = System.Windows.Forms.DockStyle.Fill; this.dataGridView1.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnF2; - this.dataGridView1.Location = new System.Drawing.Point(12, 35); + this.dataGridView1.Location = new System.Drawing.Point(0, 0); this.dataGridView1.Name = "dataGridView1"; - 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.True; - this.dataGridView1.RowHeadersDefaultCellStyle = dataGridViewCellStyle2; + dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + dataGridViewCellStyle11.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle11.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); + dataGridViewCellStyle11.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle11.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle11.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle11.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.dataGridView1.RowHeadersDefaultCellStyle = dataGridViewCellStyle11; this.dataGridView1.RowHeadersWidth = 20; - dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - this.dataGridView1.RowsDefaultCellStyle = dataGridViewCellStyle3; + dataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + this.dataGridView1.RowsDefaultCellStyle = dataGridViewCellStyle12; this.dataGridView1.RowTemplate.Height = 23; - this.dataGridView1.Size = new System.Drawing.Size(1608, 547); + this.dataGridView1.Size = new System.Drawing.Size(1632, 594); this.dataGridView1.TabIndex = 0; this.dataGridView1.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellClick); this.dataGridView1.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick); @@ -179,6 +187,7 @@ // this.count.HeaderText = "수량"; this.count.Name = "count"; + this.count.Visible = false; this.count.Width = 50; // // unit @@ -191,12 +200,14 @@ // this.total.HeaderText = "합계"; this.total.Name = "total"; + this.total.Visible = false; this.total.Width = 70; // // condition // this.condition.HeaderText = "상태"; this.condition.Name = "condition"; + this.condition.Visible = false; // // price // @@ -244,7 +255,7 @@ // // btn_lookup // - this.btn_lookup.Location = new System.Drawing.Point(706, 7); + this.btn_lookup.Location = new System.Drawing.Point(693, 4); this.btn_lookup.Name = "btn_lookup"; this.btn_lookup.Size = new System.Drawing.Size(99, 23); this.btn_lookup.TabIndex = 1; @@ -256,7 +267,7 @@ // this.cb_filter.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; this.cb_filter.FormattingEnabled = true; - this.cb_filter.Location = new System.Drawing.Point(516, 8); + this.cb_filter.Location = new System.Drawing.Point(511, 5); this.cb_filter.Name = "cb_filter"; this.cb_filter.Size = new System.Drawing.Size(161, 20); this.cb_filter.TabIndex = 2; @@ -264,7 +275,7 @@ // label1 // this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(16, 12); + this.label1.Location = new System.Drawing.Point(11, 9); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(41, 12); this.label1.TabIndex = 3; @@ -273,7 +284,7 @@ // tb_list_name // this.tb_list_name.Enabled = false; - this.tb_list_name.Location = new System.Drawing.Point(59, 8); + this.tb_list_name.Location = new System.Drawing.Point(54, 5); this.tb_list_name.Name = "tb_list_name"; this.tb_list_name.Size = new System.Drawing.Size(213, 21); this.tb_list_name.TabIndex = 4; @@ -282,7 +293,7 @@ // label2 // this.label2.AutoSize = true; - this.label2.Location = new System.Drawing.Point(457, 12); + this.label2.Location = new System.Drawing.Point(452, 9); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(57, 12); this.label2.TabIndex = 3; @@ -290,7 +301,7 @@ // // btn_Save // - this.btn_Save.Location = new System.Drawing.Point(815, 6); + this.btn_Save.Location = new System.Drawing.Point(796, 4); this.btn_Save.Name = "btn_Save"; this.btn_Save.Size = new System.Drawing.Size(99, 23); this.btn_Save.TabIndex = 1; @@ -300,7 +311,7 @@ // // btn_Close // - this.btn_Close.Location = new System.Drawing.Point(1033, 7); + this.btn_Close.Location = new System.Drawing.Point(1105, 4); this.btn_Close.Name = "btn_Close"; this.btn_Close.Size = new System.Drawing.Size(99, 23); this.btn_Close.TabIndex = 1; @@ -311,7 +322,7 @@ // label3 // this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(278, 12); + this.label3.Location = new System.Drawing.Point(285, 9); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(57, 12); this.label3.TabIndex = 5; @@ -321,7 +332,7 @@ // this.cb_api.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; this.cb_api.FormattingEnabled = true; - this.cb_api.Location = new System.Drawing.Point(337, 8); + this.cb_api.Location = new System.Drawing.Point(344, 5); this.cb_api.Name = "cb_api"; this.cb_api.Size = new System.Drawing.Size(93, 20); this.cb_api.TabIndex = 6; @@ -329,22 +340,23 @@ // // progressBar1 // - this.progressBar1.Location = new System.Drawing.Point(1166, 7); + this.progressBar1.Location = new System.Drawing.Point(1241, 4); this.progressBar1.Name = "progressBar1"; this.progressBar1.Size = new System.Drawing.Size(219, 23); this.progressBar1.TabIndex = 7; // // richTextBox1 // - this.richTextBox1.Location = new System.Drawing.Point(12, 589); + this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill; + this.richTextBox1.Location = new System.Drawing.Point(0, 0); this.richTextBox1.Name = "richTextBox1"; - this.richTextBox1.Size = new System.Drawing.Size(1608, 123); + this.richTextBox1.Size = new System.Drawing.Size(1632, 100); this.richTextBox1.TabIndex = 8; this.richTextBox1.Text = ""; // // btn_yes24 // - this.btn_yes24.Location = new System.Drawing.Point(924, 7); + this.btn_yes24.Location = new System.Drawing.Point(1002, 4); this.btn_yes24.Name = "btn_yes24"; this.btn_yes24.Size = new System.Drawing.Size(99, 23); this.btn_yes24.TabIndex = 1; @@ -358,39 +370,80 @@ this.Check_Marc.Checked = true; this.Check_Marc.CheckState = System.Windows.Forms.CheckState.Checked; this.Check_Marc.Enabled = false; - this.Check_Marc.Location = new System.Drawing.Point(1422, 10); + this.Check_Marc.Location = new System.Drawing.Point(1488, 7); this.Check_Marc.Name = "Check_Marc"; this.Check_Marc.Size = new System.Drawing.Size(132, 16); this.Check_Marc.TabIndex = 9; this.Check_Marc.Text = "마크ISBN 동시 저장"; this.Check_Marc.UseVisualStyleBackColor = true; // + // panel1 + // + this.panel1.Controls.Add(this.btn_ComparePrice); + this.panel1.Controls.Add(this.label1); + this.panel1.Controls.Add(this.Check_Marc); + this.panel1.Controls.Add(this.btn_lookup); + this.panel1.Controls.Add(this.btn_Save); + this.panel1.Controls.Add(this.progressBar1); + this.panel1.Controls.Add(this.btn_Close); + this.panel1.Controls.Add(this.cb_api); + this.panel1.Controls.Add(this.btn_yes24); + this.panel1.Controls.Add(this.label3); + this.panel1.Controls.Add(this.cb_filter); + this.panel1.Controls.Add(this.tb_list_name); + this.panel1.Controls.Add(this.label2); + 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(1632, 30); + this.panel1.TabIndex = 10; + // + // panel2 + // + this.panel2.Controls.Add(this.richTextBox1); + this.panel2.Dock = System.Windows.Forms.DockStyle.Bottom; + this.panel2.Location = new System.Drawing.Point(0, 624); + this.panel2.Name = "panel2"; + this.panel2.Size = new System.Drawing.Size(1632, 100); + this.panel2.TabIndex = 11; + // + // panel3 + // + this.panel3.Controls.Add(this.dataGridView1); + this.panel3.Dock = System.Windows.Forms.DockStyle.Fill; + this.panel3.Location = new System.Drawing.Point(0, 30); + this.panel3.Name = "panel3"; + this.panel3.Size = new System.Drawing.Size(1632, 594); + this.panel3.TabIndex = 12; + // + // btn_ComparePrice + // + this.btn_ComparePrice.Location = new System.Drawing.Point(899, 4); + this.btn_ComparePrice.Name = "btn_ComparePrice"; + this.btn_ComparePrice.Size = new System.Drawing.Size(99, 23); + this.btn_ComparePrice.TabIndex = 10; + this.btn_ComparePrice.Text = "정 가 대 조"; + this.btn_ComparePrice.UseVisualStyleBackColor = true; + this.btn_ComparePrice.Click += new System.EventHandler(this.btn_ComparePrice_Click); + // // Check_ISBN // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(1632, 724); - this.Controls.Add(this.Check_Marc); - this.Controls.Add(this.richTextBox1); - this.Controls.Add(this.progressBar1); - this.Controls.Add(this.cb_api); - this.Controls.Add(this.label3); - this.Controls.Add(this.tb_list_name); - this.Controls.Add(this.label2); - this.Controls.Add(this.label1); - this.Controls.Add(this.cb_filter); - this.Controls.Add(this.btn_yes24); - this.Controls.Add(this.btn_Close); - this.Controls.Add(this.btn_Save); - this.Controls.Add(this.btn_lookup); - this.Controls.Add(this.dataGridView1); + this.Controls.Add(this.panel3); + this.Controls.Add(this.panel2); + this.Controls.Add(this.panel1); this.Name = "Check_ISBN"; this.Text = "ISBN 조회"; this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Check_ISBN_FormClosing); this.Load += new System.EventHandler(this.Check_ISBN_Load); ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit(); + this.panel1.ResumeLayout(false); + this.panel1.PerformLayout(); + this.panel2.ResumeLayout(false); + this.panel3.ResumeLayout(false); this.ResumeLayout(false); - this.PerformLayout(); } @@ -408,6 +461,8 @@ private System.Windows.Forms.RichTextBox richTextBox1; private System.Windows.Forms.Button btn_yes24; public System.Windows.Forms.TextBox tb_list_name; + private System.Windows.Forms.CheckBox Check_Marc; + private System.Windows.Forms.Panel panel1; private System.Windows.Forms.DataGridViewTextBoxColumn idx; private System.Windows.Forms.DataGridViewTextBoxColumn num; private System.Windows.Forms.DataGridViewTextBoxColumn isbn; @@ -429,6 +484,8 @@ private System.Windows.Forms.DataGridViewTextBoxColumn sold_out; private System.Windows.Forms.DataGridViewTextBoxColumn image; private System.Windows.Forms.DataGridViewTextBoxColumn api_data; - private System.Windows.Forms.CheckBox Check_Marc; + private System.Windows.Forms.Panel panel2; + private System.Windows.Forms.Panel panel3; + private System.Windows.Forms.Button btn_ComparePrice; } } \ No newline at end of file diff --git a/unimarc/unimarc/마크/Check_ISBN.cs b/unimarc/unimarc/마크/Check_ISBN.cs index ba8c9ce..83af771 100644 --- a/unimarc/unimarc/마크/Check_ISBN.cs +++ b/unimarc/unimarc/마크/Check_ISBN.cs @@ -72,6 +72,7 @@ namespace WindowsFormsApp1.Mac public void DataLoad(string ListName) { dataGridView1.Rows.Clear(); + cb_api.Items.Clear(); list_name = ListName; @@ -356,6 +357,8 @@ namespace WindowsFormsApp1.Mac L_Array.Add(gridview.Rows[a].Cells["book_comp"].Value.ToString()); break; } + L_type.Add("display"); + L_Array.Add("30"); #endregion string[] arrayType = L_type.ToArray(); @@ -483,7 +486,8 @@ namespace WindowsFormsApp1.Mac dataGridView1.Rows[row].DefaultCellStyle.BackColor = Color.LightGray; if (cb_filter.SelectedItem.ToString() == "별치조사") input_api_aladin(insert, row, newstring); - input_api(insert, row, newstring);*/ + input_api(insert, row, newstring); + */ } string Aladin_CategorySort(string insert) { @@ -589,6 +593,7 @@ namespace WindowsFormsApp1.Mac grid[1] = data[1]; grid[2] = data[2]; string[] tmp_isbn = data[3].Split(' '); + if (tmp_isbn.Length < 2) grid[3] = data[3].Replace(" ", ""); @@ -619,6 +624,7 @@ namespace WindowsFormsApp1.Mac input_api(grid, row, newstring); } + /// /// API에서 가져온 데이터가 요구한 데이터와 일치하는지 알아보는 함수 /// @@ -654,9 +660,11 @@ namespace WindowsFormsApp1.Mac dataGridView1.Rows[idx].Cells["category"].Value = value[6]; dataGridView1.Rows[idx].Cells["sold_out"].Value = value[7]; dataGridView1.Rows[idx].Cells["image"].Value = value[8]; + dataGridView1.Rows[idx].DefaultCellStyle.BackColor = Color.Yellow; } } + private void btn_Save_Click(object sender, EventArgs e) { string[] Edit_tbl = { "isbn", "price", "pubDate", "category", "image_url" }; @@ -812,5 +820,19 @@ namespace WindowsFormsApp1.Mac search.Show(); } } + + private void btn_ComparePrice_Click(object sender, EventArgs e) + { + int GridCount = dataGridView1.Rows.Count; + + for (int a = 0; a < GridCount; a++) + { + string unit = dataGridView1.Rows[a].Cells["unit"].Value.ToString(); + string price = dataGridView1.Rows[a].Cells["price"].Value.ToString(); + + if (unit != price) + dataGridView1.Rows[a].DefaultCellStyle.BackColor = Color.Orange; + } + } } } \ No newline at end of file diff --git a/unimarc/unimarc/마크/Check_copy.cs b/unimarc/unimarc/마크/Check_copy.cs index 376e771..da6b682 100644 --- a/unimarc/unimarc/마크/Check_copy.cs +++ b/unimarc/unimarc/마크/Check_copy.cs @@ -275,6 +275,14 @@ namespace WindowsFormsApp1.Mac 전남목포입력(text); } + // 전북대학교 도서관 + else if (URL.IndexOf("dl.jbnu") > -1) + { + if (URL.IndexOf("result") > -1) + BookCount = 전북대결과(); + + 전북대입력(text); + } int tmp = RowCount - 1; if (tmp < 0) tmp = 0; @@ -854,6 +862,53 @@ namespace WindowsFormsApp1.Mac #endregion + #region 전북 소재 도서관 + + #region 전북대학교 도서관 + + void 전북대입력(string text) + { + foreach (HtmlElement input in webBrowser1.Document.GetElementsByTagName("input")) + { + if (input.GetAttribute("className").IndexOf("inputText") > -1) + { + input.SetAttribute("value", text); + } + if (input.GetAttribute("className").IndexOf("searchBtn") > -1 && input.GetAttribute("type") != "submit") + { + input.InvokeMember("click"); + break; + } + } + } + + string 전북대결과() + { + string result = ""; + + foreach (HtmlElement div in webBrowser1.Document.GetElementsByTagName("div")) + { + if (div.GetAttribute("className").IndexOf("catalogs") > -1) + { + foreach (HtmlElement span in div.GetElementsByTagName("span")) + { + if (span.GetAttribute("className").IndexOf("moreCount") > -1) + { + result = span.InnerText; + break; + } + } + break; + } + } + + return result; + } + + #endregion + + #endregion + public string CopyCount(string Text) { string result = ""; diff --git a/unimarc/unimarc/마크/Mac_List_Add.Designer.cs b/unimarc/unimarc/마크/Mac_List_Add.Designer.cs index 781a8bd..79c08bc 100644 --- a/unimarc/unimarc/마크/Mac_List_Add.Designer.cs +++ b/unimarc/unimarc/마크/Mac_List_Add.Designer.cs @@ -29,14 +29,18 @@ namespace UniMarc.마크 /// private void InitializeComponent() { - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle(); this.panel1 = new System.Windows.Forms.Panel(); + this.label5 = new System.Windows.Forms.Label(); + this.cb_Gubun = new System.Windows.Forms.ComboBox(); + this.btn_DelRow = new System.Windows.Forms.Button(); + this.btn_Upload = new System.Windows.Forms.Button(); this.cb_User = new System.Windows.Forms.ComboBox(); this.btn_Close = new System.Windows.Forms.Button(); this.btn_Empty = new System.Windows.Forms.Button(); @@ -59,11 +63,7 @@ namespace UniMarc.마크 this.Count = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Total = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.ISBN = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.btn_Upload = new System.Windows.Forms.Button(); - this.cb_Gubun = new System.Windows.Forms.ComboBox(); - this.label5 = new System.Windows.Forms.Label(); this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog(); - this.btn_DelRow = new System.Windows.Forms.Button(); this.panel1.SuspendLayout(); this.panel2.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); @@ -93,6 +93,44 @@ namespace UniMarc.마크 this.panel1.Size = new System.Drawing.Size(897, 59); this.panel1.TabIndex = 0; // + // label5 + // + this.label5.AutoSize = true; + this.label5.Location = new System.Drawing.Point(592, 35); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(53, 12); + this.label5.TabIndex = 14; + this.label5.Text = "쉼표구분"; + // + // cb_Gubun + // + this.cb_Gubun.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.cb_Gubun.FormattingEnabled = true; + this.cb_Gubun.Location = new System.Drawing.Point(647, 31); + this.cb_Gubun.Name = "cb_Gubun"; + this.cb_Gubun.Size = new System.Drawing.Size(75, 20); + this.cb_Gubun.TabIndex = 6; + // + // btn_DelRow + // + this.btn_DelRow.Location = new System.Drawing.Point(560, 4); + this.btn_DelRow.Name = "btn_DelRow"; + this.btn_DelRow.Size = new System.Drawing.Size(81, 23); + this.btn_DelRow.TabIndex = 5; + this.btn_DelRow.Text = "선택 셀 삭제"; + this.btn_DelRow.UseVisualStyleBackColor = true; + this.btn_DelRow.Click += new System.EventHandler(this.btn_DelRow_Click); + // + // btn_Upload + // + this.btn_Upload.Location = new System.Drawing.Point(728, 30); + this.btn_Upload.Name = "btn_Upload"; + this.btn_Upload.Size = new System.Drawing.Size(75, 23); + this.btn_Upload.TabIndex = 7; + this.btn_Upload.Text = "txt불러오기"; + this.btn_Upload.UseVisualStyleBackColor = true; + this.btn_Upload.Click += new System.EventHandler(this.btn_Upload_Click); + // // cb_User // this.cb_User.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; @@ -107,7 +145,7 @@ namespace UniMarc.마크 this.btn_Close.Location = new System.Drawing.Point(809, 4); this.btn_Close.Name = "btn_Close"; this.btn_Close.Size = new System.Drawing.Size(75, 23); - this.btn_Close.TabIndex = 5; + this.btn_Close.TabIndex = 8; this.btn_Close.Text = "닫 기"; this.btn_Close.UseVisualStyleBackColor = true; this.btn_Close.Click += new System.EventHandler(this.btn_Close_Click); @@ -117,7 +155,7 @@ namespace UniMarc.마크 this.btn_Empty.Location = new System.Drawing.Point(647, 4); this.btn_Empty.Name = "btn_Empty"; this.btn_Empty.Size = new System.Drawing.Size(75, 23); - this.btn_Empty.TabIndex = 3; + this.btn_Empty.TabIndex = 4; this.btn_Empty.Text = "비 우 기"; this.btn_Empty.UseVisualStyleBackColor = true; this.btn_Empty.Click += new System.EventHandler(this.btn_Empty_Click); @@ -127,7 +165,7 @@ namespace UniMarc.마크 this.btn_AddList.Location = new System.Drawing.Point(728, 4); this.btn_AddList.Name = "btn_AddList"; this.btn_AddList.Size = new System.Drawing.Size(75, 23); - this.btn_AddList.TabIndex = 4; + this.btn_AddList.TabIndex = 3; this.btn_AddList.Text = "저 장"; this.btn_AddList.UseVisualStyleBackColor = true; this.btn_AddList.Click += new System.EventHandler(this.btn_AddList_Click); @@ -138,7 +176,7 @@ namespace UniMarc.마크 this.label3.Location = new System.Drawing.Point(330, 9); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(41, 12); - this.label3.TabIndex = 1; + this.label3.TabIndex = 13; this.label3.Text = "담당자"; // // label2 @@ -147,7 +185,7 @@ namespace UniMarc.마크 this.label2.Location = new System.Drawing.Point(178, 9); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(41, 12); - this.label2.TabIndex = 1; + this.label2.TabIndex = 11; this.label2.Text = "납품명"; // // label4 @@ -156,7 +194,7 @@ namespace UniMarc.마크 this.label4.Location = new System.Drawing.Point(27, 35); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(81, 12); - this.label4.TabIndex = 1; + this.label4.TabIndex = 10; this.label4.Text = "생성될 목록명"; // // label1 @@ -165,7 +203,7 @@ namespace UniMarc.마크 this.label1.Location = new System.Drawing.Point(26, 9); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(41, 12); - this.label1.TabIndex = 1; + this.label1.TabIndex = 9; this.label1.Text = "납품처"; // // tb_ExpectList @@ -174,7 +212,7 @@ namespace UniMarc.마크 this.tb_ExpectList.Location = new System.Drawing.Point(114, 31); this.tb_ExpectList.Name = "tb_ExpectList"; this.tb_ExpectList.Size = new System.Drawing.Size(250, 21); - this.tb_ExpectList.TabIndex = 0; + this.tb_ExpectList.TabIndex = 12; // // tb_divName // @@ -199,21 +237,21 @@ namespace UniMarc.마크 this.panel2.Location = new System.Drawing.Point(0, 59); this.panel2.Name = "panel2"; this.panel2.Size = new System.Drawing.Size(897, 621); - this.panel2.TabIndex = 0; + this.panel2.TabIndex = 1; // // dataGridView1 // this.dataGridView1.BackgroundColor = System.Drawing.SystemColors.Control; this.dataGridView1.BorderStyle = System.Windows.Forms.BorderStyle.None; this.dataGridView1.ColumnHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single; - dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; - dataGridViewCellStyle8.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle8.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); - dataGridViewCellStyle8.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle8.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle8.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle8; + 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.True; + this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1; this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.header, this.num, @@ -229,7 +267,7 @@ namespace UniMarc.마크 this.dataGridView1.Name = "dataGridView1"; this.dataGridView1.RowTemplate.Height = 23; this.dataGridView1.Size = new System.Drawing.Size(897, 621); - this.dataGridView1.TabIndex = 0; + this.dataGridView1.TabIndex = 1; this.dataGridView1.RowPostPaint += new System.Windows.Forms.DataGridViewRowPostPaintEventHandler(this.dataGridView1_RowPostPaint); this.dataGridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView1_KeyDown); // @@ -247,53 +285,53 @@ namespace UniMarc.마크 // // BookName // - dataGridViewCellStyle9.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - this.BookName.DefaultCellStyle = dataGridViewCellStyle9; + dataGridViewCellStyle2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + this.BookName.DefaultCellStyle = dataGridViewCellStyle2; this.BookName.HeaderText = "도서명"; this.BookName.Name = "BookName"; this.BookName.Width = 200; // // Author // - dataGridViewCellStyle10.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - this.Author.DefaultCellStyle = dataGridViewCellStyle10; + dataGridViewCellStyle3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + this.Author.DefaultCellStyle = dataGridViewCellStyle3; this.Author.HeaderText = "저자"; this.Author.Name = "Author"; // // BookComp // - dataGridViewCellStyle11.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - this.BookComp.DefaultCellStyle = dataGridViewCellStyle11; + dataGridViewCellStyle4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + this.BookComp.DefaultCellStyle = dataGridViewCellStyle4; this.BookComp.HeaderText = "출판사"; this.BookComp.Name = "BookComp"; this.BookComp.Width = 120; // // Price // - dataGridViewCellStyle12.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - dataGridViewCellStyle12.Format = "N0"; - dataGridViewCellStyle12.NullValue = "0"; - this.Price.DefaultCellStyle = dataGridViewCellStyle12; + dataGridViewCellStyle5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + dataGridViewCellStyle5.Format = "N0"; + dataGridViewCellStyle5.NullValue = "0"; + this.Price.DefaultCellStyle = dataGridViewCellStyle5; this.Price.HeaderText = "가격"; this.Price.Name = "Price"; this.Price.Width = 80; // // Count // - dataGridViewCellStyle13.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - dataGridViewCellStyle13.Format = "N0"; - dataGridViewCellStyle13.NullValue = "1"; - this.Count.DefaultCellStyle = dataGridViewCellStyle13; + dataGridViewCellStyle6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + dataGridViewCellStyle6.Format = "N0"; + dataGridViewCellStyle6.NullValue = "1"; + this.Count.DefaultCellStyle = dataGridViewCellStyle6; this.Count.HeaderText = "수량"; this.Count.Name = "Count"; this.Count.Width = 45; // // Total // - dataGridViewCellStyle14.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); - dataGridViewCellStyle14.Format = "N0"; - dataGridViewCellStyle14.NullValue = "0"; - this.Total.DefaultCellStyle = dataGridViewCellStyle14; + dataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); + dataGridViewCellStyle7.Format = "N0"; + dataGridViewCellStyle7.NullValue = "0"; + this.Total.DefaultCellStyle = dataGridViewCellStyle7; this.Total.HeaderText = "합계"; this.Total.Name = "Total"; this.Total.Width = 80; @@ -303,48 +341,10 @@ namespace UniMarc.마크 this.ISBN.HeaderText = "ISBN"; this.ISBN.Name = "ISBN"; // - // btn_Upload - // - this.btn_Upload.Location = new System.Drawing.Point(728, 30); - this.btn_Upload.Name = "btn_Upload"; - this.btn_Upload.Size = new System.Drawing.Size(75, 23); - this.btn_Upload.TabIndex = 6; - this.btn_Upload.Text = "txt불러오기"; - this.btn_Upload.UseVisualStyleBackColor = true; - this.btn_Upload.Click += new System.EventHandler(this.btn_Upload_Click); - // - // cb_Gubun - // - this.cb_Gubun.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; - this.cb_Gubun.FormattingEnabled = true; - this.cb_Gubun.Location = new System.Drawing.Point(647, 31); - this.cb_Gubun.Name = "cb_Gubun"; - this.cb_Gubun.Size = new System.Drawing.Size(75, 20); - this.cb_Gubun.TabIndex = 1; - // - // label5 - // - this.label5.AutoSize = true; - this.label5.Location = new System.Drawing.Point(592, 35); - this.label5.Name = "label5"; - this.label5.Size = new System.Drawing.Size(53, 12); - this.label5.TabIndex = 1; - this.label5.Text = "쉼표구분"; - // // openFileDialog1 // this.openFileDialog1.FileName = "openFileDialog1"; // - // btn_DelRow - // - this.btn_DelRow.Location = new System.Drawing.Point(560, 4); - this.btn_DelRow.Name = "btn_DelRow"; - this.btn_DelRow.Size = new System.Drawing.Size(81, 23); - this.btn_DelRow.TabIndex = 6; - this.btn_DelRow.Text = "선택 셀 삭제"; - this.btn_DelRow.UseVisualStyleBackColor = true; - this.btn_DelRow.Click += new System.EventHandler(this.btn_DelRow_Click); - // // Mac_List_Add // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); diff --git a/unimarc/unimarc/마크/Marc_Plan.cs b/unimarc/unimarc/마크/Marc_Plan.cs index 048d31c..757e59b 100644 --- a/unimarc/unimarc/마크/Marc_Plan.cs +++ b/unimarc/unimarc/마크/Marc_Plan.cs @@ -272,15 +272,20 @@ namespace WindowsFormsApp1.Mac { string oldTag = string.Format("▼{0}{1}", TagName, BackUpTag[a]); string newTag = string.Format("▼{0}{1}", TagName, Content); + // 해당 식별기호가 존재할 경우 if (LineMarc.Contains(oldTag)) { AryMarc[index] = LineMarc.Replace(oldTag, newTag); + break; } + // 해당 식별기호가 존재하지 않을 경우 else { - + // 뷰어형태로 전환하여 삽입하는 형식이라 디렉토리부분은 크게 신경쓰지않아도 됨. + // 그렇지만 식별기호가 존재하지않으면 해당 태그의 식별기호 순서를 다 설정하고 그에 맞게 적용되는 시스템이 되어야 함. + // 작업이 무척 까다로워질것으로 예상됨. } } @@ -290,14 +295,11 @@ namespace WindowsFormsApp1.Mac AryMarc.Insert(index, MakeMarcLine); break; } - index++; } - dataGridView1.Rows[a].Cells["marc"].Value = string.Join("\n", AryMarc); } - #region 보류 /* for (int a = 0; a < dataGridView1.Rows.Count; a++)