Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F726449
in-commerce
No One
Temporary
Actions
View 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
Sun, Jan 5, 6:21 PM
Size
3 KB
Mime Type
text/x-diff
Expires
Tue, Jan 7, 6:21 PM (3 h, 2 m ago)
Engine
blob
Format
Raw Data
Handle
536570
Attached To
rMINC Modules.In-Commerce
in-commerce
View Options
Index: branches/5.0.x/admin_templates/shipping/shipping_zones.tpl
===================================================================
--- branches/5.0.x/admin_templates/shipping/shipping_zones.tpl (revision 13014)
+++ branches/5.0.x/admin_templates/shipping/shipping_zones.tpl (revision 13015)
@@ -1,93 +1,101 @@
<inp2:adm_SetPopupSize width="850" height="610"/>
<inp2:m_include t="incs/header"/>
<inp2:m_RenderElement name="combined_header" prefix="s" section="in-commerce:shipping" title_preset="zones" pagination="1" pagination_prefix="z" tab_preset="Default"/>
<!-- ToolBar -->
<table class="toolbar" height="30" cellspacing="0" cellpadding="0" width="100%" border="0">
<tbody>
<tr>
<td>
<script type="text/javascript">
a_toolbar = new ToolBar();
a_toolbar.AddButton( new ToolBarButton('select', '<inp2:m_phrase label="la_ToolTip_Save" escape="1"/>', function() {
submit_event('s','<inp2:s_SaveEvent/>');
}
) );
a_toolbar.AddButton( new ToolBarButton('cancel', '<inp2:m_phrase label="la_ToolTip_Cancel" escape="1"/>', function() {
submit_event('s','OnCancelEdit');
}
) );
a_toolbar.AddButton( new ToolBarSeparator('sep1') );
a_toolbar.AddButton( new ToolBarButton('prev', '<inp2:m_phrase label="la_ToolTip_Prev" escape="1"/>', function() {
go_to_id('s', '<inp2:s_PrevId/>');
}
) );
a_toolbar.AddButton( new ToolBarButton('next', '<inp2:m_phrase label="la_ToolTip_Next" escape="1"/>', function() {
go_to_id('s', '<inp2:s_NextId/>');
}
) );
a_toolbar.AddButton( new ToolBarSeparator('sep2') );
a_toolbar.AddButton( new ToolBarButton('new_item', '<inp2:m_phrase label="la_ToolTip_NewShipZone" escape="1"/>::<inp2:m_phrase label="la_ToolTip_Add" escape="1"/>',
function() {
std_new_item('z', 'in-commerce/shipping/zone_edit')
} ) );
function edit()
{
- opener_action('d');
- submit_event('z', 'OnLoadZoneForm', 'in-commerce/shipping/zone_edit')
+ // TODO: make OnLoadZoneForm as hook to OnStoreSelected, when such event will be available
+ // std_edit_temp_item('z', 'in-commerce/shipping/zone_edit');
+
+ if (use_popups('z', 'OnLoadZoneForm')) {
+ open_popup('z', 'OnLoadZoneForm', 'in-commerce/shipping/zone_edit');
+ }
+ else {
+ opener_action('d');
+ submit_event('z', 'OnLoadZoneForm', 'in-commerce/shipping/zone_edit');
+ }
}
a_toolbar.AddButton( new ToolBarButton('edit', '<inp2:m_phrase label="la_ToolTip_Edit" escape="1"/>', edit) );
a_toolbar.AddButton( new ToolBarButton('delete', '<inp2:m_phrase label="la_ToolTip_Delete" escape="1"/>',
function() {
std_delete_items('z')
} ) );
a_toolbar.AddButton( new ToolBarButton('clone', '<inp2:m_phrase label="la_ToolTip_Clone" escape="1"/>',
function() {
submit_event('z', 'OnMassClone')
} ) );
a_toolbar.AddButton( new ToolBarSeparator('sep3') );
a_toolbar.AddButton( new ToolBarButton('view', '<inp2:m_phrase label="la_ToolTip_View" escape="1"/>', function() {
show_viewmenu(a_toolbar,'view');
}
) );
a_toolbar.Render();
<inp2:m_if check="s_IsSingle" >
a_toolbar.HideButton('prev');
a_toolbar.HideButton('next');
a_toolbar.HideButton('sep1');
<inp2:m_else/>
<inp2:m_if check="s_IsLast" >
a_toolbar.DisableButton('next');
</inp2:m_if>
<inp2:m_if check="s_IsFirst" >
a_toolbar.DisableButton('prev');
</inp2:m_if>
</inp2:m_if>
</script>
</td>
<inp2:m_RenderElement name="search_main_toolbar" prefix="z" grid="Default"/>
</tr>
</tbody>
</table>
<inp2:m_RenderElement name="grid" PrefixSpecial="z" IdField="ZoneID" grid="Default"/>
<script type="text/javascript">
Grids['z'].SetDependantToolbarButtons( new Array('edit','delete','clone') );
</script>
<inp2:m_include t="incs/footer"/>
\ No newline at end of file
Event Timeline
Log In to Comment