Browse Source

优化

master
陈裕财 4 years ago
parent
commit
59d3d0c91c
  1. 2
      src/api/xm/core/xmMyFocus.js
  2. 4
      src/views/layout/components/UserInfo.vue
  3. 6
      src/views/mdp/menu/menuDef/MenuDefImport.vue
  4. 6
      src/views/myWork/my/components/MyFocusList.vue
  5. 4
      src/views/xm/core/components/XmIterationSelect.vue
  6. 2
      src/views/xm/core/components/XmProductSelect.vue
  7. 2
      src/views/xm/core/components/XmProjectSelect.vue
  8. 6
      src/views/xm/core/xmIteration/XmIterationForLinkComplex.vue
  9. 2
      src/views/xm/core/xmIteration/XmIterationOverview.vue
  10. 14
      src/views/xm/core/xmIteration/XmIterationOverviewComplex.vue
  11. 18
      src/views/xm/core/xmProduct/XmProductOverviewComplex.vue
  12. 7
      src/views/xm/core/xmProject/XmProjectOverviewComplex.vue

2
src/api/xm/core/xmMyFocus.js

@ -29,7 +29,7 @@ export const editXmMyFocus = params => { return axios.post(`${base}/xm/core/xmMy
//新增一条我关注的项目或者任务 //新增一条我关注的项目或者任务
export const addXmMyFocus = params => { export const addXmMyFocus = params => {
debugger;
localStorage.removeItem('xm-my-focus-list') localStorage.removeItem('xm-my-focus-list')
return axios.post(`${base}/xm/core/xmMyFocus/add`, params); return axios.post(`${base}/xm/core/xmMyFocus/add`, params);
}; };

4
src/views/layout/components/UserInfo.vue

@ -245,7 +245,7 @@ export default {
}, },
toLogin(user) { toLogin(user) {
debugger;
this.$prompt('请输入密码', '提示', { this.$prompt('请输入密码', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
@ -256,7 +256,7 @@ export default {
authType:'password_display_userid' , authType:'password_display_userid' ,
grantType:"password" grantType:"password"
} }
debugger;
//userloginid, password,grantType,authType,deptid,userid //userloginid, password,grantType,authType,deptid,userid
switchUser(params.userloginid,params.password,params.grantType,params.authType,'',params.userloginid).then(res => { switchUser(params.userloginid,params.password,params.grantType,params.authType,'',params.userloginid).then(res => {
this.phonenoUsersVisible=false; this.phonenoUsersVisible=false;

6
src/views/mdp/menu/menuDef/MenuDefImport.vue

@ -59,7 +59,7 @@
computed: { computed: {
'routersTreeData': function(){ 'routersTreeData': function(){
debugger;
var routers=this.permission_routers.filter(i=>i.meta&&i.meta.title&&!i.hidden); var routers=this.permission_routers.filter(i=>i.meta&&i.meta.title&&!i.hidden);
routers.forEach((i,index)=>{ routers.forEach((i,index)=>{
i.rpath=i.path i.rpath=i.path
@ -75,7 +75,7 @@
this.routersTreeDataFill(i.children,i) this.routersTreeDataFill(i.children,i)
}) })
debugger;
return routers; return routers;
}, },
...mapGetters([ ...mapGetters([
@ -136,7 +136,7 @@
this.jsonRouters=eval('(' + this.jsonRoutersText + ')'); this.jsonRouters=eval('(' + this.jsonRoutersText + ')');
}, },
batchImportMenus(){ batchImportMenus(){
debugger;
let routers=this.jsonRouters; let routers=this.jsonRouters;
if(this.importType=='1'){ if(this.importType=='1'){
try{ try{

6
src/views/myWork/my/components/MyFocusList.vue

@ -171,7 +171,7 @@ export default {
}, },
// UserFocus // UserFocus
getUserFocuss() { getUserFocuss() {
debugger;
let params = { let params = {
pageSize: this.pageInfo.pageSize, pageSize: this.pageInfo.pageSize,
pageNum: this.pageInfo.pageNum, pageNum: this.pageInfo.pageNum,
@ -191,7 +191,7 @@ export default {
this.load.list = true; this.load.list = true;
myFocusForIndex(params).then((res) => { myFocusForIndex(params).then((res) => {
debugger;
var tips=res.data.tips; var tips=res.data.tips;
if(tips.isOk){ if(tips.isOk){
this.pageInfo.total = res.data.total; this.pageInfo.total = res.data.total;
@ -312,7 +312,7 @@ export default {
initDicts(this); initDicts(this);
this.initData() this.initData()
var myFocusList=localStorage.getItem('mdp-sys-user-focus-list') var myFocusList=localStorage.getItem('mdp-sys-user-focus-list')
debugger;
if(myFocusList){ if(myFocusList){
this.userFocuss=JSON.parse(myFocusList) this.userFocuss=JSON.parse(myFocusList)
}else{ }else{

4
src/views/xm/core/components/XmIterationSelect.vue

@ -376,8 +376,8 @@
}, },
reloadOne(){ reloadOne(){
listXmIterationWithState({id:this.editForm.id}).then((res) => { listXmIterationWithState({id:this.editForm.id}).then((res) => {
var tips = res.data.tips;
if(tips.isOk && rea.data.data && res.data.data.length>0){
var tips = res.data.tips;
if(tips.isOk && res.data.data && res.data.data.length>0){
Object.assign(this.editForm,res.data.data[0]) Object.assign(this.editForm,res.data.data[0])
this.rowClick(this.editForm) this.rowClick(this.editForm)
} }

2
src/views/xm/core/components/XmProductSelect.vue

@ -502,7 +502,7 @@ export default {
reloadOne() { reloadOne() {
listXmProductWithState({ id: this.editForm.id }).then((res) => { listXmProductWithState({ id: this.editForm.id }).then((res) => {
var tips = res.data.tips; var tips = res.data.tips;
if (tips.isOk && rea.data.data && res.data.data.length > 0) {
if (tips.isOk && res.data.data && res.data.data.length > 0) {
Object.assign(this.editForm, res.data.data[0]); Object.assign(this.editForm, res.data.data[0]);
this.rowClick(this.editForm); this.rowClick(this.editForm);
} }

2
src/views/xm/core/components/XmProjectSelect.vue

@ -516,7 +516,7 @@ export default {
reloadOne() { reloadOne() {
listXmProject({ id: this.editForm.id }).then((res) => { listXmProject({ id: this.editForm.id }).then((res) => {
var tips = res.data.tips; var tips = res.data.tips;
if (tips.isOk && rea.data.data && res.data.data.length > 0) {
if (tips.isOk && res.data.data && res.data.data.length > 0) {
Object.assign(this.editForm, res.data.data[0]); Object.assign(this.editForm, res.data.data[0]);
this.rowClick(this.editForm); this.rowClick(this.editForm);
} }

6
src/views/xm/core/xmIteration/XmIterationForLinkComplex.vue

@ -407,8 +407,10 @@
/**end 自定义函数请在上面加**/ /**end 自定义函数请在上面加**/
onIterationRowClick(iteration){ onIterationRowClick(iteration){
this.xmIteration=iteration
this.$nextTick(()=>{
this.xmIteration=iteration
})
}, },
onIterationClearSelect(){ onIterationClearSelect(){

2
src/views/xm/core/xmIteration/XmIterationOverview.vue

@ -284,7 +284,7 @@ export default {
return 100; return 100;
} }
}, },
xmIterationCpd(){
xmIterationCpd(){
return this.xmIteration; return this.xmIteration;
}, },
calcXmIterationPstatusStep(){ calcXmIterationPstatusStep(){

14
src/views/xm/core/xmIteration/XmIterationOverviewComplex.vue

@ -49,9 +49,9 @@ import util from "@/common/js/util"; // 全局公共库
import { mapGetters } from "vuex"; import { mapGetters } from "vuex";
import XmIterationOverview from './XmIterationOverview.vue'; import XmIterationOverview from './XmIterationOverview.vue';
import XmIterationEdit from './XmIterationEdit.vue'; import XmIterationEdit from './XmIterationEdit.vue';
import XmIterationMenuMng from '../xmIterationMenu/XmIterationMenuMng.vue';
import XmIterationMenuMng from '../xmIterationMenu/XmIterationMenuMng.vue';
import { loadTasksToXmIterationState } from '@/api/xm/core/xmIterationState'; import { loadTasksToXmIterationState } from '@/api/xm/core/xmIterationState';
import { listXmIterationWithState } from "@/api/xm/core/xmIteration";
export default { export default {
components: {XmIterationOverview,XmIterationEdit, XmIterationMenuMng }, components: {XmIterationOverview,XmIterationEdit, XmIterationMenuMng },
@ -75,6 +75,16 @@ export default {
loadTasksToXmIterationState({id:this.xmIteration.id}).then(res=>{ loadTasksToXmIterationState({id:this.xmIteration.id}).then(res=>{
this.load.edit=false; this.load.edit=false;
var tips =res.data.tips; var tips =res.data.tips;
if(tips.isOk){
listXmIterationWithState({id:this.xmIteration.id}).then(res2=>{
var tips2=res2.data.tips;
if(tips2.isOk && res2.data.data.length>0){
var data=res2.data.data[0]
Object.assign(this.xmIteration,data);
this.$emit('edit-fields',data)
}
})
}
this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error'}); this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error'});
}); });
}, },

18
src/views/xm/core/xmProduct/XmProductOverviewComplex.vue

@ -56,7 +56,7 @@ import { mapGetters } from "vuex";
import XmProductOverview from './XmProductOverview.vue'; import XmProductOverview from './XmProductOverview.vue';
import XmProductEdit from './XmProductEdit.vue'; import XmProductEdit from './XmProductEdit.vue';
import XmProductProjectLinkMng from '../xmProductProjectLink/XmProductProjectLinkMng.vue'; import XmProductProjectLinkMng from '../xmProductProjectLink/XmProductProjectLinkMng.vue';
import { loadTasksToXmProductState } from '@/api/xm/core/xmProductState';
import { loadTasksToXmProductState,listXmProductWithState } from '@/api/xm/core/xmProductState';
import { loadTasksToXmMenuState} from '@/api/xm/core/xmMenuState'; import { loadTasksToXmMenuState} from '@/api/xm/core/xmMenuState';
import TaskMng from '@/views/mdp/workflow/ru/task/TaskMng'; import TaskMng from '@/views/mdp/workflow/ru/task/TaskMng';
import ProcinstMng from '@/views//mdp/workflow/hi/procinst/ProcinstMng'; import ProcinstMng from '@/views//mdp/workflow/hi/procinst/ProcinstMng';
@ -84,10 +84,26 @@ export default {
loadTasksToXmProductState(params).then((res) => { loadTasksToXmProductState(params).then((res) => {
this.load.calcProduct=false; this.load.calcProduct=false;
var tips=res.data.tips; var tips=res.data.tips;
if(tips.isOk){
this.getProduct(this.xmProduct.id)
}
this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error' }); this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error' });
}).catch( err => this.load.calcProduct=false ); }).catch( err => this.load.calcProduct=false );
}, },
getProduct(id){
listXmProductWithState({id:id}).then(res=>{
var tips = res.data.tips;
if(tips.isOk){
Object.assign(this.xmProduct,res.data.data[0])
localStorage.setItem("xm-product-info-route",JSON.stringify(this.xmProduct))
this.$emit('edit-fields',this.xmProduct)
this.showInfo=true;
}else{
}
})
},
loadTasksToXmMenuState: function () { loadTasksToXmMenuState: function () {
this.load.calcMenu=true; this.load.calcMenu=true;

7
src/views/xm/core/xmProject/XmProjectOverviewComplex.vue

@ -90,6 +90,13 @@ export default {
loadTasksToXmProjectState(params).then((res) => { loadTasksToXmProjectState(params).then((res) => {
this.load.calcProject=false; this.load.calcProject=false;
var tips=res.data.tips; var tips=res.data.tips;
listXmProject({id:this.selProject.id}).then(res=>{
var tips = res.data.tips;
if(tips.isOk){
var selProject=res.data.data[0]
this.onEditFields(selProject)
}
})
this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error'}); this.$notify({position:'bottom-left',showClose:true,message: tips.msg, type: tips.isOk?'success':'error'});
}).catch( err => this.load.calcProject=false ); }).catch( err => this.load.calcProject=false );
}, },

Loading…
Cancel
Save