From 499f80d531c3a87026342bea85f5a314d307e94b Mon Sep 17 00:00:00 2001 From: lch Date: Fri, 23 Apr 2021 09:29:41 +0000 Subject: [PATCH] =?UTF-8?q?=ED=8C=9D=EB=B9=8C=20=EC=84=B8=EA=B8=88?= =?UTF-8?q?=EA=B3=84=EC=82=B0=EC=84=9C=20=EA=B4=80=EB=A0=A8=20=EC=9E=91?= =?UTF-8?q?=EC=97=85=20=EC=A4=91=EA=B0=84=20=EC=BB=A4=EB=B0=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Base/Popbill/PopbillService.cs | 90 ++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) diff --git a/Base/Popbill/PopbillService.cs b/Base/Popbill/PopbillService.cs index 0029e26..cbf5c34 100644 --- a/Base/Popbill/PopbillService.cs +++ b/Base/Popbill/PopbillService.cs @@ -161,6 +161,52 @@ namespace NP.Base.Popbill return result; } + /// + /// 세금계산서 발행 + /// + /// 파트너가 할당한 문서번호 + /// 세금계산서 유형 : SELL = 매출, BUY = 매입, TRUSTEE = 위수탁 + /// 메모 + /// IssueResponse + public static Result Issue(string mgtkey, MgtKeyType mgtKeyType = MgtKeyType.SELL, string memo = "") + { + Result result = new Result(); + try + { + result.Data = PopbillConfig.taxinvoiceService.Issue(PopbillConfig.CorpNum, mgtKeyType, mgtkey, memo, PopbillConfig.UserID); + } + catch (PopbillException ex) + { + result.Code = ex.code.ToString(); + result.Message = ex.Message; + Logger.TryError(ex.Message, ex); + } + return result; + } + + /// + /// 세금계산서 발행취소 + /// + /// 파트너가 할당한 문서번호 + /// 세금계산서 유형 : SELL = 매출, BUY = 매입, TRUSTEE = 위수탁 + /// 메모 + /// IssueResponse + public static Result CancelIssue(string mgtkey, MgtKeyType mgtKeyType = MgtKeyType.SELL, string memo = "") + { + Result result = new Result(); + try + { + result.Data = PopbillConfig.taxinvoiceService.CancelIssue(PopbillConfig.CorpNum, mgtKeyType, mgtkey, memo, PopbillConfig.UserID); + } + catch (PopbillException ex) + { + result.Code = ex.code.ToString(); + result.Message = ex.Message; + Logger.TryError(ex.Message, ex); + } + return result; + } + /// /// 세금계산서 즉시 발행 /// @@ -183,6 +229,50 @@ namespace NP.Base.Popbill } return result; } + + /// + /// 세금계산서 인쇄 팝업 URL 확인 + /// + /// 파트너가 할당한 문서번호 + /// 세금계산서 유형 : SELL = 매출, BUY = 매입, TRUSTEE = 위수탁 + /// URL + public static Result GetPrintURL(string mgtkey, MgtKeyType mgtKeyType = MgtKeyType.SELL) + { + Result result = new Result(); ; + try + { + result.Data = PopbillConfig.taxinvoiceService.GetPrintURL(PopbillConfig.CorpNum, mgtKeyType, mgtkey, PopbillConfig.UserID); + } + catch (PopbillException ex) + { + result.Code = ex.code.ToString(); + result.Message = ex.Message; + Logger.TryError(ex.Message, ex); + } + return result; + } + + /// + /// 세금계산서 인쇄 팝업 URL 확인 - 공급받는자용 + /// + /// 파트너가 할당한 문서번호 + /// 세금계산서 유형 : SELL = 매출, BUY = 매입, TRUSTEE = 위수탁 + /// URL + public static Result GetEPrintURL(string mgtkey, MgtKeyType mgtKeyType = MgtKeyType.SELL) + { + Result result = new Result(); ; + try + { + result.Data = PopbillConfig.taxinvoiceService.GetEPrintURL(PopbillConfig.CorpNum, mgtKeyType, mgtkey, PopbillConfig.UserID); + } + catch (PopbillException ex) + { + result.Code = ex.code.ToString(); + result.Message = ex.Message; + Logger.TryError(ex.Message, ex); + } + return result; + } } public class Result