Browse Source

feat:[档案管理]给药制剂,麻精药,发放记录档案

lkf
15881625488@163.com 2 months ago
parent
commit
674fac8fa1
6 changed files with 480 additions and 706 deletions
  1. +60
    -0
      src/api/business/gyzj/gyzjFfjlArchive.js
  2. +60
    -0
      src/api/business/mjy/mjyFfjlArchive.js
  3. +169
    -350
      src/views/business/archive/drug/comps/ffjlList.vue
  4. +187
    -352
      src/views/business/archive/formulation/comps/ffjlList.vue
  5. +2
    -2
      src/views/business/resource/gyzj/comps/ffjlList.vue
  6. +2
    -2
      src/views/business/resource/mjy/comps/ffjlList.vue

+ 60
- 0
src/api/business/gyzj/gyzjFfjlArchive.js View File

@ -0,0 +1,60 @@
import request from '@/utils/request'
// 列表
export function list(query) {
return request({
url: '/system/business/gyzjFfjlArchive/list',
method: 'get',
params: query
})
}
export function tygd(data) {
return request({
url: '/system/business/gyzjFfjlArchive/tygd',
method: 'post',
data: data
})
}
export function jjgd(data) {
return request({
url: '/system/business/gyzjFfjlArchive/jjgd',
method: 'post',
data: data
})
}
export function tyjd(data) {
return request({
url: '/system/business/gyzjFfjlArchive/tyjd',
method: 'post',
data: data
})
}
export function jjjd(data) {
return request({
url: '/system/business/gyzjFfjlArchive/jjjd',
method: 'post',
data: data
})
}
export function tyjy(data) {
return request({
url: '/system/business/gyzjFfjlArchive/tyjy',
method: 'post',
data: data
})
}
export function jjjy(data) {
return request({
url: '/system/business/gyzjFfjlArchive/jjjy',
method: 'post',
data: data
})
}
export function qrgh(data) {
return request({
url: '/system/business/gyzjFfjlArchive/qrgh',
method: 'post',
data: data
})
}

+ 60
- 0
src/api/business/mjy/mjyFfjlArchive.js View File

@ -0,0 +1,60 @@
import request from '@/utils/request'
// 列表
export function list(query) {
return request({
url: '/system/business/mjyFfjlArchive/list',
method: 'get',
params: query
})
}
export function tygd(data) {
return request({
url: '/system/business/mjyFfjlArchive/tygd',
method: 'post',
data: data
})
}
export function jjgd(data) {
return request({
url: '/system/business/mjyFfjlArchive/jjgd',
method: 'post',
data: data
})
}
export function tyjd(data) {
return request({
url: '/system/business/mjyFfjlArchive/tyjd',
method: 'post',
data: data
})
}
export function jjjd(data) {
return request({
url: '/system/business/mjyFfjlArchive/jjjd',
method: 'post',
data: data
})
}
export function tyjy(data) {
return request({
url: '/system/business/mjyFfjlArchive/tyjy',
method: 'post',
data: data
})
}
export function jjjy(data) {
return request({
url: '/system/business/mjyFfjlArchive/jjjy',
method: 'post',
data: data
})
}
export function qrgh(data) {
return request({
url: '/system/business/mjyFfjlArchive/qrgh',
method: 'post',
data: data
})
}

+ 169
- 350
src/views/business/archive/drug/comps/ffjlList.vue View File

@ -1,132 +1,87 @@
<template>
<div>
<!-- 列表 -->
<div>
<!-- 列表 -->
<div class="ffjl" v-show="!showDetail">
<div class="mjy" v-show="!showDetail">
<el-form :model="queryParams" ref="queryForm" class="search-area" :inline="true" label-width="88px">
<el-row>
<el-col :span="24">
<!-- 名称 -->
<el-form-item :label="$t('page.business.resource.gyzj.mc') + ':'">
<el-input v-model="queryParams.mc" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 编号 -->
<el-form-item :label="$t('page.business.resource.gyzj.bh') + ':'">
<el-input v-model="queryParams.bh" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 目的 -->
<el-form-item :label="$t('page.business.resource.gyzj.md') + ':'">
<el-input v-model="queryParams.mdId" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 记录状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jlzt') + ':'">
<el-select v-model="queryParams.jlzt" :placeholder="$t('form.placeholderSelect')" clearable
>
<el-option :label="$t('page.business.resource.resource.jlzt.wsd')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jlzt.ysd')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jlzt.dgd')" :value="5" />
<el-option :label="$t('page.business.resource.resource.jlzt.gd')" :value="7" />
<el-option :label="$t('page.business.resource.resource.jlzt.djd')" :value="9" />
</el-select>
</el-form-item>
<!-- 借阅状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jyzt') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'150px'">
<el-select v-model="queryParams.jyzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jyzt.wjy')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jyzt.djy')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jyzt.jyz')" :value="5" />
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">{{ $t('form.search') }}</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">{{ $t('form.reset') }}</el-button>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<!-- 出库日期 -->
<el-form-item :label="$t('page.business.resource.gyzj.cksj') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'180px'">
<el-date-picker v-model="daterangeCk" class="chat-histogram-daterange" type="daterange"
range-separator="-" :start-placeholder="$t('form.startDate')" :end-placeholder="$t('form.endDate')"
value-format="yyyy-MM-dd" @change="handleQuery" style="width: 250px;" />
</el-form-item>
<!-- 入库日期 -->
<el-form-item :label="$t('page.business.resource.gyzj.rksj') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'180px'">
<el-date-picker v-model="daterangeRk" class="chat-histogram-daterange" type="daterange"
range-separator="-" :start-placeholder="$t('form.startDate')" :end-placeholder="$t('form.endDate')"
value-format="yyyy-MM-dd" @change="handleQuery" style="width: 250px;" />
</el-form-item>
</el-col>
</el-row>
<!-- 名称 -->
<el-form-item :label="$t('page.business.resource.mjy.mc') + ':'">
<el-input v-model="queryParams.mc" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 编号 -->
<el-form-item :label="$t('page.business.resource.mjy.bh') + ':'">
<el-input v-model="queryParams.bh" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 目的 -->
<el-form-item :label="$t('page.business.resource.mjy.md') + ':'">
<el-input v-model="queryParams.mdId" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 记录状态 -->
<el-form-item :label="$t('page.business.resource.mjy.jlzt') + ':'">
<el-select v-model="queryParams.jlzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jlzt.wsd')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jlzt.ysd')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jlzt.dgd')" :value="5" />
<el-option :label="$t('page.business.resource.resource.jlzt.gd')" :value="7" />
<el-option :label="$t('page.business.resource.resource.jlzt.djd')" :value="9" />
</el-select>
</el-form-item>
<!-- 借阅状态 -->
<el-form-item :label="$t('page.business.resource.mjy.jyzt') + ':'"
:label-width="$i18n.locale === 'zh_CN' ? '88px' : '150px'">
<el-select v-model="queryParams.jyzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jyzt.wjy')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jyzt.djy')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jyzt.jyz')" :value="5" />
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">{{ $t('form.search') }}</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">{{ $t('form.reset') }}</el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<!-- 批量归档 -->
<el-button type="primary" :disabled="multiple" @click="handlePlgd"
v-hasPermi="['business:resource:gyzj:ffjlgd']">{{
$t('page.business.resource.gyzj.plgd') }}</el-button>
</el-col>
<el-col :span="1.5">
<!-- 批量锁定 -->
<el-button type="primary" :disabled="multiple" @click="handlePlsd"
v-hasPermi="['business:resource:gyzj:ffjlsd']">{{
$t('page.business.resource.gyzj.plsd') }}</el-button>
</el-col>
<el-col :span="1.5">
<!-- 导出 -->
<el-button type="primary" @click="exportExcel"
v-hasPermi="['business:resource:gyzj:ffjldc']">{{
$t('form.export') }}</el-button>
</el-col>
</el-row>
<el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange">
<el-table-column type="selection" fixed="left" width="55" align="center" :selectable="checkSelectable" />
<el-table-column :label="$t('page.business.resource.gyzj.bh')" align="center" prop="bh"
<el-table v-loading="loading" :data="list">
<el-table-column :label="$t('page.business.resource.mjy.mc')" align="left" prop="mc"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.mc')" align="left" prop="mc"
<el-table-column :label="$t('page.business.resource.mjy.bh')" align="center" prop="bh"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.md')" align="center" width="100px" :show-overflow-tooltip="true" >
<el-table-column :label="$t('page.business.resource.gyzj.md')" align="center" width="100px" :show-overflow-tooltip="true" >
<template slot-scope="scope">
<span v-if="scope.row.mdOther && scope.row.mdOther != ''&&scope.row.mdMcs && scope.row.mdMcs != ''">{{ scope.row.mdMcs }},{{ scope.row.mdOther }}</span>
<span v-else>{{ scope.row.mdMcs }}{{ scope.row.mdOther }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.zytj')" align="center" prop="ffzytj" :width="$i18n.locale === 'zh_CN'?'100px':'180px'"/>
<el-table-column :label="$t('page.business.resource.gyzj.cksj')" align="center" prop="ffrq" width="150px" />
<el-table-column :label="$t('page.business.resource.gyzj.rksj')" align="center" prop="ghrq" width="150px" />
<el-table-column :label="$t('page.business.resource.gyzj.ckl')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.mjy.zytj')" align="center" prop="ffzytj"
:width="$i18n.locale === 'zh_CN'?'100px':'180px'"/>
<el-table-column :label="$t('page.business.resource.mjy.cksj')" align="center" prop="ffrq" width="150px" />
<el-table-column :label="$t('page.business.resource.mjy.rksj')" align="center" prop="ghrq" width="150px" />
<el-table-column :label="$t('page.business.resource.mjy.ckmz')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<template slot-scope="scope">
{{ scope.row.ckl }} {{ scope.row.ckldw }}
{{ scope.row.ckmz }} {{ scope.row.ckmzdw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.rkl')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.mjy.rkmz')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<template slot-scope="scope">
{{ scope.row.rkl }} {{ scope.row.rkldw }}
{{ scope.row.rkmz }} {{ scope.row.rkmzdw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.syl')" align="center" :width="$i18n.locale === 'zh_CN'?'80px':'120px'">
<el-table-column :label="$t('page.business.resource.mjy.syl')" align="center" :width="$i18n.locale === 'zh_CN'?'80px':'120px'">
<template slot-scope="scope">
{{ scope.row.syl }} {{ scope.row.syldw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.kgy1')" align="center" prop="jsr1Mc" :width="$i18n.locale === 'zh_CN'?'80px':'180px'"
<el-table-column :label="$t('page.business.resource.mjy.lqr1')" align="center" prop="lqr1Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.kgy2')" align="center" prop="jsr2Mc" :width="$i18n.locale === 'zh_CN'?'80px':'180px'"
<el-table-column :label="$t('page.business.resource.mjy.lqr2')" align="center" prop="lqr2Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr1')" align="center" prop="lqr1Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
<el-table-column :label="$t('page.business.resource.mjy.kgy1')" align="center" prop="jsr1Mc" :width="$i18n.locale === 'zh_CN'?'100px':'180px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr2')" align="center" prop="lqr2Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
<el-table-column :label="$t('page.business.resource.mjy.kgy2')" align="center" prop="jsr2Mc" :width="$i18n.locale === 'zh_CN'?'100px':'180px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.zcg')" align="center" prop="zcgMc"
<el-table-column :label="$t('page.business.resource.mjy.zcg')" align="center" prop="zcgMc"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.jlzt')" align="center" width="100px" fixed="right">
<el-table-column :label="$t('page.business.resource.mjy.jlzt')" align="center" width="100px" fixed="right">
<template slot-scope="scope">
<span v-if="scope.row.jlzt == 1"><span class="status-circle wsd"></span>{{ $t('page.business.resource.resource.jlzt.wsd') }}</span>
<span v-if="scope.row.jlzt == 3"><span class="status-circle ysd"></span>{{ $t('page.business.resource.resource.jlzt.ysd') }}</span>
@ -135,75 +90,89 @@
<span v-if="scope.row.jlzt == 9"><span class="status-circle djd"></span>{{ $t('page.business.resource.resource.jlzt.djd') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.jyzt')" align="center" fixed="right" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.mjy.jyzt')" align="center" fixed="right" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<template slot-scope="scope">
<span v-if="scope.row.jyzt == 1"><span class="status-circle wjy"></span>{{ $t('page.business.resource.resource.jyzt.wjy') }}</span>
<span v-if="scope.row.jyzt == 3"><span class="status-circle djy"></span>{{ $t('page.business.resource.resource.jyzt.djy') }}</span>
<span v-if="scope.row.jyzt == 5"><span class="status-circle jyz"></span>{{ $t('page.business.resource.resource.jyzt.jyz') }}</span>
<span v-if="scope.row.jyzt == 3"><span class="status-circle ysd"></span>{{ $t('page.business.resource.resource.jyzt.djy') }}</span>
<span v-if="scope.row.jyzt == 5"><span class="status-circle syz"></span>{{ $t('page.business.resource.resource.jyzt.jyz') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('form.operate')" fixed="right" align="center"
class-name="small-padding fixed-width" width="250px">
class-name="small-padding fixed-width" width="200px">
<template slot-scope="scope">
<!-- 加签 -->
<el-button v-if="scope.row.jlzt == 1" type="text" @click="handleJq(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljq']">{{
$t('page.business.resource.gyzj.jiaqian') }}</el-button>
<!-- 详情 -->
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jlzt == 7" type="text"
@click="handleXq(scope.row)" v-hasPermi="['business:resource:gyzj:ffjlxq']">{{
$t('page.business.resource.gyzj.detail') }}</el-button>
<!-- 锁定 -->
<el-button type="text" v-if="scope.row.jlzt == 1" @click="handleSd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjlsd']">{{
$t('page.business.resource.gyzj.lock') }}</el-button>
<!-- 解锁 -->
<el-button type="text" v-if="scope.row.jlzt == 3" @click="handleJs(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljs']">{{
$t('page.business.resource.gyzj.unlock') }}</el-button>
<!-- 归档 -->
<el-button type="text" v-if="scope.row.jlzt == 3" @click="handleGd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjlgd']">{{
$t('page.business.resource.gyzj.guidang') }}</el-button>
<!-- 解档 -->
<el-button type="text" v-if="scope.row.jlzt == 7" @click="handleJd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljd']">{{
$t('page.business.resource.gyzj.jiedang') }}</el-button>
<!-- 借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 1" @click="handleJy(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljy']">{{
$t('page.business.resource.gyzj.jieyue') }}</el-button>
<template>
<!-- 详情 -->
<el-button type="text" @click="handleXq(scope.row)" v-hasPermi="['business:archive:mjyFfjl:xq']">{{
$t('page.business.resource.mjy.detail') }}</el-button>
<!-- 同意归档 -->
<el-button type="text" v-if="scope.row.jlzt == 5"
@click="handleSign(scope.row, 'page.business.resource.mjy.tygd', false, 'tygd')"
v-hasPermi="['business:archive:mjyFfjl:tygd']">{{
$t('page.business.resource.mjy.tygd') }}</el-button>
<!-- 拒绝归档 -->
<el-button type="text" v-if="scope.row.jlzt == 5"
@click="handleSign(scope.row, 'page.business.resource.mjy.jjgd', false, 'jjgd', true, true)"
v-hasPermi="['business:archive:mjyFfjl:jjgd']">{{
$t('page.business.resource.mjy.jjgd') }}</el-button>
<!-- 同意解档 -->
<el-button type="text" v-if="scope.row.jlzt == 9"
@click="handleSign(scope.row, 'page.business.resource.mjy.tyjd', false, 'tyjd')"
v-hasPermi="['business:archive:mjyFfjl:tyjd']">{{
$t('page.business.resource.mjy.tyjd') }}</el-button>
<!-- 拒绝解档 -->
<el-button type="text" v-if="scope.row.jlzt == 9"
@click="handleSign(scope.row, 'page.business.resource.mjy.jjjd', false, 'jjjd', true, true)"
v-hasPermi="['business:archive:mjyFfjl:jjjd']">{{
$t('page.business.resource.mjy.jjjd') }}</el-button>
<!-- 同意借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 3"
@click="handleSign(scope.row, 'page.business.resource.mjy.tyjy', true, 'tyjy')"
v-hasPermi="['business:archive:mjyFfjl:tyjy']">{{
$t('page.business.resource.mjy.tyjy') }}</el-button>
<!-- 拒绝借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 3"
@click="handleSign(scope.row, 'page.business.resource.mjy.jjjy', true, 'jjjy', true, true)"
v-hasPermi="['business:archive:mjyFfjl:jjjy']">{{
$t('page.business.resource.mjy.jjjy') }}</el-button>
<!-- 确认归还 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 5"
@click="handleSign(scope.row, 'page.business.resource.mjy.qrgh', false, 'qrgh')"
v-hasPermi="['business:archive:mjyFfjl:qrgh']">{{
$t('page.business.resource.mjy.qrgh') }}</el-button>
</template>
</template>
</el-table-column>
</el-table>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" />
</div>
<!-- 详情 -->
<Xq v-show="showDetail" key="Xq" ref="Xq" @callback="closeXq" />
<!-- 签名 -->
<Sign ref="refSign" @callback="doSign" />
</div>
</div>
</template>
<script>
import { list } from "@/api/business/gyzj/gyzjFfjl"
import moment from "moment";
import { deepClone } from "@/utils/index";
import { list, tygd, jjgd, tyjd, jjjd, tyjy, jjjy, qrgh } from "@/api/business/mjy/mjyFfjlArchive"
import Sign from "@/views/business/comps/common/sign";
import Xq from "@/views/business/resource/mjy/comps/ffjl/Xq";
export default {
name: "FfjlList",
components: { },
name: "GyzjDaList",
components: { Xq, Sign },
data() {
return {
daterangeCk: [],
daterangeRk: [],
loading: true,
showDetail: false,
single: true,
multiple: true,
type: '',
total: 0,
list: [],
//
selectList: [],
//
form: {
id: null
},
queryParams: {
pageNum: 1,
pageSize: 10,
@ -212,10 +181,6 @@ export default {
jlzt: null,
jyzt: null,
bh: null,
startDateCk: null,
endDateCk: null,
startDateRk: null,
endDateRk: null,
},
}
},
@ -223,168 +188,63 @@ export default {
this.getList()
},
methods: {
exportExcel() {
let that = this
that.$modal.loading()
let params = deepClone(this.queryParams)
params.pageSize = 999999
list(params).then(response => {
var tabelStr =
'<table border="1" class="html-tabel">' +
'<tr style="background:#eee;">' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.mc') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.bh') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.md') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.zytj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.cksj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.rksj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.ckmz') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.rkmz') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.syl') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.lqr1') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.lqr2') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.kgy1') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.kgy2') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.zcg') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.jlzt') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.jyzt') + '</th>' +
' </tr>'
let _datastr = ''
_.forEach(response.rows, function (value) {
let jlzt = ''
switch (value.jlzt) {
case 1:
jlzt = that.$t('page.business.resource.resource.jlzt.wsd')
break
case 3:
jlzt = that.$t('page.business.resource.resource.jlzt.ysd')
break
case 5:
jlzt = that.$t('page.business.resource.resource.jlzt.dgd')
break
case 7:
jlzt = that.$t('page.business.resource.resource.jlzt.gd')
break
case 9:
jlzt = that.$t('page.business.resource.resource.jlzt.djd')
break
default: zjzt = ''
}
let jyzt = ''
switch (value.jyzt) {
case 1:
jyzt = that.$t('page.business.resource.resource.jyzt.wjy')
break
case 3:
jyzt = that.$t('page.business.resource.resource.jyzt.djy')
break
case 5:
jyzt = that.$t('page.business.resource.resource.jyzt.jyz')
break
default: jyzt = ''
}
_datastr =
_datastr +
'<tr style="text-align: center;">' +
' <td>' +
value.mc +
'</td>' +
' <td>' +
'&nbsp;'+value.bh +
'</td>' +
' <td>' +
(value.mdMcs&&value.mdMcs!=''&&value.mdOther&&value.mdOther!=''? (value.mdMcs +","+value.mdOther) :(value.mdMcs +value.mdOther))+
'</td>' +
' <td>' +
value.ffzytj +
'</td>' +
' <td>' +
value.ffrq +
'</td>' +
' <td>' +
value.ghrq +
'</td>' +
' <td>' +
value.ckl +value.ckldw+
'</td>' +
' <td>' +
value.rkl+value.rkldw +
'</td>' +
' <td>' +
value.syl+value.syldw +
'</td>' +
' <td>' +
value.lqr1Mc +
'</td>' +
' <td>' +
value.lqr2Mc +
'</td>' +
' <td>' +
value.jsr1Mc +
'</td>' +
' <td>' +
value.jsr2Mc +
'</td>' +
' <td>' +
value.zcgMc +
'</td>' +
' <td>' +
jlzt +
'</td>' +
' <td>' +
jyzt +
'</td>' +
'</tr>'
})
tabelStr = tabelStr + _datastr + ' <table>'
// Worksheet
var worksheet = that.$t('page.business.resource.gyzj.ffhsjl')
var uri = 'data:application/vnd.ms-excel;base64,'
// HTML
var exportTemplate = `<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel"
xmlns="http://www.w3.org/TR/REC-html40">
<head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet>
<x:Name>${worksheet}</x:Name>
<x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet>
</x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]-->
</head>
<body>
${tabelStr}
</body>
</html>`
var a = document.createElement('a')
a.download = worksheet + '.xls'
a.href = uri + window.btoa(unescape(encodeURIComponent(exportTemplate)))
a.click()
that.$modal.closeLoading()
}).finally(() => {
that.$modal.closeLoading()
})
},
//
handleJq(row) {
this.$refs.Jq.show(row)
},
//
handleSd(row) {
this.$refs.Sd.show(row)
},
//
handleJs(row) {
this.$refs.Js.show(row)
handleSign(row, qmyy, showDate, type, isReson, reasonRequired) {
this.form.id = row.id
let title = this.$t(qmyy)
this.type = type
this.$refs.refSign.show(title, title, showDate, (type == 'jjjy' || type == 'tyjy') ? [row.jyksrq, row.jyjsrq] : [], isReson, reasonRequired)
},
//
handlePlgd() {
this.$refs.Gd.showBatch(this.selectList)
},
//
handlePlsd() {
this.$refs.Sd.showBatch(this.selectList)
doSign(val) {
let params = _.merge({}, this.form, val)
this.$modal.loading()
if (this.type == 'tygd') {
tygd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjgd') {
jjgd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'tyjd') {
tyjd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjjd') {
jjjd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'tyjy') {
tyjy(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjjy') {
jjjy(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'qrgh') {
qrgh(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
}
},
closeXq() {
this.showDetail = false
this.$emit('showDetail', this.showDetail)
this.handleQuery()
this.$emit('showDetail', this.showDetail)
},
//
handleXq(row) {
@ -392,38 +252,8 @@ export default {
this.$emit('showDetail', this.showDetail)
this.$refs.Xq.show(row)
},
//
handleGd(row) {
this.$refs.Gd.show(row)
},
//
handleJy(row) {
this.$refs.Jy.show(row)
},
//
handleJd(row) {
this.$refs.Jd.show(row)
},
//
checkSelectable(row) {
return true;
},
//
getList() {
if (this.daterangeCk != null && this.daterangeCk.length > 0) {
this.queryParams.startDateCk = this.daterangeCk[0]
this.queryParams.endDateCk = moment().add(this.daterangeCk[1], 'days').format('YYYY-MM-DD');
} else {
this.queryParams.startDateCk = ''
this.queryParams.endDateCk = ''
}
if (this.daterangeRk != null && this.daterangeRk.length > 0) {
this.queryParams.startDateRk = this.daterangeRk[0]
this.queryParams.endDateRk = moment().add(this.daterangeRk[1], 'days').format('YYYY-MM-DD');
} else {
this.queryParams.startDateRk = ''
this.queryParams.endDateRk = ''
}
this.loading = true
list(this.queryParams).then(response => {
this.list = response.rows
@ -438,30 +268,19 @@ export default {
},
//
resetQuery() {
this.queryParams.mc = null
this.queryParams.mc = null
this.queryParams.mdId = null
this.queryParams.jlzt = null
this.queryParams.jyzt = null
this.queryParams.bh = null
this.queryParams.startDateCk = null
this.queryParams.endDateCk = null
this.queryParams.startDateRk = null
this.queryParams.endDateRk = null
this.daterangeCk = []
this.daterangeRk = []
this.handleQuery()
},
//
handleSelectionChange(selection) {
this.single = selection.length !== 1
this.multiple = !selection.length
this.selectList = selection
}
}
}
</script>
<style rel="stylesheet/scss" lang="scss">
.ffjl {
.mjy {
background: #fff;
padding: 10px 10px;
}

+ 187
- 352
src/views/business/archive/formulation/comps/ffjlList.vue View File

@ -1,209 +1,194 @@
<template>
<div>
<!-- 列表 -->
<div>
<!-- 列表 -->
<div class="ffjl" v-show="!showDetail">
<div class="gyzj" v-show="!showDetail">
<el-form :model="queryParams" ref="queryForm" class="search-area" :inline="true" label-width="88px">
<el-row>
<el-col :span="24">
<!-- 名称 -->
<el-form-item :label="$t('page.business.resource.gyzj.mc') + ':'">
<el-input v-model="queryParams.mc" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 编号 -->
<el-form-item :label="$t('page.business.resource.gyzj.bh') + ':'">
<el-input v-model="queryParams.bh" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 目的 -->
<el-form-item :label="$t('page.business.resource.gyzj.md') + ':'">
<el-input v-model="queryParams.mdId" clearable
:placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 记录状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jlzt') + ':'">
<el-select v-model="queryParams.jlzt" :placeholder="$t('form.placeholderSelect')" clearable
>
<el-option :label="$t('page.business.resource.resource.jlzt.wsd')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jlzt.ysd')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jlzt.dgd')" :value="5" />
<el-option :label="$t('page.business.resource.resource.jlzt.gd')" :value="7" />
<el-option :label="$t('page.business.resource.resource.jlzt.djd')" :value="9" />
</el-select>
</el-form-item>
<!-- 借阅状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jyzt') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'150px'">
<el-select v-model="queryParams.jyzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jyzt.wjy')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jyzt.djy')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jyzt.jyz')" :value="5" />
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">{{ $t('form.search') }}</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">{{ $t('form.reset') }}</el-button>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<!-- 出库日期 -->
<el-form-item :label="$t('page.business.resource.gyzj.cksj') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'180px'">
<el-date-picker v-model="daterangeCk" class="chat-histogram-daterange" type="daterange"
range-separator="-" :start-placeholder="$t('form.startDate')" :end-placeholder="$t('form.endDate')"
value-format="yyyy-MM-dd" @change="handleQuery" style="width: 250px;" />
</el-form-item>
<!-- 入库日期 -->
<el-form-item :label="$t('page.business.resource.gyzj.rksj') + ':'" :label-width="$i18n.locale === 'zh_CN'?'88px':'180px'">
<el-date-picker v-model="daterangeRk" class="chat-histogram-daterange" type="daterange"
range-separator="-" :start-placeholder="$t('form.startDate')" :end-placeholder="$t('form.endDate')"
value-format="yyyy-MM-dd" @change="handleQuery" style="width: 250px;" />
</el-form-item>
</el-col>
</el-row>
<!-- 名称 -->
<el-form-item :label="$t('page.business.resource.gyzj.mc') + ':'">
<el-input v-model="queryParams.mc" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 编号 -->
<el-form-item :label="$t('page.business.resource.gyzj.bh') + ':'">
<el-input v-model="queryParams.bh" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 目的 -->
<el-form-item :label="$t('page.business.resource.gyzj.md') + ':'">
<el-input v-model="queryParams.mdId" clearable :placeholder="$t('form.placeholderInput')" />
</el-form-item>
<!-- 记录状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jlzt') + ':'">
<el-select v-model="queryParams.jlzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jlzt.wsd')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jlzt.ysd')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jlzt.dgd')" :value="5" />
<el-option :label="$t('page.business.resource.resource.jlzt.gd')" :value="7" />
<el-option :label="$t('page.business.resource.resource.jlzt.djd')" :value="9" />
</el-select>
</el-form-item>
<!-- 借阅状态 -->
<el-form-item :label="$t('page.business.resource.gyzj.jyzt') + ':'"
:label-width="$i18n.locale === 'zh_CN' ? '88px' : '150px'">
<el-select v-model="queryParams.jyzt" :placeholder="$t('form.placeholderSelect')" clearable>
<el-option :label="$t('page.business.resource.resource.jyzt.wjy')" :value="1" />
<el-option :label="$t('page.business.resource.resource.jyzt.djy')" :value="3" />
<el-option :label="$t('page.business.resource.resource.jyzt.jyz')" :value="5" />
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">{{ $t('form.search') }}</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">{{ $t('form.reset') }}</el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<!-- 批量归档 -->
<el-button type="primary" :disabled="multiple" @click="handlePlgd"
v-hasPermi="['business:resource:gyzj:ffjlgd']">{{
$t('page.business.resource.gyzj.plgd') }}</el-button>
</el-col>
<el-col :span="1.5">
<!-- 批量锁定 -->
<el-button type="primary" :disabled="multiple" @click="handlePlsd"
v-hasPermi="['business:resource:gyzj:ffjlsd']">{{
$t('page.business.resource.gyzj.plsd') }}</el-button>
</el-col>
<el-col :span="1.5">
<!-- 导出 -->
<el-button type="primary" @click="exportExcel"
v-hasPermi="['business:resource:gyzj:ffjldc']">{{
$t('form.export') }}</el-button>
</el-col>
</el-row>
<el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange">
<el-table-column type="selection" fixed="left" width="55" align="center" :selectable="checkSelectable" />
<el-table v-loading="loading" :data="list">
<el-table-column :label="$t('page.business.resource.gyzj.bh')" align="center" prop="bh"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.mc')" align="left" prop="mc"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.md')" align="center" width="100px" :show-overflow-tooltip="true" >
<el-table-column :label="$t('page.business.resource.gyzj.md')" align="center" width="100px"
:show-overflow-tooltip="true">
<template slot-scope="scope">
<span v-if="scope.row.mdOther && scope.row.mdOther != ''&&scope.row.mdMcs && scope.row.mdMcs != ''">{{ scope.row.mdMcs }},{{ scope.row.mdOther }}</span>
<span v-if="scope.row.mdOther && scope.row.mdOther != '' && scope.row.mdMcs && scope.row.mdMcs != ''">{{
scope.row.mdMcs }},{{ scope.row.mdOther }}</span>
<span v-else>{{ scope.row.mdMcs }}{{ scope.row.mdOther }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.zytj')" align="center" prop="ffzytj" :width="$i18n.locale === 'zh_CN'?'100px':'180px'"/>
<el-table-column :label="$t('page.business.resource.gyzj.zytj')" align="center" prop="ffzytj"
:width="$i18n.locale === 'zh_CN' ? '100px' : '180px'" />
<el-table-column :label="$t('page.business.resource.gyzj.cksj')" align="center" prop="ffrq" width="150px" />
<el-table-column :label="$t('page.business.resource.gyzj.rksj')" align="center" prop="ghrq" width="150px" />
<el-table-column :label="$t('page.business.resource.gyzj.ckl')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.gyzj.ckl')" align="center"
:width="$i18n.locale === 'zh_CN' ? '100px' : '180px'">
<template slot-scope="scope">
{{ scope.row.ckl }} {{ scope.row.ckldw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.rkl')" align="center" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.gyzj.rkl')" align="center"
:width="$i18n.locale === 'zh_CN' ? '100px' : '180px'">
<template slot-scope="scope">
{{ scope.row.rkl }} {{ scope.row.rkldw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.syl')" align="center" :width="$i18n.locale === 'zh_CN'?'80px':'120px'">
<el-table-column :label="$t('page.business.resource.gyzj.syl')" align="center"
:width="$i18n.locale === 'zh_CN' ? '80px' : '120px'">
<template slot-scope="scope">
{{ scope.row.syl }} {{ scope.row.syldw }}
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.kgy1')" align="center" prop="jsr1Mc" :width="$i18n.locale === 'zh_CN'?'80px':'180px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.kgy2')" align="center" prop="jsr2Mc" :width="$i18n.locale === 'zh_CN'?'80px':'180px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr1')" align="center" prop="lqr1Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr2')" align="center" prop="lqr2Mc" :width="$i18n.locale === 'zh_CN'?'80px':'100px'"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.kgy1')" align="center" prop="jsr1Mc"
:width="$i18n.locale === 'zh_CN' ? '80px' : '180px'" :show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.kgy2')" align="center" prop="jsr2Mc"
:width="$i18n.locale === 'zh_CN' ? '80px' : '180px'" :show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr1')" align="center" prop="lqr1Mc"
:width="$i18n.locale === 'zh_CN' ? '80px' : '100px'" :show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.lqr2')" align="center" prop="lqr2Mc"
:width="$i18n.locale === 'zh_CN' ? '80px' : '100px'" :show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.zcg')" align="center" prop="zcgMc"
:show-overflow-tooltip="true" />
<el-table-column :label="$t('page.business.resource.gyzj.jlzt')" align="center" width="100px" fixed="right">
<template slot-scope="scope">
<span v-if="scope.row.jlzt == 1"><span class="status-circle wsd"></span>{{ $t('page.business.resource.resource.jlzt.wsd') }}</span>
<span v-if="scope.row.jlzt == 3"><span class="status-circle ysd"></span>{{ $t('page.business.resource.resource.jlzt.ysd') }}</span>
<span v-if="scope.row.jlzt == 5"><span class="status-circle dgd"></span>{{ $t('page.business.resource.resource.jlzt.dgd') }}</span>
<span v-if="scope.row.jlzt == 7"><span class="status-circle gd"></span>{{ $t('page.business.resource.resource.jlzt.gd') }}</span>
<span v-if="scope.row.jlzt == 9"><span class="status-circle djd"></span>{{ $t('page.business.resource.resource.jlzt.djd') }}</span>
<span v-if="scope.row.jlzt == 1"><span class="status-circle wsd"></span>{{
$t('page.business.resource.resource.jlzt.wsd') }}</span>
<span v-if="scope.row.jlzt == 3"><span class="status-circle ysd"></span>{{
$t('page.business.resource.resource.jlzt.ysd') }}</span>
<span v-if="scope.row.jlzt == 5"><span class="status-circle dgd"></span>{{
$t('page.business.resource.resource.jlzt.dgd') }}</span>
<span v-if="scope.row.jlzt == 7"><span class="status-circle gd"></span>{{
$t('page.business.resource.resource.jlzt.gd') }}</span>
<span v-if="scope.row.jlzt == 9"><span class="status-circle djd"></span>{{
$t('page.business.resource.resource.jlzt.djd') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('page.business.resource.gyzj.jyzt')" align="center" fixed="right" :width="$i18n.locale === 'zh_CN'?'100px':'180px'">
<el-table-column :label="$t('page.business.resource.gyzj.jyzt')" align="center" fixed="right"
:width="$i18n.locale === 'zh_CN' ? '100px' : '180px'">
<template slot-scope="scope">
<span v-if="scope.row.jyzt == 1"><span class="status-circle wjy"></span>{{ $t('page.business.resource.resource.jyzt.wjy') }}</span>
<span v-if="scope.row.jyzt == 3"><span class="status-circle djy"></span>{{ $t('page.business.resource.resource.jyzt.djy') }}</span>
<span v-if="scope.row.jyzt == 5"><span class="status-circle jyz"></span>{{ $t('page.business.resource.resource.jyzt.jyz') }}</span>
<span v-if="scope.row.jyzt == 1"><span class="status-circle wjy"></span>{{
$t('page.business.resource.resource.jyzt.wjy') }}</span>
<span v-if="scope.row.jyzt == 3"><span class="status-circle djy"></span>{{
$t('page.business.resource.resource.jyzt.djy') }}</span>
<span v-if="scope.row.jyzt == 5"><span class="status-circle jyz"></span>{{
$t('page.business.resource.resource.jyzt.jyz') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('form.operate')" fixed="right" align="center"
class-name="small-padding fixed-width" width="250px">
class-name="small-padding fixed-width" width="200px">
<template slot-scope="scope">
<!-- 加签 -->
<el-button v-if="scope.row.jlzt == 1" type="text" @click="handleJq(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljq']">{{
$t('page.business.resource.gyzj.jiaqian') }}</el-button>
<!-- 详情 -->
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jlzt == 7" type="text"
@click="handleXq(scope.row)" v-hasPermi="['business:resource:gyzj:ffjlxq']">{{
<template>
<!-- 详情 -->
<el-button type="text" @click="handleXq(scope.row)" v-hasPermi="['business:archive:gyzjFfjl:xq']">{{
$t('page.business.resource.gyzj.detail') }}</el-button>
<!-- 锁定 -->
<el-button type="text" v-if="scope.row.jlzt == 1" @click="handleSd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjlsd']">{{
$t('page.business.resource.gyzj.lock') }}</el-button>
<!-- 解锁 -->
<el-button type="text" v-if="scope.row.jlzt == 3" @click="handleJs(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljs']">{{
$t('page.business.resource.gyzj.unlock') }}</el-button>
<!-- 归档 -->
<el-button type="text" v-if="scope.row.jlzt == 3" @click="handleGd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjlgd']">{{
$t('page.business.resource.gyzj.guidang') }}</el-button>
<!-- 解档 -->
<el-button type="text" v-if="scope.row.jlzt == 7" @click="handleJd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljd']">{{
$t('page.business.resource.gyzj.jiedang') }}</el-button>
<!-- 借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 1" @click="handleJy(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljy']">{{
$t('page.business.resource.gyzj.jieyue') }}</el-button>
<!-- 同意归档 -->
<el-button type="text" v-if="scope.row.jlzt == 5"
@click="handleSign(scope.row, 'page.business.resource.gyzj.tygd', false, 'tygd')"
v-hasPermi="['business:archive:gyzjFfjl:tygd']">{{
$t('page.business.resource.gyzj.tygd') }}</el-button>
<!-- 拒绝归档 -->
<el-button type="text" v-if="scope.row.jlzt == 5"
@click="handleSign(scope.row, 'page.business.resource.gyzj.jjgd', false, 'jjgd', true, true)"
v-hasPermi="['business:archive:gyzjFfjl:jjgd']">{{
$t('page.business.resource.gyzj.jjgd') }}</el-button>
<!-- 同意解档 -->
<el-button type="text" v-if="scope.row.jlzt == 9"
@click="handleSign(scope.row, 'page.business.resource.gyzj.tyjd', false, 'tyjd')"
v-hasPermi="['business:archive:gyzjFfjl:tyjd']">{{
$t('page.business.resource.gyzj.tyjd') }}</el-button>
<!-- 拒绝解档 -->
<el-button type="text" v-if="scope.row.jlzt == 9"
@click="handleSign(scope.row, 'page.business.resource.gyzj.jjjd', false, 'jjjd', true, true)"
v-hasPermi="['business:archive:gyzjFfjl:jjjd']">{{
$t('page.business.resource.gyzj.jjjd') }}</el-button>
<!-- 同意借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 3"
@click="handleSign(scope.row, 'page.business.resource.gyzj.tyjy', true, 'tyjy')"
v-hasPermi="['business:archive:gyzjFfjl:tyjy']">{{
$t('page.business.resource.gyzj.tyjy') }}</el-button>
<!-- 拒绝借阅 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 3"
@click="handleSign(scope.row, 'page.business.resource.gyzj.jjjy', true, 'jjjy', true, true)"
v-hasPermi="['business:archive:gyzjFfjl:jjjy']">{{
$t('page.business.resource.gyzj.jjjy') }}</el-button>
<!-- 确认归还 -->
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 5"
@click="handleSign(scope.row, 'page.business.resource.gyzj.qrgh', false, 'qrgh')"
v-hasPermi="['business:archive:gyzjFfjl:qrgh']">{{
$t('page.business.resource.gyzj.qrgh') }}</el-button>
</template>
</template>
</el-table-column>
</el-table>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" />
</div>
<!-- 详情 -->
<Xq v-show="showDetail" key="Xq" ref="Xq" @callback="closeXq" />
<!-- 签名 -->
<Sign ref="refSign" @callback="doSign" />
</div>
</div>
</template>
<script>
import { list } from "@/api/business/gyzj/gyzjFfjl"
import moment from "moment";
import { deepClone } from "@/utils/index";
import { list, tygd, jjgd, tyjd, jjjd, tyjy, jjjy, qrgh } from "@/api/business/gyzj/gyzjFfjlArchive"
import Sign from "@/views/business/comps/common/sign";
import Xq from "@/views/business/resource/gyzj/comps/ffjl/Xq";
export default {
name: "FfjlList",
components: { },
name: "GyzjDaList",
components: { Xq, Sign },
data() {
return {
daterangeCk: [],
daterangeRk: [],
loading: true,
showDetail: false,
single: true,
multiple: true,
type: '',
total: 0,
list: [],
//
selectList: [],
//
form: {
id: null
},
queryParams: {
pageNum: 1,
pageSize: 10,
@ -212,10 +197,6 @@ export default {
jlzt: null,
jyzt: null,
bh: null,
startDateCk: null,
endDateCk: null,
startDateRk: null,
endDateRk: null,
},
}
},
@ -223,168 +204,63 @@ export default {
this.getList()
},
methods: {
exportExcel() {
let that = this
that.$modal.loading()
let params = deepClone(this.queryParams)
params.pageSize = 999999
list(params).then(response => {
var tabelStr =
'<table border="1" class="html-tabel">' +
'<tr style="background:#eee;">' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.mc') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.bh') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.md') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.zytj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.cksj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.rksj') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.ckmz') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.rkmz') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.syl') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.lqr1') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.lqr2') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.kgy1') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.kgy2') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.zcg') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.jlzt') + '</th>' +
'<th style="text-align: center;">' + this.$t('page.business.resource.gyzj.jyzt') + '</th>' +
' </tr>'
let _datastr = ''
_.forEach(response.rows, function (value) {
let jlzt = ''
switch (value.jlzt) {
case 1:
jlzt = that.$t('page.business.resource.resource.jlzt.wsd')
break
case 3:
jlzt = that.$t('page.business.resource.resource.jlzt.ysd')
break
case 5:
jlzt = that.$t('page.business.resource.resource.jlzt.dgd')
break
case 7:
jlzt = that.$t('page.business.resource.resource.jlzt.gd')
break
case 9:
jlzt = that.$t('page.business.resource.resource.jlzt.djd')
break
default: zjzt = ''
}
let jyzt = ''
switch (value.jyzt) {
case 1:
jyzt = that.$t('page.business.resource.resource.jyzt.wjy')
break
case 3:
jyzt = that.$t('page.business.resource.resource.jyzt.djy')
break
case 5:
jyzt = that.$t('page.business.resource.resource.jyzt.jyz')
break
default: jyzt = ''
}
_datastr =
_datastr +
'<tr style="text-align: center;">' +
' <td>' +
value.mc +
'</td>' +
' <td>' +
'&nbsp;'+value.bh +
'</td>' +
' <td>' +
(value.mdMcs&&value.mdMcs!=''&&value.mdOther&&value.mdOther!=''? (value.mdMcs +","+value.mdOther) :(value.mdMcs +value.mdOther))+
'</td>' +
' <td>' +
value.ffzytj +
'</td>' +
' <td>' +
value.ffrq +
'</td>' +
' <td>' +
value.ghrq +
'</td>' +
' <td>' +
value.ckl +value.ckldw+
'</td>' +
' <td>' +
value.rkl+value.rkldw +
'</td>' +
' <td>' +
value.syl+value.syldw +
'</td>' +
' <td>' +
value.lqr1Mc +
'</td>' +
' <td>' +
value.lqr2Mc +
'</td>' +
' <td>' +
value.jsr1Mc +
'</td>' +
' <td>' +
value.jsr2Mc +
'</td>' +
' <td>' +
value.zcgMc +
'</td>' +
' <td>' +
jlzt +
'</td>' +
' <td>' +
jyzt +
'</td>' +
'</tr>'
})
tabelStr = tabelStr + _datastr + ' <table>'
// Worksheet
var worksheet = that.$t('page.business.resource.gyzj.ffhsjl')
var uri = 'data:application/vnd.ms-excel;base64,'
// HTML
var exportTemplate = `<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel"
xmlns="http://www.w3.org/TR/REC-html40">
<head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet>
<x:Name>${worksheet}</x:Name>
<x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet>
</x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]-->
</head>
<body>
${tabelStr}
</body>
</html>`
var a = document.createElement('a')
a.download = worksheet + '.xls'
a.href = uri + window.btoa(unescape(encodeURIComponent(exportTemplate)))
a.click()
that.$modal.closeLoading()
}).finally(() => {
that.$modal.closeLoading()
})
},
//
handleJq(row) {
this.$refs.Jq.show(row)
},
//
handleSd(row) {
this.$refs.Sd.show(row)
handleSign(row, qmyy, showDate, type, isReson, reasonRequired) {
this.form.id = row.id
let title = this.$t(qmyy)
this.type = type
this.$refs.refSign.show(title, title, showDate, (type == 'jjjy' || type == 'tyjy') ? [row.jyksrq, row.jyjsrq] : [], isReson, reasonRequired)
},
//
handleJs(row) {
this.$refs.Js.show(row)
},
//
handlePlgd() {
this.$refs.Gd.showBatch(this.selectList)
},
//
handlePlsd() {
this.$refs.Sd.showBatch(this.selectList)
doSign(val) {
let params = _.merge({}, this.form, val)
this.$modal.loading()
if (this.type == 'tygd') {
tygd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjgd') {
jjgd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'tyjd') {
tyjd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjjd') {
jjjd(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'tyjy') {
tyjy(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'jjjy') {
jjjy(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
} else if (this.type == 'qrgh') {
qrgh(params).then(response => {
this.handleQuery()
}).finally(() => {
this.$modal.closeLoading()
})
}
},
closeXq() {
this.showDetail = false
this.$emit('showDetail', this.showDetail)
this.handleQuery()
this.$emit('showDetail', this.showDetail)
},
//
handleXq(row) {
@ -392,38 +268,8 @@ export default {
this.$emit('showDetail', this.showDetail)
this.$refs.Xq.show(row)
},
//
handleGd(row) {
this.$refs.Gd.show(row)
},
//
handleJy(row) {
this.$refs.Jy.show(row)
},
//
handleJd(row) {
this.$refs.Jd.show(row)
},
//
checkSelectable(row) {
return true;
},
//
getList() {
if (this.daterangeCk != null && this.daterangeCk.length > 0) {
this.queryParams.startDateCk = this.daterangeCk[0]
this.queryParams.endDateCk = moment().add(this.daterangeCk[1], 'days').format('YYYY-MM-DD');
} else {
this.queryParams.startDateCk = ''
this.queryParams.endDateCk = ''
}
if (this.daterangeRk != null && this.daterangeRk.length > 0) {
this.queryParams.startDateRk = this.daterangeRk[0]
this.queryParams.endDateRk = moment().add(this.daterangeRk[1], 'days').format('YYYY-MM-DD');
} else {
this.queryParams.startDateRk = ''
this.queryParams.endDateRk = ''
}
this.loading = true
list(this.queryParams).then(response => {
this.list = response.rows
@ -438,30 +284,19 @@ export default {
},
//
resetQuery() {
this.queryParams.mc = null
this.queryParams.mc = null
this.queryParams.mdId = null
this.queryParams.jlzt = null
this.queryParams.jyzt = null
this.queryParams.bh = null
this.queryParams.startDateCk = null
this.queryParams.endDateCk = null
this.queryParams.startDateRk = null
this.queryParams.endDateRk = null
this.daterangeCk = []
this.daterangeRk = []
this.handleQuery()
},
//
handleSelectionChange(selection) {
this.single = selection.length !== 1
this.multiple = !selection.length
this.selectList = selection
}
}
}
</script>
<style rel="stylesheet/scss" lang="scss">
.ffjl {
.gyzj {
background: #fff;
padding: 10px 10px;
}

+ 2
- 2
src/views/business/resource/gyzj/comps/ffjlList.vue View File

@ -150,7 +150,7 @@
v-hasPermi="['business:resource:gyzj:ffjljq']">{{
$t('page.business.resource.gyzj.jiaqian') }}</el-button>
<!-- 详情 -->
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jlzt == 7" type="text"
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jyzt == 5" type="text"
@click="handleXq(scope.row)" v-hasPermi="['business:resource:gyzj:ffjlxq']">{{
$t('page.business.resource.gyzj.detail') }}</el-button>
<!-- 锁定 -->
@ -166,7 +166,7 @@
v-hasPermi="['business:resource:gyzj:ffjlgd']">{{
$t('page.business.resource.gyzj.guidang') }}</el-button>
<!-- 解档 -->
<el-button type="text" v-if="scope.row.jlzt == 7" @click="handleJd(scope.row)"
<el-button type="text" v-if="scope.row.jlzt == 7 && scope.row.jyzt == 1" @click="handleJd(scope.row)"
v-hasPermi="['business:resource:gyzj:ffjljd']">{{
$t('page.business.resource.gyzj.jiedang') }}</el-button>
<!-- 借阅 -->

+ 2
- 2
src/views/business/resource/mjy/comps/ffjlList.vue View File

@ -148,7 +148,7 @@
@click="handleJq(scope.row)" v-hasPermi="['business:resource:mjy:ffjljq']">{{
$t('page.business.resource.mjy.jiaqian') }}</el-button>
<!-- 详情 -->
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jlzt == 7" type="text"
<el-button v-if="scope.row.jlzt == 1 || scope.row.jlzt == 3 || scope.row.jyzt == 5" type="text"
@click="handleXq(scope.row)" v-hasPermi="['business:resource:mjy:ffjlxq']">{{
$t('page.business.resource.mjy.detail') }}</el-button>
<!-- 锁定 -->
@ -164,7 +164,7 @@
v-hasPermi="['business:resource:mjy:ffjlgd']">{{
$t('page.business.resource.mjy.guidang') }}</el-button>
<!-- 解档 -->
<el-button type="text" v-if="scope.row.jlzt == 7" @click="handleJd(scope.row)"
<el-button type="text" v-if="scope.row.jlzt == 7&&scope.row.jyzt == 1" @click="handleJd(scope.row)"
v-hasPermi="['business:resource:mjy:ffjljd']">{{
$t('page.business.resource.mjy.jiedang') }}</el-button>
<!-- 借阅 -->

Loading…
Cancel
Save