廖井涛
2024-08-05 43e115a7de2c763c36d79e610a3abb1d833ea892
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)
@@ -79,7 +79,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 +
@@ -112,7 +116,8 @@
        <span>{{ item.project }}</span>&nbsp;
        <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.processingNote }}</span>
@@ -175,10 +180,18 @@
  height: 25px;
  font-weight: bold;
  font-size: 15pt;
  margin-left: 40px;
}
.row1 span{
  font-size: 15pt;
}
.row2 span{
  font-size: 15pt;
}
.row5 span{
  font-size: 10pt;
  font-size: 15pt;
}
.row6 {
@@ -189,16 +202,17 @@
@page {
  size: auto;  /* auto is the initial value */
  margin: 12mm 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>