1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- <template>
- <view>
- <view class='wrap' v-for="(item, index) in tableData" :key="index">
- <view class="wenzi audit1" v-if="item.status == '待审核'">审核中</view>
- <view class="wenzi audit2" v-if="item.status == '已通过'">已通过</view>
- <view class="wenzi audit3" v-if="item.status == '未通过'" >未通过</view>
- <view class="c-row">
- <view class="title">请假类型 : {{item.leaveType}}</view>
- </view>
- <view class="c-row">
- <view class="title">请假事由 : {{item.reasonForLeave}}</view>
- </view>
- <view class="c-row">
- <view class="title">开始时间 : {{item.startDate}}</view>
- </view>
- <view class="c-row">
- <view class="title">结束时间 : {{item.endDate}}</view>
- </view>
- </view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- pageSize: 10,
- currentPage: 1,
- tableData: [],
- }
- },
- onShow() {
- this.getList()
- },
- methods: {
- getList() {
- this.$api.doRequest('get', '/leaveInfo/selectLeaveInfo', {
- pageSize: this.pageSize,
- currentPage: this.currentPage,
- pcFlag: 0,
- compId: uni.getStorageSync('pcUserInfo').compId,
- commonId: uni.getStorageSync('pcUserInfo').userId,
- }).then(res => {
- if (res.data.code == 200) {
- this.tableData = res.data.data.records
- }
- })
- },
- }
- }
- </script>
- <style lang='scss' scoped>
- page {
- background: #F5F6FA;
- }
- .wrap {
- padding-top: 15px;
- padding-bottom: 20px;
- font-size: 14px;
- background: #fff;
- margin: 10px;
- border-radius: 10px;
- input {
- font-size: 14px;
- }
- >.title {
- padding: 10px 16px;
- }
- }
- .wenzi {
- text-align: right;
- border-radius: 10rpx;
- margin-right: 30rpx;
- height: 10rpx;
- }
- .audit1{
- color: red;
- }
- .audit2{
- color: #afafe6;
- }
- .audit3{
- color: red;
- }
- .c-row {
- display: -webkit-box;
- display: -webkit-flex;
- display: flex;
- -webkit-box-align: center;
- -webkit-align-items: center;
- align-items: center;
- padding: 5rpx 30rpx;
- position: relative;
- }
- </style>
|