text stringlengths 81 112k |
|---|
Creates a new document based on the given data
def create(self, request):
"""
Creates a new document based on the given data
"""
document = self.collection(request.json)
document.created_at = datetime.utcnow()
document.updated_at = document.created_at
created = ... |
Returns the document containing the given _id or 404
def retrieve(self, request, _id):
"""
Returns the document containing the given _id or 404
"""
_id = deserialize(_id)
retrieved = self.collection.find_one({'_id': _id})
if retrieved:
return Response(serial... |
Updates the document with the given _id using the given data
def update(self, request, _id):
"""
Updates the document with the given _id using the given data
"""
_id = deserialize(_id)
to_update = self.collection.find_one({'_id': _id})
if to_update:
document... |
Deletes the document with the given _id if it exists
def delete(self, request, _id):
"""
Deletes the document with the given _id if it exists
"""
_id = deserialize(_id)
to_delete = self.collection.get({'_id': _id})
if to_delete:
deleted = to_delete.delete()
... |
Decorator for test functions that require a running reactor.
Can be used like this::
@with_reactor
def test_connect_to_server(self):
...
Or like this::
@with_reactor(timeout=10)
def test_connect_to_server(self):
...
If the ... |
Starts the twisted reactor if it is not running already.
The reactor is started in a new daemon-thread.
Has to perform dirty hacks so that twisted can register
signals even if it is not running in the main-thread.
def _ensure_reactor_running():
"""
Starts the twisted reactor if it is not ... |
Cancels the given deferred after the given time, if it has not yet callbacked/errbacked it.
def _timeoutDeferred(deferred, timeout):
"""
Cancels the given deferred after the given time, if it has not yet callbacked/errbacked it.
"""
delayedCall = reactor.callLater(timeout, deferred.cancel)
def gotR... |
Find best fitting pRF model for voxel time course, using the CPU.
Parameters
----------
idxPrc : int
Process ID of the process calling this function (for CPU
multi-threading). In GPU version, this parameter is 0 (just one thread
on CPU).
aryFunc : np.array
2D array with ... |
Checks the revert status of a revision. With this method, you can
determine whether an edit is a 'reverting' edit, was 'reverted' by another
edit and/or was 'reverted_to' by another edit.
:Parameters:
session : :class:`mwapi.Session`
An API session to make use of
rev_id : int
... |
Checks the revert status of an archived revision (from a deleted page).
With this method, you can determine whether an edit is a 'reverting'
edit, was 'reverted' by another edit and/or was 'reverted_to' by
another edit.
:Parameters:
session : :class:`mwapi.Session`
An API session to... |
Convert the given value to a JSON object.
def _get_json(value):
"""Convert the given value to a JSON object."""
if hasattr(value, 'replace'):
value = value.replace('\n', ' ')
try:
return json.loads(value)
except json.JSONDecodeError:
# Escape double quotes.
if hasattr(va... |
Convert the given list of parameters to a JSON object.
JSON object is of the form:
{ key: [values[0], values[1], ... ] },
where values represent the given list of parameters.
def save_list(key, *values):
"""Convert the given list of parameters to a JSON object.
JSON object is of the form:
{ k... |
Convert the given parameters to a special JSON object.
JSON object is of the form:
{ key: {"file": file_path}}, or
{ key: {"file": file_path, "refs": [refs[0], refs[1], ... ]}}
def save_file(key, file_path, *refs):
"""Convert the given parameters to a special JSON object.
JSON object is of the fo... |
Convert the given parameters to a special JSON object.
Each parameter is a file-refs specification of the form:
<file-path>:<reference1>,<reference2>, ...,
where the colon ':' and the list of references are optional.
JSON object is of the form:
{ key: {"file": file_path}}, or
{ key: {"file": f... |
Convert the given parameters to a special JSON object.
JSON object is of the form:
{ key: {"dir": dir_path}}, or
{ key: {"dir": dir_path, "refs": [refs[0], refs[1], ... ]}}
def save_dir(key, dir_path, *refs):
"""Convert the given parameters to a special JSON object.
JSON object is of the form:
... |
Convert the given parameters to a special JSON object.
Each parameter is a dir-refs specification of the form:
<dir-path>:<reference1>,<reference2>, ...,
where the colon ':' and the list of references are optional.
JSON object is of the form:
{ key: {"dir": dir_path}}, or
{ key: {"dir": dir_pa... |
Convert given progress to a JSON object.
Check that progress can be represented as float between 0 and 1 and
return it in JSON of the form:
{"proc.progress": progress}
def progress(progress):
"""Convert given progress to a JSON object.
Check that progress can be represented as float between ... |
Check if ``rc`` (return code) meets requirements.
Check if ``rc`` is 0 or is in ``args`` list that contains
acceptable return codes.
Last argument of ``args`` can optionally be error message that
is printed if ``rc`` doesn't meet requirements.
Output is JSON of the form:
{"proc.rc": <rc>,... |
Prepend the given parameter with ``export``
def export_file(file_path):
"""Prepend the given parameter with ``export``"""
if not os.path.isfile(file_path):
return error("Referenced file does not exist: '{}'.".format(file_path))
return "export {}".format(file_path) |
Import file to working directory.
:param src: Source file path or URL
:param file_name: Source file name
:param imported_format: Import file format (extracted, compressed or both)
:param progress_from: Initial progress value
:param progress_to: Final progress value
:return: Destination file pat... |
load nii data.
Parameters
----------
lstNiiFls : list, list of str with nii file names
strPathNiiMask : str, path to nii file with mask (optional)
strPathNiiFunc : str, parent path to nii files (optional)
Returns
-------
aryFunc : np.array
Nii... |
calculate coefficient of determination. Assumes that axis=0 is time
Parameters
----------
predTst : np.array, predicted reponse for yTest
yTest : np.array, acxtually observed response for yTest
Returns
-------
aryFunc : np.array
R2
def calcR2(predTst... |
calculate coefficient of determination. Assumes that axis=0 is time
Parameters
----------
predTst : np.array, predicted reponse for yTest
yTest : np.array, acxtually observed response for yTest
p: float, number of predictors
Returns
-------
aryFunc : np.a... |
calculate mean squared error. Assumes that axis=0 is time
Parameters
----------
predTst : np.array, predicted reponse for yTest
yTest : np.array, acxtually observed response for yTest
Returns
-------
aryFunc : np.array
MSE
def calcMse(predTst, yTest,... |
date_string string in format "(number|a) day(s) ago"
def n_day(date_string):
"""
date_string string in format "(number|a) day(s) ago"
"""
today = datetime.date.today()
match = re.match(r'(\d{1,3}|a) days? ago', date_string)
groups = match.groups()
if groups:
... |
Detects reverts that occur in a sequence of revisions. Note that,
`revision` data meta will simply be returned in the case of a revert.
This function serves as a convenience wrapper around calls to
:class:`mwreverts.Detector`'s :func:`~mwreverts.Detector.process`
method.
:Parameters:
chec... |
과금정보 확인
args
CorpNum : 회원 사업자번호
ItemCode : 전자명세서 종류코드
UserID : 팝빌 회원아이디
return
과금정보 객체
raise
PopbillException
def getChargeInfo(self, CorpNum, ItemCode, UserID=None):
""" 과금정보 확인
... |
전자명세서 발행단가 확인.
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
return
발행단가 by float
raise
Pop... |
선팩스 전송
args
CorpNum : 팝빌회원 사업자번호
statement : 전자명세서 객체
SendNum : 팩스 발신번호
ReceiveNum : 팩스 수신번호
UserID : 팝빌회원 아이디
return
팩스전송 접수번호(receiptNum)
raise
PopbillException... |
즉시발행
args
CorpNum : 팝빌회원 사업자번호
statement : 등록할 전자명세서 object. made with Statement(...)
Memo : 즉시발행메모
UserID : 팝빌회원 아이디
return
처리결과. consist of code and message
raise
PopbillExcep... |
임시저장
args
CorpNum : 팝빌회원 사업자번호
statement : 등록할 전자명세서 object. made with Statement(...)
UserID : 팝빌회원 아이디
return
처리결과. consist of code and message
raise
PopbillException
def register(self, CorpNum,... |
임시저장
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
Statement : 등록할 전자명세서 object. made with Statem... |
발행
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
Memo : 처리메모
EmailSubject : 발행메일... |
발행취소
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
Memo : 처리메모
UserID : 팝빌회원 아이디... |
삭제
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
UserID : 팝빌회원 아이디
return
... |
목록 조회
args
CorpNum : 팝빌회원 사업자번호
DType : 일자유형, R-등록일시, W-작성일자, I-발행일시 중 택 1
SDate : 시작일자, 표시형식(yyyyMMdd)
EDate : 종료일자, 표시형식(yyyyMMdd)
State : 상태코드, 2,3번째 자리에 와일드카드(*) 사용가능
ItemCode : 명세서 종류코드 배열, 121-명세서, 1... |
상태/요약 정보 확인
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
return
문서 상태/요약정보 object
... |
전자명세서 상세정보 확인
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
return
문서 상세정보 object
... |
알림문자 전송
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
Sender : 발신번호
Receiver : 수... |
전자명세서 문서이력 목록 확인
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
return
문서이력 정보 목록 as ... |
파일 첨부
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
FilePath : 첨부파일의 경로
UserID :... |
첨부파일 목록 확인
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
return
첨부파일 목록 as List
... |
첨부파일 삭제
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKey : 파트너 문서관리번호
FileID : 파일아이디, 첨부파일 목록확인(getFiles) API 응답전... |
다량 인쇄 URL 확인
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 명세서 종류 코드
[121 - 거래명세서], [122 - 청구서], [123 - 견적서],
[124 - 발주서], [125 - 입금표], [126 - 영수증]
MgtKeyList : 파트너 문서관리번호 목록
UserID : 팝빌회원 아이디
... |
다른 전자명세서 첨부
args
CorpNum : 팝빌회원 사업자번호
ItemCode : 전자명세서 종류코드, 121-명세서, 122-청구서, 123-견적서, 124-발주서 125-입금표, 126-영수증
MgtKey : 전자명세서 문서관리번호
SubItemCode : 첨부할 명세서 종류코드, 121-명세서, 122-청구서, 123-견적서, 124-발주서 125-입금표, 126-영수증
SubMgtK... |
Ingests an article and processes it for metadata and elements to provide
proper references in the EPUB spine.
This method may only be called once unless the Package was instantiated
in collection mode using ``Package(collection=True)``. It places entries
in an internal spine list for th... |
Handles the acquisition of metadata for both collection mode and single
mode, uses the metadata methods belonging to the article's publisher
attribute.
def acquire_metadata(self):
"""
Handles the acquisition of metadata for both collection mode and single
mode, uses the metadata... |
An iterator through the files in a location which yields item elements
suitable for insertion into the package manifest.
def file_manifest(self, location):
"""
An iterator through the files in a location which yields item elements
suitable for insertion into the package manifest.
... |
Returns an appropriate Name and File-As-Name for a contrib element.
This code was refactored out of nav_contributors and
package_contributors to provide a single definition point for a common
job. This is a useful utility that may be well-employed for other
publishers as well.
def get_... |
Given an Article class instance, this is responsible for returning an
article description. For this method I have taken the approach of
serializing the article's first abstract, if it has one. This results
in 0 or 1 descriptions per article.
def package_description(self):
"""
Gi... |
Makes the Article Title for the Heading.
Metadata element, content derived from FrontMatter
def heading_title(self):
"""
Makes the Article Title for the Heading.
Metadata element, content derived from FrontMatter
"""
art_title = self.article.root.xpath('./front/article... |
Constructs the Authors content for the Heading. This should display
directly after the Article Title.
Metadata element, content derived from FrontMatter
def make_heading_authors(self, authors):
"""
Constructs the Authors content for the Heading. This should display
directly aft... |
Makes the content for the Author Affiliations, displays after the
Authors segment in the Heading.
Metadata element, content derived from FrontMatter
def make_heading_affiliations(self, heading_div):
"""
Makes the content for the Author Affiliations, displays after the
Authors s... |
An article may contain data for various kinds of abstracts. This method
works on those that are included in the Heading. This is displayed
after the Authors and Affiliations.
Metadata element, content derived from FrontMatter
def make_heading_abstracts(self, heading_div):
"""
A... |
The Article Info contains the (self) Citation, Editors, Dates,
Copyright, Funding Statement, Competing Interests Statement,
Correspondence, and Footnotes. Maybe more...
This content follows the Heading and precedes the Main segment in the
output.
This function accepts the recei... |
Creates a self citation node for the ArticleInfo of the article.
This method uses code from this page as a reference implementation:
https://github.com/PLOS/ambra/blob/master/base/src/main/resources/articleTransform-v3.xsl
def make_article_info_citation(self):
"""
Creates a self citati... |
Makes the section containing important dates for the article: typically
Received, Accepted, and Published.
def make_article_info_dates(self):
"""
Makes the section containing important dates for the article: typically
Received, Accepted, and Published.
"""
dates_div = et... |
Makes the copyright section for the ArticleInfo. For PLoS, this means
handling the information contained in the metadata <permissions>
element.
def make_article_info_copyright(self, article_info_div):
"""
Makes the copyright section for the ArticleInfo. For PLoS, this means
hand... |
Creates the element for declaring Funding in the article info.
def make_article_info_funding(self, article_info_div):
"""
Creates the element for declaring Funding in the article info.
"""
funding_group = self.article.root.xpath('./front/article-meta/funding-group')
if funding_g... |
Creates the element for declaring competing interests in the article
info.
def make_article_info_competing_interests(self, article_info_div):
"""
Creates the element for declaring competing interests in the article
info.
"""
#Check for author-notes
con_expr = "./... |
Articles generally provide a first contact, typically an email address
for one of the authors. This will supply that content.
def make_article_info_correspondences(self, article_info_div):
"""
Articles generally provide a first contact, typically an email address
for one of the authors.... |
This will catch all of the footnotes of type 'other' in the <fn-group>
of the <back> element.
def make_article_info_footnotes_other(self, article_info_div):
"""
This will catch all of the footnotes of type 'other' in the <fn-group>
of the <back> element.
"""
other_fn_exp... |
The <back> element may have 0 or 1 <label> elements and 0 or 1 <title>
elements. Then it may have any combination of the following: <ack>,
<app-group>, <bio>, <fn-group>, <glossary>, <ref-list>, <notes>, and
<sec>. <sec> is employed here as a catch-all for material that does not
fall und... |
The only intended use for this function is to patch a problem seen in
at least one PLoS article (journal.pgen.0020002). This will move any
<boxed-text> elements over to the receiving element, which is probably
the main body.
def move_back_boxed_texts(self):
"""
The only intended... |
The <ack> is an important piece of back matter information, and will be
including immediately after the main text.
This element should only occur once, optionally, for PLoS, if a need
becomes known, then multiple instances may be supported.
def make_back_acknowledgments(self):
"""
... |
Though this goes in the back of the document with the rest of the back
matter, it is not an element found under <back>.
I don't expect to see more than one of these. Compare this method to
make_article_info_competing_interests()
def make_back_author_contributions(self, body):
"""
... |
Glossaries are a fairly common item in papers for PLoS, but it also
seems that they are rarely incorporated into the PLoS web-site or PDF
formats. They are included in the ePub output however because they are
helpful and because we can.
def make_back_glossary(self, body):
"""
Gl... |
The notes element in PLoS articles can be employed for posting notices
of corrections or adjustments in proof. The <notes> element has a very
diverse content model, but PLoS practice appears to be fairly
consistent: a single <sec> containing a <title> and a <p>
def make_back_notes(self, body):
... |
<disp-formula> elements must be converted to conforming elements
def convert_disp_formula_elements(self):
"""
<disp-formula> elements must be converted to conforming elements
"""
for disp in self.main.getroot().findall('.//disp-formula'):
#find label element
labe... |
<inline-formula> elements must be converted to be conforming
These elements may contain <inline-graphic> elements, textual content,
or both.
def convert_inline_formula_elements(self):
"""
<inline-formula> elements must be converted to be conforming
These elements may contain <... |
Extract or extended quoted passage from another work, usually made
typographically distinct from surrounding text
<disp-quote> elements have a relatively complex content model, but PLoS
appears to employ either <p>s or <list>s.
def convert_disp_quote_elements(self):
"""
Extract... |
Textual material that is part of the body of text but outside the
flow of the narrative text, for example, a sidebar, marginalia, text
insert (whether enclosed in a box or not), caution, tip, note box, etc.
<boxed-text> elements for PLoS appear to all contain a single <sec>
element whic... |
Supplementary material are not, nor are they generally expected to be,
packaged into the epub file. Though this is a technical possibility,
and certain epub reading systems (such as those run on a PC) might be
reasonably capable of the external handling of diverse file formats
I presume ... |
This function will render a formatted URL for accessing the PLoS' server
SingleRepresentation of an object.
def fetch_single_representation(self, item_xlink_href):
"""
This function will render a formatted URL for accessing the PLoS' server
SingleRepresentation of an object.
"""... |
Responsible for the correct conversion of JPTS 3.0 <fig> elements to
EPUB xhtml. Aside from translating <fig> to <img>, the content model
must be edited.
def convert_fig_elements(self):
"""
Responsible for the correct conversion of JPTS 3.0 <fig> elements to
EPUB xhtml. Aside fr... |
A song, poem, or verse
Implementor’s Note: No attempt has been made to retain the look or
visual form of the original poetry.
This unusual element, <verse-group> is used to convey poetry and is
recursive in nature (it may contain further <verse-group> elements).
Examples of the... |
<fn> elements may be used in the main text body outside of tables and
figures for purposes such as erratum notes. It appears that PLoS
practice is to not show erratum notes in the web or pdf formats after
the appropriate corrections have been made to the text. The erratum
notes are thus ... |
A sequence of two or more items, which may or may not be ordered.
The <list> element has an optional <label> element and optional <title>
element, followed by one or more <list-item> elements. This is element
is recursive as the <list-item> elements may contain further <list> or
<def-li... |
A list in which each item consists of two parts: a word, phrase, term,
graphic, chemical structure, or equation paired with one of more
descriptions, discussions, explanations, or definitions of it.
<def-list> elements are lists of <def-item> elements which are in turn
composed of a pai... |
List of references (citations) for an article, which is often called
“References”, “Bibliography”, or “Additional Reading”.
No distinction is made between lists of cited references and lists of
suggested references.
This method should not be confused with the method(s) employed for the... |
Responsible for the correct conversion of JPTS 3.0 <table-wrap>
elements to EPUB content.
The 'id' attribute is treated as mandatory by this method.
def convert_table_wrap_elements(self):
"""
Responsible for the correct conversion of JPTS 3.0 <table-wrap>
elements to EPUB conte... |
This is a method for the odd special cases where <graphic> elements are
standalone, or rather, not a part of a standard graphical element such
as a figure or a table. This method should always be employed after the
standard cases have already been handled.
def convert_graphic_elements(self):
... |
과금정보 확인
args
CorpNum : 회원 사업자번호
MsgType : 문자전송 유형
UserID : 팝빌 회원아이디
return
과금정보 객체
raise
PopbillException
def getChargeInfo(self, CorpNum, MsgType, UserID=None):
""" 과금정보 확인
... |
단문 문자메시지 다량전송
args
CorpNum : 팝빌회원 사업자번호
Sender : 발신자번호 (동보전송용)
Contents : 문자 내용 (동보전송용)
Messages : 개별전송정보 배열
reserveDT : 예약전송시간 (형식. yyyyMMddHHmmss)
UserID : 팝빌회원 아이디
RequestNum : 전송요청번호
... |
장문 문자메시지 단건 전송
args
CorpNum : 팝빌회원 사업자번호
Sender : 발신번호
Receiver : 수신번호
ReceiverName : 수신자명
Subject : 메시지 제목
Contents : 메시지 내용(2000Byte 초과시 길이가 조정되어 전송됨)
reserveDT : 예약전송시간 (형식. yyyyMMddHHm... |
장문 문자메시지 다량전송
args
CorpNum : 팝빌회원 사업자번호
Sender : 발신자번호 (동보전송용)
Subject : 장문 메시지 제목 (동보전송용)
Contents : 장문 문자 내용 (동보전송용)
Messages : 개별전송정보 배열
reserveDT : 예약시간 (형식. yyyyMMddHHmmss)
UserID : 팝... |
멀티 문자메시지 다량 전송
args
CorpNum : 팝빌회원 사업자번호
Sender : 발신자번호 (동보전송용)
Subject : 장문 메시지 제목 (동보전송용)
Contents : 장문 문자 내용 (동보전송용)
Messages : 개별전송정보 배열
FilePath : 전송하고자 하는 파일 경로
reserveDT : 예약전송시간 (형... |
문자 메시지 전송
args
MsgType : 문자 전송 유형(단문:SMS, 장문:LMS, 단/장문:XMS)
CorpNum : 팝빌회원 사업자번호
Sender : 발신자번호 (동보전송용)
Subject : 장문 메시지 제목 (동보전송용)
Contents : 장문 문자 내용 (동보전송용)
Messages : 개별전송정보 배열
reserve... |
문자 전송결과 조회
args
CorpNum : 팝빌회원 사업자번호
ReceiptNum : 전송요청시 발급받은 접수번호
UserID : 팝빌회원 아이디
return
전송정보 as list
raise
PopbillException
def getMessages(self, CorpNum, ReceiptNum, UserID=None):
""... |
문자 전송결과 조회
args
CorpNum : 팝빌회원 사업자번호
RequestNum : 전송요청시 할당한 전송요청번호
UserID : 팝빌회원 아이디
return
전송정보 as list
raise
PopbillException
def getMessagesRN(self, CorpNum, RequestNum, UserID=None):
... |
문자 예약전송 취소
args
CorpNum : 팝빌회원 사업자번호
RequestNum : 전송요청시 할당한 전송요청번호
UserID : 팝빌회원 아이디
return
처리결과. consist of code and message
raise
PopbillException
def cancelReserveRN(self, CorpNum, RequestNum,... |
문자 관련 팝빌 URL
args
CorpNum : 팝빌회원 사업자번호
UserID : 팝빌회원 아이디
TOGO : BOX (전송내역조회 팝업)
return
팝빌 URL
raise
PopbillException
def getURL(self, CorpNum, UserID, ToGo):
""" 문자 관련 팝빌 URL
... |
전송내역 요약정보 확인
args
CorpNum : 팝빌회원 사업자번호
reciptNumList : 문자전송 접수번호 배열
UserID : 팝빌회원 아이디
return
전송정보 as list
raise
PopbillException
def getStates(self, Corpnum, reciptNumList, UserID=None):
... |
Create 1D Gaussian. Source:
http://mathworld.wolfram.com/GaussianFunction.html
def funcGauss1D(x, mu, sig):
""" Create 1D Gaussian. Source:
http://mathworld.wolfram.com/GaussianFunction.html
"""
arrOut = np.exp(-np.power((x - mu)/sig, 2.)/2)
# normalize
arrOut = arrOut/(np.sqrt(2.*np.pi)*si... |
Some paths must be made absolute, this will attempt to convert them.
def absolute_path(user_path):
"""
Some paths must be made absolute, this will attempt to convert them.
"""
if os.path.abspath(user_path):
return unix_path_coercion(user_path)
else:
try:
openaccess_epub.... |
The inner control loops for user interaction during quickstart
configuration.
def configure(default=None, dev=None):
"""
The inner control loops for user interaction during quickstart
configuration.
"""
cache_loc = openaccess_epub.utils.cache_location()
config_loc = openaccess_epub.utils.co... |
공인인증서 만료일 확인, 등록여부 확인용도로 활용가능
args
CorpNum : 확인할 회원 사업자번호
return
등록시 만료일자, 미등록시 해당 PopbillException raise.
raise
PopbillException
def getCertificateExpireDate(self, CorpNum):
""" 공인인증서 만료일 확인, 등록여부 확인용도로 활용가능
args
... |
파트너 관리번호 사용중 여부 확인.
args
CorpNum : 회원 사업자 번호
MgtKeyType : 관리번호 유형 one of ['SELL','BUY','TRUSTEE']
MgtKey : 파트너 관리번호
return
사용중 여부 by True/False
raise
PopbillException
def checkMgtKeyInUse(self, CorpNum, ... |
임시저장
args
CorpNum : 회원 사업자 번호
taxinvoice : 등록할 세금계산서 object. Made with Taxinvoice(...)
writeSpecification : 등록시 거래명세서 동시 작성 여부
UserID : 팝빌 회원아이디
return
처리결과. consist of code and message
raise
... |
즉시 발행
args
CorpNum : 팝빌회원 사업자번호
taxinvoice : 세금계산서 객체
writeSpecification : 거래명세서 동시작성 여부
forceIssue : 지연발행 강제여부
dealInvoiceMgtKey : 거래명세서 문서관리번호
memo : 메모
emailSubject : 메일제목, 미기재시 기본제목으로 전송
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.