guoyuji
2024-09-12 a366f8e668f28a92b920838637edb108e29f0c2a
north-glass-erp/northglass-erp/src/views/pp/processCard/PrintCustomLabel1.vue
@@ -35,7 +35,7 @@
const lableType = route.query.lableType
onMounted(() => {
      request.post(`/processCard/getSelectPrintCustomLabel/${type}/${lableType}`, data.value).then((res) => {
      request.post(`/processCard/getSelectPrintCustomLabel/${type}/1`, data.value).then((res) => {
        if (res.code == 200) {
          produceList.value = deepClone(res.data.title)
          list.value = deepClone(res.data.data)
@@ -50,7 +50,6 @@
              }
            }
          }
          console.log(lastList.value)
        } else {
          ElMessage.warning(res.msg)
          router.push("/login")
@@ -79,7 +78,11 @@
  style.innerHTML =
      "body>#" +
      printId +
      "{display:none}@media print{body>:not(#" +
      "{display:none}@media print{" +
      "@page {" +
      "    size: auto; " +
      "    margin: 12mm 4mm 2mm 6mm; " +
      "  }body>:not(#" +
      printId +
      "){display:none !important}body>#" +
      printId +
@@ -110,11 +113,12 @@
      </div>
      <div  class="row2">
        <span>{{ item.project }}</span>&nbsp;
        <span>{{ item.building_number }}</span>
        <span>{{ item.buildingNumber }}</span>
      </div>
      <div class="row3">{{item.width}}*{{item.height}}={{item.quantity}}</div>
      <div class="row3" v-if="item.other_columns!=null&&(JSON.parse(item.other_columns).S02!=null)">{{JSON.parse(item.other_columns).S02}}={{item.quantity}}</div>
      <div class="row3" v-else>{{Math.round(item.width)}}x{{Math.round(item.height)}}={{item.quantity}}</div>
      <div class="row5">
        <span>{{item.remarks}}</span>&nbsp;
        <span>{{item.filmNumber}}</span>&nbsp;
        <span>{{ item.processingNote }}</span>
      </div>
    </div>
@@ -159,7 +163,7 @@
  height: 25px;
}
span {
  font-size: 12pt;
  font-size: 15pt;
  font-weight: bold;
}
@@ -171,9 +175,22 @@
}
.row5 {
  text-align: left;
  height: 25px;
  font-weight: bold;
  font-size: 12pt;
  font-size: 15pt;
  margin-left: 40px;
}
.row1 span{
  font-size: 15pt;
}
.row2 span{
  font-size: 15pt;
}
.row5 span{
  font-size: 15pt;
}
.row6 {
@@ -184,16 +201,17 @@
@page {
  size: auto;  /* auto is the initial value */
  margin: 7mm 4mm 2mm 6mm  /* this affects the margin in the printer settings */
}
@media print {
  div {
    page-break-inside: avoid;
  }
  @page {
    size: auto;  /* auto is the initial value */
    margin: 12mm 4mm 2mm 6mm;  /* this affects the margin in the printer settings */
  }
}
</style>