Browse Source

4.0.35 增加打印机设备管理页面

liuyanpeng 2 years ago
parent
commit
5d25444162

+ 1 - 1
package.json

@@ -1,7 +1,7 @@
 {
   "name": "client-base-v4",
   "description": "Leanwo Prodog Client",
-  "version": "4.0.33",
+  "version": "4.0.35",
   "author": "yangzhijie1488 <yangzhijie1488@163.com>",
   "scripts": {
     "dev": "cross-env webpack serve --config ./webpack.dev.js",

+ 90 - 0
src/api/printer/printerConfiguration.js

@@ -0,0 +1,90 @@
+import Common from '../../common/Common.js';
+
+// 查询当前公司全部打印机配置
+export const queryAllPrinters = () => {
+  const requestUrl = 'PrinterConfigurationResource/selectAll';
+  return new Promise((resolve, reject) => {
+    $.ajax({
+      url: Common.getApiURL(requestUrl),
+      type: 'get',
+      contentType: 'application/json',
+      dataType: 'json',
+      beforeSend: function (request) {
+        Common.addTokenToRequest(request);
+      },
+      success: function (data) {
+        resolve(data);
+      },
+      error: function (XMLHttpRequest, textStatus, errorThrown) {
+        reject(XMLHttpRequest);
+      },
+    });
+  });
+};
+
+// 根据id查询打印机配置
+export const queryById = id => {
+  const requestUrl = `PrinterConfigurationResource/selectById?id=${id}`;
+  return new Promise((resolve, reject) => {
+    $.ajax({
+      url: Common.getApiURL(requestUrl),
+      type: 'get',
+      contentType: 'application/json',
+      dataType: 'json',
+      beforeSend: function (request) {
+        Common.addTokenToRequest(request);
+      },
+      success: function (data) {
+        resolve(data);
+      },
+      error: function (XMLHttpRequest, textStatus, errorThrown) {
+        reject(XMLHttpRequest);
+      },
+    });
+  });
+};
+
+// 新增或修改打印机配置
+export const saveOrUpdate = params => {
+  const requestUrl = 'PrinterConfigurationResource/saveOrUpdate';
+  return new Promise((resolve, reject) => {
+    $.ajax({
+      url: Common.getApiURL(requestUrl),
+      type: 'post',
+      contentType: 'application/json',
+      data: JSON.stringify(params),
+
+      beforeSend: function (request) {
+        Common.addTokenToRequest(request);
+      },
+      success: function (data) {
+        resolve(data);
+      },
+      error: function (XMLHttpRequest, textStatus, errorThrown) {
+        reject(XMLHttpRequest);
+      },
+    });
+  });
+};
+
+// 根据id删除打印机配置
+export const deleteById = id => {
+  const requestUrl = `PrinterConfigurationResource/deleteById?id=${id}`;
+  return new Promise((resolve, reject) => {
+    $.ajax({
+      url: Common.getApiURL(requestUrl),
+      type: 'delete',
+      contentType: 'application/json',
+
+      beforeSend: function (request) {
+        Common.addTokenToRequest(request);
+      },
+      success: function (data) {
+        resolve(data);
+      },
+      error: function (XMLHttpRequest, textStatus, errorThrown) {
+        reject(XMLHttpRequest);
+      },
+    });
+  });
+};

+ 116 - 0
src/api/printer/printerWebsocket.js

@@ -0,0 +1,116 @@
+
+import { Uuid } from 'pc-component-v3';
+// import Common from '../../common/Common.js';
+
+
+export default {
+
+  webSocket: null,
+
+  // 获取mac地址
+  getMacAddress: function () {
+    const _self = this;
+    const command = {
+      id: Uuid.createUUID(),
+      command: 'getMacAddress',
+    };
+    const commandStr = JSON.stringify(command);
+    return new Promise((resolve, reject) => {
+      _self.connectNodeRed(resolve, reject, commandStr);
+    });
+  },
+  // 获取打印机
+  getPrinters: function () {
+    const _self = this;
+    const command = {
+      id: Uuid.createUUID(),
+      command: 'getPrinters',
+    };
+    const commandStr = JSON.stringify(command);
+    return new Promise((resolve, reject) => {
+      _self.connectNodeRed(resolve, reject, commandStr);
+    });
+  },
+
+  // 执行打印
+  print: function (prnData) {
+    const _self = this;
+    const command = {
+      id: Uuid.createUUID(),
+      command: 'print',
+      data: prnData,
+    };
+    const commandStr = JSON.stringify(command);
+    return new Promise((resolve, reject) => {
+      _self.connectNodeRed(resolve, reject, commandStr);
+    });
+  },
+
+  // 取消打印
+  cancelAllTask: function (prnData) {
+    const _self = this;
+    const command = {
+      id: Uuid.createUUID(),
+      command: 'cancelAllTask',
+      data: prnData,
+    };
+    const commandStr = JSON.stringify(command);
+    return new Promise((resolve, reject) => {
+      _self.connectNodeRed(resolve, reject, commandStr);
+    });
+  },
+
+
+  // 连接node red的websocket
+  connectNodeRed: function (resolve, reject, commandStr) {
+    const _self = this;
+    let printers = null;
+    let socketUrl = 'ws://192.168.1.11:10092';
+
+    _self.webSocket = new WebSocket(socketUrl);
+    _self.webSocket.onopen = function (event) {
+      console.log('打印 Websocket 连接成功。');
+      if (commandStr != null && commandStr.length > 0) {
+        _self.sendCommand(commandStr);
+      } else {
+        _self.close();
+      }
+    };
+    _self.webSocket.onclose = function (event) {
+      console.log('打印 Websocket 断开连接。');
+      resolve(printers);
+    };
+    _self.webSocket.onerror = function (event) {
+      console.log('打印 Websocket 出错。');
+      _self.close();
+      reject();
+    };
+    _self.webSocket.onmessage = function (event) {
+      const data = JSON.parse(event.data);
+      printers = data;
+      _self.close();
+    };
+  },
+
+
+  /**
+           * WebSocket 发送指令
+           * @param {指令} command 
+           */
+  sendCommand: function (command) {
+    if (this.webSocket) {
+      this.webSocket.send(command);
+    }
+  },
+
+  /**
+           * 关闭Websocket
+           */
+  close: function () {
+    if (this.webSocket) {
+      this.webSocket.close();
+      this.webSocket = null;
+    };
+  },
+};
+

+ 226 - 0
src/common/CommonTable.vue

@@ -0,0 +1,226 @@
+<template>
+  <div class="tablePaganations">
+    <a-config-provider :locale="locale">
+      <a-table
+        class="ant-table-striped"
+        bordered
+        size="small"
+        height="1000px"
+        :loading="isLoading"
+        :data-source="dataSource"
+        :columns="columns"
+        :row-key="(record) => record.id"
+        :scroll="scroll"
+        :pagination="havePage ? pagination : false"
+        :row-class-name="
+          (_record, index) => (index % 2 === 1 ? 'table-striped' : null)
+        "
+        :row-selection="
+          isSelect
+            ? {
+              selectedRowKeys: state.selectedRowKeys,
+              onSelect: selectEvent,
+              onSelectAll: selectAllEvent,
+            }
+            : null
+        "
+        @change="tableChange"
+        @resize-column="handleResizeColumn"
+      >
+        <template
+          v-for="(item, index) in renderArr"
+          #[item]="scope"
+          :key="index"
+        >
+          <slot :name="item" :scope="scope" v-bind="scope || {}" />
+        </template>
+      </a-table>
+    </a-config-provider>
+  </div>
+</template>
+  
+<script setup>
+import {
+  useSlots,
+  ref,
+  reactive,
+  defineProps,
+  defineEmits,
+  defineExpose,
+  watch,
+} from 'vue';
+import zhCN from 'ant-design-vue/lib/locale-provider/zh_CN';
+const locale = ref(zhCN);
+const props = defineProps({
+  dataSource: {
+    type: Object,
+    required: true,
+  },
+  columns: {
+    type: Object,
+    required: true,
+  },
+  isSelect: {
+    type: Boolean,
+  },
+  isLoading: {
+    type: Boolean,
+  },
+  total: {
+    type: Number,
+    default: 0,
+  },
+  havePage: {
+    type: Boolean,
+    default: true,
+  },
+  scroll: {
+    type: Object,
+    default: () => ({ y: 400 }),
+  },
+  selectedKeys: {
+    type: Array,
+    default: () => [],
+  },
+});
+
+const emit = defineEmits(['getPager', 'getSorter', 'getSelected']);
+
+// 分页配置
+const pagination = reactive({
+  showQuickJumper: true,
+  current: 1,
+  pageSize: 20, // 默认每页显示数量
+  showSizeChanger: true, // 显示可改变每页数量
+  pageSizeOptions: ['10', '20', '50', '100', '200', '500'], // 每页数量选项值
+  showTotal: (total, range) =>
+    range[0] + '-' + range[1] + '条' + ' 共' + total + '条', // 显示总数
+  onShowSizeChange: (current, pageSize) => showSizeChange(current, pageSize),
+  onChange: (current, pageSize) => changePage(current, pageSize), //点击页码事件
+  total: props.total,
+});
+
+// 最后一次排序信息
+const lastSorter = reactive({ field: '', order: '' });
+
+//  选择的数据
+const state = reactive({
+  selectedRows: [],
+  selectedRowKeys: [],
+});
+
+//点击页码事件
+const changePage = (current, size) => {
+  pagination.current = current;
+  emit('getPager', pagination.current, size);
+};
+
+// 改变每页数量时更新显示
+const showSizeChange = (current, pageSize) => {
+  setTimeout(() => {
+    pagination.current = 1;
+    emit('getPager', pagination.current, pageSize);
+  });
+  pagination.pageSize = pageSize;
+};
+
+// 回到第一页
+const backFirstPage = () => {
+  pagination.current = 1;
+  emit('getPager', pagination.current, pagination.pageSize);
+};
+
+// 伸缩列
+const handleResizeColumn = (w, col) => {
+  col.width = w;
+};
+
+// 选择每一项操作
+const selectEvent = (record, selected) => {
+  if (selected) {
+    state.selectedRows.push(record);
+    state.selectedRowKeys.push(record.id);
+  } else {
+    let index = state.selectedRowKeys.indexOf(record.id);
+    if (index >= 0) {
+      state.selectedRows.splice(index, 1);
+      state.selectedRowKeys.splice(index, 1);
+    }
+  }
+  emit('getSelected', state);
+};
+
+// 点击以后全选当前分页数据
+const selectAllEvent = (selected, selectedRows, changeRows) => {
+  if (selected) {
+    changeRows.forEach(item => {
+      state.selectedRows.push(item);
+      state.selectedRowKeys.push(item.id);
+    });
+  } else {
+    changeRows.forEach(item => {
+      let index = state.selectedRowKeys.indexOf(item.id);
+      if (index >= 0) {
+        state.selectedRows.splice(index, 1);
+        state.selectedRowKeys.splice(index, 1);
+      }
+    });
+  }
+  emit('getSelected', state);
+};
+
+// 清空选择
+const clear = () => {
+  state.selectedRowKeys = [];
+  state.selectedRows = [];
+  emit('getSelected', state);
+};
+
+// 获取排序信息
+const tableChange = (pagination, filters, sorter) => {
+  // pagination, filters 变化时也会触发所以对sorter进行判断限制执行
+  if (Object.keys(sorter).length > 0) {
+    if (sorter.field != lastSorter.field && sorter.order != lastSorter.order) {
+      lastSorter.field = sorter.field;
+      lastSorter.order = sorter.order;
+      emit('getSorter', sorter);
+    }
+    if (sorter.field != lastSorter.field && sorter.order == lastSorter.order) {
+      lastSorter.field = sorter.field;
+      lastSorter.order = sorter.order;
+      emit('getSorter', sorter);
+    }
+    if (sorter.field == lastSorter.field && sorter.order != lastSorter.order) {
+      lastSorter.field = sorter.field;
+      lastSorter.order = sorter.order;
+      emit('getSorter', sorter);
+    }
+  }
+};
+
+// 暴露出方法
+defineExpose({ backFirstPage, clear });
+
+// 监听total变化
+watch(
+  props,
+  newData => {
+    pagination.total = newData.total;
+  },
+  { immediate: true, deep: true },
+);
+// 插槽的实例
+const slots = useSlots();
+const renderArr = Object.keys(slots);
+</script>
+<style scoped>
+.tablePaganations {
+  width: 100%;
+  margin-top: 8px;
+}
+.ant-table-striped :deep(.table-striped) td {
+  background-color: #fafafa;
+}
+</style>
+  
+  

+ 26 - 0
src/common/tableScroll.js

@@ -0,0 +1,26 @@
+/**
+* 获取表格的可视化高度
+* @param {*} extraHeight 额外的高度(表格底部的内容高度) 
+* @param {*} id 当前页面中有多个table时需要制定table的id
+*/
+export const getTableScroll = ({ extraHeight, id }) => {
+  if (typeof extraHeight == 'undefined') {
+    //  默认底部分页
+    extraHeight = 50;
+  }
+  let tHeader = null;
+  if (id) {
+    tHeader = document.getElementById(id) ?
+      document.getElementById(id).getElementsByClassName('ant-table-thead')[0] : null;
+  } else {
+    tHeader = document.getElementsByClassName('ant-table-thead')[0];
+  }
+  //表格内容距离顶部的距离
+  let tHeaderBottom = 0;
+  if (tHeader) {
+    tHeaderBottom = tHeader.getBoundingClientRect().bottom;
+  }
+  //窗体高度-表格内容顶部的高度-表格内容底部的高度
+  let height = `calc(100vh - ${tHeaderBottom + extraHeight}px)`;
+  return { y: height };
+};

+ 2 - 1
src/index.js

@@ -75,7 +75,7 @@ import ArchivalRecord from '../src/archive/ArchivalRecord.vue';
 import IdentityManager  from '../src/identity/IdentityManager.vue';
 import CreateIdentity  from '../src/identity/CreateIdentity.vue';
 import SamlLogin  from './client/SamlLogin.vue';
-
+import PrinterConfiguration from '../src/printer/PrinterConfiguration.vue';
 
 export {
   App,
@@ -141,4 +141,5 @@ export {
   ExcelImport,
   IdentityManager,
   CreateIdentity,
+  PrinterConfiguration,
 };

+ 334 - 0
src/printer/PrinterConfiguration.vue

@@ -0,0 +1,334 @@
+<template>
+  <Navbar title="设备管理" :is-go-back="false" />
+  <main>
+    <a-button @click="editPrinter(true)">添加打印机</a-button>
+    <CommonTable
+      id="printTable"
+      :have-page="false"
+      :y-scroll="yScroll"
+      :columns="printerColumns"
+      :data-source="printerDatas"
+    >
+      <template #bodyCell="{ record, column }">
+        <template v-if="column.key === 'operation'">
+          <span>
+            <a @click="editPrinter(false, record)">编辑</a>
+            <a-divider type="vertical" />
+            <a @click="deletePrinter(record.id)">删除</a>
+          </span>
+        </template>
+      </template>
+    </CommonTable>
+
+    <a-modal
+      v-model:visible="editVisible"
+      :title="editTitle"
+      width="800px"
+      ok-text="保存配置"
+      cancel-text="取消"
+      @ok="saveOrUpdateSetting"
+    >
+      <a-form :model="printerState">
+        <a-row :gutter="24">
+          <a-col :span="11">
+            <a-form-item
+              label="打印机名称"
+              :label-col="{ span: 8 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-select
+                v-model:value="printerState.printerName"
+                style="width: 220px"
+                :options="printerNames"
+              />
+            </a-form-item>
+          </a-col>
+          <a-col :span="11">
+            <a-form-item
+              label="打印机类型"
+              :label-col="{ span: 10 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-select
+                v-model:value="printerState.printerType"
+                style="width: 220px"
+              >
+                <a-select-option value="GK888">GK888</a-select-option>
+                <a-select-option value="Zebra">Zebra</a-select-option>
+                <a-select-option value="TOSHIBA">TOSHIBA</a-select-option>
+                <a-select-option value="蓝牙打印机">蓝牙打印机</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="24">
+          <a-col :span="11">
+            <a-form-item
+              label="旋转角度"
+              :label-col="{ span: 8 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-select v-model:value="printerState.rotateAngel">
+                <a-select-option value="0">0</a-select-option>
+                <a-select-option value="90">90</a-select-option>
+                <a-select-option value="180">180</a-select-option>
+                <a-select-option value="270">270</a-select-option>
+              </a-select>
+            </a-form-item>
+          </a-col>
+          <a-col :span="11">
+            <a-form-item
+              label="支持RFID功能"
+              :label-col="{ span: 10 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-checkbox v-model:checked="printerState.supportRfid" />
+              <a-checkbox
+                v-if="printerState.supportRfid"
+                v-model:checked="printerState.enableWritePassword"
+                style="margin-left: 40px"
+              >
+                写入密码
+              </a-checkbox>
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row v-if="printerState.enableWritePassword" :gutter="24">
+          <a-col :span="11">
+            <a-form-item
+              label="访问密码"
+              :label-col="{ span: 8 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input
+                v-model:value="printerState.accessPassword"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+          <a-col :span="11">
+            <a-form-item
+              label="杀死密码"
+              :label-col="{ span: 10 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input
+                v-model:value="printerState.killPassword"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="24">
+          <a-col :span="11">
+            <a-form-item
+              label="打印深度"
+              :label-col="{ span: 8 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input-number
+                v-model:value="printerState.darkness"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+          <a-col :span="11">
+            <a-form-item
+              label="进纸方向偏移(mm)"
+              :label-col="{ span: 10 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input-number
+                v-model:value="printerState.offsetHeight"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="24">
+          <a-col :span="11">
+            <a-form-item
+              label="标签后退距离"
+              :label-col="{ span: 8 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input-number
+                v-model:value="printerState.backLength"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+          <a-col :span="11">
+            <a-form-item
+              label="水平方向偏移(mm)"
+              :label-col="{ span: 10 }"
+              :wrapper-col="{ span: 16 }"
+            >
+              <a-input-number
+                v-model:value="printerState.offsetWidth"
+                style="width: 220px"
+              />
+            </a-form-item>
+          </a-col>
+        </a-row>
+      </a-form>
+    </a-modal>
+  </main>
+</template>
+
+<script setup>
+import Common from '../common/Common';
+import { message } from 'ant-design-vue';
+import { tableColumns } from './configData.js';
+import { ref, reactive, onMounted } from 'vue';
+import CommonTable from '../common/CommonTable.vue';
+import { getTableScroll } from '../common/tableScroll.js';
+import PrintUtil from '../api/printer/printerWebsocket.js';
+import {
+  deleteById,
+  saveOrUpdate,
+  queryAllPrinters,
+} from '../api/printer/printerConfiguration.js';
+
+const yScroll = ref();
+const editTitle = ref('');
+const printerDatas = ref([]);
+const printerNames = ref([]);
+const editVisible = ref(false);
+const printerColumns = ref(tableColumns);
+const printerState = ref({
+  printerName: '',
+  printerType: undefined,
+  supportRfid: false,
+  enableWritePassword: false,
+  accessPassword: '',
+  killPassword: '',
+  rotateAngel: 0,
+  backLength: 0,
+  offsetHeight: 0,
+  offsetWidth: 0,
+  darkness: 15,
+});
+const base = reactive({
+  clientId: '',
+  macAddress: '',
+});
+const createState = ref({});
+// 编辑打印机配置
+const editPrinter = (flag, record) => {
+  editVisible.value = true;
+  if (flag) {
+    editTitle.value = '添加打印机';
+    printerState.value = JSON.parse(JSON.stringify(createState.value));
+  } else {
+    editTitle.value = '编辑打印机';
+    printerState.value = record;
+  }
+  getPrinterNames();
+};
+
+onMounted(() => {
+  base.clientId = JSON.parse(localStorage.getItem('#LoginInfo')).loginClientId;
+  createState.value = JSON.parse(JSON.stringify(printerState.value));
+  yScroll.value = getTableScroll({ id: 'printTable' });
+  getMacAddress();
+  queryPrinters();
+});
+
+// 获取mac地址
+const getMacAddress = () => {
+  PrintUtil.getMacAddress().then(
+    success => {
+      base.macAddress = success.data;
+    },
+    err => {
+      console.log(err);
+    },
+  );
+};
+
+// 获取所有打印机名称
+const getPrinterNames = () => {
+  PrintUtil.getPrinters().then(
+    success => {
+      if (success.errorCode === 0) {
+        if (success.data && success.data.length > 0) {
+          printerNames.value = success.data.map(item => {
+            return (item = {
+              value: item,
+              label: item,
+            });
+          });
+        }
+      } else {
+        message.warning(success.errorMessage);
+      }
+    },
+    error => {
+      console.log(error);
+    },
+  );
+};
+
+// 获取所有打印配置
+const queryPrinters = () => {
+  queryAllPrinters().then(
+    success => {
+      if (success.errorCode === 0) {
+        if (success.datas && success.datas.length > 0) {
+          printerDatas.value = success.datas;
+        }
+      } else {
+        message.warning(success.errorMessage);
+      }
+    },
+    err => {
+      Common.processException(err);
+    },
+  );
+};
+
+//新增或更新打印配置
+const saveOrUpdateSetting = () => {
+  const printerInfo = JSON.parse(JSON.stringify(printerState.value));
+  const params = { ...printerInfo, ...base };
+  saveOrUpdate(params).then(
+    success => {
+      if (success.errorCode === 0) {
+        if (editTitle.value === '添加打印机') {
+          message.success('添加打印机配置成功。');
+        } else {
+          message.success('更新打印机配置成功。');
+        }
+        editVisible.value = false;
+        queryPrinters();
+      } else {
+        message.warning(success.errorMessage);
+      }
+    },
+    err => {
+      Common.processException(err);
+    },
+  );
+};
+
+// 删除打印机配置
+const deletePrinter = id => {
+  deleteById(id).then(
+    success => {
+      if (success.errorCode === 0) {
+        message.success('删除打印机配置成功。');
+        queryPrinters();
+      } else {
+        message.warning(success.errorMessage);
+      }
+    },
+    err => {
+      Common.processException(err);
+    },
+  );
+};
+</script>
+
+<style scoped>
+</style>

+ 43 - 0
src/printer/configData.js

@@ -0,0 +1,43 @@
+
+export const tableColumns =
+  [
+    {
+      title: '序号',
+      dataIndex: 'index',
+      key: 'index',
+      width: 75,
+      customRender: ({ text, record, index }) => `${index + 1}`,
+    },
+    {
+      title: '设备名称',
+      key: 'printerName',
+      dataIndex: 'printerName',
+      width: 150,
+    },
+    {
+      title: '设备类型',
+      key: 'printerType',
+      dataIndex: 'printerType',
+      width: 150,
+    },
+    {
+      title: '设备名称',
+      key: 'printerName',
+      dataIndex: 'printerName',
+      width: 150,
+    },
+    {
+      title: '操作',
+      key: 'operation',
+      dataIndex: 'operation',
+      width: 150,
+    },
+  ].map(item => ({
+    ...item,
+    align: 'center',
+    resizable: true,
+    mainWidth: 75,
+    maxWidth: 400,
+  }));
+
+

+ 3 - 0
src/routes/main_routes.js

@@ -65,6 +65,7 @@ const ExcelImport = () => import('../customer/ExcelImport.vue');
 const IdentityManager = () => import('../identity/IdentityManager.vue');
 const CreateIdentity = () => import('../identity/CreateIdentity.vue');
 const SamlLogin = () => import('../client/SamlLogin.vue');
+const PrinterConfiguration = () => import('../printer/PrinterConfiguration.vue');
 
 import { ProcessReport } from 'pc-component-v3';
 
@@ -383,6 +384,8 @@ export default [
       { path: '/desktop/excelImport', component: ExcelImport },
       { path: '/desktop/identityManager', component: IdentityManager }, // 身份源管理
       { path: '/desktop/createIdentity', name:'createIdentity',component: CreateIdentity }, // 身份源管理
+      { path: '/desktop/printerConfiguration', component: PrinterConfiguration },
+
     ],
   },
 ];