Bläddra i källkod

没有指派部门的员工也可以进行指派

dev-version-manage
kim131 4 år sedan
förälder
incheckning
ae98953f6d
3 ändrade filer med 66 tillägg och 17 borttagningar
  1. +1
    -0
      public/static/css/main.css
  2. +44
    -8
      src/views/components_web/projDetail/projDetail.vue
  3. +21
    -9
      src/views/main_web/workspace/workspace.new.vue

+ 1
- 0
public/static/css/main.css Visa fil

@@ -464,6 +464,7 @@ ul {
width: calc(100vw - 120px);
margin: 0 auto;
padding: 0 0 10px 0;
overflow: hidden;
}
.yiyun_section_top {
margin-top: 10px;


+ 44
- 8
src/views/components_web/projDetail/projDetail.vue Visa fil

@@ -95,7 +95,7 @@
</div>
<div class="part-wrap" ref="distworkpart">
<div v-if="!isEnterEdit" class="template-detail-btn"
@click.stop="isShowTemplateSummary = true">模板概况</div>
@click.stop="isShowTemplateSummary = true, isEnterEditPropValue = false">模板概况</div>
<div v-if="isProjManager" class="manager-folder-wrap"
:class="{'active-folder mb-36': isEditProjManager,'only-manager-see folder-click': !isEnterEdit}">
<div class="row-title">项目管理权限</div>
@@ -154,7 +154,7 @@
:title="nowProject.TempName" :showUserCenter="false" :showBackBtn="true"
>
<div slot="right" class="edit-template-btn"
@click.stop="isEnterEditPropValue = !isEnterEditPropValue">
@click.stop="handleEditTemplate">
{{`${isEnterEditPropValue ? "完成编辑" : "修改"}`}}
</div>
</top-header>
@@ -303,7 +303,9 @@ import NestTemp from '../project/nestTemp.vue';
isDistworkDone: false,//是否有进行过工作指派
isDistworkSuccess: false,//每一次工作指派是否成功

lastFolderId: ''
lastFolderId: '',//最后一个进行工作指派的节点的id
originPropListCopy: [],

}
},
components: {
@@ -392,6 +394,18 @@ import NestTemp from '../project/nestTemp.vue';
this.$bus.$off('enterNestTemp', this.enterNestTemp);
},
methods: {
// 点击了编辑模板概况的按钮
handleEditTemplate() {
this.isEnterEditPropValue = !this.isEnterEditPropValue;
// 此时完成编辑 -> 提示编辑成功等信息
if(!this.isEnterEditPropValue) {
this.originPropListCopy = this.listProjProp;
this.$notify({
type: ["success"],
message: '修改模板概况成功'
})
}
},
/**
* 进入嵌套模板
*/
@@ -458,6 +472,8 @@ import NestTemp from '../project/nestTemp.vue';
this.nowProject = {...this.nowProject};
this.listProjProp=projectInfoRes.Data.CustomProps;
this.listProjProp = [...this.listProjProp];

this.originPropListCopy = cloneDeep(this.listProjProp);
this.coverSrc=projectInfoRes.Data.ShowImgUrl;
},
async coverUploadSuccess(file) {
@@ -482,7 +498,22 @@ import NestTemp from '../project/nestTemp.vue';

},
returnToDistWorkClick() {
this.isShowTemplateSummary = false;
// 未点击完成编辑按钮 -》 概况信息未保存
if(this.isEnterEditPropValue) {
this.$confirm("是否保存当前项目的模板概况信息", "", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(async () => {
this.isShowTemplateSummary = false;
this.originPropListCopy = this.listProjProp;

}).catch(() => {
this.listProjProp = this.originPropListCopy;
})
} else {
this.isShowTemplateSummary = false;
}
},
// 点击返回按钮 显示项目概况页面
showProjDetailClick() {
@@ -1089,15 +1120,18 @@ import NestTemp from '../project/nestTemp.vue';
]);
// const deptHeadList = deptList[0].children || [];
let oList = this.plainTreeNodes(deptList, userList);
if(oList.length == 0) {
// 如果人员没有设置部门的话

// 如果人员没有设置部门的话
const aloneUserList = this.userList.filter(user => user.deptId == "0");
if(aloneUserList.length > 0) {
const emptyDept = {};
emptyDept.id = "0";
emptyDept.deptName = sessionStorage.CompanyName || "";
emptyDept.listUser = [];
emptyDept.listUser.push(...userList);
emptyDept.listUser.push(...aloneUserList);
oList.push(emptyDept);
}
oList.forEach(item=>{
// console.log(1)
// console.log(item.listUser)
@@ -1437,6 +1471,7 @@ import NestTemp from '../project/nestTemp.vue';
padding: 0 24px;
height: calc(100vh - 126px);
overflow: scroll;
background-color: #f8f8f8;
.cover-container {
height: 226px;
margin: 0 0 32px 0;
@@ -1571,12 +1606,13 @@ import NestTemp from '../project/nestTemp.vue';
}
.template-summary {
background-color: #f8f8f8;
.summary-wrap {
height: calc(100vh - 126px - 16px);
overflow: scroll;
padding: 0 24px;
margin: 16px 0 0 0;
background-color: #fcfcfc;
background-color: #f8f8f8;

/* 编辑状态下的模板自定义字段输入框 */
.prop-value-input {


+ 21
- 9
src/views/main_web/workspace/workspace.new.vue Visa fil

@@ -290,8 +290,8 @@
</div>
</div>

<div class="fifleBox" id="coopFileBox">
<div class="yiyun_section_warp layerout_H3">
<div class="fifleBox" id="coopFileContainer">
<div class="yiyun_section_warp layerout_H3" id="coopFileBox">
<!-- 文件大box -->
<div class="yinyong_warpBox">
<!-- 协作文件 -->
@@ -656,8 +656,10 @@ export default {
mounted: function () {
this.hackWorkLine = this.$refs.hackworkline;
window.addEventListener("scroll", this.onscroll, true);
this.listenBottomHeight();
window.addEventListener("resize", this.listenBottomHeight, true);
this.coopFileBox = document.getElementById('coopFileBox');


// window.addEventListener("resize", this.listenBottomHeight, true);
if(this.isClient) {
this.initWorkspaceDropEvent();
}
@@ -683,7 +685,7 @@ export default {
},
destroyed: function () {
window.removeEventListener("scroll", this.onscroll);
window.removeEventListener("resize", this.listenBottomHeight);
// window.removeEventListener("resize", this.listenBottomHeight);
// window.removeEventListener("mouseenter", this.setIconMouseEnter);
window.clearTimeout(this.timerIns);
@@ -715,6 +717,10 @@ export default {
subFolderList() {
const uniqSubFolderList = uniqBy(this.workSubFolderList.concat(this.tempWorkSubFolderList), folder => folder.id);
return uniqSubFolderList
},
// 得到协作文件展示区域的实际高度
coopBoxRealHeight() {
return document.getElementById('coopFileBox') ? document.getElementById('coopFileBox').offsetHeight : 0;
}
},
methods: {
@@ -1142,14 +1148,17 @@ export default {
// }
},
listenBottomHeight() {
let oDivH = document.getElementById('coopFileBox') ? document.getElementById("coopFileBox").offsetHeight : 0;
let oShodow = document.getElementById("bottomoShodow");
console.log(oDivH)
let oDivH = document.getElementById('coopFileBox') ? document.getElementById("coopFileBox").offsetHeight: 0;
// let oShodow = document.getElementById("bottomoShodow");
const target = document.getElementById('coopFileBox')

if (oDivH > 259) {
this.showadow = true;
} else {
this.showadow = false;
}
console.log(oDivH, this.showadow);
},
onSocketFileChangeDetected({ data }){
try {
@@ -1264,7 +1273,7 @@ export default {
this.currentFolder = folder;
this.breadcrumbFolderList.push(folder);
} else if(flag == 1) {
this.listenBottomHeight();
// this.listenBottomHeight();
this.currentFolderInCoop = folder;
this.breadcrumbFolderListInCoop.push(folder);
}
@@ -1825,6 +1834,9 @@ export default {
}
},
watch: {
coopBoxRealHeight(val) {
this.showadow = val> 259;
},
isShowSearchBar(val) {
if(!val) {
if(this.currentBtnIndex == 0) {


Laddar…
Avbryt
Spara