[Item] Metadata and Notes 获取条目的元数据和所有子笔记信息 #543
Replies: 5 comments 5 replies
-
说明:
当前模板在 1.0.4版本插件 上运行正常 |
Beta Was this translation helpful? Give feedback.
-
The original post is the template content that can be pasted into the template editor of BN. The latest version supports import template from clipboard, here is the full template for importing: # This template is specifically for importing/sharing, using better
# notes 'import from clipboard': copy the content and
# goto Zotero menu bar, click Edit->New Template from Clipboard.
# Do not copy-paste this to better notes template editor directly.
name: "[Item] Metadata and Notes 获取条目的元数据和所有子笔记信息"
content: |-
// @author youngfish42
// @link https://github.com/windingwind/zotero-better-notes/discussions/543
// @use-markdown
## ${topItem.getField('title')}
// @获取Item的作者信息
Authors: ${topItem.getCreators().map((v)=>v.firstName+" "+v.lastName).join("; ")}
// @获取Item的类别信息(比如是会议还是期刊,以及对应的系列名)
<p>
${(()=>{
if(topItem.itemType === "conferencePaper") return "Conference";
if(topItem.itemType === "journalArticle") return "Journal";
if(topItem.itemType === "report") return "Publisher";
return "Publisher";})()}
:
${(()=>{
if(topItem.itemType === "conferencePaper") {
const res = topItem.getField("conferenceName");
return res?res:topItem.getField("proceedingsTitle");
};
if(topItem.itemType === "journalArticle") return topItem.getField("publicationTitle");
if(topItem.itemType === "report") return topItem.getField("institution");
return topItem.getField("publicationTitle");})()}
</p>
// @获取Item的超链接信息
Url: ${topItem.getField('url')}
// @获取Item的摘要信息
Abstract: ${topItem.getField('abstractNote')}
// @获取Item的其他信息(如果使用PDF Translate等插件,会把信息存在该字段中)
${topItem.getField('extra')}
// @获取当前Item下的所有Notes,并输出
Notes: ${topItem.getNotes().map((noteID) => Zotero.Items.get(noteID).getNote())} |
Beta Was this translation helpful? Give feedback.
-
Error: ReferenceError: topItem is not defined |
Beta Was this translation helpful? Give feedback.
-
本模板已被用于 文章速览 | 联邦学习 x CVPR'2023 等文章,方便 Awesome-FL 项目对于联邦学习领域的前沿论文信息整理。 |
Beta Was this translation helpful? Give feedback.
-
你好,我使用时出现了 Error: ReferenceError: topItem is not defined |
Beta Was this translation helpful? Give feedback.
-
完整版
效果预览
清爽版
仅保留标题,作者名,超链接,摘要和笔记
效果预览
Beta Was this translation helpful? Give feedback.
All reactions