Biblatex: 텍스트의 저자 연도 참고문헌의 저자 제목

Biblatex: 텍스트의 저자 연도 참고문헌의 저자 제목

제목과 같이 인용을 하게 되는 안타까운 상황에 처해 있습니다.

동일한 저자와 동일한 연도를 가진 두 개의 서로 다른 참고문헌 항목이 없는 한 이는 문제가 되지 않습니다. 이 경우에는 (Author 2012a)및 같은 텍스트 항목을 얻지 (Author 2012b)만 참조에는 다음과 같은 항목이 추가되어야 합니다 (cited as: 2012a).

나는 그것을 처리하기 위해 biblatex에서 물건을 재정의하는 데 충분하지 않습니다. 이상적으로는 다음과 같은 솔루션이 필요합니다.

If there are multiple citations of the same author and year, then append "(cited as: <year><year_label>)", if not, do whatever you would normally do.

현재 이것은 나의 최소한의 작업 예입니다.

\documentclass{article}
\usepackage[maxcitenames=3,style=authortitle,citestyle=authoryear,dashed=false,backend=biber]{biblatex}
\DeclareNameAlias{sortname}{last-first}
\newbibmacro*{publisher+location+date}{%
      \printlist{publisher}%
      \iflistundef{location}
        {\setunit*{\addcomma\space}}
        {\setunit*{\addcolon\space}}%
      \printlist{location}%
      \setunit*{\space}%
      \usebibmacro{date}%
      \newunit
    }

\begin{filecontents}{\jobname.bib}
  @article{JoeDoe2012,
    Author = {Joe Doe},
    Title = {My article's title},
    Journal = {My journal's title},
    Editor = {Ben Editor},
    URL = {http://webpage.com},
    Year = {2012},
  }

  @article{JoeDoe20121,
    Author = {Joe Doe},
    Title = {Same author same year},
    Journal = {My journal's title},
    Editor = {Ben Editor},
    URL = {http://webpage.com},
    Year = {2012},
  }
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}
  We cite \autocite{JoeDoe2012} and \autocite{JoeDoe20121}
  \printbibliography
\end{document}

현재 다음과 같습니다.

여기에 이미지 설명을 입력하세요

나는 다음과 같이 강제로 수행하는 동안 :

여기에 이미지 설명을 입력하세요

addendum = {(cited as: 2012a)}(스크린샷에서는 " )"를 수동으로 삽입하여 문제를 해결했습니다.

내가 설명한 조건부 방식으로 이를 달성하는 데 누군가 도움을 줄 수 있기를 바랍니다.

답변1

de 이름을 바꿉니다 bibmacro{finentry}. 'a' 부분은 into extrayear필드이고 부분은 2012into labelyear필드입니다. 그런 다음 정의되지 않은 경우 아무것도 인쇄하지 않는다는 논리를 추가합니다 extrayear. 반면에 정의된 경우 괄호 사이에 labelyearentrayear필드를 인쇄합니다.

MWE:

\documentclass{article}
\usepackage[maxcitenames=3,style=authortitle,citestyle=authoryear,dashed=false,backend=biber]{biblatex}
\DeclareNameAlias{sortname}{last-first}
\newbibmacro*{publisher+location+date}{%
      \printlist{publisher}%
      \iflistundef{location}
        {\setunit*{\addcomma\space}}
        {\setunit*{\addcolon\space}}%
      \printlist{location}%
      \setunit*{\space}%
      \usebibmacro{date}%
      \newunit
    }

\renewbibmacro{finentry}{%
\usebibmacro{citeas}%
\finentry}

\newbibmacro*{citeas}{%
\iffieldundef{extrayear}
  {}
  {\setunit{\adddot\space}
  \newunit\newblock
  \printtext[citeas]{%
  \printfield{labelyear}%
  \printfield{extrayear}}}}

\DeclareFieldFormat{citeas}{\mkbibparens{Cite as:\space#1}}

\begin{filecontents}{\jobname.bib}
  @article{JoeDoe2012,
    Author = {Joe Doe},
    Title = {My article's title},
    Journal = {My journal's title},
    Editor = {Ben Editor},
    URL = {http://webpage.com},
    Year = {2012},
  }

  @article{JoeDoe20121,
    Author = {Joe Doe},
    Title = {Same author same year},
    Journal = {My journal's title},
    Editor = {Ben Editor},
    URL = {http://webpage.com},
    Year = {2012},
  }

    @article{Moe2013,
      Author = {Moe Doe},
      Title = {Other author},
      Journal = {My journal's title},
      Editor = {Ben Editor},
      URL = {http://webpage.com},
      Year = {2010},
    }
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}
  We cite \parencite{JoeDoe2012} and \parencite{JoeDoe20121}.

  Other author \parencite{Moe2013}
  \printbibliography
\end{document}

여기에 이미지 설명을 입력하세요

관련 정보