田源
2023-12-15 9bf8752700c4569e9e4d1ee7ee2e4e4b7af0abb2
Source/UBCS-WEB/src/views/docking/loge.vue
@@ -3,10 +3,10 @@
  <basic-container>
    <avue-crud :option="option"
               :table-loading="loading"
               :data="data"
               :data="data || getList"
               :page.sync="page"
               :permission="permissionList"
               ref="crud"
               @cell-dblclick="cellDbClick"
               @search-change="searchChange"
               @search-reset="searchReset"
               @selection-change="selectionChange"
@@ -14,12 +14,25 @@
               @size-change="sizeChange"
               @refresh-change="refreshChange"
               @on-load="onLoad">
      <template slot-scope="scope" slot="menuLeft">
        <vci-docking-search :SearchObject="SearchObject" :page="page" :formInline="formInline" :status="status" @getList="dockingGetList"></vci-docking-search>
      </template>
      <template slot="paramString" slot-scope="scope">
        <avue-text-ellipsis :text="scope.row.paramString" :height="50">
          <small slot="more">...</small>
        </avue-text-ellipsis>
      </template>
      <template slot="returnString" slot-scope="scope">
        <avue-text-ellipsis :text="scope.row.returnString" :height="50">
          <small slot="more">...</small>
        </avue-text-ellipsis>
      </template>
    </avue-crud>
  </basic-container>
</template>
<script>
import {getList} from "@/api/docking/loge";
import {getLogoList} from "@/api/docking/loge";
import {validatenull} from "@/util/validate";
import {mapGetters} from "vuex";
@@ -27,6 +40,81 @@
  name: "loge",
  data(){
    return {
      value:'',
      //各个类型状态
      status:{
        type:'loge',
        typeFlag:false,
        dateFlag:false,
        stateFlag:false,
      },
      //model绑定
      formInline:{
        type:'',
        cut:'',
        text:'',
        Date:'',
        state:''
      },
      //集成类型死数据
      SearchObject:{
        searchData:[
          {
            label:'数据编码',
            prop: "id",
            value:0
          },
          {
            label:'分类代号',
            prop: 'classifyId',
            value:1
          },
          {
            label:'分类名称',
            prop: 'classifyName',
            value:2
          },
          {
            label:'集成系统编号',
            prop: 'systemCode',
            value:3
          },
          {
            label:'集成系统名称',
            prop: 'systemName',
            value:4
          },
          {
            label:'类型',
            prop: 'typeText',
            value:5
          },
          {
            label:'记录时间',
            value:6,
            prop: 'createTime',
          },
          {
            label:'是否成功',
            prop: 'interfaceStatus',
            value:7
          },
          {
            label: '标准申请',
            prop: 'applyCodeForBZ',
            value:8          },
          {
            label: '部门申请',
            prop: 'syncDataForOrg',
            value:9
          },
          {
            label: '人员申请',
            prop: 'syncDataForPerson',
            value:10
          },
        ],
      },
      loading: false,
      query: {},
      selectionList: [],
@@ -41,60 +129,114 @@
        calcHeight: 0,
        tip: false,
        searchShow: false,
        searchMenuSpan: 6,
        border: true,
        index: true,
        viewBtn: true,
        selection: false,
        dialogClickModal: false,
        menu:false,
        menuFixed:false,
        dialogType: 'drawer',
        viewBtn: true,
        addBtn:false,
        editBtn:false,
        delBtn:false,
        column: [
          {
            label: "数据编码",
            prop: "id",
            search: true,
            sortable:true,
            width:150
            width:130
          },
          {
            label: "图号",
            prop: "uniquecode",
            search: true,
            prop: "uniqueCode",
            hide:true,
            sortable:true,
            width:150
          },
          {
            label: '分类id',
            prop: 'classifyid',
            search: true,
            label: '分类代号',
            prop: 'classifyId',
            sortable:true,
            width: 250
            overHidden:true,
            width: 150
          },
          {
            label: '分类名称',
            prop: 'classifyname',
            search: true,
            prop: 'classifyName',
            sortable:true,
            overHidden: true,
            width: 140
          },
          {
            label: '标准申请',
            prop: 'applyCodeForBZ',
            sortable:true,
            width: 130
          },
          {
            label: '部门申请',
            prop: 'syncDataForOrg',
            sortable:true,
            width: 130
          },
          {
            label: '人员申请',
            prop: 'syncDataForPerson',
            sortable:true,
            width: 130
          },
          {
            label: '集成系统编号',
            prop: 'systemCode',
            labelWidth:150,
            sortable:true,
            width: 130
          },
          {
            label: '集成系统名称',
            prop: 'systemName',
            sortable:true,
            labelWidth:150,
            width: 150
          },
          {
            label: '类型',
            prop: 'typeText',
            sortable:true,
            width: 150
          },
          {
            label:'接口参数',
            prop:'paramString',
            sortable:true,
            minRows: 20,
            width: 150,
            type: "textarea",
            slot: true,
          },
          {
            label:'返回参数',
            prop:'returnString',
            sortable:true,
            minRows: 20,
            width: 150,
            type: "textarea",
            slot: true,
          },
          {
            label: '返回msg',
            prop: 'msg',
            overHidden: true
          },
          {
            label: '系统编号',
            prop: 'systemcode',
            search: true,
            label: '记录时间',
            prop: 'createTime',
            sortable:true,
            width: 150
            width: 160
          },
          {
            label: '系统名称',
            prop: 'systemname',
            search: true,
            sortable:true,
            width: 150
          },
          {
            label: '是否推送成功',
            prop: 'interfacestatus',
            search: true,
            label: '是否成功',
            prop: 'interfaceStatus',
            sortable:true,
            width: 120,
            html:true,
@@ -107,20 +249,9 @@
              value: "key"
            },
            formatter : function (row, column) {
              return row.interfacestatus == 'true' || row.interfacestatus == '1' ? '<i class="el-icon-check" style="color: limegreen"></i>' : '<i class="el-icon-close" style="color: red"></i>'
              return row.interfaceStatus == 'true' || row.interfaceStatus == '' ? '<i class="el-icon-check" style="color: #32cd32;font-size: 20px;font-weight: 800"></i>' : '<i class="el-icon-close" style="color: #ff0000;font-size: 20px;font-weight: 800"></i>'
            }
          },
          {
            label: '返回msg',
            prop: 'msg',
            overHidden: true
          },
          {
            label: '记录时间',
            prop: 'createTime',
            sortable:true,
            width: 160
          }
        ]
      }
    }
@@ -137,6 +268,25 @@
    }
  },
  methods: {
    dockingGetList(val){
      this.data=val.records;
      this.page.pageSize=val.size;
      this.page.currentPage=val.current;
      this.page.total=val.total;
    },
    async cellDbClick(row, column, cell, event) {
      for (const key in row) {
        if (key === column.property) {
          this.value = row[key];
        }
      }
      try {
        await this.$copyText(this.value);
        this.$message.success('复制成功');
      } catch (error) {
        this.$message.warning('复制失败');
      }
    },
    searchReset() {
      this.query = {};
      this.onLoad(this.page);
@@ -165,13 +315,14 @@
    },
    onLoad(page, params={}) {
      this.loading = true;
      let createTime = 'desc'
      var query={}
      if (this.query) {
        for (var key in this.query) {
          query['conditionMap["' + key + '"]'] = this.query[key];
        }
      }
      getList(page.currentPage, page.pageSize, Object.assign(params,this.params, query,this.query)).then(res => {
      getLogoList(page.currentPage, page.pageSize,'createTime',Object.assign(params,this.params, query,this.query),).then(res => {
        const data = res.data.data;
        this.page.total = data.total;
        this.data = data.records;
@@ -187,6 +338,20 @@
}
</script>
<style scoped>
<style lang="scss" scoped>
// 滚动条样式修改
// 滚动条的宽度
   /deep/ .el-table__body-wrapper::-webkit-scrollbar {
     height: 15px; // 纵向滚动条 必写
   background: white;
     border: white;
     width: 10px;
   }
// 滚动条的滑块
   /deep/ .el-table__body-wrapper::-webkit-scrollbar-thumb {
     background-color: #ececec;
     border-radius: 20px;
     border: #ececec;
   }
</style>