=====* unimarc *=====

- 마크 목록 정리 - [ Marc_mkList.cs ]
기타 풀막을 시방서 마크 목록으로 넘기는 소스코드 정리완료

[Marc_Plan_Sub_SelectLIst.cs]
시방서 목록을 선택하는 폼 작업및 정리중.

[Marc_Plan_Sub_SelectList_Edit]
위의 폼 Sub폼 작업및 정리 완료.
This commit is contained in:
SeungHo Yang
2021-10-15 18:40:24 +09:00
parent 772fbfeab6
commit a70a396a2c
28 changed files with 998 additions and 281 deletions

View File

@@ -6,15 +6,20 @@ using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows.Forms;
using UniMarc.Properties;
using WindowsFormsApp1;
namespace UniMarc.
{
public partial class Marc_mkList : Form
{
Marc marc;
string compidx = Properties.Settings.Default.compidx;
Helper_DB db = new Helper_DB();
string compidx = Settings.Default.compidx;
public Marc_mkList(Marc _marc)
{
@@ -25,6 +30,8 @@ namespace UniMarc.마크
private void Marc_mkList_Load(object sender, EventArgs e)
{
db.DBcon();
#region panel1 set
rb_basicNum.Checked = true;
rb_autoNum.Enabled = false;
@@ -105,19 +112,33 @@ namespace UniMarc.마크
MessageBox.Show("목록명을 입력해주세요!");
return;
}
// 시방서 목록 DB에 들어갈 것들.
string[] insert_list_col = {
"compidx", "work_list", "date", "state", "gu",
"first_Author", "symbol_Author", "book_Author", "divType", "divNum",
"etc"
};
string[] insert_list_data = {
compidx, listName, Time, "진행", cb_listType.Text,
cb_FirstAuthor.Text, cb_authorType.Text, cb_FirstBook.Text, cb_divType.Text, cb_divNum.Text,
rtb_etc.Text
};
string cmdByList = db.DB_INSERT("Specs_List", insert_list_col, insert_list_data);
db.DB_Send_CMD_reVoid(cmdByList);
string[] update_col = {
// 시방서 마크 DB에 들어갈 것들.
string[] insert_marc_col = {
"compidx", "work_list", "date", "ISBN", "book_name",
"s_book_name1", "s_book_num1", "author", "book_comp", "pubdate",
"price", "tag008", "class_symbol", "author_symbol", "marc",
"imageURL"
};
string[] update_data = {
"", "", "", "", "",
string[] insert_marc_data = {
compidx, listName, Time, "", "",
"", "", "", "", "",
"", "", "", "", "",
""
};
}; // 마크에서 추출 ( 3 ~ 12 )
int[] row = checkGridRow();
@@ -127,57 +148,67 @@ namespace UniMarc.마크
// ISBN, book_name, s_book_name1, s_book_num1, author, book_comp, pubdate, price, tag008, class_symbol
string[] Search = { "020a", "245a", "440a", "440v", "245d", "260b", "260c", "950b", "008", "056a" };
// string[] Search = { "245d", "245a" };
insert_marc_data[14] = marc.List_Book.Rows[row[a]].Cells["db_marc"].Value.ToString();
insert_marc_data[15] = marc.List_Book.Rows[row[a]].Cells["url"].Value.ToString();
string[] Marc = Take_Tag(marc.List_Book.Rows[row[a]].Cells["db_marc"].Value.ToString(), Search);
// string Author = Take_Tag(marc.List_Book.Rows[a].Cells["db_marc"].Value.ToString(), "245d");
// string Book = Take_Tag(marc.List_Book.Rows[a].Cells["book_name"].Value.ToString(), "245a");
string[] Marc = Take_Tag(insert_marc_data[14], Search);
string[] Author = { Marc[4], Marc[1] };
for (int b = 0; b < Marc.Length; b++)
{
insert_marc_data[b + 3] = Marc[b];
}
Author[0] = Regex.Replace(Author[0], @"[^a-zA-Z0-9가-힣_]", "", RegexOptions.Singleline);
Author[1] = Regex.Replace(Author[1], @"[^a-zA-Z0-9가-힣_]", "", RegexOptions.Singleline);
char aut;
if (Marc[0].Length <= 1)
aut = Marc[0][0];
if (Author[0].Length <= 1)
aut = Author[0][0];
else
aut = Marc[0][1];
aut = Author[0][1];
AuthorSymbol.Symbol sb = new AuthorSymbol.Symbol();
string res_Author = sb.Author_Fillter(Marc[0][0], isAuthor);
string res_Author = sb.Author_Fillter(Author[0][0], isAuthor);
#region
if (cb_authorType.SelectedIndex == 0) // 이재철 1표
Marc[0] = sb.Symbol_1(aut);
Author[0] = sb.Symbol_1(aut);
if (cb_authorType.SelectedIndex == 1) // 이재철 2표
Marc[0] = sb.Symbol_2(aut);
Author[0] = sb.Symbol_2(aut);
if (cb_authorType.SelectedIndex == 2) // 이재철 3표
Marc[0] = sb.Symbol_3(aut);
Author[0] = sb.Symbol_3(aut);
if (cb_authorType.SelectedIndex == 3) // 이재철 4표
Marc[0] = sb.Symbol_4(aut);
Author[0] = sb.Symbol_4(aut);
if (cb_authorType.SelectedIndex == 4) // 이재철 5표
Marc[0] = sb.Symbol_5(aut);
Author[0] = sb.Symbol_5(aut);
if (cb_authorType.SelectedIndex == 5) // 이재철 6표
Marc[0] = sb.Symbol_6(aut);
Author[0] = sb.Symbol_6(aut);
if (cb_authorType.SelectedIndex == 6) // 이재철 7표
Marc[0] = sb.Symbol_7(aut);
Author[0] = sb.Symbol_7(aut);
if (cb_authorType.SelectedIndex == 7) // 이재철 7표 (동양서저자기호표)
Marc[0] = sb.Symbol_7_동서(aut);
Author[0] = sb.Symbol_7_동서(aut);
if (cb_authorType.SelectedIndex == 8) // 이재철 8표
Marc[0] = sb.Symbol_8(aut);
Author[0] = sb.Symbol_8(aut);
if (cb_authorType.SelectedIndex == 9) // 이재철 8표 (동양서저자기호표)
Marc[0] = sb.Symbol_8_동서(aut);
Author[0] = sb.Symbol_8_동서(aut);
if (cb_authorType.SelectedIndex == 10) // 장일세
Marc[0] = sb.Symbol_Jang(Marc[0]);
Author[0] = sb.Symbol_Jang(Marc[0]);
if (cb_authorType.SelectedIndex == 11) // 커터샌본
Marc[0] = sb.Cutter(Marc[0]);
Author[0] = sb.Cutter(Author[0]);
if (cb_authorType.SelectedIndex == 12) // 엘러드
Marc[0] = sb.Elord(Marc[0]);
Author[0] = sb.Elord(Author[0]);
if (cb_authorType.SelectedIndex == 13) // 동서양 저자기호표(국중)
Marc[0] = sb.NLK(Marc[0]);
Author[0] = sb.NLK(Author[0]);
#endregion
Marc[0] = Marc[0].Replace("|", "");
res_Author += Marc[0] + sb.Book_Fillter(Marc[1], isBook);
Author[0] = Author[0].Replace("|", "");
res_Author += Author[0] + sb.Book_Fillter(Author[1], isBook);
#region
string res_Div = cb_divType.Text + cb_divNum.Text;
#endregion
// DB_UPDATE 수량 체크
insert_marc_data[13] = res_Author;
string cmdByMarc = db.DB_INSERT("Specs_Marc", insert_marc_col, insert_marc_data);
db.DB_Send_CMD_reVoid(cmdByMarc);
}
}
@@ -221,7 +252,8 @@ namespace UniMarc.마크
}
else
{
int end = tmp.IndexOf("", start + 2);
start += 2;
int end = tmp.IndexOf("", start);
if (memo == result[b])
break;
@@ -234,6 +266,14 @@ namespace UniMarc.마크
}
}
}
for (int a = 0; a < result.Length; a++)
{
if (result[a] == null)
{
result[a] = "";
}
}
return result;
}
#region Take_Tag_Sub