lanjianrong 3 yıl önce
ebeveyn
işleme
afd365d3a4

+ 1 - 1
src/pages/Institutions/Company/Detail/index.tsx

@@ -3,7 +3,7 @@ import React, { useState, useRef, useLayoutEffect } from 'react'
 import { Menu } from 'antd'
 import Staff from './components/Staff'
 import Organization from './components/Organization'
-import Role from './components/Role'
+// import Role from './components/Role'
 import styles from './style.less'
 import type { RouteComponentProps } from 'react-router'
 import { PageContainer } from '@ant-design/pro-layout'

+ 8 - 10
src/pages/Institutions/Company/List/index.tsx

@@ -68,8 +68,7 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
       render: (name, record) => (
         <span
           onClick={() => goToDetail({ dataID: record.ID, structureType: state.structureType })}
-          className="text-primary cursor-pointer"
-        >
+          className="text-primary cursor-pointer">
           {name}
         </span>
       )
@@ -119,8 +118,7 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
                 currentModalType: ModalType.UPDATE,
                 defaultFormData: record
               })
-            }}
-          >
+            }}>
             编辑
           </div>
           {/* <Popconfirm
@@ -147,7 +145,7 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
         scroll={{ y: document.body.clientHeight - 313 }}
         columns={generateColumns(columns, schema)}
         request={async (params, filter, sorter) => {
-          const { code = -1, data: { items = [], totle = 0 } = {} } = await queryInstitutionList({
+          const { code = -1, data: { items = [], total = 0 } = {} } = await queryInstitutionList({
             ...params,
             ...filter,
             ...sorter
@@ -155,7 +153,7 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
           return {
             data: items,
             success: code === consts.RET_CODE.SUCCESS,
-            totle
+            total
           }
         }}
         toolbar={{
@@ -165,8 +163,9 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
           actions: [
             <Button
               type="primary"
-              onClick={() => setState({ ...state, visible: true, currentModalType: ModalType.ADD })}
-            >
+              onClick={() =>
+                setState({ ...state, visible: true, currentModalType: ModalType.ADD })
+              }>
               新建企事业单位
             </Button>
           ]
@@ -175,8 +174,7 @@ const CompanyList: React.FC<ListProps> = ({ base, dispatch, pTypeList }) => {
       />
       <AnimateContent
         visible={state.visible}
-        onVisibleChange={visible => setState({ ...state, visible })}
-      >
+        onVisibleChange={visible => setState({ ...state, visible })}>
         <CompanyDrawer
           type={state.currentModalType}
           defaultFormData={state.defaultFormData}

+ 2 - 2
src/pages/Institutions/Staff/index.tsx

@@ -182,7 +182,7 @@ const CompanyList: React.FC<ListProps> = ({ schema, dispatch, accountTypeList })
         scroll={{ y: document.body.clientHeight - 313 }}
         columns={generateColumns(columns, schema)}
         request={async (params, filter, sorter) => {
-          const { code = -1, data: { items = [], totle = 0 } = {} } = await queryAcountList({
+          const { code = -1, data: { items = [], total = 0 } = {} } = await queryAcountList({
             ...params,
             ...filter,
             ...sorter
@@ -190,7 +190,7 @@ const CompanyList: React.FC<ListProps> = ({ schema, dispatch, accountTypeList })
           return {
             data: items,
             success: code === consts.RET_CODE.SUCCESS,
-            totle
+            total
           }
         }}
         toolbar={{

+ 2 - 2
src/pages/Project/Management/index.tsx

@@ -154,7 +154,7 @@ const List: React.FC<ListProps> = ({ schema, dispatch, pTypeList }) => {
         scroll={{ y: document.body.clientHeight - 313 }}
         columns={generateColumns(columns, schema)}
         request={async (params, filter, sorter) => {
-          const { code = -1, data: { items = [], totle = 0 } = {} } = await getProjectList({
+          const { code = -1, data: { items = [], total = 0 } = {} } = await getProjectList({
             ...params,
             ...filter,
             ...sorter
@@ -162,7 +162,7 @@ const List: React.FC<ListProps> = ({ schema, dispatch, pTypeList }) => {
           return {
             data: items,
             success: code === consts.RET_CODE.SUCCESS,
-            totle
+            total
           }
         }}
         toolbar={{