| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167 |
- <template>
- <view class="content">
- <view class="main-box">
- <view class="main-item">
- <view class="main-font">
- 扣款类型
- </view>
- <picker @change="bindPickerType" :range="typelist" class="input">
- <text>{{ type }}</text>
- </picker>
- </view>
- <view class="main-item">
- <view class="main-font">
- 扣款人
- </view>
- <input class="input" type="text" v-model="name" placeholder="请填写姓名">
- </view>
- <view class="main-item">
- <view class="main-font">
- 处罚日期
- </view>
- <view class="input">
- <view class="uni-list-cell">
- <picker mode="date" :value="date" @change="bindDateChange">
- <view class="uni-input">{{date}}</view>
- </picker>
- </view>
- </view>
- </view>
- <view class="main-item">
- <view class="main-font">
- 扣款金额
- </view>
- <input class="input" type="text" v-model="money" placeholder="请填写金额">
- </view>
- <view class="main-item">
- <view class="main-font">
- 是否征求员工意见
- </view>
- <picker class="input" @change="bindPickerSf" :range="array">
- <text>{{ sex }}</text>
- </picker>
- </view>
- <view class="info-box">
- <view class="info-title">
- 处罚说明<text class="info-tip">(限XX字)</text>
- </view>
- <textarea class="info-box" placeholder="请填写处罚说明..." v-model="info" id="" cols="30" rows="10"></textarea>
- </view>
- </view>
- <view class="btn">
- 确认添加
- </view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- name: '',
- money: '',
- type: '请选择扣款类型',
- typelist: ['迟到', '早退', '旷工'],
- date: '请选择日期',
- array: ['是', '否'],
- sex: '请选择是否',
- info: ''
- };
- },
- onLoad() {},
- onShow() {},
- onReachBottom() {},
- onReady() {},
- methods: {
- // 选择类型
- bindPickerType: function(e) {
- this.type = this.typelist[e.target.value];
- },
- bindDateChange: function(e) {
- this.date = e.detail.value;
- console.log(e);
- },
- bindPickerSf: function(e) {
- this.sex = this.array[e.target.value];
- },
- }
- };
- </script>
- <style lang="scss">
- page,
- .content {
- min-height: 100%;
- height: auto;
- }
- .main-box {
- margin-top: 20rpx;
- padding: 0 30rpx 20rpx;
- background: #ffffff;
- .main-item {
- padding: 35rpx 18rpx;
- border-bottom: 1px solid #f5f5f5;
- display: flex;
- justify-content: space-between;
- align-items: center;
- .main-font {
- font-size: 30rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #222222;
- }
- .input {
- text-align: right;
- padding: 0 20rpx;
- font-size: 30rpx;
- font-family: PingFang SC;
- font-weight: 400;
- color: #999999;
- }
- }
- }
- .info-box {
- margin-top: 20rpx;
- .info-title {
- font-size: 30rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #222222;
- .info-tip {
- font-size: 24rpx;
- color: #666666;
- }
- }
- .info-box {
- width: 100%;
- margin-top: 20rpx;
- font-size: 28rpx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- }
- }
- .btn {
- margin: 100rpx auto 0;
- width: 622rpx;
- height: 85rpx;
- background: #069CFA;
- border-radius: 15rpx;
- text-align: center;
- line-height: 85rpx;
- font-size: 32rpx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FFFFFF;
- }
- </style>
|