|
|
@@ -60,20 +60,21 @@
|
|
|
<div class="table-operator" style="margin: 15px 0">
|
|
|
<a-button type="primary" icon="plus" @click="handleAdd">新增</a-button>
|
|
|
<a-button ghost type="danger" @click="handleExportXls()">导出数据(含报废)</a-button>
|
|
|
- <a-button ghost type="danger" @click="handleExportCode()">批量导出二维码</a-button>
|
|
|
- <a-dropdown v-if="selectedRowKeys.length > 0">
|
|
|
+
|
|
|
+ <a-dropdown type="danger">
|
|
|
<a-menu slot="overlay">
|
|
|
- <a-menu-item key="1" @click="batchDel">
|
|
|
- <a-icon type="delete" />
|
|
|
- 删除
|
|
|
+ <a-menu-item key="0" @click="handleExportCode()">
|
|
|
+ 导出选中
|
|
|
+ </a-menu-item>
|
|
|
+ <a-menu-item key="1" @click="handleExportCodeAll()">
|
|
|
+ 导出全部
|
|
|
</a-menu-item>
|
|
|
</a-menu>
|
|
|
<a-button style="margin-left: 8px">
|
|
|
- 批量操作
|
|
|
+ 批量导出二维码
|
|
|
<a-icon type="down" />
|
|
|
</a-button>
|
|
|
</a-dropdown>
|
|
|
-
|
|
|
<a-dropdown v-if="selectedRowKeys.length > 0">
|
|
|
<a-menu slot="overlay">
|
|
|
<a-menu-item key="1" @click="batchDel">
|
|
|
@@ -159,6 +160,7 @@ export default {
|
|
|
delete: '/business/safetool/base/safety/tool/',
|
|
|
exportXlsUrl: '/business/safetool/base/safety/tool/export',
|
|
|
qrcode: '/st/export',
|
|
|
+ qrcodeAll: '/st/exportAll',
|
|
|
tree: '/system/dept/treeSelect',
|
|
|
importExcelUrl: `${process.env.VUE_APP_BASE_API}/importExcelUrl`
|
|
|
}
|
|
|
@@ -200,6 +202,15 @@ export default {
|
|
|
window.location.href = data.url
|
|
|
}
|
|
|
})
|
|
|
+ },
|
|
|
+ handleExportCodeAll() {
|
|
|
+ downFile(this.url.qrcodeAll).then((data) => {
|
|
|
+ if (data.code !== 200) {
|
|
|
+ this.$message.warning('文件下载失败')
|
|
|
+ } else {
|
|
|
+ window.location.href = data.url
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
}
|
|
|
}
|