<template>
    <div class="sweet-ui-lib-dev">
        <ul>
            <!--<li>-->
            <!--para-help-->
            <!--<para-help>-->
            <!--<template #content>-->
            <!--2333-->
            <!--</template>-->
            <!--</para-help>-->
            <!--</li>-->
            <!--<li><para-image></para-image></li>-->
            <!--<li><para-multinput></para-multinput></li>-->
            <!--<li><para-select></para-select></li>-->
            <!--<li>-->
            <!--para-split-->
            <!--<div class="demo-split">-->
            <!--<para-split v-model="split1">-->
            <!--<div slot="left" class="demo-split-pane">-->
            <!--Left Pane-->
            <!--</div>-->
            <!--<div slot="right" class="demo-split-pane">-->
            <!--Right Pane-->
            <!--</div>-->
            <!--</para-split>-->
            <!--</div>-->
            <!--</li>-->
            <!--<li style="height: 800px;overflow: hidden" id="lis">-->
            <!--<para-table :request="request"-->
            <!--:pagination="{ showTotal:(t) => 'hhhhhh'}"-->
            <!--:data="data"-->
            <!--:row-key="a => a.key"-->
            <!--:radio="false"-->
            <!--:select-row="true"-->
            <!--v-model="checkList"-->
            <!--:scroll="{y:scroll}"-->
            <!--ref="userTable"-->
            <!--:search="search"-->
            <!--:show-title="false">-->
            <!--<template #default>-->
            <!--&lt;!&ndash;用户名&ndash;&gt;-->
            <!--<a-table-column-->
            <!--dataIndex="username"-->
            <!--align="center"-->
            <!--title="用户名">-->
            <!--</a-table-column>-->
            <!--&lt;!&ndash;真实名&ndash;&gt;-->
            <!--<a-table-column-->
            <!--dataIndex="realName"-->
            <!--align="center"-->
            <!--title="真实名">-->
            <!--</a-table-column>-->
            <!--&lt;!&ndash;邮箱&ndash;&gt;-->
            <!--<a-table-column-->
            <!--dataIndex="email"-->
            <!--align="center"-->
            <!--title="邮箱">-->
            <!--</a-table-column>-->
            <!--&lt;!&ndash;电话&ndash;&gt;-->
            <!--<a-table-column-->
            <!--dataIndex="phone"-->
            <!--align="center"-->
            <!--title="电话">-->
            <!--</a-table-column>-->
            <!--&lt;!&ndash;状态&ndash;&gt;-->
            <!--<a-table-column-->
            <!--align="center"-->
            <!--title="状态">-->
            <!--<template #default="row">-->
            <!--<span v-if="row.status === 'ACTIVATE'" class="active">激活</span>-->
            <!--<span v-else-if="row.status === 'DISABLE'" class="disabled">禁用</span>-->
            <!--<span v-else-if="row.status === 'SUSPEND'" class="disabled">锁定</span>-->
            <!--<span v-else-if="row.status === 'EXPIRE'" class="disabled">密码过期</span>-->
            <!--</template>-->
            <!--</a-table-column>-->
            <!--&lt;!&ndash;操作&ndash;&gt;-->
            <!--</template>-->
            <!--</para-table>-->
            <!--</li>-->
            <!--<li><para-transfer></para-transfer></li>-->
            <!--<li><para-tree></para-tree></li>-->
            <!--<li><para-tree2></para-tree2></li>-->
            <!--<li>
                <para-image></para-image>
            </li>-->
        </ul>
    </div>
</template>

<script>
  import {
    paraHelp,
    paraImage,
    paraMultinput,
    paraSelect,
    paraSplit,
    paraTable,
    paraTransfer,
    paraTree,
    paraTree2,
    paraUpload,
    Button,
  } from './entry';

  export default {
    name: 'sweetUi',
    components: {
      paraHelp,
      paraImage,
      paraMultinput,
      paraSelect,
      paraSplit,
      paraTable,
      paraTransfer,
      paraTree,
      paraTree2,
      paraUpload,
      Button,
    },
    data() {
      return {
        hh: '123',
        scroll: 300,
        checks: true,
        request: {
          url: 'rest/usersClient/query',
          // url: 'rest/usersClient/query/org/allAssociateTO',
          method: 'GET',
          // url: 'https://jsonplaceholder.typicode.com/posts',
          // url: '/rest/usersClient/query/group',
          project: 'cic-console'

          /* url: '/rest/usersClient/query/org',
           project: 'cic-console'* /
           /* url: '/v1/alarmNotice',
            project: "msg" */
        },
        search: {
          //  type: 'ORG'
        },
        data: [
          {
            key: '1',
            firstName: 'John',
            lastName: 'Brown',
            age: 32,
            address: 'New York No. 1 Lake Park',
            tags: ['nice', 'developer']
          },
          {
            key: '2',
            firstName: 'Jim',
            lastName: 'Green',
            age: 42,
            address: 'London No. 1 Lake Park',
            tags: ['loser']
          },
          {
            key: '3',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '4',
            firstName: 'John',
            lastName: 'Brown',
            age: 32,
            address: 'New York No. 1 Lake Park',
            tags: ['nice', 'developer']
          },
          {
            key: '5',
            firstName: 'Jim',
            lastName: 'Green',
            age: 42,
            address: 'London No. 1 Lake Park',
            tags: ['loser']
          },
          {
            key: '6',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '7',
            firstName: 'John',
            lastName: 'Brown',
            age: 32,
            address: 'New York No. 1 Lake Park',
            tags: ['nice', 'developer']
          },
          {
            key: '8',
            firstName: 'Jim',
            lastName: 'Green',
            age: 42,
            address: 'London No. 1 Lake Park',
            tags: ['loser']
          },
          {
            key: '9',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '10',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '11',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '12',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '13',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '14',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '15',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '16',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '17',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '18',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '19',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '20',
            firstName: 'Joe',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '21',
            firstName: 'Joe1111',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '22',
            firstName: 'Joe222',
            lastName: 'Black',
            age: 32,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          },
          {
            key: '23',
            firstName: 'Joe3333',
            lastName: 'Black',
            age: 33,
            address: 'Sidney No. 1 Lake Park',
            tags: ['cool', 'teacher']
          }
        ],
        /*       search: {
                 filters: [{
                   filterType: 'LIKE',
                   propertyName: '*',
                   values: ['']
                 }, {
                   filterType: 'LIKE',
                   propertyName: '*',
                   values: ['']
                 }]
                 // roleId: '063ab4b9-d87d-4044-9056-41b92fe00cc1'
               }, */
        // search: 'filters=%5B%7B%22filterType%22:%22LIKE%22,%22propertyName%22:%22*%22,%22values%22:%5B%22%22%5D%7D%5D',
        // search1: 'key=1&firstName=John',

        checkList: [],
        bordered: true,
        selectedRowKeys: [],
        expandedRowKeys: [],
        pagination: {
          position: 'bottom',
          type: 'server'
        },
        columns: [
          {
            title: 'Id',
            dataIndex: 'id',
            key: 'id',
            align: 'right',
            sorter: true,
            colSpan: 1
          },
          {title: 'Title', dataIndex: 'title', key: 'title'},
          {title: 'Creator', dataIndex: 'creator', key: 'creator'},
          {title: 'Source', dataIndex: 'source', key: 'source'},
          {title: 'NotificationType', dataIndex: 'notificationType', key: 'notificationType'}
        ],
        column: [
          {
            title: 'content',
            dataIndex: 'content',
            key: 'content'
          },
          {
            title: 'creationDate',
            dataIndex: 'creationDate',
            key: 'creationDate'
          }
        ],
        column1: [
          {
            title: 'lastName',
            dataIndex: 'lastName',
            key: 'lastName',
            width: '120px',
            filters: [{text: 'Brown', value: 'Brown'}, {text: 'Green', value: 'Green'}, {
              text: 'Black',
              value: 'Black'
            }],
            filterMultiple: true
          },
          {
            title: 'Age',
            dataIndex: 'age',
            key: 'age',
            width: '80px',
            sorter: (a, b) => a.age - b.age
          }
        ],
        sortOrder: 'descend',
        rowSelection: {
          columnWidth: '60px',
          columnTitle: undefined,
          fixed: false,
          getCheckboxProps: (record) => {
            // console.log('选择框的默认属性配置', record);
            return record;
          },
          hideDefaultSelections: false,
          selections: true,
          type: 'checkbox',
          // eslint-disable-next-line no-unused-vars
          onChange: (selectedRowKeys, selectedRows) => {
            //console.log('选中项发生变化时的回调change');
          },
          // eslint-disable-next-line no-unused-vars
          onSelect: (record, selected, selectedRows, nativeEvent) => {
            //console.log('用户手动选择/取消选择某列的回调');
          },
          // eslint-disable-next-line no-unused-vars
          onSelectAll: (selected, selectedRows, changeRows) => {
            //console.log('用户手动选择/取消选择所有列的回调');
          },
          // eslint-disable-next-line no-unused-vars
          onSelectInvert(selectedRows) {
            //console.log('用户手动选择反选的回调');
          }
        },
        selection: {
          key: 'refs',
          text: 'text',
          // eslint-disable-next-line no-unused-vars
          onSelect: (changeableRowKeys) => {
            //console.log('选择项点击回调');
          }
        }
      };
    },
    methods: {
      handlClick(e) {
        //console.log(e);
      }
    },
    mounted() {
      // this.scroll = document.querySelector('#lis').offsetHeight - 200;
      //  console.log(document.querySelector('#lis').offsetHeight - 100)
      // console.log()
    }
  };
</script>
<style>
    .demo-split {
        height: 200px;
        border: 1px solid #dcdee2;
    }

    .demo-split-pane {
        padding: 10px;
    }

    ul, li {
        list-style: none;
    }
</style>
