|
@@ -0,0 +1,171 @@
|
|
|
+<template>
|
|
|
+ <a-card :bordered="false">
|
|
|
+
|
|
|
+ <!-- 查询区域 -->
|
|
|
+ <div class="table-page-search-wrapper">
|
|
|
+ <a-form layout="inline" @keyup.enter.native="searchQuery">
|
|
|
+ <a-row :gutter="24">
|
|
|
+ <a-col :xl="6" :lg="7" :md="8" :sm="24">
|
|
|
+ <a-form-item label="时间">
|
|
|
+ <a-range-picker v-model="DateTime" style="width: 100%;" @change="changeStartDate" />
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :xl="6" :lg="7" :md="8" :sm="24">
|
|
|
+ <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
|
|
|
+ <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
|
|
|
+ <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
|
|
|
+ </span>
|
|
|
+ </a-col>
|
|
|
+
|
|
|
+ </a-row>
|
|
|
+ </a-form>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- 操作按钮区域 -->
|
|
|
+ <div class="table-operator">
|
|
|
+ <a-button @click="UploadAttendanceSheet" type="primary" icon="plus">上传考勤表</a-button>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- table区域-begin -->
|
|
|
+ <div>
|
|
|
+ <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
|
|
|
+ <i class="anticon anticon-info-circle ant-alert-icon"></i>
|
|
|
+ <span>已选择</span>
|
|
|
+ <a style="font-weight: 600">
|
|
|
+ {{ selectedRowKeys.length }}
|
|
|
+ </a>
|
|
|
+ <span>项</span>
|
|
|
+ <a style="margin-left: 24px" @click="onClearSelected">清空</a>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <a-table
|
|
|
+ ref="table"
|
|
|
+ size="middle"
|
|
|
+ bordered
|
|
|
+ rowKey="id"
|
|
|
+ :columns="columns"
|
|
|
+ :dataSource="dataSource"
|
|
|
+ :pagination="ipagination"
|
|
|
+ :scroll="{x: 1000}"
|
|
|
+ :loading="loading"
|
|
|
+ :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
|
|
+ @change="handleTableChange">
|
|
|
+ <span slot="operation" slot-scope="text, record">
|
|
|
+ <a @click="handleDetail(record)" >查看详情</a>
|
|
|
+ <a-divider type="vertical" />
|
|
|
+ <a @click="handleDownload(record)" >下载</a>
|
|
|
+
|
|
|
+ </span>
|
|
|
+ </a-table>
|
|
|
+ </div>
|
|
|
+ <!-- table区域-end -->
|
|
|
+
|
|
|
+ <!-- 表单区域 -->
|
|
|
+ <AttendancelDetail ref="AttendancelDetail"></AttendancelDetail>
|
|
|
+ </a-card>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ <script>
|
|
|
+
|
|
|
+ import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
+ import { getAction } from '@/api/manage'
|
|
|
+ import moment from 'moment'
|
|
|
+ import AttendancelDetail from './modules/AttendancelDetail.vue'
|
|
|
+ export default {
|
|
|
+ name: "attendanceManagement",
|
|
|
+ mixins: [JeecgListMixin],
|
|
|
+ components: {
|
|
|
+ AttendancelDetail
|
|
|
+ },
|
|
|
+ data () {
|
|
|
+ return {
|
|
|
+ description: '考勤管理',
|
|
|
+ DateTime:[],
|
|
|
+ selectedRowKeys:[],
|
|
|
+ selectedRows:[],
|
|
|
+ // 表头
|
|
|
+ columns: [
|
|
|
+ {
|
|
|
+ title: '序号',
|
|
|
+ width: 80,
|
|
|
+ align:"center",
|
|
|
+ dataIndex: 'code'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '名称 ',
|
|
|
+ align:"center",
|
|
|
+ dataIndex: 'name'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '上传时间',
|
|
|
+ align:"center",
|
|
|
+ dataIndex: 'uploadTime'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '版本',
|
|
|
+ align:"center",
|
|
|
+ dataIndex: 'version'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '操作',
|
|
|
+ align:"center",
|
|
|
+ dataIndex: 'operation',
|
|
|
+ width: 200,
|
|
|
+ scopedSlots: { customRender: 'operation' }
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ queryParam:{},
|
|
|
+ dataSource:[{}],
|
|
|
+ ipagination:{}
|
|
|
+ }
|
|
|
+ },
|
|
|
+ computed: {},
|
|
|
+ created () {
|
|
|
+ this.getTableList()
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ changeStartDate(data){
|
|
|
+ this.DateTime = data
|
|
|
+ this.queryParam.Date_begin = data.length==2?moment(data[0]).format('YYYY-MM-DD'):''
|
|
|
+ this.queryParam.Date_end = data.length==2?moment(data[1]).format('YYYY-MM-DD'):''
|
|
|
+ },
|
|
|
+ getTableList(){
|
|
|
+ getAction('/salary/salaryAttendance/list',this.queryParam).then(res=>{
|
|
|
+ debugger
|
|
|
+ if(res.success){
|
|
|
+ debugger
|
|
|
+ this.dataSource =res.result.records
|
|
|
+ this.ipagination = {
|
|
|
+ total: res.result.total,
|
|
|
+ current: res.result.current,
|
|
|
+ pageSize: res.result.size
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ this.$message.error(res.message);
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ UploadAttendanceSheet(){
|
|
|
+
|
|
|
+ },
|
|
|
+ handleDetail(record){
|
|
|
+ this.$refs.AttendancelDetail.visible = true
|
|
|
+ },
|
|
|
+ handleDownload(record){
|
|
|
+
|
|
|
+ },
|
|
|
+ onSelectChange(selectedRowKeys, selectionRows) {
|
|
|
+ this.selectedRowKeys = selectedRowKeys;
|
|
|
+ this.selectedRows = selectionRows;
|
|
|
+ },
|
|
|
+ handleTableChange(pagination, filters, sorter) {
|
|
|
+ this.queryParam.pageNo = pagination.current
|
|
|
+ this.queryParam.pageSize = pagination.pageSize
|
|
|
+ this.getTableList()
|
|
|
+ },
|
|
|
+ }
|
|
|
+ }
|
|
|
+ </script>
|
|
|
+ <style scoped>
|
|
|
+ @import '~@assets/less/common.less'
|
|
|
+ </style>
|