电子档案-ui修改

main
zk 1 year ago
parent ef42ba826b
commit 715886d755

@ -1,216 +1,234 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-card>
<!-- 搜索工作栏 -->
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="98px">
<div class="filter-box">
<div class="filter-lf">
<!-- <el-form-item label="制单人" prop="createBy">
<el-input v-model="queryParams.createBy" placeholder="请输入制单人" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="业务实体id" prop="companyId">
<el-input v-model="queryParams.companyId" placeholder="请输入业务实体id" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="业务实体" prop="company">
<el-input v-model="queryParams.company" placeholder="请输入业务实体" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="用户id" prop="userId">
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="所属部门id" prop="deptId">
<el-input v-model="queryParams.deptId" placeholder="请输入所属部门id" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="所属部门" prop="deptName">
<el-input v-model="queryParams.deptName" placeholder="请输入所属部门" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="支付账户" prop="account">
<el-input v-model="queryParams.account" placeholder="请输入支付账户" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="项目" prop="project">
<el-input v-model="queryParams.project" placeholder="请输入项目" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<!-- 搜索工作栏 --> <el-form-item label="金额" prop="price">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"> <el-input v-model="queryParams.price" placeholder="请输入金额" clearable @keyup.enter.native="handleQuery"/>
<!-- <el-form-item label="制单人" prop="createBy">--> </el-form-item>
<!-- <el-input v-model="queryParams.createBy" placeholder="请输入制单人" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="状态" prop="status">
<!-- </el-form-item>--> <el-select v-model="queryParams.status" placeholder="请选择状态" clearable size="small">
<!-- <el-form-item label="业务实体id" prop="companyId">--> <el-option v-for="dict in this.getDictDatas(DICT_TYPE.CONTRACT_STATUS)"
<!-- <el-input v-model="queryParams.companyId" placeholder="请输入业务实体id" clearable @keyup.enter.native="handleQuery"/>--> :key="dict.value" :label="dict.label" :value="dict.value"/>
<!-- </el-form-item>--> </el-select>
<!-- <el-form-item label="业务实体" prop="company">--> </el-form-item>
<!-- <el-input v-model="queryParams.company" placeholder="请输入业务实体" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="纸档位置" prop="position">
<!-- </el-form-item>--> <el-input v-model="queryParams.position" placeholder="请输入纸档位置" clearable @keyup.enter.native="handleQuery"/>
<!-- <el-form-item label="用户id" prop="userId">--> </el-form-item>
<!-- <el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="完整性" prop="cherks">
<!-- </el-form-item>--> <el-select v-model="queryParams.cherks" placeholder="请选择完整性" clearable size="small">
<!-- <el-form-item label="所属部门id" prop="deptId">--> <el-option v-for="dict in this.getDictDatas(DICT_TYPE.CHERKS)"
<!-- <el-input v-model="queryParams.deptId" placeholder="请输入所属部门id" clearable @keyup.enter.native="handleQuery"/>--> :key="dict.value" :label="dict.label" :value="dict.value"/>
<!-- </el-form-item>--> </el-select>
<!-- <el-form-item label="所属部门" prop="deptName">--> </el-form-item>
<!-- <el-input v-model="queryParams.deptName" placeholder="请输入所属部门" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="归档id" prop="recordId">
<!-- </el-form-item>--> <el-input v-model="queryParams.recordId" placeholder="请输入归档id" clearable @keyup.enter.native="handleQuery"/>
<!-- <el-form-item label="支付账户" prop="account">--> </el-form-item>-->
<!-- <el-input v-model="queryParams.account" placeholder="请输入支付账户" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="交易日期" prop="tradeDate">
<!-- </el-form-item>--> <el-date-picker v-model="queryParams.tradeDate" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
<!-- <el-form-item label="项目" prop="project">--> type="daterange"
<!-- <el-input v-model="queryParams.project" placeholder="请输入项目" clearable @keyup.enter.native="handleQuery"/>--> range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
<!-- </el-form-item>--> :default-time="['00:00:00', '23:59:59']"
/>
<!-- <el-form-item label="金额" prop="price">--> </el-form-item>
<!-- <el-input v-model="queryParams.price" placeholder="请输入金额" clearable @keyup.enter.native="handleQuery"/>--> <el-form-item label="交易类型" prop="tradeType">
<!-- </el-form-item>--> <el-select v-model="queryParams.tradeType" placeholder="请选择交易类型" clearable size="small">
<!-- <el-form-item label="状态" prop="status">--> <el-option v-for="dict in this.getDictDatas(DICT_TYPE.TRADE_TYPE)"
<!-- <el-select v-model="queryParams.status" placeholder="请选择状态" clearable size="small">--> :key="dict.value" :label="dict.label" :value="dict.value"
<!-- <el-option v-for="dict in this.getDictDatas(DICT_TYPE.CONTRACT_STATUS)"--> />
<!-- :key="dict.value" :label="dict.label" :value="dict.value"/>--> </el-select>
<!-- </el-select>--> </el-form-item>
<!-- </el-form-item>--> <el-form-item label="收据发票" prop="invoiceNumber">
<!-- <el-form-item label="纸档位置" prop="position">--> <el-input v-model="queryParams.invoiceNumber" placeholder="请输入收据/发票号码" clearable
<!-- <el-input v-model="queryParams.position" placeholder="请输入纸档位置" clearable @keyup.enter.native="handleQuery"/>--> @keyup.enter.native="handleQuery"
<!-- </el-form-item>--> />
<!-- <el-form-item label="完整性" prop="cherks">--> </el-form-item>
<!-- <el-select v-model="queryParams.cherks" placeholder="请选择完整性" clearable size="small">--> <el-form-item label="支付方式" prop="payType">
<!-- <el-option v-for="dict in this.getDictDatas(DICT_TYPE.CHERKS)"--> <el-select v-model="queryParams.payType" placeholder="请选择支付方式" clearable size="small">
<!-- :key="dict.value" :label="dict.label" :value="dict.value"/>--> <el-option v-for="dict in this.getDictDatas(DICT_TYPE.PAY_TYPE)"
<!-- </el-select>--> :key="dict.value" :label="dict.label" :value="dict.value"
<!-- </el-form-item>--> />
<!-- <el-form-item label="归档id" prop="recordId">--> </el-select>
<!-- <el-input v-model="queryParams.recordId" placeholder="请输入归档id" clearable @keyup.enter.native="handleQuery"/>--> </el-form-item>
<!-- </el-form-item>--> <!-- <el-form-item label="归档状态" prop="fileStatus">
<el-form-item label="交易日期" prop="tradeDate"> <el-select v-model="queryParams.fileStatus" placeholder="请选择归档状态" clearable size="small">
<el-date-picker v-model="queryParams.tradeDate" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" <el-option v-for="dict in this.getDictDatas(DICT_TYPE.ARCHIVES_FILE_STATUS)"
type="daterange" :key="dict.value" :label="dict.label" :value="dict.value"/>
range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" </el-select>
:default-time="['00:00:00', '23:59:59']" </el-form-item>
/> <el-form-item label="备注" prop="remarks">
</el-form-item> <el-input v-model="queryParams.remarks" placeholder="请输入备注" clearable @keyup.enter.native="handleQuery"/>
<el-form-item label="交易类型" prop="tradeType"> </el-form-item>
<el-select v-model="queryParams.tradeType" placeholder="请选择交易类型" clearable size="small"> <el-form-item label="创建日期" prop="createTime">
<el-option v-for="dict in this.getDictDatas(DICT_TYPE.TRADE_TYPE)" <el-date-picker v-model="queryParams.createTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"
:key="dict.value" :label="dict.label" :value="dict.value" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" />
/> </el-form-item>
</el-select>
</el-form-item>
<el-form-item label="收据发票" prop="invoiceNumber">
<el-input v-model="queryParams.invoiceNumber" placeholder="请输入收据/发票号码" clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="支付方式" prop="payType">
<el-select v-model="queryParams.payType" placeholder="请选择支付方式" clearable size="small">
<el-option v-for="dict in this.getDictDatas(DICT_TYPE.PAY_TYPE)"
:key="dict.value" :label="dict.label" :value="dict.value"
/>
</el-select>
</el-form-item>
<!-- <el-form-item label="归档状态" prop="fileStatus">-->
<!-- <el-select v-model="queryParams.fileStatus" placeholder="请选择归档状态" clearable size="small">-->
<!-- <el-option v-for="dict in this.getDictDatas(DICT_TYPE.ARCHIVES_FILE_STATUS)"-->
<!-- :key="dict.value" :label="dict.label" :value="dict.value"/>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="备注" prop="remarks">-->
<!-- <el-input v-model="queryParams.remarks" placeholder="请输入备注" clearable @keyup.enter.native="handleQuery"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="创建日期" prop="createTime">-->
<!-- <el-date-picker v-model="queryParams.createTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"-->
<!-- range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" />-->
<!-- </el-form-item>-->
<!-- <el-form-item label="归档日期" prop="recordTime">-->
<!-- <el-date-picker v-model="queryParams.recordTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"-->
<!-- range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" />-->
<!-- </el-form-item>-->
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<!-- 操作工具栏 --> <el-form-item label="归档日期" prop="recordTime">
<el-row :gutter="10" class="mb8"> <el-date-picker v-model="queryParams.recordTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"
<el-col :span="1.5"> range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" />
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" </el-form-item>-->
v-hasPermi="['electronic:finance:create']" <el-form-item>
>新增 <el-button type="primary" icon="el-icon-search" @click="handleQuery"></el-button>
</el-button> <el-button icon="el-icon-refresh" @click="resetQuery"></el-button>
</el-col> </el-form-item>
<el-col :span="1.5"> </div>
<el-button </div>
type="danger" </el-form>
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
>删除</el-button
>
</el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
:loading="exportLoading"
v-hasPermi="['electronic:finance:export']"
>导出
</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<!-- 列表 --> <!-- 操作工具栏 -->
<el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange"> <el-row :gutter="10" class="mb8">
<el-table-column type="selection" width="55" align="center" /> <el-col :span="1.5">
<el-table-column label="交易日期" align="center" prop="tradeDate" width="180"> <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
<template v-slot="scope"> v-hasPermi="['electronic:finance:create']"
<span>{{ parseTime(scope.row.tradeDate) }}</span> >新增
</template> </el-button>
</el-table-column> </el-col>
<!-- <el-table-column label="主键" align="center" prop="id" />--> <el-col :span="1.5">
<!-- <el-table-column label="制单人" align="center" prop="createBy" />--> <el-button
<!-- <el-table-column label="业务实体id" align="center" prop="companyId" />--> type="danger"
<!-- <el-table-column label="业务实体" align="center" prop="company" />--> plain
<!-- <el-table-column label="用户id" align="center" prop="userId" />--> icon="el-icon-delete"
<!-- <el-table-column label="所属部门id" align="center" prop="deptId" />--> size="mini"
<!-- <el-table-column label="所属部门" align="center" prop="deptName" />--> :disabled="multiple"
<el-table-column label="交易类型" align="center" prop="tradeType"> @click="handleDelete"
<template v-slot="scope"> >删除
<dict-tag :type="DICT_TYPE.TRADE_TYPE" :value="scope.row.tradeType"/> </el-button
</template> >
</el-table-column> </el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
:loading="exportLoading"
v-hasPermi="['electronic:finance:export']"
>导出
</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table-column label="金额" align="center" prop="price"/> <!-- 列表 -->
<el-table v-loading="loading" :data="list" stripe border @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/>
<el-table-column label="交易日期" align="center" prop="tradeDate" width="180">
<template v-slot="scope">
<span>{{ parseTime(scope.row.tradeDate) }}</span>
</template>
</el-table-column>
<!-- <el-table-column label="主键" align="center" prop="id" />
<el-table-column label="制单人" align="center" prop="createBy" />
<el-table-column label="业务实体id" align="center" prop="companyId" />
<el-table-column label="业务实体" align="center" prop="company" />
<el-table-column label="用户id" align="center" prop="userId" />
<el-table-column label="所属部门id" align="center" prop="deptId" />
<el-table-column label="所属部门" align="center" prop="deptName" />-->
<el-table-column label="交易类型" align="center" prop="tradeType">
<template v-slot="scope">
<dict-tag :type="DICT_TYPE.TRADE_TYPE" :value="scope.row.tradeType"/>
</template>
</el-table-column>
<el-table-column label="收据/发票号码" align="center" prop="invoiceNumber"/> <el-table-column label="金额" align="center" prop="price"/>
<!-- <el-table-column label="纸档位置" align="center" prop="position" />-->
<!-- <el-table-column label="完整性" align="center" prop="cherks">-->
<!-- <template v-slot="scope">-->
<!-- <dict-tag :type="DICT_TYPE.CHERKS" :value="scope.row.cherks" />-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- <el-table-column label="归档id" align="center" prop="recordId" />-->
<el-table-column label="支付方式" align="center" prop="payType"> <el-table-column label="收据/发票号码" align="center" prop="invoiceNumber"/>
<template v-slot="scope"> <!--<el-table-column label="纸档位置" align="center" prop="position" />
<dict-tag :type="DICT_TYPE.PAY_TYPE" :value="scope.row.payType"/> <el-table-column label="完整性" align="center" prop="cherks">
</template> <template v-slot="scope">
</el-table-column> <dict-tag :type="DICT_TYPE.CHERKS" :value="scope.row.cherks" />
<el-table-column label="账户" align="center" prop="account"/> </template>
<el-table-column label="项目" align="center" prop="project"/> </el-table-column>
<el-table-column label="状态" align="center" prop="status"> <el-table-column label="归档id" align="center" prop="recordId" />-->
<template v-slot="scope">
<dict-tag :type="DICT_TYPE.CONTRACT_STATUS" :value="scope.row.status"/>
</template>
</el-table-column>
<!-- <el-table-column label="归档状态" align="center" prop="fileStatus">-->
<!-- <template v-slot="scope">-->
<!-- <dict-tag :type="DICT_TYPE.ARCHIVES_FILE_STATUS" :value="scope.row.fileStatus" />-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="备注" align="center" prop="remarks"/>
<!-- <el-table-column label="创建日期" align="center" prop="createTime" width="180">-->
<!-- <template v-slot="scope">-->
<!-- <span>{{ parseTime(scope.row.createTime) }}</span>-->
<!-- </template>-->
<!-- </el-table-column>-->
<!-- <el-table-column label="归档日期" align="center" prop="recordTime" />--> <el-table-column label="支付方式" align="center" prop="payType">
<template v-slot="scope">
<dict-tag :type="DICT_TYPE.PAY_TYPE" :value="scope.row.payType"/>
</template>
</el-table-column>
<el-table-column label="账户" align="center" prop="account"/>
<el-table-column label="项目" align="center" prop="project"/>
<el-table-column label="状态" align="center" prop="status">
<template v-slot="scope">
<dict-tag :type="DICT_TYPE.CONTRACT_STATUS" :value="scope.row.status"/>
</template>
</el-table-column>
<!--<el-table-column label="归档状态" align="center" prop="fileStatus">
<template v-slot="scope">
<dict-tag :type="DICT_TYPE.ARCHIVES_FILE_STATUS" :value="scope.row.fileStatus" />
</template>
</el-table-column>-->
<el-table-column label="备注" align="center" prop="remarks">
<!-- 文本域的数据包含html标签需要使用v-html进行展示 -->
<template v-slot="scope">
<div v-html="scope.row.remarks"></div>
</template>
</el-table-column>
<!-- <el-table-column label="创建日期" align="center" prop="createTime" width="180">
<template v-slot="scope">
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="归档日期" align="center" prop="recordTime" />-->
<template v-slot="scope">
<el-button
size="mini"
type="text"
icon="el-icon-view"
@click="handleView(scope.row)"
>查看
</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['electronic:finance:update']"
>修改
</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['electronic:finance:delete']"
>删除
</el-button>
</template>
</el-table-column>
</el-table>
<!-- 分页组件 -->
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" fixed="right" width="180px">
<template v-slot="scope">
<el-button
size="mini"
type="text"
icon="el-icon-view"
v-if="scope.row.contractAttachment"
@click="handleViewFJ(scope.row)"
>查看附件
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-view"
@click="handleView(scope.row)"
>查看
</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['electronic:finance:update']"
>修改
</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['electronic:finance:delete']"
>删除
</el-button>
</template>
</el-table-column>
</el-table>
<!-- 分页组件 -->
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</el-card>
<!-- 对话框(添加 / 修改) --> <!-- 对话框(添加 / 修改) -->
<el-dialog :title="title" :visible.sync="open" width="1000px" v-dialogDrag append-to-body> <el-dialog :title="title" :visible.sync="open" width="1000px" v-dialogDrag append-to-body>
<el-upload <el-upload
@ -238,11 +256,11 @@
<el-input v-model="form.createBy" placeholder="请输入制单人"/> <el-input v-model="form.createBy" placeholder="请输入制单人"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <!-- <el-col :span="8">
<el-form-item label="业务实体id" prop="companyId"> <el-form-item label="业务实体id" prop="companyId">
<el-input v-model="form.companyId" placeholder="请输入业务实体id"/> <el-input v-model="form.companyId" placeholder="请输入业务实体id"/>
</el-form-item> </el-form-item>
</el-col> </el-col>-->
<el-col :span="8"> <el-col :span="8">
<el-form-item label="业务实体" prop="company"> <el-form-item label="业务实体" prop="company">
<el-select <el-select
@ -262,18 +280,6 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="用户id" prop="userId">
<el-input v-model="form.userId" placeholder="请输入用户id"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="所属部门id" prop="deptId">
<el-input v-model="form.deptId" placeholder="请输入所属部门id"/>
</el-form-item>
</el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="部门名称" prop="deptName"> <el-form-item label="部门名称" prop="deptName">
<treeselect <treeselect
@ -283,11 +289,24 @@
:clearable="true" :clearable="true"
placeholder="请选择归属部门" placeholder="请选择归属部门"
:normalizer="normalizer" :normalizer="normalizer"
:disabled = "treeDisabled" :disabled="treeDisabled"
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!-- <el-row>
<el-col :span="8">
<el-form-item label="用户id" prop="userId">
<el-input v-model="form.userId" placeholder="请输入用户id"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="所属部门id" prop="deptId">
<el-input v-model="form.deptId" placeholder="请输入所属部门id"/>
</el-form-item>
</el-col>
</el-row>-->
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="支付账户" prop="account"> <el-form-item label="支付账户" prop="account">
@ -343,11 +362,11 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <!--<el-col :span="8">
<el-form-item label="归档id" prop="recordId"> <el-form-item label="归档id" prop="recordId">
<el-input v-model="form.recordId" placeholder="请输入归档id"/> <el-input v-model="form.recordId" placeholder="请输入归档id"/>
</el-form-item> </el-form-item>
</el-col> </el-col>-->
<el-col :span="8"> <el-col :span="8">
<el-form-item label="交易类型" prop="tradeType"> <el-form-item label="交易类型" prop="tradeType">
<el-select v-model="form.tradeType" placeholder="请选择交易类型"> <el-select v-model="form.tradeType" placeholder="请选择交易类型">
@ -357,8 +376,6 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="支付方式" prop="payType"> <el-form-item label="支付方式" prop="payType">
<el-select v-model="form.payType" placeholder="请选择支付方式"> <el-select v-model="form.payType" placeholder="请选择支付方式">
@ -368,21 +385,8 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="归档状态" prop="fileStatus">
<el-select v-model="form.fileStatus" placeholder="请选择归档状态">
<el-option v-for="dict in this.getDictDatas(DICT_TYPE.ARCHIVES_FILE_STATUS)"
:key="dict.value" :label="dict.label" :value="dict.value"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="备注" prop="remarks">
<el-input v-model="form.remarks" placeholder="请输入备注"/>
</el-form-item>
</el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="交易日期" prop="tradeDate"> <el-form-item label="交易日期" prop="tradeDate">
@ -398,7 +402,26 @@
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="归档状态" prop="fileStatus">
<el-select v-model="form.fileStatus" placeholder="请选择归档状态">
<el-option v-for="dict in this.getDictDatas(DICT_TYPE.ARCHIVES_FILE_STATUS)"
:key="dict.value" :label="dict.label" :value="dict.value"
/>
</el-select>
</el-form-item>
</el-col>
</el-row> </el-row>
<!-- <el-row>
<el-col :span="8">
<el-form-item label="备注" prop="remarks">
<el-input v-model="form.remarks" placeholder="请输入备注"/>
</el-form-item>
</el-col>
</el-row>-->
<el-form-item label="备注">
<editor v-model="form.remarks" :min-height="192" />
</el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm" v-if="optType != 'view'"> </el-button> <el-button type="primary" @click="submitForm" v-if="optType != 'view'"> </el-button>
@ -422,17 +445,21 @@ import { getOrganizationPage, getSiteTree } from '@/api/setting/organization'
import { listSimpleDepts } from '@/api/system/dept' import { listSimpleDepts } from '@/api/system/dept'
import { listSimplePosts } from '@/api/system/post' import { listSimplePosts } from '@/api/system/post'
import Treeselect from '@riophae/vue-treeselect' import Treeselect from '@riophae/vue-treeselect'
import Editor from "@/components/Editor"
import WxVideoPlayer from "@/views/mp/components/wx-video-play/main"
import ImagePreview from "@/components/ImagePreview"
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import FileUpload from '@/components/FileUpload' import FileUpload from '@/components/FileUpload'
export default { export default {
name: 'Finance', name: 'Finance',
components: {FileUpload,Treeselect,}, components: { FileUpload, Treeselect,Editor, WxVideoPlayer ,ImagePreview},
data() { data() {
return { return {
propName: { propName: {
label: "pName", label: 'pName',
value: "pId", value: 'pId',
multiple: false, multiple: false
}, },
// //
loading: true, loading: true,
@ -487,7 +514,7 @@ export default {
Authorization: 'Bearer ' + getAccessToken(), Authorization: 'Bearer ' + getAccessToken(),
'tenant-id': getTenantId() 'tenant-id': getTenantId()
}, // }, //
fileList: [], // fileList: [], //
getFileUrl: process.env.VUE_APP_BASE_API + '/admin-api/infra/file/', getFileUrl: process.env.VUE_APP_BASE_API + '/admin-api/infra/file/',
uploadDisabled: undefined, uploadDisabled: undefined,
optType: undefined, optType: undefined,
@ -496,19 +523,19 @@ export default {
organizationList: [], organizationList: [],
// //
deptOptions: undefined, deptOptions: undefined,
treeDisabled:undefined, treeDisabled: undefined,
// //
multiple: true, multiple: true,
// //
single: true, single: true,
// //
ids: [], ids: []
} }
}, },
created() { created() {
this.getList(); this.getList()
this.getSiteList(); this.getSiteList()
this.getOrganizationList(); this.getOrganizationList()
this.getTreeselect() this.getTreeselect()
}, },
methods: { methods: {
@ -550,6 +577,7 @@ export default {
fileStatus: undefined, fileStatus: undefined,
remarks: undefined, remarks: undefined,
tradeDate: undefined, tradeDate: undefined,
contractAttachment: undefined,
recordTime: undefined recordTime: undefined
} }
this.resetForm('form') this.resetForm('form')
@ -559,6 +587,20 @@ export default {
this.queryParams.pageNo = 1 this.queryParams.pageNo = 1
this.getList() this.getList()
}, },
/**
* 文件预览
* @param fileUrl
*/
openLink(fileUrl) {
const url =
process.env.VUE_APP_ONLINE_API +
`/onlinePreview?url=${encodeURIComponent(this.base64Encode(fileUrl))}`
window.open(url)
},
/** 查看附件按钮操作 */
handleViewFJ(row) {
this.openLink(row.contractAttachment)
},
/** 重置按钮操作 */ /** 重置按钮操作 */
resetQuery() { resetQuery() {
this.resetForm('queryForm') this.resetForm('queryForm')
@ -568,6 +610,7 @@ export default {
handleAdd() { handleAdd() {
this.reset() this.reset()
this.open = true this.open = true
this.fileList = []
this.optType = 'add' this.optType = 'add'
this.uploadDisabled = true this.uploadDisabled = true
this.title = '添加财务档案' this.title = '添加财务档案'
@ -622,7 +665,7 @@ export default {
}, },
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const id = row.id || this.ids; const id = row.id || this.ids
this.$modal.confirm('是否确认删除财务档案编号为"' + id + '"的数据项?').then(function() { this.$modal.confirm('是否确认删除财务档案编号为"' + id + '"的数据项?').then(function() {
return deleteFinance(id) return deleteFinance(id)
}).then(() => { }).then(() => {
@ -648,14 +691,14 @@ export default {
}, },
// //
handleCompanyChange(val) { handleCompanyChange(val) {
this.form.companyId = val.id; this.form.companyId = val.id
this.form.company = val.organizationName; this.form.company = val.organizationName
}, },
// //
getOrganizationList() { getOrganizationList() {
getOrganizationPage().then((response) => { getOrganizationPage().then((response) => {
this.organizationList = response.data.list; this.organizationList = response.data.list
}); })
}, },
// //
handleSuccess(res) { handleSuccess(res) {
@ -667,62 +710,66 @@ export default {
return { return {
id: node.id, id: node.id,
label: node.name, label: node.name,
children: node.children, children: node.children
}; }
}, },
/** 查询部门下拉树结构 + 岗位下拉 */ /** 查询部门下拉树结构 + 岗位下拉 */
getTreeselect() { getTreeselect() {
listSimpleDepts().then((response) => { listSimpleDepts().then((response) => {
// deptOptions // deptOptions
this.deptOptions = []; this.deptOptions = []
this.deptOptions.push(...this.handleTree(response.data, "id")); this.deptOptions.push(...this.handleTree(response.data, 'id'))
}); })
listSimplePosts().then((response) => { listSimplePosts().then((response) => {
// postOptions // postOptions
this.postOptions = []; this.postOptions = []
this.postOptions.push(...response.data); this.postOptions.push(...response.data)
}); })
}, },
// //
handleSiteChanged(obj) { handleSiteChanged(obj) {
if (obj != null) { if (obj != null) {
this.form.organizationId = obj[0]; this.form.organizationId = obj[0]
this.form.depotId = obj[1]; this.form.depotId = obj[1]
this.form.cabinetId = obj[2]; this.form.cabinetId = obj[2]
} }
}, },
// //
getSiteList() { getSiteList() {
getSiteTree().then((response) => { getSiteTree().then((response) => {
this.siteOptions = response.data; this.siteOptions = response.data
this.siteOptions.map((w) => { this.siteOptions.map((w) => {
w.children.map((l) => { w.children.map((l) => {
let lstr = JSON.stringify(l.children) let lstr = JSON.stringify(l.children)
.replace(/depotId/g, "lId") .replace(/depotId/g, 'lId')
.replace(/cabinetId/g, "pId") .replace(/cabinetId/g, 'pId')
.replace(/cabinetName/g, "pName"); .replace(/cabinetName/g, 'pName')
l.children = JSON.parse(lstr); l.children = JSON.parse(lstr)
}); })
let wstr = JSON.stringify(w.children) let wstr = JSON.stringify(w.children)
.replace(/organizationId/g, "wId") .replace(/organizationId/g, 'wId')
.replace(/depotId/g, "pId") .replace(/depotId/g, 'pId')
.replace(/depotName/g, "pName"); .replace(/depotName/g, 'pName')
w.children = JSON.parse(wstr); w.children = JSON.parse(wstr)
}); })
let ostr = JSON.stringify(this.siteOptions) let ostr = JSON.stringify(this.siteOptions)
.replace(/organizationId/g, "pId") .replace(/organizationId/g, 'pId')
.replace(/organizationName/g, "pName"); .replace(/organizationName/g, 'pName')
this.siteOptions = JSON.parse(ostr); this.siteOptions = JSON.parse(ostr)
// console.log(this.siteOptions); // console.log(this.siteOptions);
}); })
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map((item) => item.id)
this.single = selection.length !== 1; this.single = selection.length !== 1
this.multiple = !selection.length; this.multiple = !selection.length
}, }
} }
} }
</script> </script>
<style lang="scss" scoped>
@import "@/assets/styles/header/index.scss";
@import "@/assets/styles/common/index.scss";
</style>

Loading…
Cancel
Save