Pārlūkot izejas kodu

自定义小纸张横向打印

Funny 2 gadi atpakaļ
vecāks
revīzija
383d315915
1 mainītis faili ar 6 papildinājumiem un 1 dzēšanām
  1. 6 1
      src/components/orderComponents/orderDetail.vue

+ 6 - 1
src/components/orderComponents/orderDetail.vue

@@ -326,10 +326,15 @@ export default {
           `width: ${this.params.cardWidth}mm;`,
           `width: ${this.params.cardHeight}mm;`
         );
-        console.log("html:", html);
+        html = html.replace(
+          `margin-right: ${this.params.paddingRight}mm`,
+          `margin-right: ${this.params.paddingRight + 15}mm`
+        );
       }
       html = html.replace(`</style>`, `</style><div class="card-a4">`);
       html = `${html}</div>`;
+
+      console.log("html:", html);
       let params = {
         orderId: this.orderDetail.orderId,
         shopId: this.orderDetail.shopId,