重新排序访问日期(urldate)和 URL

重新排序访问日期(urldate)和 URL

我正在尝试指定数据库的引用。考虑以下具有两个入口的 MWE:`

\documentclass[12pt, bibliography=totocnumbered, listof=totoc]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[ngerman]{babel}
\usepackage{csquotes}

\usepackage{filecontents}

%Bibliotheken
\usepackage
[style=ext-authoryear,labelnumber, useprefix=true,
sorting=nyt,maxbibnames=9,maxcitenames=3,uniquelist=false, backend=biber, 
doi=false,isbn=false,url=false,
uniquename=false,bibencoding=utf8, date=year, giveninits=true, terseinits=false, dashed=false]
{biblatex}


%Doppelpunkt nach Jahr
\renewcommand{\labelnamepunct}{\addcolon\space}

%Remove Dot after volume
\renewbibmacro*{volume+number+eid}{%
  \printfield{volume}%
%  \setunit*{\adddot}% DELETED
 % \setunit*{\addnbspace}% NEW (optional); there's also \addnbthinspace
  \printfield{number}%
  \setunit{\addcomma\space}%
  \printfield{eid}}
\DeclareFieldFormat[article]{number}{\mkbibparens{#1}}

% Number of articles in parentheses
\DeclareFieldFormat[article]{number}{\mkbibparens{#1}}

%Dot after journal title
\DeclareFieldFormat{journaltitle}{{#1}\isdot}

\renewbibmacro*{journal+issuetitle}{%
  \usebibmacro{journal}%
  \setunit*{\addcomma\space}%
  \iffieldundef{series}
    {}
    {\newunit
     \printfield{series}%
     \setunit{\addspace}}%
  \usebibmacro{volume+number+eid}%
  \setunit{\addspace}%
  \usebibmacro{issue+date}%
  \setunit{\addcolon\space}%
  \usebibmacro{issue}%
  \newunit}


%Dort und Sorting Last-First
\DeclareNameAlias{sortname}{first-last-bold}

\DeclareNameFormat{first-last-bold}{\mkbibbold{%
  \ifgiveninits
    {\usebibmacro{name:last-first}{\namepartfamily}{\namepartgiveni}{\namepartprefix}{\namepartsuffix}}
    {\usebibmacro{name:last-first}{\namepartfamily}{\namepartgiven}{\namepartprefix}{\namepartsuffix}}%
  \usebibmacro{name:andothers}}}

%Change to Zugriff am
\DefineBibliographyStrings{german}{% 
urlseen = {Zugriff am}, 
}

%URL date without parantheses
\DeclareFieldFormat{urldate}{\addcomma\space\bibstring{urlseen}\space#1}


%Remove word "URL":
\DeclareFieldFormat{url}{\url{#1}}

\begin{filecontents}{\jobname2.bib}
@Article{Hansen2011,
  author  = {Hansen, Peter R. and Lunde, Asger and Nason, James M.},
  title   = {The Model Confidence Set},
  journal = {Econometrica},
  year    = {2011},
  volume  = {79},
  number  = {2},
  pages   = {453-497},
  url     = {https://EconPapers.repec.org/RePEc:ecm:emetrp:v:79:y:2011:i:2:p:453-497},
}

@WWW{Amadeus2018,
  author  = {Bureau van Dijk},
  title   = {Amadeus},
  year    = {2018},
  url     = {https://www.bvdinfo.com/en-us/our-products/data/international/amadeus},
  urldate = {2018-11-24},
}



\end{filecontents}
\addbibresource{\jobname2.bib} 

\begin{document}
\textcite{Hansen2011}
\textcite{Amadeus2018}
\printbibliography
\end{document}

不过,我想指定数据库的引用如下:

凡·戴克局 (2018)。艾玛迪斯。于 2018 年 11 月 24 日修订。 www.bdv...

具体来说,我希望首先列出网址日期,然后列出互联网页面。此外,它们应该用点分隔。最后,与其他来源不同,我想用点替换括号中年份后的冒号。

答案1

对于 URL 和 URL 日期,您几乎已经自己找到了所有内容,要将顺序更改为“ urldate- url”,我们只需要重新定义参考书目宏url+urldate

@online通过重新定义 ,可以将冒号变成条目的句点namtitledelim。由于您希望根据条目类型获得不同的结果(这不是我在这里推荐的),我们需要使用 进行分支\ifentrytype

\documentclass[12pt, bibliography=totocnumbered, listof=totoc]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}% UTF-8 is the usual encoding in modern editors,
                           % it's even the default for modern LaTeX versions
\usepackage{lmodern}
\usepackage[ngerman]{babel}
\usepackage{csquotes}


\usepackage[backend=biber, style=ext-authoryear,
  maxbibnames=9, maxcitenames=3, uniquelist=false, uniquename=false,
  useprefix=true, giveninits=true, dashed=false
  doi=false,isbn=false,url=false,
  date=year]{biblatex}

% name formatting
\DeclareNameAlias{sortname}{family-given}
\DeclareNameWrapperFormat{sortname}{\mkbibbold{#1}}

\DeclareDelimFormat{multinamedelim}{\addslash}
\DeclareDelimAlias{finalnamedelim}{multinamedelim}

\DeclareDelimFormat[bib,biblist]{multinamedelim}{\addcomma\space}
\DeclareDelimFormat[bib,biblist]{finalnamedelim}{%
  \ifnumgreater{\value{liststop}}{2}{\finalandcomma}{}%
  \addspace\bibstring{and}\space}

% delimier between name (year) and title
% labelnamepunct is deprecated
\DeclareDelimFormat[bib,biblist]{nametitledelim}{%
  \ifentrytype{online}
    {\addperiod}
    {\addcolon}%
  \space
}

% format of journal, volume, number
\DeclareFieldFormat{journaltitle}{#1\isdot}
\renewcommand*{\jourvoldelim}{\addcomma\space}
\renewcommand*{\volnumdelim}{}
\DeclareFieldFormat[article]{number}{\mkbibparens{#1}}

% URL date and URL format
\DefineBibliographyStrings{german}{% 
  urlseen = {Zugriff am}, 
}

\DeclareFieldFormat{urldate}{\bibstring{urlseen}\space#1}
\DeclareFieldFormat{url}{\url{#1}}

\renewbibmacro*{url+urldate}{%
  \usebibmacro{urldate}%
  \newunit
  \usebibmacro{url}%
}

\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{Hansen2011,
  author  = {Hansen, Peter R. and Lunde, Asger and Nason, James M.},
  title   = {The Model Confidence Set},
  journal = {Econometrica},
  year    = {2011},
  volume  = {79},
  number  = {2},
  pages   = {453-497},
  url     = {https://EconPapers.repec.org/RePEc:ecm:emetrp:v:79:y:2011:i:2:p:453-497},
}
@online{Amadeus2018,
  author  = {Bureau van Dijk},
  title   = {Amadeus},
  year    = {2018},
  url     = {https://www.bvdinfo.com/en-us/our-products/data/international/amadeus},
  urldate = {2018-11-24},
}
\end{filecontents}
\addbibresource{\jobname.bib} 

\begin{document}
\textcite{Hansen2011}
\textcite{Amadeus2018}
\printbibliography
\end{document}

**Hansen, PR、Lunde, A. 和 Nason, JM** (2011):“模型置信集”。引自:《Econometrica》,79(2),第 453–497 页。//**Van Dijk, B.** (2018)。 *阿玛迪斯*。于 2018 年 11 月 24 日修订。 https://www.bvdinfo.com/en-us/our-products/data/international/amadeus。

请注意文中引用作者时,采用作者-年份格式,作者之间用斜线隔开我对您的代码进行了现代化改造,使其能够使用更多biblatex-ext特性以及新的biblatex3.12 功能,从而使其更加紧凑。

相关内容