Browse Source

优化

master
陈裕财 3 years ago
parent
commit
29d52b93ff
  1. 1
      src/views/xm/core/xmRptData/XmRptDataMng.vue
  2. 14
      src/views/xm/rpt/his/rptDataSelect.vue
  3. 17
      src/views/xm/rpt/index/CompsCard.vue
  4. 5
      src/views/xm/rpt/index/CompsCardHisDetail.vue
  5. 17
      src/views/xm/rpt/index/indexForHis.vue

1
src/views/xm/core/xmRptData/XmRptDataMng.vue

@ -4,7 +4,6 @@
<el-input v-model="filters.key" style="width: 20%;" placeholder="模糊查询"></el-input> <el-input v-model="filters.key" style="width: 20%;" placeholder="模糊查询"></el-input>
<el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search">查询</el-button> <el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search">查询</el-button>
<span style="float:right;"> <span style="float:right;">
<el-button type="primary" @click="showAdd" icon="el-icon-plus" plain> </el-button>
<el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete" plain></el-button> <el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete" plain></el-button>
</span> </span>
</el-row> </el-row>

14
src/views/xm/rpt/his/rptDataSelect.vue

@ -1,12 +1,10 @@
<template> <template>
<section class="page-container border padding"> <section class="page-container border padding">
<el-row> <el-row>
<el-input v-model="filters.key" style="width: 40%;" placeholder="模糊查询"></el-input>
<mdp-date-range v-model="filters" start-key="startBizDate" end-key="endBizDate"></mdp-date-range>
<el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search">查询</el-button>
<span style="float:right;">
<el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete" plain></el-button>
</span>
<el-input v-model="filters.key" style="width: 30%;" placeholder="模糊查询"></el-input>
<el-checkbox v-model="filters.myCreate" true-label="1" false-label="0">我的</el-checkbox>
<mdp-date-range v-model="filters" style="width:220px" start-key="startBizDate" end-key="endBizDate"></mdp-date-range>
<el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search"></el-button>
</el-row> </el-row>
<el-row class="padding-top"> <el-row class="padding-top">
<!--列表 XmRptData xm_rpt_data--> <!--列表 XmRptData xm_rpt_data-->
@ -68,6 +66,7 @@ export default {
key: '', key: '',
startBizDate:'', startBizDate:'',
endBizDate:'', endBizDate:'',
myCreate:'',
}, },
xmRptDatas: [],// xmRptDatas: [],//
pageInfo:{// pageInfo:{//
@ -147,6 +146,9 @@ export default {
if(this.filters.key){ if(this.filters.key){
params.key=this.filters.key params.key=this.filters.key
} }
if(this.filters.myCreate=='1'){
params.cuserid=this.userInfo.userid
}
if(this.filters.startBizDate){ if(this.filters.startBizDate){
params.startBizDate=this.filters.startBizDate params.startBizDate=this.filters.startBizDate
params.endBizDate=this.filters.endBizDate params.endBizDate=this.filters.endBizDate

17
src/views/xm/rpt/index/CompsCard.vue

@ -317,17 +317,10 @@ export default {
}) })
return; return;
} }
var compCfgListTemp=JSON.parse(JSON.stringify(this.compCfgList))
compCfgListTemp.sort((i1,i2)=>{
return i2.i-i1.i
})
var maxI=(compCfgListTemp.length>0?(compCfgListTemp[0].i+1):1);
compCfgListTemp.sort((i1,i2)=>{
return i2.y-i1.y
})
var maxY=(compCfgListTemp.length>0?(compCfgListTemp[0].y+6):0);
var compCfg={...comp,i:maxI, x: 0, y: maxY, w: 12, h: 6,id:comp.compId+seq.sn()}
this.compCfgList.push(compCfg)
var allCheckedList=this.$refs.compsSet.datas.filter(k=>k.isChecked)
var index=allCheckedList.findIndex(k=>k.compId==comp.compId)
var compCfg={...comp,id:comp.compId+seq.sn()}
this.compCfgList.splice(index,0,compCfg)
this.$nextTick(()=>{ this.$nextTick(()=>{
setTimeout(()=>{ setTimeout(()=>{
this.scrollToComp(compCfg) this.scrollToComp(compCfg)
@ -436,7 +429,7 @@ export default {
}, },
onCompChange(compCfg,checked){ onCompChange(compCfg,checked){
if(checked=='false'||!checked){ if(checked=='false'||!checked){
var index=this.compCfgList.findIndex(k=>k.id==compCfg.id)
var index=this.compCfgList.findIndex(k=>k.compId==compCfg.compId)
if(index>=0){ if(index>=0){
this.compCfgList.splice(index,1) this.compCfgList.splice(index,1)
} }

5
src/views/xm/rpt/index/CompsCardHisDetail.vue

@ -130,9 +130,10 @@ export default {
}) })
return; return;
} }
var allCheckedList=this.$refs.compsSet.datas.filter(k=>k.isChecked)
var index=allCheckedList.findIndex(k=>k.compId==comp.compId)
var compCfg={...comp,id:comp.compId+seq.sn()} var compCfg={...comp,id:comp.compId+seq.sn()}
this.compCfgList.push(compCfg)
this.compCfgList.splice(index,0,compCfg)
this.$nextTick(()=>{ this.$nextTick(()=>{
setTimeout(()=>{ setTimeout(()=>{
this.scrollToComp(compCfg) this.scrollToComp(compCfg)

17
src/views/xm/rpt/index/indexForHis.vue

@ -1,9 +1,11 @@
<template> <template>
<section class="padding"> <section class="padding">
<el-row> <el-row>
<el-input v-model="filters.key" style="width: 40%;" placeholder="模糊查询"></el-input>
<mdp-date-range v-model="filters" start-key="startBizDate" end-key="endBizDate"></mdp-date-range>
<el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search">查询</el-button>
<el-input v-model="filters.key" style="width: 30%;" placeholder="模糊查询"></el-input>
<el-checkbox v-model="filters.myCreate" true-label="1" false-label="0">我的</el-checkbox>
<mdp-date-range v-model="filters" start-key="startBizDate" style="width:250px;" end-key="endBizDate"></mdp-date-range>
<el-button v-loading="load.list" :disabled="load.list==true" @click="searchXmRptDatas" icon="el-icon-search"></el-button>
<span style="float:right;"> <span style="float:right;">
<el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete" plain></el-button> <el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete" plain></el-button>
</span> </span>
@ -12,12 +14,12 @@
<!--列表 XmRptData xm_rpt_data--> <!--列表 XmRptData xm_rpt_data-->
<el-table ref="xmRptDataTable" :data="xmRptDatas" :height="maxTableHeight" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;"> <el-table ref="xmRptDataTable" :data="xmRptDatas" :height="maxTableHeight" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="55" show-overflow-tooltip fixed="left"></el-table-column> <el-table-column type="selection" width="55" show-overflow-tooltip fixed="left"></el-table-column>
<el-table-column prop="rptName" label="报告名称" min-width="120" show-overflow-tooltip>
<el-table-column prop="rptName" label="报告名称" min-width="250" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<span> {{scope.row.rptName}} </span> <span> {{scope.row.rptName}} </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="bizDate" label="业务日期" min-width="120" show-overflow-tooltip>
<el-table-column prop="bizDate" label="业务日期" min-width="100" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<span> {{scope.row.bizDate}} </span> <span> {{scope.row.bizDate}} </span>
</template> </template>
@ -67,6 +69,7 @@ export default {
key: '', key: '',
startBizDate:'', startBizDate:'',
endBizDate:'', endBizDate:'',
myCreate:'0',
}, },
xmRptDatas: [],// xmRptDatas: [],//
pageInfo:{// pageInfo:{//
@ -150,6 +153,10 @@ export default {
params.startBizDate=this.filters.startBizDate params.startBizDate=this.filters.startBizDate
params.endBizDate=this.filters.endBizDate params.endBizDate=this.filters.endBizDate
} }
if(this.filters.myCreate=='1'){
params.cuserid=this.userInfo.userid
}
this.load.list = true; this.load.list = true;
listXmRptData(params).then((res) => { listXmRptData(params).then((res) => {
var tips=res.data.tips; var tips=res.data.tips;

Loading…
Cancel
Save