zouyu
2023-12-01 72ae3c97c344694addc7990b42ea0fc8ef513e7f
src/views/quality/Packaging_ledger/index.vue
@@ -20,7 +20,7 @@
                <div slot="header">
                <el-row>
                    <el-col :span="8">
                    <span>标准参数</span>
                    <span>装箱明细</span>
                    </el-col>
                    <el-col :span="8" :offset="4">
                    <!-- <el-button
@@ -118,7 +118,7 @@
        <!-- 新增 -->
        <packfrom
        :currshowlist.sync="addOrUpdateVisible"
        >
        @refreshDataList="getData">
        </packfrom>
        <packfromadd
        :currshowlist.sync="increase"
@@ -131,7 +131,7 @@
</template>
<script>
import { pagedata,dropById,list,saveList,deledata} from '@/api/quality/Packaging_ledger'
import { pagedata,dropById,list,saveList,deledata,sAuditstatus} from '@/api/quality/Packaging_ledger'
import ttable from '@/views/common/ztt-table.vue'
import packfrom from './pack-from.vue'
import packfromadd from './pack-fromadd.vue'
@@ -153,7 +153,8 @@
                border: true, // 是否有纵向边框
                lazy: false, // 是否需要懒加载
                fit: true, // 列的宽度是否自撑开
                multiSelect: true, //
                multiSelect: false, //
                isEdit:false,
                seqNo: true,
                isShowHide: true, // 是否显示显影按钮
                isRefresh: true, // 是否显示刷新按钮
@@ -242,11 +243,11 @@
                      size: 'small',
                      fun: this.deleteHandle
                    },{
                      text: 'xx',
                      text: '检验',
                      icon: 'el-icon-delete',
                      type: 'text',
                      size: 'small',
                      // fun: this.deleteHandle
                      fun: this.check
                    }
                  ],
                  operatorConfig: {
@@ -264,13 +265,7 @@
        packfromadd
        },
        watch: {
          // renovate() {
          //   if (this.innerVisible = false) {
          //     this.$nextTick(() => {
          //       this.getData()
          //     })
          //   }
          // }
      },
    methods: {
       // 获取数据列表
@@ -301,13 +296,16 @@
      },
      //详情添加
      relateOperationParam(){
        this.increase = true
      },
      preserve(datalist){
        console.log(datalist);
        this.testStandardParams = datalist
      },
      //右边保存
      addpreserve(){
        console.log(this.testStandardParams,"保存数据");
         this.testStandardParams.forEach(el => {
@@ -315,18 +313,32 @@
         });
        console.log(this.testStandardParams,"niaho");
        saveList(this.testStandardParams).then((res) =>{
          console.log(res,"保存的");
          this.$message.success('保存成功')
          this.testStandardParams
        })
      },
      //删除
      deleteadd(row){
          console.log(row,"");
          deledata({id:row.id}).then((res)=>{
          this.$message.success('删除成功')
          this.testStandardParams
          })
      }
      },
      //审核
      check(row){
        console.log(row,"审核");
        let packageBox = {
                id:row.id,
                packageNo:row.packageNo,
                contractNo:row.contractNo,
                customerId:row.customerId,
        }
        sAuditstatus(packageBox).then((res) =>{
          this.getData()
          this.$message.success('检验成功')
        })
      },
    },
    computed: {
  },