廖井涛
2024-09-05 8b2c74fb6842e8af60f70e7df6eef8837d74be07
north-glass-erp/northglass-erp/src/components/pp/PrintCustomLabelSemi.vue
@@ -30,7 +30,9 @@
  list:null,//勾选的数据
  faceOrientation:null,//内外面
  type:null,//标签模板
  lableType:null//标签类型
  lableType:null,//标签类型
  titleList:null,//标题
  switch:null//判断是否为新打印
})
const {currentRoute} = useRouter()
@@ -38,8 +40,8 @@
let type = props.type
let faceOrientation = props.faceOrientation
let lableType = props.lableType
let switchType = props.switch
data.value.printList = JSON.parse(props.list)
onMounted(() => {
      request.post(`/processCard/getSelectPrintCustomLabel/${type}/${lableType}`, data.value).then((res) => {
        if (res.code == 200) {
@@ -48,7 +50,11 @@
          list.value = deepClone(res.data.data)
          const data = produceList.value[0].value
          dataList = JSON.parse(`[${data}]`);
          labelList = dataList[0]
          if (switchType===true){
            labelList = props.titleList
          }else {
            labelList = dataList[0]
          }
          for (let i = 0; i < list.value.length; i++) {
            let count= list.value[i].data.length
            for (let j = 0; j < count; j++) {
@@ -59,7 +65,6 @@
          }
        } else {
          ElMessage.warning(res.msg)
          router.push("/login")
        }
      })