licp
2024-03-22 e2140d53c0d017da55bbebc22a24671662febd12
完成部分检验任务前端
已修改1个文件
已添加1个文件
171 ■■■■■ 文件已修改
src/components/do/b1-inspect-order-plan/Inspection.vue 157 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/view/b1-inspect-order-plan.vue 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/do/b1-inspect-order-plan/Inspection.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,157 @@
<style scoped>
    .ins-order-plan-main .title {
        height: 60px;
        line-height: 60px;
    }
    .ins-order-plan-main .search {
        width: 100%;
        margin-bottom: 10px;
        height: 140px;
        background-color: #fff;
        border-radius: 3px;
    }
    .search .form-inline {
        height: 50px;
        padding-top: 20px;
        padding-left: 50px;
    }
    .ins-order-plan-main .center {
        width: calc(100% - 40px);
        height: calc(100% - 60px - 80px - 40px);
        background-color: #fff;
        border-radius: 3px;
        padding: 20px;
    }
</style>
<style>
    .ins-order-plan-main .el-form-item__label{
        color: #000;
    }
  .el-drawer__header::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 30.24px;
    background: #3A7BFA;
    border-radius: 10px;
    margin-left: 32px;
    margin-right: 8.5px;
  }
  .el-drawer__header{
    color: #303133;
  }
</style>
<template>
    <div class="ins-order-plan-main">
        <el-row class="title">
                    <el-col :span="12" style="padding-left: 20px;">样品详情</el-col>
                    <el-col :span="12" style="text-align: right;">
                        <el-button size="small" type="primary" @click="sampleVisible=true">样品切换</el-button>
            <el-button size="small" type="primary" @click="taskVisible=true">任务切换</el-button>
            <el-button size="small" @click="$emit('goback')">返回</el-button>
                    </el-col>
                </el-row>
        <div class="search">
            <el-form :inline="true" :model="searchForm" class="form-inline">
                <el-form-item label="委托编号:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
                <el-form-item label="样品编号:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="样品名称:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="样品数量:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="下发时间:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="紧急程度:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="约定时间:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="当前样品数:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
            </el-form>
        </div>
        <div class="center">
        </div>
    <el-drawer
      title="样品切换"
      :visible.sync="sampleVisible"
      :destroy-on-close="true"
      size="55%">
      <el-table class="el-table" ref="productTable" :data="productList" height="100%" tooltip-effect="dark" border highlight-current-row @row-click="handleChangeSample">
                <el-table-column type="index" align="center" label="序号" width="70" :key="Math.random()">
                </el-table-column>
                <el-table-column prop="inspectionItemSubclass" label="样品编号" min-width="100"
                    show-overflow-tooltip></el-table-column>
                <el-table-column prop="sonLaboratory" label="检测状态" min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="method" label="检测人" min-min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="unit" label="是否留样" min-width="100" show-overflow-tooltip></el-table-column>
            </el-table>
    </el-drawer>
    <el-drawer
      title="任务切换"
      :visible.sync="taskVisible"
      :destroy-on-close="true"
      size="55%">
      <el-table class="el-table" ref="productTable" :data="productList" height="100%" tooltip-effect="dark" border highlight-current-row @row-click="handleChangeTask">
                <el-table-column prop="inspectionItemSubclass" label="委托编号" min-width="100"
                    show-overflow-tooltip></el-table-column>
                <el-table-column prop="sonLaboratory" label="样品编号" min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="method" label="样品名称" min-min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="unit" label="紧急程度" min-width="100" show-overflow-tooltip>
          <template slot-scope="scope">
            <el-tag
              :type="scope.row.type" size="medium">{{scope.row.label}}</el-tag>
                    </template>
        </el-table-column>
        <el-table-column prop="unit" label="状态" min-width="100" show-overflow-tooltip>
          <template slot-scope="scope">
            <el-tag
              :type="scope.row.type" size="medium">{{scope.row.label}}</el-tag>
                    </template>
        </el-table-column>
        <el-table-column prop="method" label="约定时间" min-min-width="100" show-overflow-tooltip></el-table-column>
        <el-table-column prop="method" label="下发时间" min-min-width="100" show-overflow-tooltip></el-table-column>
            </el-table>
    </el-drawer>
    </div>
</template>
<script>
    export default {
        data() {
            return {
        sampleVisible:false,
        taskVisible:false,
                searchForm: {
                    sampleName: null,
                    state: null
                },
        productList:[]
            }
        },
        created() {
        },
        methods: {
      handleChangeSample(row){
        console.log(1111111111,row)
        this.sampleVisible = false;
      },
      handleChangeTask(row){
        console.log(222222222,row)
        this.taskVisible = false;
      }
        }
    }
</script>
src/components/view/b1-inspect-order-plan.vue
@@ -82,8 +82,8 @@
</style>
<template>
    <div class="ins-order-plan-main">
        <p style="font-size: 16px;padding:19.5px 0px">检验任务</p>
        <div class="search">
        <p style="font-size: 16px;padding:19.5px 0px" v-show="state==0">检验任务</p>
        <div class="search" v-show="state==0">
            <el-form :inline="true" :model="searchForm" class="form-inline">
                <el-form-item label="样品名称:">
                    <el-input clearable v-model="searchForm.sampleName" size="small" placeholder="请输入"></el-input>
@@ -100,7 +100,7 @@
                </el-form-item>
            </el-form>
        </div>
        <div class="center">
        <div class="center" v-show="state==0">
            <div class="center-options">
                <el-row>
                    <el-col :span="21">
@@ -127,6 +127,7 @@
                :url="$api.insOrderPlan.selectInsOrderPlanList" :upUrl="$api.user.updateUser" :componentData="componentData"
                :key="upIndex" @upUser="upUser" />
        </div>
    <Inspection v-if="state==1" @goback="state=0"/>
        <el-dialog title="提示" :visible.sync="claimVisible" width="400px">
            æ˜¯å¦è®¤é¢†å§”托编号<span style="color:#33C130">{{sampleUserForm.entrustCode}}</span>的任务
            <span slot="footer" class="dialog-footer">
@@ -139,12 +140,14 @@
<script>
    import ValueTable from '../tool/value-table.vue'
  import Inspection from '../do/b1-inspect-order-plan/Inspection.vue'
    import {
        getYearAndMonthAndDays
    } from '../../util/date'
    export default {
        components: {
            ValueTable
            ValueTable,
      Inspection
        },
        data() {
            return {
@@ -219,7 +222,8 @@
                },
                upIndex: 0,
                planTotal: 0,
                insStateList: []
                insStateList: [],
        state:0//0:台账页,1:检验页面,默认为0
            }
        },
        created() {