Sfoglia il codice sorgente

优化布局样式

zl 4 anni fa
parent
commit
16d4a3730c

+ 5 - 3
src/pages/openplatform/components/FontManage/index.js

@@ -1,5 +1,5 @@
 import React, { Component } from 'react'
-import { Modal, Button, Checkbox, Spin, message } from 'antd'
+import { Row, Modal, Button, Checkbox, Spin, message } from 'antd'
 import { connect } from 'dva'
 
 @connect(({ loading }) => ({
@@ -65,7 +65,7 @@ class FontManage extends Component {
     }
   }
 
-  render() {
+  render () {
     const { list } = this.state
 
     const checkChange = (e, i) => {
@@ -92,7 +92,9 @@ class FontManage extends Component {
           <Spin spinning={this.props.getLoading}>
             {
               list.map((item, i) => (
-                <Checkbox onChange={(e) => checkChange(e, i)} key={item.key} checked={item.value} value={item.key}>{item.key}</Checkbox>
+                <Row style={{ width: '31%', float: 'left' }} >
+                  <Checkbox onChange={(e) => checkChange(e, i)} key={item.key} checked={item.value} value={item.key}>{item.key}</Checkbox>
+                </Row>
               ))
             }
           </Spin>

+ 1 - 0
src/pages/openplatform/datacore/sublist/structure.js

@@ -18,6 +18,7 @@ export default {
       {
         align: 'center',
         title: '订阅ID',
+        width: 70,
         dataIndex: 'subId'
       },
       {

+ 17 - 16
src/pages/openplatform/datacore/subscribeList/index.js

@@ -184,7 +184,7 @@ const Index = props => {
 
   const tableSetting = {
     getRefresh: refresh => {
-      refreshPage = refresh;
+      refreshPage = refresh
     },
     rowKey: 'id',
     defaultExpandAllRows: true,
@@ -194,23 +194,24 @@ const Index = props => {
       {
         align: 'center',
         title: 'ID',
-        dataIndex: 'id',
+        width: 70,
+        dataIndex: 'id'
       },
       {
         align: 'center',
         title: '名称',
-        dataIndex: 'name',
+        dataIndex: 'name'
       },
       {
         align: 'center',
         title: '描述',
-        dataIndex: 'description',
+        dataIndex: 'description'
       },
       {
         align: 'center',
         title: '场景',
         dataIndex: 'scene',
-        textLength: 20,
+        textLength: 20
       },
       {
         align: 'center',
@@ -218,11 +219,11 @@ const Index = props => {
         dataIndex: 'state',
         render: text => {
           if (text === 1) {
-            return <Tag color="green">启用</Tag>;
+            return <Tag color="green">启用</Tag>
           } else {
-            return <Tag color="red">禁用</Tag>;
+            return <Tag color="red">禁用</Tag>
           }
-        },
+        }
       },
       {
         align: 'center',
@@ -230,25 +231,25 @@ const Index = props => {
         dataIndex: 'is_show',
         render: text => {
           if (text === 1) {
-            return <Tag color="green">显示</Tag>;
+            return <Tag color="green">显示</Tag>
           } else {
-            return <Tag color="red">隐藏</Tag>;
+            return <Tag color="red">隐藏</Tag>
           }
-        },
+        }
       },
       {
         align: 'center',
         title: '创建时间',
-        dataIndex: 'created_at',
+        dataIndex: 'created_at'
       },
       {
         align: 'center',
         title: '操作',
         dataIndex: 'actions',
-        render: (text, record) => renderOption(record),
-      },
-    ],
-  };
+        render: (text, record) => renderOption(record)
+      }
+    ]
+  }
   return (
     <>
       {visible && <Edit setVisible={setVisible} params={params} identify={identify} refreshPage={refreshPage}/> }

+ 43 - 42
src/pages/openplatform/devcore/aplist/structure.js

@@ -19,6 +19,7 @@ export default {
       {
         align: 'center',
         title: 'ID',
+        width: 70,
         dataIndex: 'id'
       },
       {
@@ -78,46 +79,6 @@ export default {
         fixed: 'right',
         dataIndex: 'state',
         coloumnRender: [
-          {
-            type: 'operatButton',
-            showControl: [
-              {
-                key: 'state',
-                relationship: '=',
-                value: 0
-              }
-            ],
-            props: {
-              buttonType: 'link',
-              buttonText: '审核通过',
-              confirm: true,
-              confirmText: '确认审核吗?',
-              apiUrl: `${wop}/v1/admin/developer/app/check`,
-              params: {
-                cloumnParams: ['id']
-              }
-            }
-          },
-          {
-            type: 'operatButton',
-            showControl: [
-              {
-                key: 'state',
-                relationship: '=',
-                value: 1
-              }
-            ],
-            props: {
-              buttonType: 'link',
-              buttonText: '取消审核',
-              confirm: true,
-              confirmText: '确认取消审核吗?',
-              apiUrl: `${wop}/v1/admin/developer/app/check`,
-              params: {
-                cloumnParams: ['id']
-              }
-            }
-          },
           {
             type: 'modalFormButton',
             props: {
@@ -185,6 +146,46 @@ export default {
               }
             }
           },
+          {
+            type: 'operatButton',
+            showControl: [
+              {
+                key: 'state',
+                relationship: '=',
+                value: 0
+              }
+            ],
+            props: {
+              buttonType: 'link',
+              buttonText: '启用',
+              confirm: true,
+              confirmText: '确认启用吗?',
+              apiUrl: `${wop}/v1/admin/developer/app/check`,
+              params: {
+                cloumnParams: ['id']
+              }
+            }
+          },
+          {
+            type: 'operatButton',
+            showControl: [
+              {
+                key: 'state',
+                relationship: '=',
+                value: 1
+              }
+            ],
+            props: {
+              buttonType: 'link',
+              buttonText: '禁用',
+              confirm: true,
+              confirmText: '确认禁用吗?',
+              apiUrl: `${wop}/v1/admin/developer/app/check`,
+              params: {
+                cloumnParams: ['id']
+              }
+            }
+          },
           {
             type: 'operatButton',
             props: {
@@ -236,11 +237,11 @@ export default {
           },
           {
             value: '1',
-            label: '通过'
+            label: '启用'
           },
           {
             value: '0',
-            label: '未通过'
+            label: '禁用'
           }
         ],
         styles: {

+ 13 - 0
src/pages/openplatform/devcore/appsublist/structure.js

@@ -25,6 +25,7 @@ export default {
       {
         align: 'center',
         title: 'ID',
+        width: 70,
         dataIndex: 'id'
       },
       {
@@ -49,6 +50,18 @@ export default {
           }
         }
       },
+      {
+        align: 'center',
+        title: '订阅字段',
+        dataIndex: 'callbackFields',
+        render: (v) => {
+          if (v === '') {
+            return '-'
+          } else {
+            return <LongText text={v} limit={20}/>
+          }
+        }
+      },
       {
         align: 'center',
         title: '订阅类目',

+ 54 - 53
src/pages/openplatform/devcore/numlist/structure.js

@@ -19,6 +19,7 @@ export default {
       {
         align: 'center',
         title: 'ID',
+        width: 70,
         dataIndex: 'id'
       },
       {
@@ -65,59 +66,6 @@ export default {
         title: '操作',
         dataIndex: 'nickname',
         coloumnRender: [
-          {
-            type: 'operatButton',
-            props: {
-              buttonType: 'link',
-              buttonText: '删除',
-              confirm: true,
-              confirmText: '确认删除吗?',
-              apiUrl: `${wop}/v1/admin/developer/account/delete`,
-              params: {
-                cloumnParams: ['userInfoId']
-              }
-            }
-          },
-          {
-            type: 'operatButton',
-            showControl: [
-              {
-                key: 'state',
-                relationship: '=',
-                value: 0
-              }
-            ],
-            props: {
-              buttonType: 'link',
-              buttonText: '启用',
-              confirm: true,
-              confirmText: '确认改变状态吗?',
-              apiUrl: `${wop}/v1/admin/developer/account/disable-enable`,
-              params: {
-                cloumnParams: ['userInfoId']
-              }
-            }
-          },
-          {
-            type: 'operatButton',
-            showControl: [
-              {
-                key: 'state',
-                relationship: '=',
-                value: 1
-              }
-            ],
-            props: {
-              buttonType: 'link',
-              buttonText: '禁用',
-              confirm: true,
-              confirmText: '确认改变状态吗?',
-              apiUrl: `${wop}/v1/admin/developer/account/disable-enable`,
-              params: {
-                cloumnParams: ['userInfoId']
-              }
-            }
-          },
           {
             type: 'modalFormButton',
             props: {
@@ -174,6 +122,59 @@ export default {
                 formParams: []
               }
             }
+          },
+          {
+            type: 'operatButton',
+            showControl: [
+              {
+                key: 'state',
+                relationship: '=',
+                value: 0
+              }
+            ],
+            props: {
+              buttonType: 'link',
+              buttonText: '启用',
+              confirm: true,
+              confirmText: '确认改变状态吗?',
+              apiUrl: `${wop}/v1/admin/developer/account/disable-enable`,
+              params: {
+                cloumnParams: ['userInfoId']
+              }
+            }
+          },
+          {
+            type: 'operatButton',
+            showControl: [
+              {
+                key: 'state',
+                relationship: '=',
+                value: 1
+              }
+            ],
+            props: {
+              buttonType: 'link',
+              buttonText: '禁用',
+              confirm: true,
+              confirmText: '确认改变状态吗?',
+              apiUrl: `${wop}/v1/admin/developer/account/disable-enable`,
+              params: {
+                cloumnParams: ['userInfoId']
+              }
+            }
+          },
+          {
+            type: 'operatButton',
+            props: {
+              buttonType: 'link',
+              buttonText: '删除',
+              confirm: true,
+              confirmText: '确认删除吗?',
+              apiUrl: `${wop}/v1/admin/developer/account/delete`,
+              params: {
+                cloumnParams: ['userInfoId']
+              }
+            }
           }
         ]
       }