@@ -284,9 +285,15 @@ export default {
isHistoryShow: true, //修改历史是否显示,默认显示
isSiderHide: false,
unCommitTransactionCount: 0, //未提交事务数量
- isTransactionDialogShow: false
+ isTransactionDialogShow: false,
+ fromFullPath: '' // 上一个页面地址
};
},
+ beforeRouteEnter(to, from, next) {
+ next(vm => {
+ vm.fromFullPath = from?.fullPath || '';
+ });
+ },
beforeCreate() {},
created() {},
beforeMount() {},
@@ -308,6 +315,13 @@ export default {
beforeDestroy() {},
destroyed() {},
methods: {
+ back() {
+ // 下榻页面返回
+ this.$router.push({
+ path: this.fromFullPath,
+ query: {isBack: true}
+ });
+ },
showCustomViewData(customView) {
if (customView._type === 'data') {
if (customView.type === 'scene') {