Módulo:BibRules: mudanças entre as edições

sem sumário de edição
imported>Jaideraf
Sem resumo de edição
imported>Jaideraf
Sem resumo de edição
end
local test, info, queryResult
local f020infos = {}
if frame:expandTemplate{ title = 'Exist', args = { '245' } } ~= '' then
-- Record status
if test == 'n' then
info = "* Segundo o Líder, este é um registro '''novo''' (não um alterado ou revisado, expandido, excluído, etc.)."
table.insert(f020infos, info)
elseif test == 'c' then
info = "* Segundo o Líder, este é um registro '''alterado ou revisado''' (não um novo, expandido, excluído, etc.)."
table.insert(f020infos, info)
elseif test == 'a' or test == 'd' or test == 'p' then
info = "* Segundo o Líder, este é um registro '''expandido''' ou '''excluído''' (não novo)."
table.insert(f020infos, info)
end
-- Type of record
if test == 'a' then
info = "* Segundo o Líder, este registro descreve um '''material textual'''."
table.insert(f020infos, info)
end
-- Bibliographic level
if test == 'm' then
info = "* Segundo o Líder, este registro descreve um '''item monográfico''' (não parte de um item, não um item seriado, não uma coleção, etc.)."
table.insert(f020infos, info)
end
-- Encoding level
if test == '1' then
info = "* Segundo o Líder, este registro tem um nível '''completo''' de catalogação (mas o material não foi examinado)."
table.insert(f020infos, info)
else
info = "* Segundo o Líder, este registro tem um nível '''completo''' de catalogação (a descrição foi realizada com o material em mãos)."
table.insert(f020infos, info)
end
-- Descriptive cataloging form
if test == 'a' then
info = "* Segundo o Líder, este registro possui uma catalogação '''compatível com as regras do AACR 2'''."
table.insert(f020infos, info)
else
info = "* Segundo o Líder, este registro possui uma catalogação '''não compatível com as regras da ISBD'''."
table.insert(f020infos, info)
end
-- Explica a sintaxe "(Biblioteca)NúmeroDeControle"
local f001 = frame:expandTemplate{ title = 'Field data string', args = { '001', '0', '', property = 'Control field data' } }
info = '* Internamente, este registro é identificado pelo código "' .. f001 .. '"; para sistemas externos, o código é "(' .. frame:expandTemplate{ title = 'Field data string', args = { '003', '0', '', property = 'Control field data' } } .. ')' .. f001 .. '".'
table.insert(f020infos, info)
 
-- Campo 005
 
info = "* O registro foi criado em: " .. creationDate .. ". Sua última transação foi em: " .. modificationDate .. "."
table.insert(f020infos, info)
-- Campo 008
info = "* O item possui a seguinte origem: " .. f008pubPlace .. "."
end
table.insert(f020infos, info)
local invalidCode = "<strong class='error'>código inválido para o idioma, campo 008</strong>"
end
end
table.insert(f020infos, info)
-- testa se existe(m) ISBN(s) inválido(s)
if string.match(test, 'error') then
info = "* <strong class='error'>ISBN inválido, por favor, reveja os números informados.</strong>"
table.insert(f020infos, info)
end
for _, row in pairs( queryResult ) do
for _, data in pairs( row ) do
f020 = queryResultdata
end
end
end
if string.match(f020, '-') then
if string.match(infos, '-') then
info = "* <strong class='error'>O ISBN não pode conter hifens. Apenas números e \"X\" maiúsculo.</strong>"
table.insert(f020infos, info)
elseif string.match(f020infos, 'x') then
info = "* <strong class='error'>O ISBN não pode conter um x minúsculo. Apenas números e \"X\" maiúsculo.</strong>"
table.insert(f020infos, info)
end
end
end -- end if 245
return table.concat( f020infos, '\n' ), table.concat( f020, '\n')
 
end
Usuário anônimo