|
@@ -37852,29 +37852,7 @@ define(['exports'], function (exports) { 'use strict';
|
|
|
.find('.navbar>.x-panelheader')
|
|
|
.find('.x-body-el>.fa-angle-left');
|
|
|
$back.off('click');
|
|
|
- $back.on('click', function () {
|
|
|
- var handle = Ext.Viewport.getActiveItem();
|
|
|
- // 显示前一个页面
|
|
|
- var index = Scope.SHOW_PAGE_STACK.findIndex(function (scope) { return scope._handle === handle; });
|
|
|
- // console.log("###### remove", index)
|
|
|
- if (index >= 0) {
|
|
|
- Scope.SHOW_PAGE_STACK.splice(index, 1);
|
|
|
- }
|
|
|
- var scopeArr = lodash.sortBy(Scope.SHOW_PAGE_STACK, function (scope) { return scope._lastShowTime; });
|
|
|
- if (scopeArr.length > 0) {
|
|
|
- var scope = scopeArr[scopeArr.length - 1];
|
|
|
- scope._handle.setStyle({ 'z-index': 1 });
|
|
|
- Ext.Viewport.getLayout().setAnimation({ type: 'slide', direction: 'right', duration: 300 });
|
|
|
- Ext.Viewport.setActiveItem(scope._handle);
|
|
|
- scope._lastShowTime = new Date().getTime();
|
|
|
- // console.log("###### show", (scopeArr.length - 1), Scope.SHOW_PAGE_STACK)
|
|
|
- }
|
|
|
- // 关闭
|
|
|
- handle.setStyle({ 'z-index': 0 });
|
|
|
- // Ext.Viewport.getLayout().setAnimation({type: 'slide', direction: 'right', duration: 300})
|
|
|
- Ext.Viewport.remove(handle);
|
|
|
- handle.close();
|
|
|
- });
|
|
|
+ $back.on('click', function () { return that.goBack(); });
|
|
|
}
|
|
|
},
|
|
|
destroy: function () {
|
|
@@ -37912,6 +37890,29 @@ define(['exports'], function (exports) { 'use strict';
|
|
|
});
|
|
|
return that._handle;
|
|
|
};
|
|
|
+ Scope.prototype.goBack = function () {
|
|
|
+ var handle = Ext.Viewport.getActiveItem();
|
|
|
+ // 显示前一个页面
|
|
|
+ var index = Scope.SHOW_PAGE_STACK.findIndex(function (scope) { return scope._handle === handle; });
|
|
|
+ // console.log("###### remove", index)
|
|
|
+ if (index >= 0) {
|
|
|
+ Scope.SHOW_PAGE_STACK.splice(index, 1);
|
|
|
+ }
|
|
|
+ var scopeArr = lodash.sortBy(Scope.SHOW_PAGE_STACK, function (scope) { return scope._lastShowTime; });
|
|
|
+ if (scopeArr.length > 0) {
|
|
|
+ var scope = scopeArr[scopeArr.length - 1];
|
|
|
+ scope._handle.setStyle({ 'z-index': 1 });
|
|
|
+ Ext.Viewport.getLayout().setAnimation({ type: 'slide', direction: 'right', duration: 300 });
|
|
|
+ Ext.Viewport.setActiveItem(scope._handle);
|
|
|
+ scope._lastShowTime = new Date().getTime();
|
|
|
+ // console.log("###### show", (scopeArr.length - 1), Scope.SHOW_PAGE_STACK)
|
|
|
+ }
|
|
|
+ // 关闭
|
|
|
+ handle.setStyle({ 'z-index': 0 });
|
|
|
+ // Ext.Viewport.getLayout().setAnimation({type: 'slide', direction: 'right', duration: 300})
|
|
|
+ Ext.Viewport.remove(handle);
|
|
|
+ handle.close();
|
|
|
+ };
|
|
|
/**
|
|
|
* 对话框"保存"成功.
|
|
|
* 关闭对话框,并响应 success 方法
|