Browse Source

优化

master
陈裕财 3 years ago
parent
commit
ae49a94d13
  1. 6
      src/router/routes_xm.js
  2. 42
      src/views/xm/core/xmGroup/XmGroupForProject.vue
  3. 34
      src/views/xm/core/xmProject/top-nav.vue
  4. 44
      src/views/xm/core/xmQuestion/XmQuestionForProject.vue
  5. 47
      src/views/xm/core/xmTask/XmTaskListForProject.vue

6
src/router/routes_xm.js

@ -96,7 +96,7 @@ export default {
}, },
{ {
path: 'task', path: 'task',
component: _import('xm/core/xmTask/XmTaskMng'),
component: _import('xm/core/xmTask/XmTaskListForProject'),
name: 'projectMenu', name: 'projectMenu',
iconCls: 'fa el-icon-menu', iconCls: 'fa el-icon-menu',
meta: { meta: {
@ -118,7 +118,7 @@ export default {
}, },
{ {
path: 'question', path: 'question',
component: _import('xm/core/xmQuestion/XmQuestionMng'),
component: _import('xm/core/xmQuestion/XmQuestionForProject'),
name: 'projectQuestion', name: 'projectQuestion',
iconCls: 'fa el-icon-menu', iconCls: 'fa el-icon-menu',
meta: { meta: {
@ -129,7 +129,7 @@ export default {
}, },
{ {
path: 'group', path: 'group',
component: _import('xm/core/xmGroup/XmGroupMng'),
component: _import('xm/core/xmGroup/XmGroupForProject'),
name: 'projectGroup', name: 'projectGroup',
iconCls: 'fa el-icon-menu', iconCls: 'fa el-icon-menu',
meta: { meta: {

42
src/views/xm/core/xmGroup/XmGroupForProject.vue

@ -0,0 +1,42 @@
<template>
<section class="padding">
<xm-group-mng :sel-project="projectInfo" :visible="projectInfo && projectInfo.id"></xm-group-mng>
</section>
</template>
<script>
import util from '@/common/js/util';//
import { listXmProject } from '@/api/xm/core/xmProject';
import { mapGetters } from 'vuex';
import XmGroupMng from './XmGroupMng'
export default {
computed: {
...mapGetters([
'userInfo','roles','projectInfo'
]),
},
watch:{
},
data() {
return {
}
},//end data
methods: {
},//end methods
components: {
XmGroupMng,
//
},
activated(){
},
mounted() {
}
}
</script>
<style scoped>
</style>

34
src/views/xm/core/xmProject/top-nav.vue

@ -297,21 +297,23 @@ export default {
} }
}, },
}, },
watch: {},
watch: {
$route:{
handler(newVal,oldValu){
this.infotype=newVal.fullPath
},
deep:true,
immediate:true,
}
},
data() { data() {
return { return {
infotype:'',
dicts: getDefOptions(),
/**end 自定义属性请在上面加 请加备注**/
infotype:'',
}; };
}, //end data }, //end data
methods: { methods: {
setInfotype(infotype) {
if (infotype == "返回") {
this.goBack();
} else {
this.infotype = infotype;
}
setInfotype(infotype) {
this.infotype = infotype;
}, },
goBack() { goBack() {
@ -328,16 +330,8 @@ export default {
// //
}, },
mounted() {
this.$nextTick(() => {
//this.maxTableHeight = this.source == 'GZT' ? this.maxTableHeight : util.calcTableMaxHeight(this.$refs.pageBody.$el);
var infotype = localStorage.getItem("project-infotype");
if (infotype) {
this.infotype = infotype;
}
});
initDicts(this)
mounted() {
this.infotype=this.$route.fullPath
}, },
}; };
</script> </script>

44
src/views/xm/core/xmQuestion/XmQuestionForProject.vue

@ -0,0 +1,44 @@
<template>
<xm-question-mng class="padding-top" :sel-project="projectInfo"></xm-question-mng>
</template>
<script>
import util from '@/common/js/util';//
import config from '@/common/config';//
import XmQuestionMng from './XmQuestionMng';//
import { mapGetters } from 'vuex'
export default {
computed: {
...mapGetters([
'userInfo','roles','projectInfo'
]),
},
data() {
return {
}
},//end data
methods: {
},//end methods
components: {
XmQuestionMng
},
mounted() {
}
}
</script>
<style lang="scss" scoped>
</style>

47
src/views/xm/core/xmTask/XmTaskListForProject.vue

@ -0,0 +1,47 @@
<template>
<section>
<xm-task-mng :sel-project="projectInfo" ptype="0" query-scope="task"></xm-task-mng>
</section>
</template>
<script>
import Vue from 'vue'
import util from '@/common/js/util';//
import { mapGetters } from 'vuex'
import XmTaskMng from './XmTaskMng.vue';
export default {
computed: {
...mapGetters([
'userInfo','roles','projectInfo'
]),
},
watch: {
},
data() {
return {
/**end 自定义属性请在上面加 请加备注**/
}
},//end data
methods: {
/**end 自定义函数请在上面加**/
},//end methods
components: {
XmTaskMng
//
},
mounted() {
}
}
</script>
<style scoped>
</style>
Loading…
Cancel
Save