Browse Source

fix 表格文案过长

code4eat 3 years ago
parent
commit
615ff9c467
41 changed files with 1169 additions and 214 deletions
  1. 20 1
      config/routes.js
  2. 134 0
      mock/beforeCollectionSearch.js
  3. 17 6
      src/components/CAUpload/index.jsx
  4. 4 3
      src/menuIcons.js
  5. 7 2
      src/pages/DepartmentMana/index.jsx
  6. 6 2
      src/pages/UserMana/index.js
  7. 3 1
      src/pages/accountingSubject/index.jsx
  8. 6 1
      src/pages/accountingSubjectConnect/index.jsx
  9. 5 1
      src/pages/apportionmentLevel/index.jsx
  10. 1 1
      src/pages/baseSetting/incomeCollectionSetting/component/drawer.jsx
  11. 21 10
      src/pages/baseSetting/incomeCollectionSetting/index.js
  12. 241 141
      src/pages/baseSetting/reportProjectSetting/index.js
  13. 15 0
      src/pages/baseSetting/reportProjectSetting/updateForm.jsx
  14. 11 1
      src/pages/baseSetting/visitsAndBedDayCostSetting/index.jsx
  15. 3 1
      src/pages/baseSetting/wholeHospCostAndIncomeSet/index.jsx
  16. 12 1
      src/pages/costAccounting/afterCollectionSearch/index.jsx
  17. 5 1
      src/pages/costAccounting/afterCostShareSearch/index.jsx
  18. 11 1
      src/pages/costAccounting/beforeCollectionSearch/index.jsx
  19. 7 4
      src/pages/costAccounting/beforeCostShareSearch/index.jsx
  20. 5 1
      src/pages/costAccounting/costShare/index.jsx
  21. 11 1
      src/pages/costAccounting/costShareParamsHandle/index.js
  22. 16 11
      src/pages/costAccounting/costShareReportTable/index.jsx
  23. 8 1
      src/pages/costAccounting/departmentCostCalculate/index.jsx
  24. 4 1
      src/pages/costAccounting/incomeCollection/index.jsx
  25. 11 1
      src/pages/costAccounting/incomeCostDataImport/index.jsx
  26. 6 1
      src/pages/costAccounting/wholeHospCostCalculate/index.jsx
  27. 7 1
      src/pages/costAccounting/wholeHospIncomeAndCost/index.jsx
  28. 15 1
      src/pages/costAllocationParamsConnect/index.jsx
  29. 4 3
      src/pages/costAllocationParamsConnect/service.js
  30. 6 1
      src/pages/costAllocationParamsSetting/index.jsx
  31. 6 2
      src/pages/costProjectMana/index.jsx
  32. 8 1
      src/pages/platformMana/districtMana/index.jsx
  33. 7 1
      src/pages/platformMana/menuManage/index.js
  34. 10 1
      src/pages/platformMana/roleManage/index.js
  35. 217 0
      src/pages/reportTableExport/departmentOperatingReport/index.jsx
  36. 35 0
      src/pages/reportTableExport/departmentOperatingReport/service.js
  37. 209 0
      src/pages/reportTableExport/wholeHospOperatingReport/index.jsx
  38. 35 0
      src/pages/reportTableExport/wholeHospOperatingReport/service.js
  39. 10 4
      src/pages/responsibilityCenter/index.jsx
  40. 9 3
      src/pages/responsibilityCenterConnect/index.jsx
  41. 1 1
      src/projectConstant.js

+ 20 - 1
config/routes.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-22 15:04:09
- * @LastEditTime: 2021-08-28 14:25:11
+ * @LastEditTime: 2021-09-01 15:10:17
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/config/routes.js
@@ -144,6 +144,25 @@ export default [
       },
     ],
   },
+  {
+    path: '/reportTableExport',
+    name: '报表输出',
+    icon: 'tool',
+    routes: [
+      {
+        path: '/reportTableExport/departmentOperatingReport',
+        name: '科室经营报表',
+        icon: 'tool',
+        component: './reportTableExport/departmentOperatingReport/index',
+      },
+      {
+        path: '/reportTableExport/wholeHospOperatingReport',
+        name: '全院经营报表',
+        icon: 'tool',
+        component: './reportTableExport/wholeHospOperatingReport/index',
+      },
+    ],
+  },
   {
     path: '/UserMana',
     name: '用户管理',

+ 134 - 0
mock/beforeCollectionSearch.js

@@ -6,3 +6,137 @@
  * @Description: In User Settings Edit
  * @FilePath: /CostAccountManaSys/mock/beforeCollectionSearch.js
  */
+
+
+// eslint-disable-next-line import/no-extraneous-dependencies
+import moment from 'moment';
+import { parse } from 'url'; // mock tableListDataSource
+
+const genList = (current, pageSize) => {
+  const tableListDataSource = [];
+
+  for (let i = 0; i < pageSize; i += 1) {
+    const index = (current - 1) * 10 + i;
+    tableListDataSource.push({
+      key: index,
+      id: index,
+      paymentsType:1,
+      paymentsName:`paymentsName ${index}`
+    });
+  }
+  //   console.log({tableListDataSource});
+  tableListDataSource.reverse();
+  return tableListDataSource;
+};
+
+let tableListDataSource = genList(1, 100);
+
+function getList(req, res, u) {
+  let realUrl = u;
+
+  if (!realUrl || Object.prototype.toString.call(realUrl) !== '[object String]') {
+    realUrl = req.url;
+  }
+
+  const { current = 1, pageSize = 10 } = req.query;
+  let dataSource = [...tableListDataSource].slice((current - 1) * pageSize, current * pageSize);
+
+  const result = {
+    data: {
+      list: dataSource,
+      totalCount: tableListDataSource.length,
+      pageSize: pageSize,
+    },
+    status: 200,
+    success: true,
+  };
+  return res.json(result);
+}
+
+function postList(req, res, u, b) {
+  let realUrl = u;
+
+  if (!realUrl || Object.prototype.toString.call(realUrl) !== '[object String]') {
+    realUrl = req.url;
+  }
+
+  const { method, body } = req;
+
+  tableListDataSource.push({ ...body });
+
+  const result = {
+    status: 200,
+    msg: '',
+  };
+  res.json(result);
+}
+
+function delList(req, res, u, b) {
+  const { method, body } = req;
+  tableListDataSource = tableListDataSource.filter((item) => !body.includes(item.roleId));
+  const result = {
+    status: 200,
+    msg: '',
+  };
+  res.json(result);
+}
+
+
+function getHasBindList(req, res, u, b){
+   const data = {
+    id:98,
+    allocation:1,
+    incomeType:2,
+    shareParamCode:98,
+    shareParamName:'shareParamName 98',
+    incomeFieldNum:98,
+    incomeFileName:'incomeFileName 98',
+    costCorresponding:98,
+    costCorrespondingName:'costCorrespondingName 98'
+   }
+       
+   const result = {
+    status: 200,
+    msg: '',
+    data:data
+   };
+   res.json(result);
+}
+
+
+function getHasBindMenuList(req, res, u, b){
+    const data = [
+        {
+            id:98,name:'菜单98'
+        },
+        {
+            id:92,name:'菜单92'
+        }
+    ]
+ 
+    const result = {
+     status: 200,
+     msg: '',
+     data:data
+    };
+    res.json(result);
+}
+
+function bindList(req, res, u, b) {
+  const { method, body } = req;
+  const { roleId, userIds } = body;
+  const result = {
+    status: 200,
+    msg: '',
+  };
+  res.json(result);
+}
+
+export default {
+  'GET /api/costAccount/costotherpayments/list': getList,
+  'GET /api/costAccount/costotherpayments': getHasBindList,
+  'GET /api/costAccount/role/roleMenus': getHasBindMenuList,
+  'POST /api/costAccount/costotherpayments/save': postList,
+  'POST /api/costAccount/role/delete': delList,
+  'POST /api/costAccount/role/editUserRole': bindList,
+};

+ 17 - 6
src/components/CAUpload/index.jsx

@@ -40,7 +40,12 @@ class CAUpload extends Component {
     jumpTo() {
         const userData = localStorage.getItem('userData');
         const { token } = JSON.parse(userData);
-        window.open(`${Host}${this.templeteUrl}?token=${token}`);
+        if(this.templeteUrl == '/costAccount/excel/getcurrentTemplate'){
+            //找后端
+            window.open(`${Host}${this.templeteUrl}`);
+        }else{
+            window.open(`${Host}${this.templeteUrl}?token=${token}`);
+        }
     }
     // 上传参数
     uploadProps = {
@@ -140,11 +145,17 @@ class CAUpload extends Component {
     }
 
     handleButtonClick(e){
+          
+         const { type,templateHrefs } = this.props;
+
+         if(type == 'normal'){
+            this.templeteUrl = templateHrefs;
+         }
          if(this.templeteUrl == ''){
             message.error('请选择下载模板!');
-         }else{
-            this.jumpTo();
+            return;
          }
+         this.jumpTo();
     }
 
     openModal() {
@@ -186,7 +197,7 @@ class CAUpload extends Component {
 
     render() {
         const uploadProps = this.uploadProps;
-        const { type,templateHrefs } = this.props;
+        const { type } = this.props;
         // console.log({...this.props});
         if (type == 'normal'||!type) {
             return [
@@ -194,7 +205,7 @@ class CAUpload extends Component {
                 <Upload style={{ marginLeft: 10 }} key='importExcel' {...uploadProps} >
                     <Button type="primary">导入</Button>
                 </Upload>,
-                <Button style={{ marginLeft: 10 }} key='templateDowload' onClick={()=>{this.templeteUrl = templateHrefs;this.jumpTo();}}>模板下载</Button>
+                <Button style={{ marginLeft: 10 }} key='templateDowload' onClick={this.handleButtonClick.bind(this)}>模板下载</Button>
             ]
         }
         if (type == 'dialog') {
@@ -224,7 +235,7 @@ CAUpload.propTypes = {
     url: PropTypes.string.isRequired,
     // 导入成功后的回调
     importSuccessCallback: PropTypes.func,
-    //最终必需resolve一个值
+   
     customRequestCallback: PropTypes.func,
     //上传功能类型 【‘normal’,'dialog'】
     type: PropTypes.string,

+ 4 - 3
src/menuIcons.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-08-05 15:54:27
- * @LastEditTime: 2021-08-30 14:00:06
+ * @LastEditTime: 2021-09-01 09:02:33
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /CostAccountManaSys/src/menuIcons.js
@@ -21,7 +21,8 @@ import { SmileOutlined,
      ControlOutlined,
      CrownOutlined,
      ToolOutlined,
-     TableOutlined
+     TableOutlined,
+     FileDoneOutlined
 } from '@ant-design/icons';
 
 const iconEnum = {
@@ -38,7 +39,7 @@ const iconEnum = {
   ProfileOutlined:<ProfileOutlined />,
   AccountBookOutlined:<AccountBookOutlined />,
   ControlOutlined:<ControlOutlined />,
-  
+  FileDoneOutlined:<FileDoneOutlined />
 };
 
 export default iconEnum;

+ 7 - 2
src/pages/DepartmentMana/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-03 17:25:23
+ * @LastEditTime: 2021-09-10 09:21:28
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -25,23 +25,27 @@ const DepartmentMana = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '科室名',
       dataIndex: 'departmentName',
       key: 'departmentName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '科室编号',
       dataIndex: 'departmentCode',
       key: 'departmentCode',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '创建时间',
       dataIndex: 'createDateTime',
       key: 'createTime',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -149,10 +153,11 @@ const DepartmentMana = () => {
             新增
           </Button>,
           <CAUpload  
-          templateHref={'/costAccount/excel/getDepartmentTemplate'}
+          templateHrefs={'/costAccount/excel/getDepartmentTemplate'}
           url='/costAccount/excel/importDepartment'
           importSuccessCallback={() =>{}}
           token={token}
+          type='normal'
           customRequestCallback={customRequestCallback}
     />
         ]}

+ 6 - 2
src/pages/UserMana/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-12 19:19:17
+ * @LastEditTime: 2021-09-10 09:24:49
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -25,23 +25,27 @@ const UserMana = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '姓名',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
     },
     {
       title: '用户名',
       dataIndex: 'account',
       key: 'account',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '在职状态',
       dataIndex: 'hospitalStatus',
       key: 'hospitalStatus',
       hideInSearch: true,
+      ellipsis: true,
       render: (text) => <>{text == 1 ? '在职' : '离职'}</>,
     },
     {
@@ -145,7 +149,7 @@ const UserMana = () => {
             新增
           </Button>,
           <CAUpload  
-                templateHrefs={'/costAccount/excel/getImportUserTemplate'}
+                templateHrefs={'/costAccount/excel/getcurrentTemplate'}
                 url='/costAccount/excel/importUser'
                 importSuccessCallback={() =>{}}
                 token={token}

+ 3 - 1
src/pages/accountingSubject/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:28:33
+ * @LastEditTime: 2021-09-10 09:10:17
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -28,6 +28,7 @@ const AccountingSubject = () => {
       dataIndex: 'accountingName',
       key: 'accountingName',
       hideInSearch: false,
+      ellipsis: true,
       width: '30%'
     },
     {
@@ -35,6 +36,7 @@ const AccountingSubject = () => {
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
       width: '30%'
     },
     // {

+ 6 - 1
src/pages/accountingSubjectConnect/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:50:56
+ * @LastEditTime: 2021-09-10 09:10:34
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -23,6 +23,7 @@ const AccountingSubjectConnect = () => {
       dataIndex: 'accountingName',
       key: 'accountingName',
       hideInSearch: false,
+      ellipsis: true,
       width: '20%',
     },
     {
@@ -30,12 +31,14 @@ const AccountingSubjectConnect = () => {
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
       width: '20%'
     },
     {
       title: '成本列表',
       dataIndex: 'productVOs',
       key: 'productVOs',
+      ellipsis: true,
       hideInSearch: false,
       render: (productVOs) => {
 
@@ -73,12 +76,14 @@ const AccountingSubjectConnect = () => {
       title: 'Id',
       dataIndex: 'id',
       key: 'id',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '成本中心名称',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
       hideInSearch: false,
     }
 

+ 5 - 1
src/pages/apportionmentLevel/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:34:23
+ * @LastEditTime: 2021-09-10 09:11:07
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -25,24 +25,28 @@ const ApportionmentLevel = () => {
       dataIndex: 'shareName',
       key: 'shareName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '分摊层级序号',
       dataIndex: 'leverSort',
       key: 'leverSort',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '目标层级',
       dataIndex: 'targetLevel',
       key: 'targetLevel',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '计算方式',
       dataIndex: 'calcType',
       key: 'calcType',
       hideInSearch: true,
+      ellipsis: true,
       render: (text) => <>{text == 0 ? '合并计算' : '分开计算'}</>,
     },
     {

+ 1 - 1
src/pages/baseSetting/incomeCollectionSetting/component/drawer.jsx

@@ -72,7 +72,7 @@ export default function DrawerContent(props) {
                  }}
                  tabList={[
                       {
-                        tab: '收',
+                        tab: '收',
                         key:1,
                       },
                     //   {

+ 21 - 10
src/pages/baseSetting/incomeCollectionSetting/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-06 18:43:57
+ * @LastEditTime: 2021-09-10 09:11:41
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -31,30 +31,35 @@ const IncomeCollectionSetting = () => {
       title: '收入归集Id',
       dataIndex: 'id',
       key: 'id',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
-      title: '开科室状态',
+      title: '开科室状态',
       dataIndex: 'openDepartmentStatus',
       key: 'openDepartmentStatus',
       hideInSearch: true,
+      ellipsis: true,
       render:num=><>{num==1?'收益中心':'成本中心'}</>
     },
     {
-      title: '开单科室比例',
+      title: '开单科室分配比例',
       dataIndex: 'openDepartmentProportion',
       key: 'openDepartmentProportion',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
-      title: '执行科室状态',
+      title: '执行科室',
       dataIndex: 'startDepartmentStatus',
       key: 'startDepartmentStatus',
       hideInSearch: true,
+      ellipsis: true,
       render:num=><>{num==1?'收益中心':'成本中心'}</>
     },
     {
       title: '执行科室比例',
+      ellipsis: true,
       dataIndex: 'startDepartmentProportion',
       key: 'startDepartmentProportion',
       hideInSearch: true,
@@ -70,6 +75,7 @@ const IncomeCollectionSetting = () => {
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '操作',
@@ -115,11 +121,13 @@ const IncomeCollectionSetting = () => {
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目名',
       dataIndex: 'accountingName',
       key: 'accountingName',
+      ellipsis: true,
     },
   ];
 
@@ -188,11 +196,14 @@ const IncomeCollectionSetting = () => {
   //获取Drawer表格列表
   const getTableList = async (params = {}, sort, filter) => {
     const res = await getAccountingSubjectList({ ...params,accountType});
-    return {
-      data: res.data.list,
-      total: res.data.totalCount,
-      success: res.success,
-    };
+    const {data} = res;
+    if(data&&data.list){
+      return {
+        data: res.data.list,
+        total: res.data.totalCount,
+        success: res.success,
+      };
+    } 
   };
   
 
@@ -201,7 +212,7 @@ const IncomeCollectionSetting = () => {
     const {id} = record;
     const resp = await getIncomeCollectionListHasConnected({id});
     const {status,data=[]} = resp;
-    if(status == 200){
+    if(status == 200&&data&&data.list){
        const tempArr = data&&data.map(item=>item.accountingCode);
        setSelectedKeys(tempArr);
     }

+ 241 - 141
src/pages/baseSetting/reportProjectSetting/index.js

@@ -1,14 +1,14 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 17:35:45
+ * @LastEditTime: 2021-09-10 09:12:58
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
  */
 
 import { PlusOutlined } from '@ant-design/icons';
-import { Button, Popconfirm } from 'antd';
+import { Button, Popconfirm, Tag, Modal, Form, Switch } from 'antd';
 import React, { useState, useRef } from 'react';
 
 import { PageContainer } from '@ant-design/pro-layout';
@@ -28,20 +28,20 @@ import {
   getReportProjectSettingList,
   saveReportRelation,
   getHasSetReportRelation,
-  copyDataToSelectedType
+  copyDataToSelectedType,
 } from './service';
 
 import { getAccountingSubjectList } from '@/pages/accountingSubject/service';
 
 import { getApportionmentLevelList } from '@/pages/apportionmentLevel/service';
 
-import {getResponsibilityCenterList} from '@/pages/responsibilityCenter/service';
+import { getResponsibilityCenterList } from '@/pages/responsibilityCenter/service';
 
 import DrawerContent from './component/drawerContent';
 
-import {reportTypes} from '@/projectConstant';
+import { reportTypes } from '@/projectConstant';
 
-import {deepGetAllParents} from '@/utils';
+import { deepGetAllParents } from '@/utils';
 
 const ReportProjectSetting = () => {
   const columns = [
@@ -50,23 +50,27 @@ const ReportProjectSetting = () => {
       dataIndex: 'reportName',
       key: 'reportName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: 'Id',
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '编号',
       dataIndex: 'num',
       key: 'num',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '计算方式',
       dataIndex: 'calcType',
       key: 'calcType',
+      ellipsis: true,
       hideInSearch: true,
       //1.对应会计科目,2.对应分摊层级,3.小计,4.计算公式
       render: (num) => {
@@ -90,6 +94,7 @@ const ReportProjectSetting = () => {
       title: '报表类型',
       dataIndex: 'reportType',
       key: 'reportType',
+      ellipsis: true,
       hideInSearch: true,
       //报表类型:0.损益表、1.完全成本法表、2.变动成本表、3.全院损益表、4.全成本报表
       render: (num) => {
@@ -112,17 +117,20 @@ const ReportProjectSetting = () => {
       dataIndex: 'calcFormula',
       key: 'calcFormula',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '排序',
       dataIndex: 'sort',
       key: 'sort',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '比率基数',
       dataIndex: 'ratioBase',
       key: 'ratioBase',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -135,7 +143,8 @@ const ReportProjectSetting = () => {
           <a
             key="config1"
             onClick={() => {
-              setIfAddZeroLevelMenu(false);
+              setIfOperateZeroLevelMenu(false);
+              setEdit(false);
               handleModalVisible(true);
               setModalFormType(1);
               setCurrentRow(record);
@@ -146,7 +155,10 @@ const ReportProjectSetting = () => {
           <a
             key="config2"
             onClick={() => {
-              handleUpdateModalVisible(true);
+              setIfOperateZeroLevelMenu(parentId==0?true:false);
+              setEdit(true);
+              setModalFormType(1);
+              handleModalVisible(true);
               setCurrentRow(record);
             }}
           >
@@ -171,7 +183,11 @@ const ReportProjectSetting = () => {
                   setRelationInit(showAddRelation, record);
                 }}
               >
-                {showAddRelation == 1 ? '对应会计科目设置' : showAddRelation == 2 ? '对应分摊层级设置':showAddRelation==3&&'对应责任中心设置'}
+                {showAddRelation == 1
+                  ? '对应会计科目设置'
+                  : showAddRelation == 2
+                  ? '对应分摊层级设置'
+                  : showAddRelation == 3 && '对应责任中心设置'}
               </a>,
               ...btnGroup,
             ]
@@ -186,11 +202,13 @@ const ReportProjectSetting = () => {
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目名',
       dataIndex: 'accountingName',
       key: 'accountingName',
+      ellipsis: true,
     },
   ];
 
@@ -199,12 +217,14 @@ const ReportProjectSetting = () => {
       title: '分摊层级Id',
       dataIndex: 'id',
       key: 'id',
+      ellipsis: true,
       hideInSearch: false,
     },
     {
       title: '分摊层级名',
       dataIndex: 'shareName',
       key: 'shareName',
+      ellipsis: true,
       hideInSearch: false,
     },
   ];
@@ -215,27 +235,28 @@ const ReportProjectSetting = () => {
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: false,
+      ellipsis: true,
     },
   ];
 
-
-  const tabList = [
-    ...reportTypes
-  ]
+  const tabList = [...reportTypes].filter((item) => item.key == 0 || item.key == 3);
 
   const [createModalVisible, handleModalVisible] = useState(false);
   const [updateModalVisible, handleUpdateModalVisible] = useState(false);
   const actionRef = useRef();
   const [currentRow, setCurrentRow] = useState(undefined);
-  const [ifAddZeroLevelMenu, setIfAddZeroLevelMenu] = useState(true);
+  const [ifOperateZeroLevelMenu, setIfOperateZeroLevelMenu] = useState(true);
   const [reportType, setReportType] = useState(0);
 
+  const [edit, setEdit] = useState(false);
+
   const [accountType, setAccountType] = useState(1);
 
   const [modalFormType, setModalFormType] = useState(0); // 1 新增表单  2  复制表单
@@ -247,7 +268,7 @@ const ReportProjectSetting = () => {
 
   const [selectedKeys, setSelectedKeys] = useState([]);
 
-  const [defaultExpandedKeys,setDefaultExpandedKeys] = useState([]);
+  const [defaultExpandedKeys, setDefaultExpandedKeys] = useState([]);
 
   /**
    *
@@ -272,8 +293,8 @@ const ReportProjectSetting = () => {
   const getTableList = async (params = {}, sort, filter) => {
     if (settingType == 1) {
       const res = await getAccountingSubjectList({ ...params, accountType });
-      const opendedArr = deepGetAllParents(res.data.list,'children');
-      opendedArr&&setDefaultExpandedKeys(opendedArr.map(item=>item.accountingCode));
+      const opendedArr = deepGetAllParents(res.data.list, 'children');
+      opendedArr && setDefaultExpandedKeys(opendedArr.map((item) => item.accountingCode));
 
       return {
         data: res.data.list,
@@ -291,8 +312,8 @@ const ReportProjectSetting = () => {
     }
     if (settingType == 3) {
       const res = await getResponsibilityCenterList({ ...params });
-      const opendedArr = deepGetAllParents(res.data.list,'child');
-      opendedArr&&setDefaultExpandedKeys(opendedArr.map(item=>item.responsibilityCode));
+      const opendedArr = deepGetAllParents(res.data.list, 'child');
+      opendedArr && setDefaultExpandedKeys(opendedArr.map((item) => item.responsibilityCode));
       return {
         data: res.data.list,
         total: res.data.totalCount,
@@ -334,7 +355,7 @@ const ReportProjectSetting = () => {
     setCurrentRow(record);
 
     const resp = await getHasSetReportRelation({ reportId, relation: showAddRelation });
-    const { status, data=[] } = resp;
+    const { status, data = [] } = resp;
     if (status == 200) {
       if (showAddRelation == 1) {
         const tempArr = data.map((item) => item.code);
@@ -345,25 +366,56 @@ const ReportProjectSetting = () => {
         setSelectedKeys(tempArr);
       }
       if (showAddRelation == 3) {
-        const tempArr = data.map((item) =>item.code);
+        const tempArr = data.map((item) => item.code);
         setSelectedKeys(tempArr);
       }
     }
     setDrawerVisible(true);
   };
 
- 
+  const openRule = () => {
+    Modal.info({
+      title: '报表项目填写注意事项!',
+      width: 800,
+      content: (
+        <div>
+          <h4>计算类型说明 </h4>
+          <span>不设置:</span>
+          一般用于第一层。 对应成本科目:对应的是成本科目,如工资,收入类等
+          <div></div>
+          <span>对应责任中心:</span>
+          对应的是分摊的责任中心,放射科,功能科等
+          <div></div>
+          <span>对应分摊层级:</span>
+          对应的是分摊的层级,如“护理”分摊层级,“医技”分摊层级。
+          <div></div>
+          <span>小计:</span>
+          是对第一层下的所有项目的合计计算。
+          <div></div>
+          <span>计算公式:</span>
+          是按编号对报表项目的项目进行计算结果,支持加/减法。
+          <div style={{ marginBottom: 20 }}></div>
+          <h4>报表项目顺序注意事项</h4>
+          计算类型是小计报表项目需要维护在对应层级的其他项目之后
+          <div></div>
+          计算类型是计算公式的报表项目需要维护在公式里包含的其他项目之后
+        </div>
+      ),
+    });
+  };
 
   return (
-    <PageContainer
-      tabList={tabList}
-      onTabChange={onTabChangeHandle}
-    >
+    <PageContainer tabList={tabList} onTabChange={onTabChangeHandle}>
       <ProTable
         columns={columns}
         request={getReportProjectSetting}
         actionRef={actionRef}
         rowKey="id"
+        headerTitle={
+          <Tag style={{ cursor: 'pointer' }} onClick={openRule} color="warning">
+            注意事项
+          </Tag>
+        }
         toolBarRender={() => [
           <Button
             key="button"
@@ -380,7 +432,8 @@ const ReportProjectSetting = () => {
             type="primary"
             onClick={() => {
               setModalFormType(1);
-              setIfAddZeroLevelMenu(true);
+              setEdit(false);
+              setIfOperateZeroLevelMenu(true);
               handleModalVisible(true);
             }}
           >
@@ -394,45 +447,86 @@ const ReportProjectSetting = () => {
       />
 
       <ModalForm
-        title="新增报表项目设置"
+        title={modalFormType==2?'复制数据':edit ? '编辑报表项目设置' : '新增报表项目设置'}
         width="800px"
         labelCol={{ span: 5, offset: 3 }}
         layout={'horizontal'}
+        initialValues={edit?{...currentRow}:{}}
         modalProps={{
           destroyOnClose: true,
         }}
         visible={createModalVisible}
-        onVisibleChange={handleModalVisible}
+        onVisibleChange={(bool) => {
+          !bool && setCurrentRow(undefined);
+          handleModalVisible(bool);
+        }}
         onFinish={async (value) => {
-          if(modalFormType ==1){
-            let id = 0;
-            currentRow && (id = currentRow.id);
-            const resp = await addReportProjectSettingList({
-              ...value,
-              reportType: Number(reportType),
-              parentId: id,
-            });
-            const { status } = resp;
-            setCurrentRow(undefined);
-            if (status == 200) {
-              if (actionRef.current) {
-                actionRef.current.reload();
+          // console.log({edit,value});
+          if (modalFormType == 1) {
+            //新增数据
+           
+            if (edit) {
+              //编辑
+              const { parentId,id} = currentRow;
+              const {reportName, sort, calcType=0, calcFormula='', isLoss } = value;
+              const updateData = {
+                id,
+                parentId,
+                reportName,
+                sort,
+                reportType,
+                calcType,
+                calcFormula,
+                isLoss: isLoss ? 1 : 0,
+              };
+  
+              const resp = await editReportProjectSettingList(updateData);
+              const { status } = resp;
+
+              if (status == 200) {
+                if (actionRef.current) {
+                  actionRef.current.reload();
+                }
+                return true;
               }
-              return true;
             }
-          }
-
-          if(modalFormType == 2){
-               const {toReportType} = value;
-               const resp = await copyDataToSelectedType({fromReportType:Number(reportType),toReportType});
-               if (resp) {
+            if (!edit) {
+              //新增
+              const { calcType = 0, calcFormula = '' } = value;
+              let id = 0;
+              currentRow && (id = currentRow.id);
+              const resp = await addReportProjectSettingList({
+                ...value,
+                calcType,
+                calcFormula,
+                isLoss: value.isLoss ? 1 : 0,
+                reportType: Number(reportType),
+                parentId: id,
+              });
+              const { status } = resp;
+              if (status == 200) {
                 if (actionRef.current) {
                   actionRef.current.reload();
                 }
                 return true;
               }
+            }
+          }
+
+          if (modalFormType == 2) {
+            //复制数据
+            const { toReportType } = value;
+            const resp = await copyDataToSelectedType({
+              fromReportType: Number(reportType),
+              toReportType,
+            });
+            if (resp) {
+              if (actionRef.current) {
+                actionRef.current.reload();
+              }
+              return true;
+            }
           }
-          
         }}
       >
         {modalFormType == 1 && (
@@ -459,71 +553,104 @@ const ReportProjectSetting = () => {
               width="sm"
               name="sort"
             />
-            <ProFormSelect
-              name="calcType"
-              label="计算类型"
-              width="sm"
-              options={[
-                { label: '不设置', value: 0 },
-                { label: '对应会计科目', value: 1 },
-                { label: '对应分摊层级', value: 2 },
-                { label: '小计', value: 3 },
-                { label: '计算公式', value: 4 },
-                { label: '按责任中心', value: 5 },
-              ]}
-              placeholder="请选择状态"
-              rules={[{ required: true, message: '请选择开单科室状态!' }]}
-            />
-
-            <ProFormDependency name={['calcType']}>
-              {({ calcType }) => {
-                // const resp = await getResponsibilityCenterList({pageSize:100,current:1});
-                return calcType == 4 ? (
-                  <ProFormText
-                    label="计算公示"
-                    rules={[
-                      {
-                        required: true,
-                        message: '计算公式是必填项!',
-                      },
-                    ]}
-                    width="sm"
-                    placeholder="例如:[1] + [2]"
-                    name="calcFormula"
-                  />
-                ) : (
-                  <></>
-                );
-              }}
-            </ProFormDependency>
+            {!ifOperateZeroLevelMenu&& (
+              //编辑/新增顶级不展示
+              <>
+                <ProFormSelect
+                  name="calcType"
+                  label="计算类型"
+                  width="sm"
+                  options={[
+                    { label: '不设置', value: 0 },
+                    { label: '对应会计科目', value: 1 },
+                    { label: '对应分摊层级', value: 2 },
+                    { label: '小计', value: 3 },
+                    { label: '计算公式', value: 4 },
+                    { label: '按责任中心', value: 5 },
+                  ]}
+                  placeholder="请选择状态"
+                  rules={[{ required: true, message: '请选择开单科室状态!' }]}
+                />
+
+                <ProFormDependency name={['calcType']}>
+                  {({ calcType }) => {
+                    // const resp = await getResponsibilityCenterList({pageSize:100,current:1});
+                    return calcType == 4 ? (
+                      <ProFormText
+                        label="计算公示"
+                        rules={[
+                          {
+                            required: true,
+                            message: '计算公式是必填项!',
+                          },
+                        ]}
+                        width="sm"
+                        placeholder="例如:[1] + [2]"
+                        name="calcFormula"
+                      />
+                    ) : (
+                      <></>
+                    );
+                  }}
+                </ProFormDependency>
+                <ProFormDependency name={['calcType']}>
+                  {({ calcType }) => {
+                    // const resp = await getResponsibilityCenterList({pageSize:100,current:1});
+                    return calcType == 4 && reportType == 3 ? (
+                      <Form.Item
+                        name="isLoss"
+                        label="损益标志"
+                        valuePropName="checked"
+                      >
+                        <Switch />
+                      </Form.Item>
+                    ) : (
+                      <></>
+                    );
+                  }}
+                </ProFormDependency>
+              </>
+            )}
           </>
         )}
         {modalFormType == 2 && (
-            <ProFormSelect
-              name="toReportType"
-              label="复制到"
-              width="sm"
-              options={(()=>{
-                 const tempArr = tabList.map(item=>({label:item.tab,value:item.key}));
-                 return tempArr.filter(item=>item.value != reportType);
-              })()}
-              placeholder="请选择"
-              rules={[{ required: true, message: '请选择复制到目标!' }]}
-            />
+          <ProFormSelect
+            name="toReportType"
+            label="复制到"
+            width="sm"
+            options={(() => {
+              const tempArr = tabList.map((item) => ({ label: item.tab, value: item.key }));
+              return tempArr.filter((item) => item.value != reportType);
+            })()}
+            placeholder="请选择"
+            rules={[{ required: true, message: '请选择复制到目标!' }]}
+          />
         )}
       </ModalForm>
 
       {/* 对应设置抽屉 */}
       <DrawerContent
-        title={settingType == 1 ? '对应会计科目设置' : settingType==2?'对应分摊层级设置':'对应责任中心设置'}
-        columns={settingType == 1 ? accountingSubjectColumn : settingType==2?shareParamsColumn:responsibilityColumn} //shareParamsColumn
+        title={
+          settingType == 1
+            ? '对应会计科目设置'
+            : settingType == 2
+            ? '对应分摊层级设置'
+            : '对应责任中心设置'
+        }
+        columns={
+          settingType == 1
+            ? accountingSubjectColumn
+            : settingType == 2
+            ? shareParamsColumn
+            : responsibilityColumn
+        } //shareParamsColumn
         visible={drawerVisible}
         currentRow={currentRow}
         // tableRef = {drawerTableRef}
         defaultSelected={selectedKeys}
         expandable={{
-          childrenColumnName:settingType==1?'children':'child',
-          expandedRowKeys:defaultExpandedKeys
+          childrenColumnName: settingType == 1 ? 'children' : 'child',
+          expandedRowKeys: defaultExpandedKeys,
         }}
         pageContainerConfig={(tableRef) => {
           return {
@@ -553,14 +680,23 @@ const ReportProjectSetting = () => {
             },
           };
         }}
-        onVisibleChange={(bool) => {!bool&&setAccountType(1);setDrawerVisible(bool)}}
+        onVisibleChange={(bool) => {
+          !bool && setAccountType(1);
+          setDrawerVisible(bool);
+        }}
         renderListFunc={getTableList}
-        config={{ tableSearch: false, rowKeys: settingType == 1 ? 'accountingCode' :settingType==2?'id':'responsibilityCode' }}
+        config={{
+          tableSearch: false,
+          rowKeys:
+            settingType == 1 ? 'accountingCode' : settingType == 2 ? 'id' : 'responsibilityCode',
+        }}
         onFinishFunc={async (value, selectedRowKeys) => {
           // console.log({value,selectedRowKeys});
           let selectedRowKeysToStr = [];
           if (settingType == 2) {
-            selectedRowKeys?selectedRowKeys.map((item) => selectedRowKeysToStr.push(`${item}`)):[];
+            selectedRowKeys
+              ? selectedRowKeys.map((item) => selectedRowKeysToStr.push(`${item}`))
+              : [];
           }
           const { id: reportId } = currentRow;
           const resp = await saveReportRelation({
@@ -578,42 +714,6 @@ const ReportProjectSetting = () => {
           }
         }}
       />
-
-      {/* 更新 */}
-      <UpdateForm
-        onSubmit={async (value) => {
-          const { parentId, calcType: calcTypePrev } = currentRow;
-          const { id, reportName, sort, calcType,calcFormula } = value;
-          const updateData = {
-            id,
-            parentId,
-            reportName,
-            sort,
-            reportType,
-            calcType,
-            calcFormula
-          };
-
-          const resp = await editReportProjectSettingList(updateData);
-          const { status } = resp;
-
-          if (status == 200) {
-            handleUpdateModalVisible(false);
-            setCurrentRow(undefined);
-
-            if (actionRef.current) {
-              actionRef.current.reload();
-            }
-          }
-        }}
-        onCancel={() => {
-          handleUpdateModalVisible(false);
-          setCurrentRow(undefined);
-        }}
-        updateModalVisible={updateModalVisible}
-        updateModalVisibleChange={updateModalVisibleChange}
-        values={currentRow || {}}
-      />
     </PageContainer>
   );
 };

+ 15 - 0
src/pages/baseSetting/reportProjectSetting/updateForm.jsx

@@ -7,10 +7,13 @@ import {
   ProFormDigit
 } from '@ant-design/pro-form';
 
+import {Form,Switch} from 'antd';
+
 
 
 const UpdateForm = (props) => {
   const { updateModalVisible, updateModalVisibleChange, values, onSubmit } = props;
+  const {reportType} = values;
   return (
     <>
       {
@@ -82,6 +85,18 @@ const UpdateForm = (props) => {
             );
           }}
         </ProFormDependency>
+        <ProFormDependency name={['calcType']}>
+              {({ calcType }) => {
+                // const resp = await getResponsibilityCenterList({pageSize:100,current:1});
+                return calcType == 4&&reportType==3 ? (
+                  <Form.Item name="isLoss" label="损益标志" valuePropName='checked' initialValue={false}>
+                    <Switch  />
+                  </Form.Item>
+                ) : (
+                  <></>
+                );
+              }}
+            </ProFormDependency>
         </ModalForm>
       }
     </>

+ 11 - 1
src/pages/baseSetting/visitsAndBedDayCostSetting/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:53:18
+ * @LastEditTime: 2021-09-10 09:13:29
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -28,6 +28,7 @@ const VisitsAndBedDayCostSetting = () => {
       dataIndex: 'allocation',
       key: 'allocation',
       hideInSearch: true,
+      ellipsis: true,
       render: num => <>{num == 1 ? '按照收入比例分配' : '按照固定比例分配'}</>
     },
     {
@@ -35,6 +36,7 @@ const VisitsAndBedDayCostSetting = () => {
       dataIndex: 'incomeType',
       key: 'incomeType',
       hideInSearch: true,
+      ellipsis: true,
       render: num => <>{num == 1 ? '门诊方式' : '住院方式'}</>
     },
     {
@@ -42,24 +44,28 @@ const VisitsAndBedDayCostSetting = () => {
       dataIndex: 'incomeFileName',
       key: 'incomeFileName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '分摊参数编码',
       dataIndex: 'shareParamCode',
       key: 'shareParamCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊参数名称',
       dataIndex: 'shareParamName',
       key: 'shareParamName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本对应',
       dataIndex: 'costCorrespondingName',
       key: 'costCorrespondingName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '操作',
@@ -94,12 +100,14 @@ const VisitsAndBedDayCostSetting = () => {
       dataIndex: 'shareParamName',
       key: 'shareParamName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊参数代码',
       dataIndex: 'shareParamCode',
       key: 'shareParamCode',
       hideInSearch: true,
+      ellipsis: true,
     }
   ]
 
@@ -109,11 +117,13 @@ const VisitsAndBedDayCostSetting = () => {
       dataIndex: 'reportName',
       key: 'reportName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '编号',
       dataIndex: 'num',
       key: 'num',
+      ellipsis: true,
       hideInSearch: true,
     }
   ]

+ 3 - 1
src/pages/baseSetting/wholeHospCostAndIncomeSet/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-13 09:08:46
+ * @LastEditTime: 2021-09-10 09:13:43
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -26,6 +26,7 @@ const WholeHospCostAndIncomeSet = () => {
       dataIndex: 'paymentsType',
       key: 'paymentsType',
       hideInSearch: true,
+      ellipsis: true,
       render: num => <>{num == 1 ? '收入' : '支出'}</>
     },
     {
@@ -33,6 +34,7 @@ const WholeHospCostAndIncomeSet = () => {
       dataIndex: 'paymentsName',
       key: 'paymentsName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '操作',

+ 12 - 1
src/pages/costAccounting/afterCollectionSearch/index.jsx

@@ -2,7 +2,7 @@
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
 
- * @LastEditTime: 2021-08-31 10:46:51
+ * @LastEditTime: 2021-09-10 09:14:21
 
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
@@ -125,12 +125,14 @@ const AfterCollectionSearch = () => {
       title: '年份',
       dataIndex: 'year',
       key: 'year',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -138,53 +140,62 @@ const AfterCollectionSearch = () => {
       dataIndex: 'departmentCode',
       key: 'departmentCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '科室名称',
       dataIndex: 'departmentName',
       key: 'departmentName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心编码',
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目编码',
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目名',
       dataIndex: 'accountingName',
       key: 'accountingName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本项目编码',
       dataIndex: 'productCode',
       key: 'productCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本项目名',
       dataIndex: 'productName',
       key: 'productName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     },
   ];

+ 5 - 1
src/pages/costAccounting/afterCostShareSearch/index.jsx

@@ -2,7 +2,7 @@
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
 
- * @LastEditTime: 2021-08-31 10:43:53
+ * @LastEditTime: 2021-09-10 09:07:07
 
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
@@ -88,12 +88,14 @@ const AfterCostShareSearch = () => {
       title: '年份',
       dataIndex: 'dateYear',
       key: 'dateYear',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'dateMonth',
       key: 'dateMonth',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -101,6 +103,7 @@ const AfterCostShareSearch = () => {
       dataIndex: 'levelSort',
       key: 'levelSort',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊层级名',
@@ -141,6 +144,7 @@ const AfterCostShareSearch = () => {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     }
   ];

+ 11 - 1
src/pages/costAccounting/beforeCollectionSearch/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:54:46
+ * @LastEditTime: 2021-09-10 09:15:16
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -113,12 +113,14 @@ const BeforeCollectionSearch = () => {
       title: '年份',
       dataIndex: 'dateYear',
       key: 'dateYear',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'dateMonth',
       key: 'dateMonth',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -126,47 +128,55 @@ const BeforeCollectionSearch = () => {
       dataIndex: 'openDepartmentName',
       key: 'openDepartmentName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '开单责任中心',
       dataIndex: 'openResponsibilityCodeName',
       key: 'openResponsibilityCodeName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '执行科室',
       dataIndex: 'startDepartmentCodeName',
       key: 'startDepartmentCodeName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '执行责任中心',
       dataIndex: 'startResponsibilityCodeName',
       key: 'startResponsibilityCodeName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目',
       dataIndex: 'accountCodeName',
       key: 'accountCodeName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本项目',
       dataIndex: 'productCodeName',
       key: 'productCodeName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '文件序号',
       dataIndex: 'fileId',
       key: 'fileId',
+      ellipsis: true,
       hideInSearch: true,
     },
   ];

+ 7 - 4
src/pages/costAccounting/beforeCostShareSearch/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:50:18
+ * @LastEditTime: 2021-09-10 09:15:57
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -79,9 +79,7 @@ const BeforeCostShareSearch = () => {
       title: '会计科目(支出)',
       key: 'accountCode',
       hideInTable: true,
-      fieldProps:(form,config)=>{
-  
-      },
+      ellipsis: true,
       dataIndex: 'accountCode',
       renderFormItem: (item, { type, defaultRender,formItemProps, fieldProps, ...rest }, form) => {
         // console.log({item,type, defaultRender,formItemProps, fieldProps,rest,form })
@@ -107,12 +105,14 @@ const BeforeCostShareSearch = () => {
       title: '年份',
       dataIndex: 'year',
       key: 'year',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -161,18 +161,21 @@ const BeforeCostShareSearch = () => {
       title: '成本项目编码',
       dataIndex: 'productCode',
       key: 'productCode',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '成本项目名称',
       dataIndex: 'productName',
       key: 'productName',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     },
   ];

+ 5 - 1
src/pages/costAccounting/costShare/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 19:31:21
+ * @LastEditTime: 2021-09-10 09:16:15
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -52,18 +52,21 @@ const CostShare = () => {
       title: '年份',
       dataIndex: 'year',
       key: 'year',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -71,6 +74,7 @@ const CostShare = () => {
       dataIndex: 'isAllocation',
       key: 'isAllocation',
       hideInSearch: true,
+      ellipsis: true,
       render:bool=>bool?'已分摊':'未分摊'
     },
     {

+ 11 - 1
src/pages/costAccounting/costShareParamsHandle/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:49:29
+ * @LastEditTime: 2021-09-10 09:16:56
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -216,6 +216,7 @@ const CostShareParamsHandle = () => {
       title: 'id',
       dataIndex: 'id',
       key: 'id',
+      ellipsis: true,
       hideInSearch: true,
       hideInTable: true,
     },
@@ -223,12 +224,14 @@ const CostShareParamsHandle = () => {
       title: '年份',
       dataIndex: 'dateYear',
       key: 'dateYear',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'dateMonth',
       key: 'dateMonth',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -236,29 +239,34 @@ const CostShareParamsHandle = () => {
       dataIndex: 'shareParamCode',
       key: 'shareParamCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊参数名称',
       dataIndex: 'shareParamName',
       key: 'shareParamName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心编码',
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心名称',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '数值',
       dataIndex: 'valueNum',
       key: 'valueNum',
+      ellipsis: true,
       hideInSearch: true,
       editable: true,
     },
@@ -301,12 +309,14 @@ const CostShareParamsHandle = () => {
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: false,
+      ellipsis: true,
     },
   ];
 

+ 16 - 11
src/pages/costAccounting/costShareReportTable/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:55:35
+ * @LastEditTime: 2021-09-10 09:17:19
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -60,12 +60,14 @@ const CostShareReportTable = () => {
       title: '年份',
       dataIndex: 'year',
       key: 'year',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -73,18 +75,21 @@ const CostShareReportTable = () => {
       dataIndex: 'shareReportName',
       key: 'shareReportName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊层级',
       dataIndex: 'shareLevel',
       key: 'shareLevel',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊时间',
       dataIndex: 'shareTime',
       key: 'shareTime',
       hideInSearch: true,
+      ellipsis: true,
     },
     
     {
@@ -95,16 +100,16 @@ const CostShareReportTable = () => {
       width: '15%',
       render: (_, record) => {
         return [
-          <Button
-            key="review"
-            size='small'
-            onClick={() => {
-              setCurrentRow(record);
-              optionBtnGroupshandle('preview',record);
-            }}
-          >
-            预览
-          </Button>,
+          // <Button
+          //   key="review"
+          //   size='small'
+          //   onClick={() => {
+          //     setCurrentRow(record);
+          //     optionBtnGroupshandle('preview',record);
+          //   }}
+          // >
+          //   预览
+          // </Button>,
           <Button
             key="download"
             size='small'

+ 8 - 1
src/pages/costAccounting/departmentCostCalculate/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:55:57
+ * @LastEditTime: 2021-09-10 09:17:42
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -89,41 +89,48 @@ const DepartmentCostCalculate = () => {
       dataIndex: 'year',
       key: 'year',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '报表项目编码',
       dataIndex: 'reportNum',
       key: 'reportNum',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '报表项目名',
       dataIndex: 'reportName',
       key: 'reportName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心编码',
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     },
     

+ 4 - 1
src/pages/costAccounting/incomeCollection/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-20 16:14:33
+ * @LastEditTime: 2021-09-10 09:17:56
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -49,12 +49,14 @@ const IncomeCollection = () => {
       title: '年份',
       dataIndex: 'year',
       key: 'year',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '月份',
       dataIndex: 'month',
       key: 'month',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -62,6 +64,7 @@ const IncomeCollection = () => {
       dataIndex: 'amount',
       key: 'amount',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title:'操作',

+ 11 - 1
src/pages/costAccounting/incomeCostDataImport/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-19 15:57:26
+ * @LastEditTime: 2021-09-10 09:18:24
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -49,23 +49,27 @@ const IncomeCostDataImport = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '导入类型',
       dataIndex: 'fileType',
       key: 'fileType',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '文件名称',
       dataIndex: 'fileName',
       key: 'fileName',
+      ellipsis: true,
     },
     {
       title: '所属年月',
       dataIndex: 'dateTime',
       key: 'dateTime',
       hideInSearch: true,
+      ellipsis: true,
       render:(_,record)=>{
           return `${record.dateYear}-${record.dateMonth}`
       }
@@ -74,12 +78,14 @@ const IncomeCostDataImport = () => {
       title: '导入时间',
       dataIndex: 'dateTime',
       key: 'dateTime',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '总数',
       dataIndex: 'totalAmount',
       key: 'totalAmount',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -87,12 +93,14 @@ const IncomeCostDataImport = () => {
       dataIndex: 'successAmount',
       key: 'successAmount',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '导入人员',
       dataIndex: 'userName',
       key: 'userName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '下载',
@@ -134,12 +142,14 @@ const IncomeCostDataImport = () => {
       dataIndex: 'total',
       key: 'total',
       width:'10%',
+      ellipsis: true,
       hideInSearch: true,
      },
      {
       title: '错误信息',
       dataIndex: 'errMessage',
       key: 'errMessage',
+      ellipsis: true,
       hideInSearch: true,
      }
   ]

+ 6 - 1
src/pages/costAccounting/wholeHospCostCalculate/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:56:33
+ * @LastEditTime: 2021-09-10 09:18:59
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -61,29 +61,34 @@ const WholeHospCostCalculate = () => {
       dataIndex: 'dateYear',
       key: 'dateYear',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '月份',
       dataIndex: 'dateMonth',
       key: 'dateMonth',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '报表项目编码',
       dataIndex: 'reportNum',
       key: 'reportNum',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '报表项目名',
       dataIndex: 'reportName',
       key: 'reportName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '金额',
       dataIndex: 'amount',
       key: 'amount',
+      ellipsis: true,
       hideInSearch: true,
     },
     

+ 7 - 1
src/pages/costAccounting/wholeHospIncomeAndCost/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:51:11
+ * @LastEditTime: 2021-09-10 09:19:18
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -58,24 +58,28 @@ const WholeHospIncomeAndCost = () => {
       key: 'id',
       hideInSearch: true,
       hideInTable: true,
+      ellipsis: true,
     },
     {
       title: '年份',
       dataIndex: 'dateYear',
       key: 'dateYear',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '月份',
       dataIndex: 'dateMonth',
       key: 'dateMonth',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '收支类型',
       dataIndex: 'paymentsType',
       key: 'paymentsType',
       hideInSearch: true,
+      ellipsis: true,
       render: num => <>{num == 1 ? '收入' : '支出'}</>
     },
     {
@@ -83,12 +87,14 @@ const WholeHospIncomeAndCost = () => {
       dataIndex: 'paymentsName',
       key: 'paymentsName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '金额',
       dataIndex: 'totalAmount',
       key: 'totalAmount',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '操作',

+ 15 - 1
src/pages/costAllocationParamsConnect/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 12:20:03
+ * @LastEditTime: 2021-09-10 09:20:09
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -35,17 +35,20 @@ const CostAllocationParamsConnect = () => {
       dataIndex: 'shareLevel',
       key: 'shareLevel',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心编码',
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
+      ellipsis: true,
       hideInSearch: false,
       render:(_,record) => {
              const {isShareCost,responsibilityName} = record;
@@ -58,6 +61,7 @@ const CostAllocationParamsConnect = () => {
       key: 'accountingName',
       hideInSearch: true,
       ellipsis: true,
+      
     },
     {
       title: '会计科目编码',
@@ -70,12 +74,14 @@ const CostAllocationParamsConnect = () => {
       title: '别名',
       dataIndex: 'alias',
       key: 'alias',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '备注',
       dataIndex: 'costNode',
       key: 'costNode',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -135,18 +141,21 @@ const CostAllocationParamsConnect = () => {
       dataIndex: 'shareParamCode',
       key: 'shareParamCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '分摊参数名称',
       dataIndex: 'shareParamName',
       key: 'shareParamName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '分摊比例',
       dataIndex: 'shareParamPopout',
       key: 'shareParamPopout',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '操作',
@@ -184,12 +193,14 @@ const CostAllocationParamsConnect = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '责任中心名',
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: false,
+      ellipsis: true,
     }
   ]
 
@@ -199,12 +210,14 @@ const CostAllocationParamsConnect = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '会计科目名名',
       dataIndex: 'accountingName',
       key: 'accountingName',
       hideInSearch: false,
+      ellipsis: true,
     }
   ]
 
@@ -261,6 +274,7 @@ const CostAllocationParamsConnect = () => {
 
   //获取科室列表
   const getList = async (params = {}, sort, filter) => {
+
     const res = await getCostshareparamConnectList(params);
     return {
       data: res.data.list,

+ 4 - 3
src/pages/costAllocationParamsConnect/service.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 08:54:08
- * @LastEditTime: 2021-08-17 08:55:57
+ * @LastEditTime: 2021-09-03 09:09:45
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/DepartmentMana/service.js
@@ -12,11 +12,12 @@ import { request } from 'umi';
 
 //获取列表
 export async function getCostshareparamConnectList(params, options) {
-    const {shareParamName,current,pageSize} = params;
+    const {responsibilityName,current,pageSize} = params;
+    console.log({params});
     return request('/api/costAccount/costaccountshare/list', {
       method: 'GET',
       params:{
-          name:shareParamName,
+          name:responsibilityName,
           current,
           pageSize
       },

+ 6 - 1
src/pages/costAllocationParamsSetting/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:57:21
+ * @LastEditTime: 2021-09-10 09:20:52
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -29,18 +29,21 @@ const CostAllocationParamsSetting = () => {
       dataIndex: 'shareParamName',
       key: 'shareParamName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '成本分摊参数编号',
       dataIndex: 'shareParamCode',
       key: 'shareParamCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '计算方式',
       dataIndex: 'calcType',
       key: 'calcType',
       hideInSearch: true,
+      ellipsis: true,
       render: (text) => <>{text == 1 ? '手动填写' : '按对应会计科目计算'}</>,
     },
     {
@@ -91,12 +94,14 @@ const CostAllocationParamsSetting = () => {
       dataIndex: 'accountingCode',
       key: 'accountingCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '会计科目名称',
       dataIndex: 'accountingName',
       key: 'accountingName',
       hideInSearch: false,
+      ellipsis: true,
     }
   ];
 

+ 6 - 2
src/pages/costProjectMana/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-30 15:57:46
+ * @LastEditTime: 2021-09-10 09:21:09
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -30,18 +30,21 @@ const CostProjectMana = () => {
       key: 'id',
       hideInTable: true,
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本编号',
       dataIndex: 'productCode',
       key: 'productCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '成本项目名',
       dataIndex: 'productName',
       key: 'productName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title:'操作',
@@ -152,10 +155,11 @@ const CostProjectMana = () => {
             新增
           </Button>,
           <CAUpload
-            templateHref={'/costAccount/excel/getImportProductTemplate'}
+            templateHrefs={'/costAccount/excel/getImportProductTemplate'}
             url='/costAccount/excel/importProduct'
             importSuccessCallback={() => { }}
             token={token}
+            type='normal'
             customRequestCallback={customRequestCallback}
           />
         ]}

+ 8 - 1
src/pages/platformMana/districtMana/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:55:45
+ * @LastEditTime: 2021-09-10 09:21:56
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -24,12 +24,14 @@ const DistrictMana = () => {
       title: '医院/院区ID',
       dataIndex: 'id',
       key: 'id',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '医院名称',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
       hideInSearch: false,
     },
     {
@@ -37,30 +39,35 @@ const DistrictMana = () => {
       dataIndex: 'isHospital',
       key: 'isHospital',
       hideInSearch: true,
+      ellipsis: true,
       render: (text) => <a>{text == 0 ? '是' : '否'}</a>,
     },
     {
       title: '医院标识',
       dataIndex: 'sign',
       key: 'sign',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '医院Id',
       dataIndex: 'parentId',
       key: 'parentId',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '主医院名',
       dataIndex: 'parentName',
       key: 'parentName',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: '创建时间',
       dataIndex: 'createDateTime',
       key: 'createDateTime',
+      ellipsis: true,
       hideInSearch: true,
     },
     {

+ 7 - 1
src/pages/platformMana/menuManage/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-27 11:48:00
+ * @LastEditTime: 2021-09-10 09:22:16
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -24,23 +24,27 @@ const UserMana = () => {
       title: '菜单名称',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
     },
     {
       title: '菜单Id',
       dataIndex: 'menuId',
       key: 'menuId',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: 'URL',
       dataIndex: 'url',
       key: 'url',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
       title: 'Path',
       dataIndex: 'path',
       key: 'path',
+      ellipsis: true,
       hideInSearch: true,
     },
     {
@@ -48,12 +52,14 @@ const UserMana = () => {
       dataIndex: 'modifyUserName',
       key: 'modifyUserName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '变更日期',
       dataIndex: 'modifyTime',
       key: 'modifyTime',
       valueType: 'date',
+      ellipsis: true,
       hideInSearch: true,
     },
     {

+ 10 - 1
src/pages/platformMana/roleManage/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:56:39
+ * @LastEditTime: 2021-09-10 09:22:49
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -30,17 +30,20 @@ const UserMana = () => {
       title: '角色名',
       dataIndex: 'roleName',
       key: 'roleName',
+      ellipsis: true,
     },
     {
       title: '变更人',
       dataIndex: 'modifyUserName',
       key: 'modifyUserName',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '变更日期',
       dataIndex: 'modifyTime',
       key: 'modifyTime',
+      ellipsis: true,
       renderFormItem: (item, { type, defaultRender, formItemProps, fieldProps, ...rest }, form) => {
 
         if (type === 'form') {
@@ -102,23 +105,27 @@ const UserMana = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '姓名',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
     },
     {
       title: '用户名',
       dataIndex: 'account',
       key: 'account',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '在职状态',
       dataIndex: 'hospitalStatus',
       key: 'hospitalStatus',
       hideInSearch: true,
+      ellipsis: true,
       render:num=><>{num==0?'离职':'在职'}</>
     },
   ];
@@ -129,11 +136,13 @@ const UserMana = () => {
       dataIndex: 'menuId',
       key: 'menuId',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '菜单名称',
       dataIndex: 'name',
       key: 'name',
+      ellipsis: true,
     }
   ];
 

+ 217 - 0
src/pages/reportTableExport/departmentOperatingReport/index.jsx

@@ -0,0 +1,217 @@
+/*
+ * @Author: your name
+ * @Date: 2021-07-26 10:13:13
+ * @LastEditTime: 2021-09-10 09:23:15
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
+ */
+
+// import { PlusOutlined } from '@ant-design/icons';
+import { Form, Button } from 'antd';
+import React, { useRef, useState, useEffect } from 'react';
+import { PageContainer } from '@ant-design/pro-layout';
+import ProTable from '@ant-design/pro-table';
+import {
+  ProFormDatePicker,
+} from '@ant-design/pro-form';
+import { getDepartmentOperatingReportList,generateDepartmentOperatingReportList } from './service';
+
+import moment from 'moment';
+import 'moment/locale/zh-cn';
+import locale from 'antd/es/date-picker/locale/zh_CN';
+
+
+import {envConfig} from '../../../../config/defaultSettings';
+
+
+const {host} = envConfig;
+const Host = host;
+
+
+const CostShareReportTable = () => {
+
+  const [currentTime, setCurrentTime] = useState(moment(new Date()).subtract(1, 'months').format('YYYY-MM'));
+
+  const columns = [
+    {
+      title: '选择年月',
+      key: 'date',
+      hideInTable: true,
+      dataIndex: 'date',
+      renderFormItem: (item, { type, defaultRender, formItemProps, fieldProps, ...rest }, form) => {
+
+        if (type === 'form') {
+          return null;
+        }
+        return (
+          <Form.Item >
+            <ProFormDatePicker 
+              initialValue={moment(new Date()).subtract(1, 'months').format('YYYY-MM')}
+              fieldProps={{
+                picker: 'month', format: (value) => { return value.format('YYYY-MM') }, locale: locale,
+                onChange: (val) => { console.log({ val }); setCurrentTime(val) }
+              }}
+              name="date" />
+          </Form.Item>
+        )
+      },
+    },
+    {
+      title: '年份',
+      dataIndex: 'dateYear',
+      key: 'dateYear',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '月份',
+      dataIndex: 'dateMonth',
+      key: 'dateMonth',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '报表类型',
+      dataIndex: 'fileType',
+      key: 'fileType',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '报表名称',
+      dataIndex: 'fileName',
+      key: 'fileName',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '更新时间',
+      dataIndex: 'updateTime',
+      key: 'updateTime',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    
+    {
+      title: '操作',
+      dataIndex: 'option',
+      valueType: 'option',
+      key: 'option',
+      width: '15%',
+      render: (_, record) => {
+        return [
+          // <Button
+          //   key="review"
+          //   size='small'
+          //   onClick={() => {
+          //     setCurrentRow(record);
+          //     optionBtnGroupshandle('preview',record);
+          //   }}
+          // >
+          //   预览
+          // </Button>,
+          <Button
+            key="download"
+            size='small'
+            onClick={() => {
+              setCurrentRow(record);
+              optionBtnGroupshandle('download',record);
+            }}
+          >
+            下载
+          </Button>
+        ]
+      },
+    },
+  ];
+
+
+  const actionRef = useRef();
+  const [currentRow, setCurrentRow] = useState(undefined);
+
+  //获取列表
+  const getList = async (params = {}, sort, filter) => {
+    const {pageSize, current,date } = params;
+      const tempResp = await getDepartmentOperatingReportList({pageSize, current,date: moment(currentTime).format('YYYY-MM-DD')});
+      const {status,data:{list=[],totalCount},success} = tempResp;
+      if(status){
+        return {
+          data: list,
+          total: totalCount,
+          success: success,
+        };
+      }
+  };
+
+  
+  const generateReport = async ()=>{
+        //reportType 暂时传0
+        await generateDepartmentOperatingReportList({date: moment(currentTime).format('YYYY-MM-DD'),reportType:0 });
+        actionRef?.current?.reload();
+  }
+
+  /**
+   * 
+   * @param {String} type 操作类型
+   * @param {Object} record 
+   */
+  const optionBtnGroupshandle = async (type, record) => {
+    const userData = localStorage.getItem('userData');
+    const {shareLevel,shareLevelId} = record;
+    let tokenVal='';
+    if (userData) {
+      const { token } = JSON.parse(userData);
+      tokenVal = token
+    }
+    const url = `${Host}/costAccount/excel/getDepartmentProfit?token=${tokenVal}&date=${currentTime.format('YYYY-MM-DD')}`;
+    if(type=='download'){
+      // const resp = await getExcelDownloadLink({ year: currentTime.format('YYYY'), month: currentTime.format('MM'),token:tokenVal,levelSort:shareLevel });
+      window.open(url);
+    }
+    if(type=='preview'){
+      // const resp = await getExcelDownloadLink({ year: currentTime.format('YYYY'), month: currentTime.format('MM'),token:tokenVal,levelSort:shareLevel });
+      window.open(`http://view.xdocin.com/xdoc?_xdoc=${url}`);
+    }
+  }
+
+
+
+
+
+  return (
+    <PageContainer>
+      <ProTable
+        columns={columns}
+        request={getList}
+        actionRef={actionRef}
+        rowKey="id"
+        toolBarRender={() => [
+           <Button key='generate' type='primary' onClick={generateReport}>生成报表</Button>
+        ]}
+
+        pagination={{
+          pageSize: 10,
+        }}
+        search={{
+          defaultCollapsed: false,
+          labelWidth: 'auto',
+          optionRender:(searchConfig,formProps,dom)=>{
+    
+              return dom.map(item=>{
+                   if(item.key == 'rest'){
+                        return <Button key='resetBtn' onClick={()=>{
+                          setCurrentTime(moment(new Date()).subtract(1, 'months').format('YYYY-MM'));
+                          actionRef.current.reset();
+                        }}>重置</Button>
+                   }
+                   return item;
+              })
+          }
+        }}
+      />
+    </PageContainer>
+  );
+};
+
+export default CostShareReportTable;

+ 35 - 0
src/pages/reportTableExport/departmentOperatingReport/service.js

@@ -0,0 +1,35 @@
+/*
+ * @Author: your name
+ * @Date: 2021-07-26 08:54:08
+ * @LastEditTime: 2021-09-01 18:29:09
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /TracerMethodology_PC/src/pages/DepartmentMana/service.js
+ */
+
+import { request } from 'umi';
+
+
+//获取 科室经营表列表
+export async function getDepartmentOperatingReportList(params, options) {
+    return request('/api/costAccount/departmentprofitfile/list', {
+      method: 'GET',
+      params:{...params},
+      ...(options || {}),
+    });
+}
+
+
+
+//生成 科室经营表列表
+export async function generateDepartmentOperatingReportList(params, options) {
+  return request('/api/costAccount/costdepartmentprofit/getDepartProfitReport', {
+    method: 'POST',
+    params:{...params},
+    ...(options || {}),
+  });
+}
+
+
+
+

+ 209 - 0
src/pages/reportTableExport/wholeHospOperatingReport/index.jsx

@@ -0,0 +1,209 @@
+/*
+ * @Author: your name
+ * @Date: 2021-07-26 10:13:13
+ * @LastEditTime: 2021-09-10 09:23:32
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
+ */
+
+// import { PlusOutlined } from '@ant-design/icons';
+import { Form, Button } from 'antd';
+import React, { useRef, useState, useEffect } from 'react';
+import { PageContainer } from '@ant-design/pro-layout';
+import ProTable from '@ant-design/pro-table';
+import {
+  ProFormDatePicker,
+} from '@ant-design/pro-form';
+import { getWholeHospOperatingReportList,generateWholeHospOperatingReportList } from './service';
+
+import moment from 'moment';
+import 'moment/locale/zh-cn';
+import locale from 'antd/es/date-picker/locale/zh_CN';
+
+
+import {envConfig} from '../../../../config/defaultSettings';
+
+const {host} = envConfig;
+const Host = host;
+
+
+const CostShareReportTable = () => {
+
+  const [currentTime, setCurrentTime] = useState(moment(new Date()).subtract(1, 'months').format('YYYY-MM'));
+
+  const columns = [
+    {
+      title: '选择年月',
+      key: 'date',
+      hideInTable: true,
+      dataIndex: 'date',
+      renderFormItem: (item, { type, defaultRender, formItemProps, fieldProps, ...rest }, form) => {
+
+        if (type === 'form') {
+          return null;
+        }
+        return (
+          <Form.Item >
+            <ProFormDatePicker 
+              initialValue={moment(new Date()).subtract(1, 'months').format('YYYY-MM')}
+              fieldProps={{
+                picker: 'month', format: (value) => { return value.format('YYYY-MM') }, locale: locale,
+                onChange: (val) => { console.log({ val }); setCurrentTime(val) }
+              }}
+              name="date" />
+          </Form.Item>
+        )
+      },
+    },
+    {
+      title: '年份',
+      dataIndex: 'dateYear',
+      key: 'dateYear',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '月份',
+      dataIndex: 'dateMonth',
+      key: 'dateMonth',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '报表类型',
+      dataIndex: 'fileType',
+      key: 'fileType',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+    {
+      title: '报表名称',
+      dataIndex: 'fileName',
+      key: 'fileName',
+      hideInSearch: true,
+      ellipsis: true,
+    },
+
+    
+    {
+      title: '操作',
+      dataIndex: 'option',
+      valueType: 'option',
+      key: 'option',
+      width: '15%',
+      render: (_, record) => {
+        return [
+          // <Button
+          //   key="review"
+          //   size='small'
+          //   onClick={() => {
+          //     setCurrentRow(record);
+          //     optionBtnGroupshandle('preview',record);
+          //   }}
+          // >
+          //   预览
+          // </Button>,
+          <Button
+            key="download"
+            size='small'
+            onClick={() => {
+              setCurrentRow(record);
+              optionBtnGroupshandle('download',record);
+            }}
+          >
+            下载
+          </Button>
+        ]
+      },
+    },
+  ];
+
+
+  const actionRef = useRef();
+  const [currentRow, setCurrentRow] = useState(undefined);
+
+  //获取列表
+  const getList = async (params = {}, sort, filter) => {
+    const { date, pageSize, current } = params;
+    const tempResp = await getWholeHospOperatingReportList({pageSize, current,date: moment(date).format('YYYY-MM-DD') })
+      if(tempResp.status){
+        return {
+          data: tempResp.data.list,
+          total: tempResp.data.totalCount,
+          success: tempResp.success,
+        };
+      }
+
+  };
+
+  const generateReport = async ()=>{
+    //reportType 暂时传0
+    await generateWholeHospOperatingReportList({date: moment(currentTime).format('YYYY-MM-DD'),reportType:0 });
+    actionRef?.current?.reload();
+}
+
+  /**
+   * 
+   * @param {String} type 操作类型
+   * @param {Object} record 
+   */
+  const optionBtnGroupshandle = async (type, record) => {
+    const userData = localStorage.getItem('userData');
+    const {fileUrl} = record;
+    let tokenVal='';
+    if (userData) {
+      const { token } = JSON.parse(userData);
+      tokenVal = token
+    }
+    const url = fileUrl;
+    if(type=='download'){
+      // const resp = await getExcelDownloadLink({ year: currentTime.format('YYYY'), month: currentTime.format('MM'),token:tokenVal,levelSort:shareLevel });
+      window.open(url);
+    }
+    if(type=='preview'){
+      // const resp = await getExcelDownloadLink({ year: currentTime.format('YYYY'), month: currentTime.format('MM'),token:tokenVal,levelSort:shareLevel });
+      window.open(`http://view.xdocin.com/xdoc?_xdoc=${url}`);
+    }
+  }
+
+
+
+
+
+  return (
+    <PageContainer>
+      <ProTable
+        columns={columns}
+        request={getList}
+        actionRef={actionRef}
+        rowKey="id"
+        toolBarRender={() => [
+          <Button key='generate' type='primary' onClick={generateReport}>生成报表</Button>
+        ]}
+
+        pagination={{
+          pageSize: 10,
+        }}
+        search={{
+          defaultCollapsed: false,
+          labelWidth: 'auto',
+          optionRender:(searchConfig,formProps,dom)=>{
+    
+            return dom.map(item=>{
+                 if(item.key == 'rest'){
+                      return <Button key='resetBtn' onClick={()=>{
+                        setCurrentTime(moment(new Date()).subtract(1, 'months').format('YYYY-MM'));
+                        actionRef.current.reset();
+                      }}>重置</Button>
+                 }
+                 return item;
+            })
+        }
+        }}
+      />
+    </PageContainer>
+  );
+};
+
+export default CostShareReportTable;

+ 35 - 0
src/pages/reportTableExport/wholeHospOperatingReport/service.js

@@ -0,0 +1,35 @@
+/*
+ * @Author: your name
+ * @Date: 2021-07-26 08:54:08
+ * @LastEditTime: 2021-09-01 17:56:18
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /TracerMethodology_PC/src/pages/DepartmentMana/service.js
+ */
+
+import { request } from 'umi';
+
+
+//获取 全院经营表列表
+export async function getWholeHospOperatingReportList(params, options) {
+  return request('/api/costAccount/hospProfitAndLoss/hospReports', {
+    method: 'GET',
+    params:{...params},
+    ...(options || {}),
+  });
+}
+
+
+//生成 全院经营表列表
+export async function generateWholeHospOperatingReportList(params, options) {
+    return request('/api/costAccount/hospProfitAndLoss/report', {
+      method: 'POST',
+      params:{...params},
+      ...(options || {}),
+    });
+}
+
+
+
+
+

+ 10 - 4
src/pages/responsibilityCenter/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:57:18
+ * @LastEditTime: 2021-09-10 09:24:03
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -28,6 +28,7 @@ const responsibilityCenter = () => {
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: false,
+      ellipsis: true,
       width: '15%',
       render: (_, record) => {
         const { isDefault, responsibilityName } = record;
@@ -39,6 +40,7 @@ const responsibilityCenter = () => {
       dataIndex: 'responsibilityCode',
       key: 'responsibilityCode',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '是否汇总中心',
@@ -46,7 +48,8 @@ const responsibilityCenter = () => {
       key: 'isGatherCenter',
       hideInSearch: true,
       render: (text) => <>{text == 1 ? '是' : '否'}</>,
-      width: '15%'
+      width: '15%',
+      ellipsis: true,
     },
     {
       title: '责任类型',
@@ -54,6 +57,7 @@ const responsibilityCenter = () => {
       key: 'responsibilityType',
       hideInSearch: true,
       width: '15%',
+      ellipsis: true,
       render: (text) => <>{text == 1 ? '收益中心' : '成本(费用)中心'}</>,
     },
     {
@@ -61,14 +65,16 @@ const responsibilityCenter = () => {
       dataIndex: 'shareLevel',
       key: 'shareLevel',
       hideInSearch: true,
-      width: '10%'
+      width: '10%',
+      ellipsis: true,
     },
     {
       title: '分摊级别名称',
       dataIndex: 'shareName',
       key: 'shareName',
       hideInSearch: true,
-      width: '15%'
+      width: '15%',
+      ellipsis: true,
     },
     {
       title: '操作',

+ 9 - 3
src/pages/responsibilityCenterConnect/index.jsx

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-08-28 10:58:53
+ * @LastEditTime: 2021-09-10 09:24:25
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -24,20 +24,23 @@ const ResponsibilityCenterConnect = () => {
       dataIndex: 'responsibilityName',
       key: 'responsibilityName',
       hideInSearch: false,
-      width: '20%'
+      width: '20%',
+      ellipsis: true,
     },
     {
       title: '责任中心Id',
       dataIndex: 'responsibilityId',
       key: 'responsibilityId',
       hideInSearch: true,
-      width: '20%'
+      width: '20%',
+      ellipsis: true,
     },
     {
       title: '部门列表',
       dataIndex: 'departments',
       key: 'departments',
       hideInSearch: false,
+      ellipsis: true,
       render: (departments) => {
 
         if (Array.isArray(departments)) {
@@ -76,18 +79,21 @@ const ResponsibilityCenterConnect = () => {
       dataIndex: 'id',
       key: 'id',
       hideInSearch: true,
+      ellipsis: true,
     },
     {
       title: '科室名称',
       dataIndex: 'departmentName',
       key: 'departmentName',
       hideInSearch: false,
+      ellipsis: true,
     },
     {
       title: '科室编码',
       dataIndex: 'departmentCode',
       key: 'departmentCode',
       hideInSearch: true,
+      ellipsis: true,
     },
 
   ];

+ 1 - 1
src/projectConstant.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-08-25 10:48:32
- * @LastEditTime: 2021-08-25 10:51:13
+ * @LastEditTime: 2021-09-01 15:28:41
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /CostAccountManaSys/config/projectConstant.js