Módulo:Citas: Diferenzas entre revisións

Contido eliminado Contido engadido
Banjo (conversa | contribucións)
mSen resumo de edición
Banjo (conversa | contribucións)
Sen resumo de edición
Liña 3.037:
Date validation supporting code is in Module:Citation/CS1/Date_validation
]]
-- do -- create defined block to contain local variables error_message and mismatch
-- local error_message = '';
-- AirDate has been promoted to Date so not necessary to check it
anchor_year, error_message = dates({['access-date']=AccessDate, ['archive-date']=ArchiveDate, ['date']=Date, ['doi-broken-date']=DoiBroken,
['embargo']=Embargo, ['lay-date']=LayDate, ['publication-date']=PublicationDate, ['year']=Year}, COinS_date);
 
-- if is_set (Year) and is_set (Date) then -- both |date= and |year= not normally needed;
-- local mismatch = year_date_check (Year, Date)
-- if 0 == mismatch then -- |year= does not match a year-value in |date=
-- if is_set (error_message) then -- if there is already an error message
-- error_message = error_message .. ', '; -- tack on this additional message
-- end
-- error_message = error_message .. '|year= / |date= mismatch';
-- elseif 1 == mismatch then -- |year= matches year-value in |date=
-- add_maint_cat ('date_year');
-- end
-- end
 
-- if is_set(error_message) then
-- table.insert( z.message_tail, { set_error( 'bad_date', {error_message}, true ) } ); -- add this error message
-- end
-- end -- end of do
 
-- Account for the oddity that is {{cite journal}} with |pmc= set and |url= not set. Do this after date check but before COInS.