Commit 36bed85e by cwq0219

员工-导出

1 parent 21a8cdd3
...@@ -104,4 +104,14 @@ const deleteEmployeeApi = params => { ...@@ -104,4 +104,14 @@ const deleteEmployeeApi = params => {
}) })
} }
export default { getListApi, getAllMerchantListApi, getRoleListApi, getAllDictApi, getMerchantTreeApi, getDetailInfoApi, getDetailLogApi, addEmployeeApi, updateEmployeeApi, deleteEmployeeApi } const exportEmployeeApi = params => {
params.method = `${defaultPath}staff.exportData`
return http({
url: 'rop-merchants/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getListApi, getAllMerchantListApi, getRoleListApi, getAllDictApi, getMerchantTreeApi, getDetailInfoApi, getDetailLogApi, addEmployeeApi, updateEmployeeApi, deleteEmployeeApi, exportEmployeeApi }
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
</template> </template>
<span slot="footer" class="footer-btns"> <span slot="footer" class="footer-btns">
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button> <el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
<el-button :size="size" type="primary">导出</el-button> <el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</span> </span>
</glsx-combi-form> </glsx-combi-form>
</div> </div>
...@@ -290,6 +290,13 @@ export default { ...@@ -290,6 +290,13 @@ export default {
handleSearch() { handleSearch() {
this.$refs.employeeRef.refreshTable() this.$refs.employeeRef.refreshTable()
},
handleExport() {
var params = this.getParams()
this.$apis.employee.exportEmployeeApi(params).then(res => {
window.open(res)
})
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!