king
2021-11-18 c98e45bfac25e9110ad0383faac54a54d98ea9d5
src/views/printTemplate/option.js
@@ -288,6 +288,7 @@
    item.align = 'left'
    item.vertialAlign = 'top'
  } else if (type === 'barcode') {
    item.value = ''
    item.url = url
    item.barcodeType = 'code128'
    item.barcodeWidth = Math.floor(width * 0.6)
@@ -295,6 +296,7 @@
    item.barcodeLabel = 'true'
    item.fontSize = Math.floor(12 * (boxwidth / 210))
  } else if (type === 'qrcode') {
    item.value = ''
    item.url = url
    item.qrcodeType = 'qrcode'
    item.qrcodeWidth = Math.floor(height * 0.6)
@@ -313,6 +315,7 @@
      type: 'title',
      label: '类型',
      initval: '文本',
      class: 'text',
      required: false
    },
    {
@@ -336,6 +339,14 @@
      initval: item.field || '',
      required: false,
      options: fields
    },
    {
      type: 'text',
      key: 'cusfield',
      label: '自定义',
      initval: item.cusfield || '',
      required: true,
      hidden: true
    },
    {
      type: 'number',
@@ -466,6 +477,7 @@
      type: 'title',
      label: '类型',
      initval: '条形码',
      class: 'barcode',
      required: false
    },
    {
@@ -476,12 +488,27 @@
      required: false
    },
    {
      type: 'text',
      key: 'value',
      label: '内容',
      initval: item.value || '',
      required: false
    },
    {
      type: 'select',
      key: 'field',
      label: '关联字段',
      initval: item.field,
      required: true,
      required: false,
      options: fields
    },
    {
      type: 'text',
      key: 'cusfield',
      label: '自定义',
      initval: item.cusfield || '',
      required: true,
      hidden: true
    },
    {
      type: 'number',
@@ -612,6 +639,7 @@
      type: 'title',
      label: '类型',
      initval: '二维码',
      class: 'qrcode',
      required: false
    },
    {
@@ -622,12 +650,27 @@
      required: false
    },
    {
      type: 'text',
      key: 'value',
      label: '内容',
      initval: item.value || '',
      required: false
    },
    {
      type: 'select',
      key: 'field',
      label: '关联字段',
      initval: item.field,
      required: true,
      required: false,
      options: fields
    },
    {
      type: 'text',
      key: 'cusfield',
      label: '自定义',
      initval: item.cusfield || '',
      required: true,
      hidden: true
    },
    {
      type: 'number',
@@ -734,6 +777,7 @@
      type: 'title',
      label: '类型',
      initval: '图片',
      class: 'image',
      required: false
    },
    {
@@ -743,13 +787,21 @@
      initval: item.name,
      required: false
    },
    // {
    //   type: 'text',
    //   key: 'value',
    //   label: '图片地址',
    //   initval: item.value,
    //   required: false
    // },
    {
      type: 'fileupload',
      key: 'value',
      label: '图片地址',
      initval: item.value,
      required: false
    },
    {
      type: 'textarea',
      key: 'productValue',
      label: '正式地址',
      initval: item.productValue || '',
      tooltip: '正式系统使用的图片,为空时使用图片地址。',
      required: false
    },
    {
      type: 'select',
      key: 'field',
@@ -759,6 +811,14 @@
      options: fields
    },
    {
      type: 'text',
      key: 'cusfield',
      label: '自定义',
      initval: item.cusfield || '',
      required: true,
      hidden: true
    },
    {
      type: 'number',
      key: 'left',
      label: '距左',