Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F1949549
catalog_tab.tpl
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Thu, Oct 29, 6:39 AM
Size
5 KB
Mime Type
text/html
Expires
Sat, Oct 31, 6:39 AM (3 h, 16 m)
Engine
blob
Format
Raw Data
Handle
963462
Attached To
rINP In-Portal
catalog_tab.tpl
View Options
<
inp2:m_DefineElement
name
=
"catalog_tab"
>
<
inp2:m_if
check
=
"m_ParamEquals"
name
=
"tab_init"
value
=
""
inverse
=
"inverse"
>
<
inp2:m_if
check
=
"m_ParamEquals"
name
=
"tab_init"
value
=
"1"
>
a_toolbar.AddButton(
new ToolBarButton(
'new_cat',
'
<
inp2:m_phrase
label
=
"la_ToolTip_New_Category"
escape
=
"1"
/>
',
function() {
$
form_name =
$
Catalog.queryTabRegistry('prefix', '
<
inp2:m_param
name
=
"prefix"
/>
', 'tab_id') + '_form';
std_precreate_item('
<
inp2:m_param
name
=
"prefix"
/>
', 'categories/categories_edit');
}, true
)
);
</
inp2:m_if
>
<
inp2:m_if
check
=
"m_Param"
name
=
"tab_init"
equals_to
=
"2"
>
<
div
id
=
"categories_div"
prefix
=
"<inp2:m_param name='prefix'/>"
view_template
=
"catalog_tab"
edit_template
=
"categories/categories_edit"
category_id
=
"-1"
dep_buttons
=
"new_cat"
class
=
"catalog-tab"
></
div
>
<
script
type
=
"text/javascript"
>
$
Catalog
.
registerTab
(
'categories'
);</
script
>
</
inp2:m_if
>
<
inp2:m_if
check
=
"m_ParamEquals"
name
=
"tab_init"
value
=
"3"
>
$
Catalog.setItemCount('
<
inp2:m_Param
name
=
"prefix"
/>
', '
<
inp2:
{$
prefix
}
_CatalogItemCount
grid
=
"
$
grid_name"
/>
');
</
inp2:m_if
>
<
inp2:m_else
/>
<
inp2:lang.current_Field
name
=
"Charset"
result_to_var
=
"charset"
/>
<
inp2:m_Header
data
=
"Content-type: text/plain; charset=
$
charset"
/>
<
inp2:m_include
t
=
"incs/blocks"
/>
<
inp2:m_include
t
=
"incs/in-portal"
/>
<
inp2:m_include
t
=
"categories/ci_blocks"
/>
<
inp2:m_if
check
=
"m_Param"
name
=
"prefix"
equals_to
=
"c.showall"
>
<
inp2:
$
prefix_InitList
grid
=
"
$
grid_name"
parent_cat_id
=
"any"
/>
<
inp2:m_else
/>
<
inp2:
$
prefix_InitList
grid
=
"
$
grid_name"
/>
</
inp2:m_if
>
// substiture form action, like from was created from here
document.getElementById('categories_form').action = '
<
inp2:m_t
pass
=
"all"
no_amp
=
"1"
js_escape
=
"1"
/>
';
$
Catalog.setItemCount('
<
inp2:m_param
name
=
"prefix"
/>
', '
<
inp2:
$
prefix_CatalogItemCount
/>
');
$
Catalog.setCurrentCategory('
<
inp2:m_param
name
=
"prefix"
/>
',
<
inp2:m_get
name
=
"m_cat_id"
/>
);
$
Catalog.saveSearch('
<
inp2:m_Param
name
=
"prefix"
/>
', '
<
inp2:
$
prefix_SearchKeyword
js_escape
=
"1"
/>
', '
<
inp2:m_Param
name
=
"grid_name"
/>
');
<
inp2:m_DefineElement
name
=
"page_browse_td"
format
=
""
>
<
inp2:m_if
check
=
"m_Param"
name
=
"Special"
equals_to
=
"showall|user"
>
<
inp2:Field
field
=
"
$
fi
eld"
grid
=
"
$
grid"
format
=
"
$
format"
/>
<
inp2:m_if
check
=
"Field"
field
=
"IsSystem"
>
<
span
class
=
"field-required"
>
*
</
span
>
</
inp2:m_if
>
<
br
/>
<
span
class
=
"cats_stats"
>
<
inp2:Field
name
=
"ParentId"
result_to_var
=
"item_category"
/>
<
inp2:m_Phrase
name
=
"la_fld_PrimaryCategory"
/>
:
<
a
href
=
"<inp2:m_Link template="
catalog
/
catalog
"
m_cat_id
=
"
$
item_category"
no_pass_through
=
"1"
/>
">
<
inp2:CategoryName
cat_id
=
"
$
item_category"
/></
a
><
br
/>
</
span
>
<
inp2:m_else
/>
<
a
href
=
"javascript:
$
Catalog.go_to_cat(<inp2:m_get name="
c_id
"
/>
, '
<
inp2:GetModulePrefix
/>
');" title="
<
inp2:m_Phrase
name
=
'la_alt_GoInside'
html_escape
=
'1'
/>
">
<
inp2:Field
field
=
"
$
fi
eld"
grid
=
"
$
grid"
format
=
"
$
format"
/></
a
>
<
inp2:m_if
check
=
"Field"
field
=
"IsSystem"
>
<
span
class
=
"field-required"
>
*
</
span
>
</
inp2:m_if
>
</
inp2:m_if
>
<!--<span class="cats_stats">(<inp2:SubCatCount/> / <inp2:ItemCount/>)</span>-->
<
a
href
=
"<inp2:PageBrowseLink/>"
title
=
"<inp2:m_Phrase name='la_alt_Browse' html_escape='1'/>"
>
<
img
src
=
"<inp2:m_TemplatesBase/>/img/arrow.gif"
width
=
"15"
height
=
"15"
alt
=
"<inp2:m_Phrase name='la_alt_Browse' html_escape='1'/>"
border
=
"0"
/>
</
a
>
<!--
<span class="priority">
<inp2:m_if check="FieldEquals" field="Priority" value="0" inverse="inverse">
<sup><inp2:Field field="Priority"/></sup>
</inp2:m_if>
</span>-->
<
br
/>
<
inp2:m_if
check
=
"m_IsDebugMode"
>
PP:
<
inp2:Field
name
=
"ParentPath"
/>
</
inp2:m_if
>
</
inp2:m_DefineElement
>
<
inp2:m_RenderElement
name
=
"grid_js"
PrefixSpecial
=
"
$
prefix"
IdField
=
"CategoryId"
grid
=
"
$
grid_name"
menu_filters
=
"yes"
/>
<
inp2:m_RenderElement
name
=
"grid_search_buttons"
PrefixSpecial
=
"
$
prefix"
grid
=
"
$
grid_name"
ajax
=
"1"
/>
Grids['
<
inp2:m_param
name
=
"prefix"
/>
'].SetDependantToolbarButtons( new Array('edit','delete','approve','decline','sep3','cut','copy','move_up','move_down','sep6'));
<
inp2:m_if
check
=
"m_GetEquals"
name
=
"m_cat_id"
value
=
"0"
>
a_toolbar.DisableButton('upcat');
a_toolbar.DisableButton('homecat');
<
inp2:m_else
/>
a_toolbar.EnableButton('upcat');
a_toolbar.EnableButton('homecat');
</
inp2:m_if
>
$
Catalog.reflectPasteButton(
<
inp2:
$
prefix_HasClipboard
/>
);
<
inp2:m_if
check
=
"m_Recall"
name
=
"root_delete_error"
>
alert('
<
inp2:m_Phrase
name
=
"la_error_RootCategoriesDelete"
/>
');
<
inp2:m_RemoveVar
name
=
"root_delete_error"
/>
</
inp2:m_if
>
#separator#
<!-- categories tab: begin -->
<
inp2:m_RenderElement
name
=
"kernel_form"
form_name
=
"categories_form"
/>
<
inp2:m_RenderElement
name
=
"grid"
ajax
=
"1"
PrefixSpecial
=
"
$
prefix"
IdField
=
"CategoryId"
grid
=
"
$
grid_name"
menu_filters
=
"yes"
/>
<
inp2:m_RenderElement
name
=
"kernel_form_end"
/>
<!-- categories tab: end -->
</
inp2:m_if
>
</
inp2:m_DefineElement
>
<
inp2:c_InitCatalogTab
render_as
=
"catalog_tab"
default_grid
=
"Default"
radio_grid
=
"Radio"
/>
Event Timeline
Log In to Comment