<template>
    <global-page title="考核记录登记">
        <view class="content">
            <view class="form">
                <view class="form-item">
                    <view class="form-item-label">事件来源</view>
                    <input class="form-item-input" type="text" placeholder="请输入" />
                </view>
                <view class="form-item">
                    <view class="form-item-label">基地/职能部门</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">考核对象</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">机号</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">客户</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">机型</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">日期</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item textarea">
                    <view class="form-item-label">事件描述</view>
                    <textarea placeholder="请输入" />
                </view>
                <view class="form-item">
                    <view class="form-item-label">事件类别</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item">
                    <view class="form-item-label">考核类型</view>
                    <global-picker></global-picker>
                </view>
                <view class="form-item textarea">
                    <view class="form-item-label">考核依据</view>
                    <textarea placeholder="请输入" />
                </view>
                <view class="form-item">
                    <view class="form-item-label">分值</view>
                    <input class="form-item-input" type="text" placeholder="请输入" />
                </view>
                <view class="form-item">
                    <view class="form-item-label">当班人员</view>
                    <input class="form-item-input" type="text" placeholder="请输入" />
                </view>
            </view>
            <card-details type="company" edit></card-details>
            <card-details type="quality" edit></card-details>
        </view>
        <template #bottom>
            <view class="submit-btn">
                <global-button type="primary" size="large">保存</global-button>
            </view>
        </template>
    </global-page>
</template>

<script setup>
import { ref } from 'vue'
import CardDetails from './components/card-details.vue'
</script>
<style lang="scss" scoped>
.content {
    padding-bottom: 140rpx;
    .form {
        background: #fff;
        &-item {
            display: flex;
            justify-content: space-between;
            padding: 24rpx 32rpx;
            border-bottom: 2rpx solid #f4f4f4;
            &-label {
                color: rgba(0, 0, 0, 0.9);
            }
            &-input {
                text-align: right;
            }
            &.textarea {
                flex-direction: column;
                textarea {
                    margin-top: 8rpx;
                    height: 80rpx;
                }
            }
        }
    }
}
.submit-btn {
    padding: 24rpx 32rpx;
    background-color: #fff;
}
</style>
