Ответ
Trollo 09.02.2011 02:37
Это левая часть фрейма
@main[]
$text[^getLanguageText[/admin/engine/process]]
^left_html{
^openRightFrame[process_right.html?id=0&rnd=^math:random(100000);$text.actions.insert.label;$text.actions.insert.title]<br />
<div class="separator"></div>
$process_type[^MAIN:pSQL.sql[table]{
SELECT
data_process_type_id,
name
FROM
data_process_type
ORDER BY
sort_order
}]
^process_type.menu{
<p><b>$process_type.name:</b><br />
$process[^MAIN:pSQL.sql[table]{
SELECT
data_process.data_process_id,
data_process.name,
data_process.sort_order,
COUNT(^if($process_type.data_process_type_id == 1){object}{block}.data_process_id) AS cnt
FROM
data_process
^if($process_type.data_process_type_id == 1){
^MAIN:pSQL.left_join[from;object;data_process.data_process_id = object.data_process_id]
}{
^MAIN:pSQL.left_join[from;block;data_process.data_process_id = block.data_process_id]
}
WHERE
^if($process_type.data_process_type_id == 1){
^MAIN:pSQL.left_join[where;object;data_process.data_process_id = object.data_process_id]
}{
^MAIN:pSQL.left_join[where;block;data_process.data_process_id = block.data_process_id]
}
^if($process_type.data_process_type_id == 1){
( data_process.data_process_type_id = 1 OR data_process.data_process_type_id = '' ) AND
}{
data_process.data_process_type_id = $process_type.data_process_type_id AND
}
data_process.data_process_id != 0
GROUP BY
data_process.data_process_id, data_process.name, data_process.sort_order
ORDER BY
data_process.sort_order
}]
^if(^process.count[] > 1){
^openRightFrame[asort.html?type=data_process&where=^taint[uri][data_process_type_id%3D$process_type.data_process_type_id]&rnd=^math:random(100000);$text.actions.sort.label]
}{
$text.actions.sort.label<br />
}
^if($process){
<ul class="filelist">
^process.menu{
<li>^openRightFrame[./process_right.html?id=$process.data_process_id;$process.name]^if($process.cnt){ [^openRightFrame[./process_right.html?id=$process.data_process_id&data_process_type_id=$process_type.data_process_type_id;$process.cnt;$text.actions.find-use.title]]}</li>
}
</ul>
}{
$text.descriptions.not-found
}
</p>
}
}