
<template>
  <div>
    <basicLayout 
      ref="list" 
      formPath="promotion"
      tableName="bankStatementTable" 
      idName="sa_bankstatementid" 
      :apiId="{query:20230106154004,del:''}"
      :options="options"
      :detailPath="{
        path:'/bankStatementDetail'
      }"
      @listData="list">
      <div slot="custom">
        <div class="label_center">
          <p class="search__label">状态:</p>
          <el-select @clear="$refs.list.param.content.pageNumber = 1 ;$refs.list.param.content.where.status = '';$refs.list.listData()" v-model="status" clearable style="margin-right:10px" size="small" placeholder="请选择状态" @change="$refs.list.param.content.pageNumber = 1 ;$refs.list.param.content.where.status = status;$refs.list.listData()">
            <el-option label="已入账(人工)" value="已入账(人工)" />
            <el-option label="已入账(系统)" value="已入账(系统)" />
            <el-option label="已确认(非货款)" value="已确认(非货款)" />
            <el-option label="未入账" value="未入账" />
          </el-select>
        </div>
      </div>
      <div slot="custom-right">
        <div class="label_center">
          <p class="search__label" style="width:200px">最新数据更新时间:</p>
          <el-input readonly v-model="time" size="small"></el-input>
        </div>
      </div>
      <template v-slot:tbList="scope">
        <div v-if="scope.data.column.data[[scope.data.column.columnname]]">
          <span v-if="scope.data.column.columnname == 'status'">
            <span style="color:#000000" v-if="scope.data.column.data[[scope.data.column.columnname]] == '未入账'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
            <span style="color:#52C41A" v-else-if="scope.data.column.data[[scope.data.column.columnname]] == '已确认(非货款)'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
            <span style="color:#3874f6" v-if="scope.data.column.data[[scope.data.column.columnname]] == '已入账(系统)'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
            <span style="color:#e09a1a" v-else-if="scope.data.column.data[[scope.data.column.columnname]] == '已入账(人工)'">{{scope.data.column.data[[scope.data.column.columnname]]}}</span>
          </span>
          <span v-else>
            {{scope.data.column.data[[scope.data.column.columnname]]}}
          </span>
        </div>
        <div v-if="scope.data.column.columnname != 'operation' && !scope.data.column.data[[scope.data.column.columnname]] && scope.data.column.data[[scope.data.column.columnname]] !== 0">--</div>
      </template>
      <template v-slot:tbOpreation="scope">
      </template>
    </basicLayout>
  </div>
</template>

<script>
export default {
  data () {
    return {
      options:[],
      status:'',
      time:'暂无'
    }
  },
  methods:{
    list (data) {
      if (data.length) this.time = data[0].lastruntime
    }
  }
}

</script>
<style>
</style>