<template>
    <el-container>
        <el-header>
            <div class="left-panel">
            </div>
            <div class="right-panel">
                <el-date-picker
                    v-model="query.date"
                    type="date"
                    value-format="YYYY-MM-DD"
                />
                <el-button
                    type="primary"
                    icon="el-icon-search"
                    @click="handleQuery"
                >查询</el-button>
            </div>
        </el-header>
        <el-main class="nopadding">
            <scTable
                ref="table"
                :apiObj="apiObj"
                row-key="id"
                stripe
                :params="query"
            >
                <el-table-column type="index" width="50"/>
                <el-table-column label="日期" prop="name" show-overflow-tooltip>
                </el-table-column>
                <el-table-column label="工序" prop="number">
                </el-table-column>
                <el-table-column label="检测内容" prop="model">
                </el-table-column>
                <el-table-column label="检测标准" prop="factory" show-overflow-tooltip>
                </el-table-column>
                <el-table-column label="操作人测量值" prop="production_date">
                </el-table-column>
                <el-table-column label="操作人" prop="production_date">
                </el-table-column>
                <el-table-column label="专检人测量值" prop="buy_date">
                </el-table-column>
                <el-table-column label="专检人" prop="production_date">
                </el-table-column>
                <el-table-column label="结论" prop="production_date">
                </el-table-column>
                <!-- <el-table-column label="结论">
                <template #default="scope">
                    <el-tag v-if="scope.row.state===10" type="success">
                    {{ state_[scope.row.state] }}
                    </el-tag>
                    <el-tag v-else-if="scope.row.state===20" type="warning">
                    {{ state_[scope.row.state] }}
                    </el-tag>
                    <el-tag v-else-if="scope.row.state===30">
                    {{ state_[scope.row.state] }}
                    </el-tag>
                    <el-tag v-else type="danger">
                    {{ state_[scope.row.state] }}
                    </el-tag>
                </template>
                </el-table-column> -->
            </scTable>
        </el-main>
    </el-container>
</template>
<script>
    export default {
        name: "rparty",
        data() {
            return {
                // apiObj: this.$API.qm.list,
                apiObj:null,
                query: {
                    page:1,
                    page_size:20,
                    type:10
                },
                selection: [],
                state_: {
                    10: '',
                    20: '',
                },
            };
        },
        methods: {
            //查看
            table_show(row) {
                this.dialog.save = true;
                this.$nextTick(() => {
                    this.$refs.saveDialog.open("show",10).setData(row);
                });
            },
            handleQuery() {
                this.$refs.table.queryData(this.query)
            },
            resetQuery() {
                this.query = {};
            },
        },
    };
</script>