#310 zone quests
This commit is contained in:
parent
7fd353862c
commit
b568a0e045
@ -100,18 +100,16 @@
|
||||
|
||||
<div id="tabs-generic"></div>
|
||||
<div id="listview-generic" class="listview"></div>
|
||||
<!--<div id="lv-quests" class="listview"></div>-->
|
||||
<script type="text/javascript">
|
||||
var tabsRelated = new Tabs({ldelim}parent: ge('tabs-generic'){rdelim});
|
||||
{if isset($allitems)}{include file='bricks/allitems_table.tpl' data=$allitems}{/if}
|
||||
{if isset($zone.fishing)}{include file='bricks/item_table.tpl' id='fishing' name='fishing' tabsid='tabsRelated' data=$zone.fishing}{/if}
|
||||
{if isset($zone.subzones)}{include file='bricks/zone_table.tpl' id='zones' name='zones' tabsid='tabsRelated' data=$zone.subzones}{/if}
|
||||
|
||||
{if $page.comment}new Listview({ldelim}template: 'comment', id: 'comments', name: LANG.tab_comments, tabs: tabsRelated, parent: 'listview-generic', data: lv_comments{rdelim});{/if}
|
||||
{if isset($quests)}{include file='bricks/quest_table.tpl' id='quests' name='quests' tabsid='tabsRelated' data=$quests}{/if}
|
||||
tabsRelated.flush();
|
||||
</script>
|
||||
|
||||
{if $page.comment}{include file='bricks/contribute.tpl'}{/if}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
22
zone.php
22
zone.php
@ -8,6 +8,7 @@ require_once('includes/allitems.php');
|
||||
$smarty->config_load($conf_file, 'zone');
|
||||
|
||||
// номер объекта;
|
||||
//$podrazdel = explode('/',$podrazdel)[0];
|
||||
$id = intval($podrazdel);
|
||||
|
||||
$file = dirname(__FILE__).'/images/maps/enus/normal/'.$id;
|
||||
@ -57,6 +58,23 @@ if(!$zone = load_cache(ZONE_PAGE, $id))
|
||||
}
|
||||
unset($rows);
|
||||
|
||||
global $DB, $quest_class, $quest_cols;
|
||||
|
||||
$rows = $DB->select('
|
||||
SELECT ?#
|
||||
FROM ?_quest_template q
|
||||
WHERE
|
||||
1 = 1
|
||||
{ AND ZoneOrSort = ? }
|
||||
{ AND ZoneOrSort IN (?a) }
|
||||
ORDER BY Title
|
||||
{LIMIT ?d}
|
||||
', $quest_cols[2], $id, ((!IsSet($ZoneOrSort)) and $Type) ? $quest_class[$Type] : DBSIMPLE_SKIP, ($UDWBaseconf['limit'] > 0) ? $UDWBaseconf['limit'] : DBSIMPLE_SKIP
|
||||
);
|
||||
$quests = array();
|
||||
foreach ($rows as $numRow => $row)
|
||||
$quests[] = GetQuestInfo($row, QUEST_DATAFLAG_LISTINGS);
|
||||
|
||||
/*$rows = $DB->select('SELECT * FROM ?_dungeon_floor WHERE MapID = ?d', $zone['mapID']);
|
||||
if ($rows)
|
||||
{
|
||||
@ -185,6 +203,9 @@ if(!$zone = load_cache(ZONE_PAGE, $id))
|
||||
if (IsSet($allitems))
|
||||
$smarty->assign('allitems', $allitems);
|
||||
|
||||
if ($quests)
|
||||
$smarty->assign('quests', $quests);
|
||||
|
||||
/* // Положения объектофф:
|
||||
$zone['position'] = position($object['entry'], 'gameobject');
|
||||
|
||||
@ -213,7 +234,6 @@ $page = array(
|
||||
'path' => '[1, 1, '.$zone['map'].']',
|
||||
'comment' => true
|
||||
);
|
||||
|
||||
// Комментарии
|
||||
//if($AoWoWconf['disable_comments'])
|
||||
$page['comment'] = false;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user