మాడ్యూల్:Further: కూర్పుల మధ్య తేడాలు
Jump to navigation
Jump to search
Content deleted Content added
Arjunaraoc (చర్చ | రచనలు) చి en:Module:Further నుండి ఒక కూర్పు: తెలుగు వికీ లో వాడుటకు |
Updated from sandbox |
||
పంక్తి 5: | పంక్తి 5: | ||
local mHatnote = require('Module:Hatnote') |
local mHatnote = require('Module:Hatnote') |
||
local mHatlist = require('Module:Hatnote list') |
|||
local mTableTools -- lazily initialise |
local mTableTools -- lazily initialise |
||
local mArguments -- lazily initialise |
local mArguments -- lazily initialise |
||
local p = {} |
local p = {} |
||
పంక్తి 25: | పంక్తి 25: | ||
selfref = args.selfref |
selfref = args.selfref |
||
} |
} |
||
return p._further( |
return p._further(pages, options) |
||
end |
end |
||
function p._further( |
function p._further(pages, options) |
||
⚫ | |||
local links = mHatnote.formatPages(...) |
|||
⚫ | |||
return mHatnote._hatnote(text, options) |
return mHatnote._hatnote(text, options) |
||
end |
end |
14:35, 20 జూన్ 2016 నాటి కూర్పు
--[[
-- This module produces a "Further information: a, b and c" link. It implements
-- the {{further}} template.
--]]
local mHatnote = require('Module:Hatnote')
local mHatlist = require('Module:Hatnote list')
local mTableTools -- lazily initialise
local mArguments -- lazily initialise
local p = {}
function p.further(frame)
mTableTools = require('Module:TableTools')
mArguments = require('Module:Arguments')
local args = mArguments.getArgs(frame, {parentOnly = true})
local pages = mTableTools.compressSparseArray(args)
if #pages < 1 then
return mHatnote.makeWikitextError(
'no page names specified',
'Template:Further#Errors',
args.category
)
end
local options = {
selfref = args.selfref
}
return p._further(pages, options)
end
function p._further(pages, options)
local text = 'Further information: ' .. mHatlist.andList(pages, true)
return mHatnote._hatnote(text, options)
end
return p