提交 e0344f0f 编写于 作者: ibizdev's avatar ibizdev

zhujiamin 发布系统代码 [TrainSys,网页端]

上级 7bcfa1eb
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
:closable="false" :closable="false"
v-model="isShow" v-model="isShow"
:width="width" :width="width"
:before-close="beforeClose"
@on-visible-change="onVisibleChange($event)" @on-visible-change="onVisibleChange($event)"
@on-close="close(tempResult)" @on-close="close(tempResult)"
> >
...@@ -42,7 +43,7 @@ export default class AppDrawerCompponent extends Vue { ...@@ -42,7 +43,7 @@ export default class AppDrawerCompponent extends Vue {
* 视图动态参数 * 视图动态参数
* *
* @type {any} * @type {any}
* @memberof AppModal * @memberof AppDrawerCompponent
*/ */
@Prop({default:{}}) public dynamicProps?:any; @Prop({default:{}}) public dynamicProps?:any;
...@@ -50,7 +51,7 @@ export default class AppDrawerCompponent extends Vue { ...@@ -50,7 +51,7 @@ export default class AppDrawerCompponent extends Vue {
* 视图静态参数 * 视图静态参数
* *
* @type {any} * @type {any}
* @memberof AppModal * @memberof AppDrawerCompponent
*/ */
@Prop({default:{}}) public staticProps?:any; @Prop({default:{}}) public staticProps?:any;
...@@ -110,10 +111,18 @@ export default class AppDrawerCompponent extends Vue { ...@@ -110,10 +111,18 @@ export default class AppDrawerCompponent extends Vue {
*/ */
public zIndex:any = null; public zIndex:any = null;
/**
* 是否在抽屉区按下鼠标
*
* @type {any}
* @memberof AppDrawerCompponent
*/
public isMouseDown: boolean = false;
/** /**
* 获取数据传递对象 * 获取数据传递对象
* *
* @memberof AppModal * @memberof AppDrawerCompponent
*/ */
public getSubject(){ public getSubject(){
return this.subject; return this.subject;
...@@ -144,7 +153,7 @@ export default class AppDrawerCompponent extends Vue { ...@@ -144,7 +153,7 @@ export default class AppDrawerCompponent extends Vue {
} else { } else {
this.width = 800; this.width = 800;
} }
document.onkeydown = (e) => { document.onkeydown = (e: any) => {
var keyCode = e.keyCode || e.which || e.charCode; var keyCode = e.keyCode || e.which || e.charCode;
if (keyCode == 27) { if (keyCode == 27) {
const zIndex = this.$store.getters.getZIndex(); const zIndex = this.$store.getters.getZIndex();
...@@ -154,6 +163,18 @@ export default class AppDrawerCompponent extends Vue { ...@@ -154,6 +163,18 @@ export default class AppDrawerCompponent extends Vue {
this.isShow = false; this.isShow = false;
} }
} }
// 监听鼠标是否在抽屉内容区按下
document.onmousedown = (e: any) => {
const documentPaths = e.path;
this.isMouseDown = false;
if (documentPaths?.length > 0) {
documentPaths.forEach((path: any) => {
if (path.className == 'ivu-drawer-content') {
this.isMouseDown = true;
}
})
}
}
} }
/** /**
...@@ -196,6 +217,21 @@ export default class AppDrawerCompponent extends Vue { ...@@ -196,6 +217,21 @@ export default class AppDrawerCompponent extends Vue {
warpTag.style.zIndex = this.zIndex; warpTag.style.zIndex = this.zIndex;
} }
/**
* 关闭之前
* 在内容区按下鼠标,在其他地方松开鼠标时不关闭抽屉
* @memberof AppDrawerCompponent
*/
public beforeClose() {
return new Promise((resolve: any, reject: any) => {
if (this.isMouseDown) {
this.isMouseDown = false;
return
}
resolve(true)
})
}
/** /**
* 关闭回调 * 关闭回调
* *
...@@ -285,9 +321,6 @@ export default class AppDrawerCompponent extends Vue { ...@@ -285,9 +321,6 @@ export default class AppDrawerCompponent extends Vue {
}, 500) }, 500)
} }
} }
</script> </script>
<style lang="less"> <style lang="less">
......
...@@ -194,7 +194,7 @@ ...@@ -194,7 +194,7 @@
</changeSet> </changeSet>
<!--输出实体[REGINFO]数据结构 --> <!--输出实体[REGINFO]数据结构 -->
<changeSet author="root" id="tab-reginfo-60-8"> <changeSet author="root" id="tab-reginfo-62-8">
<createTable tableName="T_REGINFO"> <createTable tableName="T_REGINFO">
<column name="UPDATEDATE" remarks="" type="DATETIME"> <column name="UPDATEDATE" remarks="" type="DATETIME">
</column> </column>
......
...@@ -1121,10 +1121,12 @@ ...@@ -1121,10 +1121,12 @@
"dEFName" : "STUNO", "dEFName" : "STUNO",
"name" : "[常规条件] 等于(=) 数据对象属性(testaaa)", "name" : "[常规条件] 等于(=) 数据对象属性(testaaa)",
"paramType" : "ENTITYFIELD", "paramType" : "ENTITYFIELD",
"paramValue" : "testaaa" "paramValue" : "testaaa",
} ] "ruleInfo" : "文本值为testaaa"
} ],
"ruleInfo" : "文本值为testaaa"
}, },
"ruleInfo" : "测试实体值规则", "ruleInfo" : "文本值为testaaa",
"checkDefault" : false, "checkDefault" : false,
"defaultMode" : false, "defaultMode" : false,
"enableBackend" : true, "enableBackend" : true,
......
...@@ -256,10 +256,12 @@ ...@@ -256,10 +256,12 @@
"dEFName" : "STUNO", "dEFName" : "STUNO",
"name" : "[常规条件] 等于(=) 数据对象属性(testaaa)", "name" : "[常规条件] 等于(=) 数据对象属性(testaaa)",
"paramType" : "ENTITYFIELD", "paramType" : "ENTITYFIELD",
"paramValue" : "testaaa" "paramValue" : "testaaa",
} ] "ruleInfo" : "文本值为testaaa"
} ],
"ruleInfo" : "文本值为testaaa"
}, },
"ruleInfo" : "测试实体值规则", "ruleInfo" : "文本值为testaaa",
"checkDefault" : false, "checkDefault" : false,
"defaultMode" : false, "defaultMode" : false,
"enableBackend" : true, "enableBackend" : true,
......
...@@ -685,10 +685,12 @@ ...@@ -685,10 +685,12 @@
"dEFName" : "STUNO", "dEFName" : "STUNO",
"name" : "[常规条件] 等于(=) 数据对象属性(testaaa)", "name" : "[常规条件] 等于(=) 数据对象属性(testaaa)",
"paramType" : "ENTITYFIELD", "paramType" : "ENTITYFIELD",
"paramValue" : "testaaa" "paramValue" : "testaaa",
} ] "ruleInfo" : "文本值为testaaa"
} ],
"ruleInfo" : "文本值为testaaa"
}, },
"ruleInfo" : "测试实体值规则", "ruleInfo" : "文本值为testaaa",
"checkDefault" : false, "checkDefault" : false,
"defaultMode" : false, "defaultMode" : false,
"enableBackend" : true, "enableBackend" : true,
......
...@@ -2143,10 +2143,12 @@ ...@@ -2143,10 +2143,12 @@
"dEFName" : "STUNO", "dEFName" : "STUNO",
"name" : "[常规条件] 等于(=) 数据对象属性(testaaa)", "name" : "[常规条件] 等于(=) 数据对象属性(testaaa)",
"paramType" : "ENTITYFIELD", "paramType" : "ENTITYFIELD",
"paramValue" : "testaaa" "paramValue" : "testaaa",
} ] "ruleInfo" : "文本值为testaaa"
} ],
"ruleInfo" : "文本值为testaaa"
}, },
"ruleInfo" : "测试实体值规则", "ruleInfo" : "文本值为testaaa",
"checkDefault" : false, "checkDefault" : false,
"defaultMode" : false, "defaultMode" : false,
"enableBackend" : true, "enableBackend" : true,
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册