gaoluyang
4 天以前 c1e2cf24e4fb89c3ff09841b7c3762e807a4076a
src/views/mes/pro/workorder/index.vue
@@ -32,7 +32,8 @@
    destroyOnClose: true,
  });
  const archiveDetailRef = ref<InstanceType<typeof ArchiveDetail>>();
  const archiveVisible = ref(false);
  const archiveProductCode = ref('');
// const barcodeDetailRef = ref<InstanceType<typeof BarcodeDetail>>(); // 条码详情弹窗
  /** 刷新表格 */
@@ -100,6 +101,12 @@
    await cancelWorkOrder(row.id!);
    message.success("订单已取消");
    handleRefresh();
  }
  /** 打开归档详情 */
  function handleArchive(row: MesProWorkOrderApi.WorkOrder) {
    archiveProductCode.value = row.productCode || '';
    archiveVisible.value = true;
  }
  /** 查看订单条码 */
@@ -237,7 +244,7 @@
              },
            },
            {
              label: $t('common.create'),
              label: '新增子订单',
              type: 'link',
              auth: ['mes:pro-work-order:create'],
              ifShow:
@@ -274,13 +281,13 @@
            {
              label: '归档',
              type: 'link',
              onClick: () => archiveDetailRef.value?.open(row.productCode),
              onClick: handleArchive.bind(null, row),
            },
          ]" />
      </template>
    </Grid>
    <!-- <BarcodeDetail ref="barcodeDetailRef" /> -->
    <ArchiveDetail ref="archiveDetailRef" />
    <ArchiveDetail :visible="archiveVisible" :product-code="archiveProductCode" @update:visible="archiveVisible = $event" />
  </Page>
</template>