<template>
    <el-dialog v-model="props.modelValue" title="操作记录" @open="handleOpen" width="1000" @close="handleClose">
        <el-table :data="repairLogList" stripe>
            <el-table-column property="repairCode" label="维修单号" width="150" />
            <el-table-column property="user" label="操作人" />
            <el-table-column property="changeContent" label="内容" />
            <el-table-column property="ts" label="时间" width="200" />
            <el-table-column property="method" label="维修单状态" />
        </el-table>
    </el-dialog>
</template>

<script setup>
import { ref } from "vue";
import { selectRepairFLow} from "@/api/pms/repair";
const emit = defineEmits();
const props = defineProps({
    modelValue: Boolean,
    repairCode: {
        type: String,
        default: '',
    },
});
const baseUrl = import.meta.env.VITE_APP_BASE_API;
let column = ref(2);
let repairLogList = ref([]);
function handleOpen() {
    selectRepairFLow({repairCode: props.repairCode}).then(res => {
        repairLogList.value = res.data
    });
}

function handleClose() {
    emit('update:modelValue', false);
}
</script>

<style lang="scss" scoped></style>
