瀏覽代碼

首页排行详情以及下载

yuhan 11 月之前
父節點
當前提交
02f499bba1

+ 3 - 3
src/views/module_kzks/dashboard/Analysis.vue

@@ -133,14 +133,14 @@
             <a-tab-pane loading="true" tab="下达部门指标排行" key="1">
               <a-row>
                 <a-col :xl="24" :lg="24" :md="24" :sm="24" :xs="24">
-                  <deptZbphTable :dataSource="zbPhDataSource.jycsCharts" :loading="zhbLoading" deptType="xd" class="dept-zbph-table"></deptZbphTable>
+                  <deptZbphTable :dataSource="zbPhDataSource.jycsCharts" :loading="zhbLoading" deptType="xd" :zbPhParams="zbPhParams" class="dept-zbph-table"></deptZbphTable>
                 </a-col>
               </a-row>
             </a-tab-pane>
             <a-tab-pane loading="true" tab="责任部门指标排行" key="2">
               <a-row>
                 <a-col :xl="24" :lg="24" :md="24" :sm="24" :xs="24">
-                  <deptZbphTable :dataSource="zbPhDataSource.zrbmCharts" :loading="zhbLoading" deptType="zr" class="dept-zbph-table"></deptZbphTable>
+                  <deptZbphTable :dataSource="zbPhDataSource.zrbmCharts" :loading="zhbLoading" deptType="zr" :zbPhParams="zbPhParams" class="dept-zbph-table"></deptZbphTable>
                 </a-col>
               </a-row>
             </a-tab-pane>
@@ -193,7 +193,7 @@
       </div>
     </template>
 
-    <!-- 弹框列表 -->
+    <!-- 一层模块弹框列表 -->
     <!-- <list-modal ref="modalForm" :listData = "listData"></list-modal> -->
     <detail-list-modal ref="detailModalRef"></detail-list-modal>
 

+ 70 - 14
src/views/module_kzks/dashboard/components/deptZbphTable.vue

@@ -1,24 +1,38 @@
 <template>
-  <a-table
-    ref="table"
-    size="middle"
-    :scroll="{x:true}"
-    bordered
-    :rowKey="(record,index)=>{return index}"
-    :columns="columns"
-    :dataSource="dataSource"
-    :loading="loading"
-    class="j-table-force-nowrap">
-    <!-- :pagination="ipagination" -->
-    
-  </a-table>
+  <div>
+    <a-table
+      ref="table"
+      size="middle"
+      :scroll="{x:true}"
+      bordered
+      :rowKey="(record,index)=>{return index}"
+      :columns="columns"
+      :dataSource="dataSource"
+      :loading="loading"
+      class="j-table-force-nowrap">
+      <!-- :pagination="ipagination" -->
+      
+    </a-table>
+    <j-modal
+      :title="title"
+      :width="width"
+      :visible="visible"
+      switchFullscreen
+      @cancel="handleCancel"
+      :footer="false"
+      >
+      <hte-detail ref="hteDetailRef"></hte-detail>
+    </j-modal>
+  </div>
 </template>
 
 <script>
+  import hteDetail from '../deptZbphDetail/hteDetail.vue';
   // import '@/assets/less/TableExpand.less'
   // import { mixinDevice } from '@/utils/mixin'
   // import { JeecgListMixin } from '@/mixins/JeecgListMixin'
   export default {
+  components: { hteDetail },
     name: '',
     // mixins:[JeecgListMixin, mixinDevice],
     props: {
@@ -33,7 +47,11 @@
       deptType: {
         type: String,
         default: ''
-      }
+      },
+      zbPhParams: {
+        type: Object,
+        default: () => {}
+      },
     },
     data () {
       return {
@@ -75,6 +93,7 @@
             customRender: (text, record) => {
               return (Number(text)/10000).toFixed(2)
             },
+            customCell: (record, index)=>{ return this.customCellDetail(record, index, 'contractAmount', '当期合同额')}
           },
           {
             title:'当期已收款',
@@ -84,6 +103,7 @@
             customRender: (text, record) => {
               return (Number(text)/10000).toFixed(2)
             },
+            customCell: (record, index)=>{ return this.customCellDetail(record, index, 'received', '当期已收款')}
           },
           {
             title:'当期完成额',
@@ -93,6 +113,7 @@
             customRender: (text, record) => {
               return (Number(text)/10000).toFixed(2)
             },
+            customCell: (record, index)=>{ return this.customCellDetail(record, index, 'contractAmount', '当期完成额')}
           },
           {
             title:'完成度',
@@ -105,6 +126,10 @@
         ],
         // 表头
         columns: [],
+        // 弹窗
+        title: '',
+        width: 1200,
+        visible: false,
       }
     },
     created() {
@@ -129,6 +154,37 @@
       }
     },
     methods: {
+      customCellDetail(record, index, columnValue, columnTitle){
+        return {
+          style: {
+            'color': "#1890ff !important",
+            'cursor': "pointer",
+          },
+          on: {
+            // 点击事件
+            click: (event) => {
+              console.log(record, index, columnValue, columnTitle)
+              this.visible = true
+              this.title = columnTitle
+              this.$nextTick(() => {
+                console.log(this.$refs.hteDetailRef.queryParam)
+                console.log(this.zbPhParams)
+                this.$refs.hteDetailRef.queryParam.beginDate = this.zbPhParams.beginDate
+                this.$refs.hteDetailRef.queryParam.time = this.zbPhParams.time
+                this.$refs.hteDetailRef.queryParam.departName = record.depart
+              })
+            },
+          }
+        }
+      },
+      // close () {
+      //   // this.$emit('close');
+      //   this.visible = false;
+      // },
+      handleCancel () {
+        // this.close()
+        this.visible = false;
+      },
       initDictConfig(){
       },
     }

+ 267 - 0
src/views/module_kzks/dashboard/deptZbphDetail/hteDetail.vue

@@ -0,0 +1,267 @@
+<template>
+  <a-card :bordered="false" class="u-dialog-card">
+
+    <div class="table-operator">
+      <a-button type="primary" icon="download" @click="handleExportXls('当期合同额明细')">导出</a-button>
+    </div>
+    <!-- table区域-begin -->
+    <div>
+      <!-- <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
+        <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
+        <a style="margin-left: 24px" @click="onClearSelected">清空</a>
+      </div> -->
+
+      <a-table
+        ref="table"
+        size="middle"
+        :scroll="{x:true}"
+        bordered
+        rowKey="id"
+        :columns="columns"
+        :dataSource="dataSource"
+        :pagination="ipagination"
+        :loading="loading"
+        class="j-table-force-nowrap"
+        @change="handleTableChange">
+      </a-table>
+    </div>
+  </a-card>
+</template>
+
+<script>
+
+  import '@/assets/less/TableExpand.less'
+  import { mixinDevice } from '@/utils/mixin'
+  import { JeecgListMixin } from '@/mixins/JeecgListMixin'
+  import { getAction } from '@/api/manage'
+
+  export default {
+    name: 'ListModalList',
+    mixins:[JeecgListMixin, mixinDevice],
+    components: {
+    },
+    data () {
+      return {
+        // 表头
+        columns: [
+          {
+            title: '序号',
+            dataIndex: '',
+            key:'rowIndex',
+            width:60,
+            align:"center",
+            customRender:function (t,r,index) {
+                return parseInt(index)+1;
+            }
+          },
+          {
+            title:'ID',
+            align:"center",
+            dataIndex: 'htid'
+          },
+          {
+            title:'主合同编号',
+            align:"center",
+            dataIndex: 'zhtbh'
+          },
+          {
+            title:'合同编号',
+            align:"center",
+            dataIndex: 'htbh'
+          },
+          {
+            title:'合同名称',
+            align:"center",
+            dataIndex: 'htname'
+          },
+          {
+            title:'签署日期',
+            align:"center",
+            dataIndex: 'qsrq'
+          },
+          {
+            title:'甲方(付款方)',
+            align:"center",
+            dataIndex: 'jf'
+          },
+          {
+            title:'甲方简称',
+            align:"center",
+            dataIndex: 'jfjc'
+          },
+          {
+            title:'合同金额',
+            align:"center",
+            dataIndex: 'htje'
+          },
+          {
+            title:'自筹',
+            align:"center",
+            dataIndex: 'zc'
+          },
+          {
+            title:'合同到款',
+            align:"center",
+            dataIndex: 'htdk'
+          },
+          {
+            title:'合同待收款',
+            align:"center",
+            dataIndex: 'htdsk'
+          },
+          {
+            title:'合同已开票',
+            align:"center",
+            dataIndex: 'htykp'
+          },
+          {
+            title:'合同待开票',
+            align:"center",
+            dataIndex: 'htdkp'
+          },
+          {
+            title:'任务编号',
+            align:"center",
+            dataIndex: 'rwbh'
+          },
+          {
+            title:'任务名称',
+            align:"center",
+            dataIndex: 'rwname'
+          },
+          {
+            title:'产品型号',
+            align:"center",
+            dataIndex: 'cpxh'
+          },
+          {
+            title:'阶段',
+            align:"center",
+            dataIndex: 'jd'
+          },
+          {
+            title:'研制部门',
+            align:"center",
+            dataIndex: 'yzbm'
+          },
+          {
+            title:'任务应收款',
+            align:"center",
+            dataIndex: 'rwyingsk'
+          },
+          {
+            title:'任务已收款',
+            align:"center",
+            dataIndex: 'rwyisk'
+          },
+          {
+            title:'发票类型1',
+            align:"center",
+            dataIndex: 'fptypeone'
+          },
+          {
+            title:'发票1金额',
+            align:"center",
+            dataIndex: 'fpjeone'
+          },
+          {
+            title:'1已开票额',
+            align:"center",
+            dataIndex: 'ykpeone'
+          },
+          {
+            title:'发票类型2',
+            align:"center",
+            dataIndex: 'fptypetwo'
+          },
+          {
+            title:'发票2金额',
+            align:"center",
+            dataIndex: 'fpjetwo'
+          },
+          {
+            title:'2已开票额',
+            align:"center",
+            dataIndex: 'ykpetwo'
+          },
+          {
+            title:'合同主管部门',
+            align:"center",
+            dataIndex: 'htzgbm'
+          },
+          {
+            title:'业务员',
+            align:"center",
+            dataIndex: 'ywy'
+          },
+          {
+            title:'合同履行情况',
+            align:"center",
+            dataIndex: 'htlxqk'
+          },
+          {
+            title:'合同状态说明',
+            align:"center",
+            dataIndex: 'htztsm'
+          },
+        ],
+        url: {
+          list: "/index/getXdbmHteDepartKpiDetail",
+          exportXlsUrl: "/index/exportXdbmHteDepartKpiXls",
+        },
+        dictOptions:{},
+        superFieldList:[],
+      }
+    },
+    created() {
+    },
+    computed: {
+    },
+    methods: {
+      loadData(arg) {
+        if(!this.url.list){
+          this.$message.error("请设置url.list属性!")
+          return
+        }
+        //加载数据 若传入参数1则加载第一页的内容
+        if (arg === 1) {
+          this.ipagination.current = 1;
+        }
+        // var params = this.getQueryParams();//查询条件
+        var params = this.queryParam
+        params.pageNo = this.ipagination.current;
+        params.pageSize = this.ipagination.pageSize;
+        this.loading = true;
+        getAction(this.url.list, params).then((res) => {
+          if (res.success) {
+            //update-begin---author:zhangyafei    Date:20201118  for:适配不分页的数据列表------------
+            this.dataSource = res.result.records||res.result;
+            if(res.result.total)
+            {
+              this.ipagination.total = res.result.total;
+            }else{
+              this.ipagination.total = 0;
+            }
+            //update-end---author:zhangyafei    Date:20201118  for:适配不分页的数据列表------------
+          }else{
+            this.$message.warning(res.message)
+          }
+        }).finally(() => {
+          this.loading = false
+        })
+      },
+      initDictConfig(){
+      },
+    }
+  }
+</script>
+<style scoped>
+  @import '~@assets/less/common.less';
+</style>
+<style lang="less" scoped>
+  .u-dialog-card{
+    /deep/.ant-card-body{
+      padding: 0 !important;
+    }
+  }
+</style>