Модуль:Песочница/Pok: различия между версиями

Нет описания правки
мНет описания правки
Строка 317: Строка 317:
         elseif subMode == 'contained' then
         elseif subMode == 'contained' then
             return frame:preprocess('{{СollapsibleMenu|' .. getContainedOutput(itemDataIndex, id) .. '}}')
             return frame:preprocess('{{СollapsibleMenu|' .. getContainedOutput(itemDataIndex, id) .. '}}')
elseif mode == "slot" then
elseif subMode == "slot" then
    local itemDataEntry = findDataById(itemSlotsData, id)
    local itemDataEntry = findDataById(itemSlotsData, id)
    if not itemDataEntry then return "ID не найден в данных ItemSlots." end
    if not itemDataEntry then return "" end
    local startingItem = getFirstStartingItem(itemDataEntry)
    local startingItem = getFirstStartingItem(itemDataEntry)
    if not startingItem then return "Не найден startingItem в slots." end
    if not startingItem then return "" end
    return frame:preprocess(formatContent(startingItem))
    return frame:preprocess(formatContent(startingItem))
Строка 334: Строка 334:
elseif mode == "slot" then
elseif mode == "slot" then
    local itemDataEntry = findDataById(itemSlotsData, id)
    local itemDataEntry = findDataById(itemSlotsData, id)
    if not itemDataEntry then return "ID не найден в данных ItemSlots." end
    if not itemDataEntry then return "" end
    local startingItem = getFirstStartingItem(itemDataEntry)
    local startingItem = getFirstStartingItem(itemDataEntry)
    if not startingItem then return "Не найден startingItem в slots." end
    if not startingItem then return "" end
    return frame:preprocess(formatContent(startingItem))
    return frame:preprocess(formatContent(startingItem))