@@ -67,8 +67,8 @@ | |||
<el-form-item label="选择工作链"> | |||
<el-select v-model="newProjData.projectData.templateID" filterable no-data-text="暂无数据" | |||
placeholder="请选择工作链" class="bg_w" @change="changeSelectTemplate"> | |||
<el-option v-for="item in selectTemlateData" :key="item.templateID" :label="item.tempName" | |||
:value="item.templateID"> | |||
<el-option v-for="item in templateList" :key="item.Id" :label="item.TempName" | |||
:value="item.Id"> | |||
</el-option> | |||
</el-select> | |||
</el-form-item> | |||
@@ -103,16 +103,16 @@ | |||
</div> | |||
</div> | |||
<div class="clear"></div> | |||
<div class="yiyun_col-12 fl mt-10"> | |||
<div class="yiyun_col-12img fl mt-10"> | |||
<div class="clear"></div> | |||
<div class="yiyun_col-6"> | |||
<div class="pageImgBox"> | |||
<img v-lazy="coverSrc" alt="" /> | |||
<img :src="coverSrc" alt="" /> | |||
<file-Uploader :mutiple="false" :label="uploadLabel" :auto="true" accept="image" ref="webUploadlist" | |||
:btn-id="filePicker" :companyId="uploadCompId" :typeId="uploadTypeCover" @upload-success="coverUploadSuccess" | |||
:url="chunkUploadUrl" class="listUpdateBtn"> | |||
</file-Uploader> | |||
<span class="faceBtn" @click="setSystemCover">使用随机封面</span> | |||
<span class="faceBtn" @click="setSystemCoverRandom">使用随机封面</span> | |||
</div> | |||
</div> | |||
</div> | |||
@@ -549,6 +549,7 @@ | |||
</template> | |||
<script> | |||
import * as templateService from '@/services/template'; | |||
export default { | |||
props: { | |||
isNewProj: { | |||
@@ -640,6 +641,9 @@ | |||
currSelectData: [], | |||
currUser:JSON.parse(sessionStorage.user), | |||
isShowManager:true, | |||
/* */ | |||
templateList: [], // 模板列表 | |||
}; | |||
}, | |||
watch: { | |||
@@ -653,7 +657,7 @@ | |||
}, | |||
components: {}, | |||
created: function() { | |||
}, | |||
mounted: function() { | |||
this.listDeptUsers(); | |||
@@ -886,6 +890,7 @@ | |||
backdistNewProj: function() { | |||
this.isAllhide(); | |||
this.ProjInfoDialog = true; //项目信息概况 | |||
}, | |||
/* | |||
*返回协作人页面 | |||
@@ -1267,15 +1272,32 @@ | |||
/** | |||
* 设置系统封面 | |||
*/ | |||
setSystemCover: function() { | |||
// setSystemCover: function() { | |||
// this.coverSrc = "static\\img\\faceImg\\face0" + this.srcIndex + ".png"; | |||
// this.newProjData.projectData.showImgUrl = this.srcIndex; | |||
// if (this.srcIndex < 9) { | |||
// this.srcIndex = this.srcIndex + 1; | |||
// } else { | |||
// this.srcIndex = 1; | |||
// } | |||
// }, | |||
/** | |||
* 设置随机封面 | |||
*/ | |||
setSystemCoverRandom: function(){ | |||
var temp=Math.ceil(Math.random()*10); | |||
while(this.srcIndex ===temp){ | |||
temp=Math.ceil(Math.random()*10); | |||
} | |||
this.srcIndex=temp; | |||
if(this.srcIndex===10){ | |||
this.coverSrc = "static\\img\\faceImg\\face" + this.srcIndex + ".png"; | |||
}else{ | |||
this.coverSrc = "static\\img\\faceImg\\face0" + this.srcIndex + ".png"; | |||
} | |||
this.newProjData.projectData.showImgUrl = this.srcIndex; | |||
if (this.srcIndex < 9) { | |||
this.srcIndex = this.srcIndex + 1; | |||
} else { | |||
this.srcIndex = 1; | |||
} | |||
}, | |||
/** | |||
* 封面上传成功时 | |||
*/ | |||
@@ -1416,23 +1438,30 @@ | |||
/** | |||
* 获取模板列表数据 | |||
*/ | |||
getSelectTemplateData: function() { | |||
var thisApp = this; | |||
this.$axios({ | |||
method: 'get', | |||
url: encodeURI(process.env.API_HOST + "templates/company/enable/" + sessionStorage.companyId), | |||
}) | |||
.then(response => { | |||
thisApp.selectTemlateData = response.data; | |||
if (thisApp.selectTemlateData != null && thisApp.selectTemlateData.length > 0) { | |||
thisApp.selectTemlateID = thisApp.selectTemlateData[0].templateID; | |||
// thisApp.newProjData.projectData.templateID= thisApp.selectTemlateID; | |||
// thisApp.changeSelectTemplate(thisApp.selectTemlateID); | |||
} | |||
}) | |||
.catch(error => { | |||
console.log(error); | |||
}); | |||
async getSelectTemplateData() { | |||
const templateListRes = await templateService.queryTemplateList(); | |||
const templateList = templateListRes.Data || []; | |||
this.templateList = templateList; | |||
console.log(templateList); | |||
if(this.templateList && this.templateList.length) { | |||
this.selectTemlateID = templateList[0].Id; | |||
} | |||
// var thisApp = this; | |||
// this.$axios({ | |||
// method: 'get', | |||
// url: encodeURI(process.env.API_HOST + "templates/company/enable/" + sessionStorage.companyId), | |||
// }) | |||
// .then(response => { | |||
// thisApp.selectTemlateData = response.data; | |||
// if (thisApp.selectTemlateData != null && thisApp.selectTemlateData.length > 0) { | |||
// thisApp.selectTemlateID = thisApp.selectTemlateData[0].templateID; | |||
// // thisApp.newProjData.projectData.templateID= thisApp.selectTemlateID; | |||
// // thisApp.changeSelectTemplate(thisApp.selectTemlateID); | |||
// } | |||
// }) | |||
// .catch(error => { | |||
// console.log(error); | |||
// }); | |||
}, | |||
/** | |||
* 获取模板属性字段 | |||
@@ -1479,6 +1508,7 @@ | |||
} | |||
this.listTempPropLoad(); // 获取模板属性字段 | |||
this.isAllhide(); | |||
this.setSystemCoverRandom(); | |||
this.ProjInfoDialog = true; //隐藏新建项目面板 | |||
}, | |||
/* | |||
@@ -23,13 +23,14 @@ | |||
<div class="yiyun-col-4"> | |||
<div class="yiyun_row" style="width: 95%;"> | |||
<!-- 系统时间 --> | |||
<div class="section_item fl section_item_aside_fl"> | |||
<!-- <div class="section_item fl section_item_aside_fl"> | |||
<h1>{{ nowTime }}</h1> | |||
<div> | |||
<span class="nowshijian">{{ nowDate }}</span> | |||
<span class="nowshijian">{{ welcome }}</span> | |||
</div> | |||
</div> | |||
</div> --> | |||
<timer :cnName="cnName"></timer> | |||
</div> | |||
</div> | |||
<div class="yiyun-col-4"> | |||
@@ -102,9 +103,9 @@ | |||
> | |||
<span>工作指派</span> | |||
</el-dropdown-item> | |||
<el-dropdown-item @click.native="toCloudIndex(projItem)"> | |||
<!-- <el-dropdown-item @click.native="toCloudIndex(projItem)"> | |||
<span>查看云盘</span> | |||
</el-dropdown-item> | |||
</el-dropdown-item> --> | |||
</el-dropdown-menu> | |||
</el-dropdown> | |||
<!-- <i class="Cicon text_wirte icon font_family icon-icon_yunpan" title="去云盘" @click="toCloudIndex(projItem)"></i> --> | |||
@@ -210,6 +211,7 @@ import DistWork from "@/views/components_web/distWork/distWork"; | |||
import NewProj from "@/views/components_web/newProj/newProj"; | |||
import ProjSetting from "@/views/components_web/projSetting/projSetting"; | |||
import { haveAccess, AccessCode } from '@/utils/access'; | |||
import Timer from '@/views/main_web/time' | |||
const BMap = window.BMap; | |||
const Velocity = window.Velocity; | |||
export default { | |||
@@ -218,6 +220,7 @@ export default { | |||
DistWork, | |||
NewProj, | |||
ProjSetting, | |||
Timer | |||
}, | |||
data() { | |||
const { currentPlatform } = this.$store.state; | |||
@@ -288,8 +291,8 @@ export default { | |||
}, | |||
mounted: function () { | |||
this.cnName = JSON.parse(sessionStorage.user).userName; | |||
this.setDateTime(); | |||
setInterval(this.setDateTime, 1000); | |||
//this.setDateTime(); | |||
//setInterval(this.setDateTime, 1000); | |||
this.listProjects(); | |||
setInterval(this.listProjects, 1000 * 60); | |||
}, | |||
@@ -0,0 +1,61 @@ | |||
<template> | |||
<!-- 系统时间 --> | |||
<div class="section_item fl section_item_aside_fl"> | |||
<h1>{{ nowTime }}</h1> | |||
<div> | |||
<span class="nowshijian">{{ nowDate }}</span> | |||
<span class="nowshijian">{{ welcome }}</span> | |||
</div> | |||
</div> | |||
</template> | |||
<style scoped> | |||
[v-cloak] { | |||
display: none !important; | |||
} | |||
</style> | |||
<script> | |||
import commonJs from "@/common/webCommon"; | |||
export default { | |||
props:["cnName"], | |||
data(){ | |||
return{ | |||
nowTime:'', | |||
nowDate:'', | |||
welcome:'', | |||
timer:null | |||
} | |||
}, | |||
methods:{ | |||
/** | |||
* 设置日期、时间 | |||
*/ | |||
setDateTime: function () { | |||
this.nowDate = commonJs.getDate(); | |||
this.createDate = this.nowDate; | |||
this.nowTime = commonJs.getTime(); | |||
var time = this.nowTime.substring(0, 2); | |||
if (time < 12 && time > 0) { | |||
this.welcome = "上午好! " + this.cnName; | |||
} else if (time == 12) { | |||
this.welcome = "中午好! " + this.cnName; | |||
} else if (time > 12 && time > 20) { | |||
this.welcome = "晚上好,注意休息! " + this.cnName; | |||
} else if (time > 12 && time < 20) { | |||
this.welcome = "下午好!" + this.cnName; | |||
} | |||
}, | |||
}, | |||
mounted(){ | |||
this.setDateTime(); | |||
this.timer=setInterval(this.setDateTime, 1000); | |||
}, | |||
beforeDestroy(){ | |||
clearInterval(this.timer); | |||
this.timer=null; | |||
} | |||
} | |||
</script> |
@@ -1532,6 +1532,7 @@ export default { | |||
children: "children", | |||
// multiple: true, | |||
checkStrictly: true, | |||
expandTrigger:'hover', | |||
}, | |||
listUpdateUserID: [], //选中的用户ID | |||
deptOptions: [], // 级联选择器部门数据 | |||
@@ -1681,6 +1682,17 @@ export default { | |||
}, | |||
mounted: function () { | |||
this.listDepts(); | |||
setInterval(function () { | |||
document.querySelectorAll('.el-cascader-node__label').forEach(el => { | |||
el.onclick = function () { | |||
if (this.previousElementSibling) { | |||
this.previousElementSibling.click() | |||
} | |||
} | |||
}) | |||
}, 1000) | |||
}, | |||
methods: { | |||
/** | |||
@@ -2018,6 +2030,7 @@ export default { | |||
*/ | |||
colseSet: function () { | |||
this.isDistWorkDeptDialog = false; | |||
this.currentUser.arraySuper=[]; | |||
}, | |||
/** | |||
* 取消选项 | |||
@@ -2761,10 +2774,41 @@ export default { | |||
</script> | |||
<style lang="scss" scoped> | |||
.avator-btn { | |||
line-height: 50px; | |||
::v-deep > div { | |||
margin-left: 20px; | |||
} | |||
} | |||
.ec_dialogBoxBody { | |||
::v-deep .el-radio__input .el-radio__inner{ | |||
background-color:#A7A8B7; | |||
background:#A7A8B7; | |||
border: 1px solid #A7A8B7; | |||
} | |||
::v-deep .el-scrollbar__wrap { overflow-x: hidden; } | |||
::v-deep li.el-cascader-node { | |||
padding: 0px 20px; | |||
&.is-active, | |||
&.in-active-path, | |||
&.in-checked-path | |||
{ | |||
.el-radio__input .el-radio__inner{ | |||
background-color:#8c00ff !important; | |||
background:#8c00ff !important; | |||
} | |||
background-color:#EBEBF2; | |||
font-weight: normal; | |||
color:#606266; | |||
} | |||
} | |||
::v-deep .el-cascader-menu__list{ | |||
padding:6px 16px 0px 0px; | |||
li{ | |||
height: 44px; | |||
background-color: rgba(255, 255, 255, 0); | |||
} | |||
} | |||
} | |||
</style> |