فهرست منبع

Merge remote-tracking branch 'origin/dev' into dev

# Conflicts:
#	src/components/DataManager/index.js
zhouna 3 سال پیش
والد
کامیت
d11f76e7bc

+ 5 - 5
src/components/DataManager/index.js

@@ -38,7 +38,7 @@ function DataManager() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size
   }
   const showModal = (flag, id) => {
     setaddVisible(true)
@@ -117,7 +117,8 @@ function DataManager() {
             roles[i].push(item.id)
           })
             //遍历出权限范围数据,已选中的数据遍历出来
-          arr.softwareVOS[i].dataAuthDetails && arr.softwareVOS[i].dataAuthDetails.depts && arr.softwareVOS[i].dataAuthDetails.depts.forEach(item => {
+          const authDetails = arr.softwareVOS[i].dataAuthDetails
+          authDetails && authDetails.depts && authDetails.depts.forEach(item => {
             dataAuthDetails[i].push({
               dataType: 7,
               detailId: item.hospitalId,
@@ -131,7 +132,7 @@ function DataManager() {
               //科室树形结构选中的id
             softwareMenuIds[i].push(item.hospitalId + '-' + item.id + '-' + item.name)
           })
-          arr.softwareVOS[i].dataAuthDetails && arr.softwareVOS[i].dataAuthDetails.doctors && arr.softwareVOS[i].dataAuthDetails.doctors.forEach(item => {
+          authDetails && authDetails.doctors && authDetails.doctors.forEach(item => {
             dataAuthDetails[i].push({
               dataType: 7,
               detailId: item.id,
@@ -144,7 +145,7 @@ function DataManager() {
             })
             selectedRowKeys[i].push(item.id + '-' + item.name)
           })
-          arr.softwareVOS[i].dataAuthDetails && arr.softwareVOS[i].dataAuthDetails.hospitals && arr.softwareVOS[i].dataAuthDetails.hospitals.forEach(item => {
+          authDetails && authDetails.hospitals && authDetails.hospitals.forEach(item => {
             dataAuthDetails[i].push({
               dataType: 7,
               detailId: item.id,
@@ -161,7 +162,6 @@ function DataManager() {
           arr.softwareVOS[i].dataAuthDetails = dataAuthDetails[i] && dataAuthDetails[i].length > 0 ? dataAuthDetails[i] : [{ dataType: it.dataType }]
           arr.softwareVOS[i].selectedRowKeys = selectedRowKeys[i]
           arr.softwareVOS[i].softwareMenuIds = softwareMenuIds[i]
-
           if (arr.softwareVOS[i].dataAuthDetails && arr.softwareVOS[i].dataAuthDetails.length > 0) {
             arr.softwareVOS[i].datatype = JSON.stringify(arr.softwareVOS[i].dataAuthDetails[0].dataType)
             val[i] = arr.softwareVOS[i].dataAuthDetails[0].dataType

+ 4 - 20
src/components/ExceptionLog/index.js

@@ -8,8 +8,6 @@ const { Option } = Select;
 function ExceptionLog() {
   useEffect(() => {
     getAbnormalLog();
-    console.log(123);
-
   }, []);
   const [logList, setLogList] = useState([]);
   const [total, setTotal] = useState(0);
@@ -28,15 +26,13 @@ function ExceptionLog() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size,
   }
   //表格数据
   function getAbnormalLog(param) {
     post(api.getAbnormalLog, param || params).then((res) => {
       if (res.data.code === 200) {
         const data = res.data.data;
-        console.log(data);
-
         setLogList(data.records);
         setTotal(data.total)
       }
@@ -58,9 +54,9 @@ function ExceptionLog() {
     setParams(params)
     getAbnormalLog()
   }
-  function showModal(operationWay) {
+  function showModal(operationErrorInfo) {
     setMsvisible(true)
-    getAbnormalLogWayAndIp(operationWay)
+    setTipText(operationErrorInfo)
   }
   function handleOk() {
     setMsvisible(false)
@@ -68,18 +64,6 @@ function ExceptionLog() {
   function handleCancel() {
     setMsvisible(false)
   }
-  function getAbnormalLogWayAndIp(operationWay) {
-    let params = {
-      mark:0,
-      operationWay: operationWay
-    }
-    post(api.getAbnormalLogWayAndIp, params).then((res) => {
-      if (res.data.code === 200) {
-        const data = res.data.data;
-        setTipText(data)
-      }
-    })
-  }
   const onFinish = (value) => {
     const param = {
       ...data,
@@ -114,7 +98,7 @@ function ExceptionLog() {
     {
       title: '操作', dataIndex: 'key', render: (text, record) => (
         <Space size="middle">
-          <a onClick={e => showModal(record.operationWay)}>查看</a>
+          <a onClick={e => showModal(record.operationErrorInfo)}>查看</a>
         </Space>
       )
     }

+ 1 - 1
src/components/InpaManager/index.js

@@ -40,7 +40,7 @@ function InpaManager() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size
   }
   const tipText = {
     1: '确定要删除该病区?',

+ 1 - 1
src/components/LoginLog/index.js

@@ -25,7 +25,7 @@ function LoginLog() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size
   }
   //表格数据
   function getLoginLog(param) {

+ 1 - 1
src/components/OperationLog/index.js

@@ -25,7 +25,7 @@ function OperationLog() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size
   }
   //表格数据
   function getOperationLog(param) {

+ 1 - 1
src/components/RoleManager/index.js

@@ -46,7 +46,7 @@ function RoleManager(){
     let data = {
         pages: 1,
         current: 1,
-        size: 15
+        size: size
     }
     //获取表格数据
     function getTableData(param){

+ 1 - 1
src/components/UserManager/index.js

@@ -45,7 +45,7 @@ function UserManager() {
   let data = {
     pages: 1,
     current: 1,
-    size: 15
+    size: size
   }
   const { statusList } = staticInfo;
   //新增弹窗

+ 8 - 3
src/index.js

@@ -5,15 +5,20 @@ import App from './App';
 import { Provider } from 'react-redux'
 import configureStore from './store/reducerExtras/configureStore'
 import utils from '@api/index';
+import { ConfigProvider } from 'antd'
+import zhCN from 'antd/lib/locale/zh_CN';
+
 
 const { interceptors } = utils;
 const store = configureStore();
 interceptors();       //拦截所有请求,401跳登录
 const renderApp = () =>
     render(
-        <Provider store={store}>
-            <App />
-        </Provider>,
+        <ConfigProvider locale={zhCN} >
+            <Provider store={store}>
+                <App />
+            </Provider>
+        </ConfigProvider>,
         document.getElementById('root')
     )