* unimarc
a. 팩스전송 완료. b. 마크목록 폼 작성중 1. 엑셀반출 기능 추가중 사용 작업중 2. 마크편집 폼 수정 중 (마크 반출 test프로젝트 진행완료, 본 프로젝트에 적용중. / 저장기능활성화 작업완료) 2-1. 기존의 칸채우기에서 예상되지 못한 버그가 발생하여 칸채우기 숨김. 2-2. 008태크 재배치 => TextBox에 적용완료. 변경사항 메모장으로 넘기는 작업 진행해야함. 2-3. 현재 TODO : 저장기능 TODOLIST 1. 팩스로 전송될 엑셀파일 밑작업마무리 (입력될 파라미터만 적용하면 실사용가능) 2. 알라딘API, 네이버 API연동중 자잘한 버그 수정작업 필요. 3. Form3 => Line 62 수정작업 필요함.
This commit is contained in:
@@ -100,23 +100,17 @@ namespace ISBN_Check_test
|
||||
}
|
||||
return result;
|
||||
}
|
||||
public string Naver(string[] Query, string[] Param)
|
||||
public string Naver(string[] Query, string[] QueryType, string[] Param)
|
||||
{
|
||||
string result = string.Empty;
|
||||
string json = string.Empty;
|
||||
// url 생성
|
||||
string url = "https://openapi.naver.com/v1/search/book_adv?";
|
||||
|
||||
if(Query[0] != null || Query[0] != "")
|
||||
url += "d_titl=" + Query[0] + "&";
|
||||
|
||||
if(Query[1] != null || Query[1] != "")
|
||||
url += "d_auth=" + Query[1] + "&";
|
||||
|
||||
if(Query[2] != null || Query[2] != "")
|
||||
url += "d_publ=" + Query[2] + "&";
|
||||
|
||||
//
|
||||
for(int a = 0; a < Query.Length; a++)
|
||||
{
|
||||
url += string.Format("{0}={1}&", QueryType[a], Query[a]);
|
||||
}
|
||||
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
|
||||
|
||||
request.Headers.Add("X-Naver-Client-Id", "wYr0JczCBoDopq1NKTyQ"); // 클라이언트 아이디
|
||||
@@ -179,6 +173,62 @@ namespace ISBN_Check_test
|
||||
}
|
||||
return result;
|
||||
}
|
||||
public string Daum(string[] Query, string[] Param)
|
||||
{
|
||||
string result = string.Empty;
|
||||
|
||||
// url생성
|
||||
string url = "https://dapi.kakao.com/v3/search/book";
|
||||
string query = string.Format("{0}?query={1}&target={2}", url, Query[0], "title");
|
||||
WebRequest request = WebRequest.Create(query);
|
||||
|
||||
string rKey = "e3935565b731a2a6f32880c90d76403a";
|
||||
string header = "KakaoAK " + rKey;
|
||||
|
||||
request.Headers.Add("Authorization", header);
|
||||
|
||||
WebResponse response = request.GetResponse();
|
||||
Stream stream = response.GetResponseStream();
|
||||
StreamReader reader = new StreamReader(stream, Encoding.UTF8);
|
||||
string json = reader.ReadToEnd();
|
||||
stream.Close();
|
||||
|
||||
JavaScriptSerializer js = new JavaScriptSerializer();
|
||||
dynamic dob = js.Deserialize<dynamic>(json);
|
||||
dynamic docs = dob["documents"];
|
||||
object[] buf = docs;
|
||||
|
||||
int length = buf.Length;
|
||||
int ID_length = Param.Length;
|
||||
|
||||
for(int a = 0; a < length; a++)
|
||||
{
|
||||
List<object> tmp_data = new List<object>();
|
||||
for(int b = 0; b < ID_length; b++)
|
||||
{
|
||||
if (Param[b] == "authors") {
|
||||
object[] tmp = docs[a][Param[b]];
|
||||
string tmp_str = string.Empty;
|
||||
for(int j = 0; j < tmp.Length; j++)
|
||||
{
|
||||
tmp_str += tmp[j];
|
||||
if (j < tmp.Length - 1) {
|
||||
tmp_str += ", ";
|
||||
}
|
||||
}
|
||||
tmp_data.Add(tmp_str);
|
||||
result += tmp_data[b] + "|";
|
||||
tmp_str = "";
|
||||
}
|
||||
else {
|
||||
tmp_data.Add(docs[a][Param[b]]);
|
||||
result += tmp_data[b] + "|";
|
||||
}
|
||||
}
|
||||
result += "\n";
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
class Skill_Grid
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user