Problem with CSL Macro

I have a Macro called "author-editor-note". It should print the Author(s) or - if there are no Author(s) it should print the Editor(s). (Substituted < and > with ( and ) )

(macro name="author-editor-note")
(names variable="author" font-style="italic")
(name form="short" delimiter="/" et-al-min="3" et-al-use-first="1" sort-separator=""/)
(substitute)
(names variable="editor")
(name form="short" delimiter="/" et-al-min="3" et-al-use-first="1" sort-separator=""/)
(/names)
(/substitute)
(/names)
(/macro)

The Macro works in the citation, but not in the bibliography (It shows no editor(s)
In the bibliography it is used like so:
(group)
(text term="cited_as"/)
(text macro="author-editor-note" suffix=", "/)
(text variable="title" form="short"/)
(text value=")"/)
(/group)

In the citation it looks so:
(group delimiter=", ")
(text macro="author-editor-note"/)
(text variable="title" form="short"/)
(text macro="locator-with-label"/)
(/group)

Any thoughts?
https://s3.amazonaws.com/zotero.org/images/forums/u16653648/swz5ue7t8ja44nit4vvk.png
  • I seem to have a similar problem with the editor field. Here is an example of a book entry with editor (first) and a chapter entry with author (second). I use the author-citation macro to identify the bibliography entries.

    https://s3.amazonaws.com/zotero.org/images/forums/u13740491/qfm5koo52zrckofnilv4.png

    As you can see, displaying the author works, but subsidising the author with the editor does not.


    The first bibliography entry should look like this:

    Kalusche (2021)
    Kalusche, W. (Hrsg.): BKI Handbuch Kostenplanung im Hochbau. 4. komplett überarbeitete Auflage Stuttgart : BKI 2021, 422 Seiten, ISBN: 978-3-948683-10-8


    This is my author-bib macro, which does not work as expected:



    <macro name="author-bib">
    <names variable="author" delimiter=" ; " suffix=": ">
    <name delimiter=" ; " initialize-with=". " name-as-sort-order="all"/>
    <label/>
    <substitute>
    <names variable="editor"/>
    </substitute>
    </names>
    </macro>


    Here is my author-citation macro:


    <macro name="author-citation">
    <names variable="author">
    <name form="short" delimiter=" / " et-al-min="3" et-al-use-first="1"/>
    <substitute>
    <names variable="editor"/>
    </substitute>
    </names>
    </macro>
Sign In or Register to comment.