Модуль:Отексте: различия между версиями

+ ДАТАПУБЛИКАЦИИОРИГИНАЛА
(повтор)
Метка: отмена
(+ ДАТАПУБЛИКАЦИИОРИГИНАЛА)
origTitle = nodict and is( pargs["НАЗВАНИЕОРИГИНАЛА"] ),
origSub = nodict and is( pargs["ПОДЗАГОЛОВОКОРИГИНАЛА"] ),
origPublished = nodict and is( pargs["ДАТАПУБЛИКАЦИИОРИГИНАЛА"] ),
translator = nodict and is( pargs["ПЕРЕВОДЧИК"] ),
index = nodict and is( pargs["СОДЕРЖАНИЕ"] ),
function renderNotes ( frame )
-- Languages
local ol, os, ot, od = data.p.origLang, data.p.origSub, data.p.origTitle, data.p.origPublished
local langorig_str = ""
if isTrans then
local langs = mw.loadData('Модуль:Отексте/transl-lang')
if not langs[ol] then ol = "un" end
if ot then
lang = s.lang[isPRS] .. langs[ol][isPRS]
if os then os = " : " .. os; addCat(s.cat.pageWithSub) else os = "" end
if ot then lang orig_str = lang'Оригинал: .. ". "' .. s.orig_titlelangs[isPRSol].abbr .. "' ''" .. ot .. os .. "'''" end
if od then orig_str = orig_str .. ", опубл.: " .. od end
else
lang orig_str = s.lang[isPRS] .. langs[ol][isPRS] .. ' '
end
addCat ( s.cat.transFrom .. langs[ol]["cat"] .. "]]" )
end
if data.p.cycle and data.p.collection then coll_pre = "сб. " else coll_pre = s.collection[isPRS] end
local publ_pre, dates
if isTrans then
if created and published then publ_pre = ", опубл.: " else publ_pre = "Опубл.: " end
if created and published then
if created then created = s.created[isPRS] .. created else created = "" end
dates = "Перевод созд.: " .. created .. ', опубл: ' .. published
if published then published = publ_pre .. published else published = "" end
dates = elseif created ..then published
dates = "Перевод созд.: " .. created
elseif published then
dates = "Перевод опубл.: " .. published
end
else
local publ_pre
if created and published then publ_pre = ", опубл.: " else publ_pre = "Опубл.: " end
if created then created = s.created[isPRS] .. created else created = "" end
if published then published = publ_pre .. published else published = "" end
dates = created .. published
end
if is( dates ) then dates = dates .. ". " else dates = "" end
local lawdeprecated = data.lawdeprecated or data.p.lawdeprecated
-- separators
if isData or other then if is( langorig_str ) then langorig_str = langorig_str .. ". — " end end
if isData then
if other then other = " • " .. other else other = "" end
-- render
local result = mw.html.create( "td" )
result:wikitext ( langorig_str )
if data.p.index then