提交 169b1f7d 编写于 作者: guangjun.yang's avatar guangjun.yang

加loading

上级 eff87121
......@@ -198,12 +198,10 @@ import { mapGetters, mapMutations } from "vuex";
import BreadCrumb from "@/components/breadcrumb.vue";
import { doUpload, getFilePath } from "@/utils/qiniu-util";
import { validateWord } from "@/utils/validate.js";
// import { openLoading, closeLoading } from "@/utils/utils";
import {
openLoading,
closeLoading,
betaHandle,
timeHandle
} from "@/utils/utils";
import * as commonUtil from "@/utils/utils";
import { getPicaKFAccid, getPhomeDemain } from "@/utils";
......@@ -308,41 +306,21 @@ export default {
},
mounted() {
// this.resizeHeight();
this.$nextTick(() => {
_this.containerHeight =
_this.p_getElm('slidebar-container').getBoundingClientRect().height - 15;
_this.p_getElm('screenSet').style.height =
_this.getElmByID('slidebar-container').getBoundingClientRect().height - 15;
_this.getElmByID('screenSet').style.height =
_this.containerHeight - 152 + "px";
console.log('_this.containerHeight', _this.containerHeight);
_this.p_getElm("sessionListId").style.height = _this.containerHeight - 252 + 'px';
_this.p_getElm("msgContentId").style.height = _this.containerHeight - 287 + 'px';
_this.getElmByID("sessionListId").style.height = _this.containerHeight - 252 + 'px';
_this.getElmByID("msgContentId").style.height = _this.containerHeight - 287 + 'px';
});
},
methods: {
//
resizeHeight(
cMinusHeight = 152,
iMinuxHeight = 210,
refHeightId = "slidebar-container",
containerHeightId = "screenSet"
) {
_this.containerHeight =
_this.p_getElm(refHeightId).getBoundingClientRect().height - 15;
_this.p_getElm(containerHeightId).style.height =
_this.containerHeight - cMinusHeight + "px";
console.log("containerHeight", _this.containerHeight);
window.onresize = function() {
console.log("containerHeight2", _this.containerHeight);
_this.containerHeight =
_this.p_getElm(refHeightId).getBoundingClientRect().height - 15;
_this.p_getElm(containerHeightId).style.height =
_this.containerHeight - cMinusHeight + "px";
};
},
p_getElm(elmId) {
// 获取元素
getElmByID(elmId) {
return document.getElementById(elmId);
},
......@@ -855,6 +833,7 @@ export default {
});
return;
}
openLoading(_this);
doUpload(
_this,
file,
......@@ -863,6 +842,7 @@ export default {
"progress",
""
).then(function(resData) {
closeLoading(_this)
let params = {};
params.fileSize = resData.size;
params.fileExt = resData.ext;
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册