feat(CoilSelector): 新增入场卷号字段并调整当前卷号显示

feat(customer): 新增客户相关配卷和财务信息查询接口

fix(base.vue): 修复发货单时间条件显示问题

refactor(CustomerEdit): 替换地址选择组件为普通输入框

feat(CoilSelector): 增加入场卷号查询条件并调整对话框宽度

style(OrderEdit): 调整客户名称和销售员选择框宽度

refactor(ChinaAreaSelect): 优化地址解析逻辑并支持空对象处理

feat(FileUpload/FileList): 新增文件预览功能组件

refactor(KLPService/CustomerSelect): 优化客户选择组件并支持自定义字段绑定

fix(AbnormalForm): 修复异常位置校验逻辑并保留当前卷号

feat(ContractTabs): 新增合同附件展示功能

refactor(warehouse/record): 重构操作记录统计展示方式

feat(contract): 集成客户选择组件并优化合同信息填充

refactor(order): 调整订单表单布局并集成合同信息

feat(FilePreview): 新增文件预览组件

feat(customer): 新增财务状态和发货配卷展示

refactor(CustomerOrder): 移除冗余代码并优化布局

feat(PlanDetailForm): 新增合同附件查看功能

feat(dict): 新增字典管理页面
This commit is contained in:
砂糖
2026-04-06 13:16:45 +08:00
parent 4075ead84e
commit 1fa4c55869
21 changed files with 1158 additions and 192 deletions

View File

@@ -15,25 +15,47 @@
<i class="el-icon-document"></i>
<span class="file-name">{{ file.originalName }}</span>
</div>
<el-button
type="text"
icon="el-icon-download"
@click="downloadFile(file)"
size="small"
class="download-btn"
>
下载
</el-button>
<div class="file-actions">
<el-button
type="text"
icon="el-icon-view"
@click="handlePreview(file)"
size="small"
class="preview-btn"
>
预览
</el-button>
<el-button
type="text"
icon="el-icon-download"
@click="downloadFile(file)"
size="small"
class="download-btn"
>
下载
</el-button>
</div>
</div>
</div>
<!-- 文件预览组件 -->
<file-preview
:visible.sync="previewVisible"
:file-url="previewFileUrl"
:file-name="previewFileName"
/>
</div>
</template>
<script>
import { listByIds } from "@/api/system/oss";
import FilePreview from "../FilePreview";
export default {
name: "FileList",
components: {
FilePreview
},
props: {
ossIds: {
type: String,
@@ -43,7 +65,11 @@ export default {
data() {
return {
fileList: [],
loading: false // 加载状态
loading: false, // 加载状态
// 预览相关
previewVisible: false,
previewFileUrl: '',
previewFileName: ''
}
},
watch: {
@@ -81,6 +107,12 @@ export default {
return;
}
this.$download.oss(file.ossId);
},
// 预览文件
handlePreview(file) {
this.previewFileUrl = file.url;
this.previewFileName = file.originalName;
this.previewVisible = true;
}
}
}
@@ -115,6 +147,12 @@ export default {
transition: background-color 0.3s;
}
.file-actions {
display: flex;
align-items: center;
gap: 16px;
}
.file-item:last-child {
border-bottom: none;
}