Modul:Citation: Unterschied zwischen den Versionen
urn/doi/hdl
(urn check) |
(urn/doi/hdl) |
||
| Zeile 2: | Zeile 2: | ||
local citation = { | local citation = { | ||
suite = 'Citation', | suite = 'Citation', | ||
serial = '2022-08- | serial = '2022-08-17', | ||
item = 56159597 | item = 56159597 | ||
} | } | ||
| Zeile 216: | Zeile 216: | ||
not cu.check_UrnNbn( 'urn:' .. args.urn ) then | not cu.check_UrnNbn( 'urn:' .. args.urn ) then | ||
cu.addErrorMsg( ci.texts.wrongURN ) | cu.addErrorMsg( ci.texts.wrongURN ) | ||
end | end | ||
| Zeile 231: | Zeile 227: | ||
args.hdl = '' | args.hdl = '' | ||
table.insert( wrong, 'hdl' ) | table.insert( wrong, 'hdl' ) | ||
end | |||
if not cu.isSet( args.url ) then | |||
for _, key in ipairs( { 'urn', 'doi', 'hdl' } ) do | |||
if cu.isSet( args[ key ] ) then | |||
args.url = ci.params[ key ].url:format( args[ key ] ) | |||
if key == 'urn' then | |||
args.urn = '' | |||
end | |||
break | |||
end | |||
end | |||
end | end | ||