|
|
@@ -1,8 +1,112 @@
|
|
|
<template>
|
|
|
+<!-- 右侧内容区域 -->
|
|
|
+<layout-content >
|
|
|
+ <el-main>
|
|
|
+ <el-tabs v-model="activeName" @tab-click="handleClick">
|
|
|
+ <el-tab-pane label="技术附件" name="first">
|
|
|
+ <el-table ref="multipleTable"
|
|
|
+ :row-style="{ height: '30px' }"
|
|
|
+ :cell-style="{ padding: '0px' }"
|
|
|
+ :header-row-style="{ height: '30px' }"
|
|
|
+ :header-cell-style="{ padding: '0px' }"
|
|
|
+ :show-overflow-tooltip="true"
|
|
|
+ :cell-class-name="planUsageCellClass"
|
|
|
+ highlight-current-row="true"
|
|
|
+ @row-dblclick="ExcelShow"
|
|
|
+ style="width: 100%;height: 72vh"
|
|
|
+ border tooltip-effect="dark"
|
|
|
+ :data="jstableData"
|
|
|
+ row-key="ID"
|
|
|
+ @selection-change="fjSelectionChange">
|
|
|
+
|
|
|
+ <el-table-column align="left" label="关联编号" prop="关联编号" width="115"/>
|
|
|
+ <el-table-column align="left" label="附件备注" prop="附件备注" width="110"/>
|
|
|
+ <el-table-column align="left" label="文件类型" prop="附件类型" width="100"/>
|
|
|
+ <el-table-column align="left" label="版本号" prop="version" width="80"/>
|
|
|
+ <el-table-column align="left" label="建档用户" prop="sys_id" width="160"/>
|
|
|
+ <el-table-column align="left" label="建档时间" prop="sys_rq" width="160"/>
|
|
|
+
|
|
|
+ <!-- 操作列,新增修改和删除按钮 -->
|
|
|
+ <el-table-column align="left" label="操作" width="230" fixed="right">
|
|
|
+ <template #default="scope">
|
|
|
+ <!-- PDF预览按钮 -->
|
|
|
+ <el-button type="success" size="small" :data="ddtableData" @click="showPdf(scope.row)">PDF预览</el-button>
|
|
|
+ <!-- 删除按钮 -->
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </el-tab-pane>
|
|
|
+ <!-- 分页 -->
|
|
|
+ <div class="gva-pagination">
|
|
|
+ <el-pagination
|
|
|
+ @size-change="handleSizeChange"
|
|
|
+ @current-change="handleCurrentChange"
|
|
|
+ :current-page="page"
|
|
|
+ :page-sizes="[10, 30, 50, 100]"
|
|
|
+ :page-size="pageSize"
|
|
|
+ layout="total, sizes, prev, pager, next, jumper"
|
|
|
+ :total="total">
|
|
|
+ </el-pagination>
|
|
|
+ </div>
|
|
|
+ </el-tabs>
|
|
|
+ </el-main>
|
|
|
+ </layout-content>
|
|
|
+ <luckyexcelPage ref="luckyexcelPageRef" />
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
+//点击按钮显示下方表格
|
|
|
+export default {
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ currentTable: '', // 当前展示的表格
|
|
|
+ activeName: 'first',
|
|
|
+ _ddhval:'',
|
|
|
+ size: '',
|
|
|
+ add_gddialogFormVisible: true,
|
|
|
+ };
|
|
|
+ }
|
|
|
+};
|
|
|
</script>
|
|
|
+<script setup>
|
|
|
+import { Layout, LayoutSider, LayoutContent } from '@arco-design/web-vue';
|
|
|
+import { ElMessage, ElMessageBox,ElUpload, ElButton,ElLoading } from 'element-plus'
|
|
|
+import { ref, reactive, computed, nextTick, watch,onMounted,onBeforeUnmount } from 'vue'
|
|
|
+import {OrderAttachments} from '@/api/mes/job'
|
|
|
+import axios from 'axios';
|
|
|
+import luckyexcelPage from '@/view/yunyin/shengchanguanli/components/luckyexcel.vue'
|
|
|
+const luckyexcelPageRef = ref()
|
|
|
+// 分页相关的响应式变量
|
|
|
+const page = ref(1)
|
|
|
+ const total = ref(0)
|
|
|
+ const pageSize = ref(50)
|
|
|
|
|
|
-<style>
|
|
|
-</style>
|
|
|
+//获取表格数据
|
|
|
+const jstableData = reactive([])
|
|
|
+
|
|
|
+const getjsfjtable = async () => {
|
|
|
+ const jsOrderAttachments = await OrderAttachments({order:'',desc:'',page:page.value,limit:pageSize.value})
|
|
|
+ if (jsOrderAttachments.code === 0) {
|
|
|
+ console.log(jsOrderAttachments.data.list.length)
|
|
|
+ jstableData.splice(0,jsOrderAttachments.data.list.length,...jsOrderAttachments.data.list);
|
|
|
+ total.value = jsOrderAttachments.data.total;
|
|
|
+ }
|
|
|
+}
|
|
|
+getjsfjtable();
|
|
|
+const showPdf = async (row) => {
|
|
|
+ luckyexcelPageRef.value.open(row)
|
|
|
+};
|
|
|
+
|
|
|
+
|
|
|
+ // 分页
|
|
|
+ const handleCurrentChange = (val) => {
|
|
|
+ page.value = val;
|
|
|
+ getjsfjtable();
|
|
|
+ };
|
|
|
+
|
|
|
+ // 修改页面容量 点击多少条/页
|
|
|
+ const handleSizeChange = (val) => {
|
|
|
+ pageSize.value = val;
|
|
|
+ getjsfjtable();
|
|
|
+ };
|
|
|
+</script>
|