| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301 |
- <template>
- <div class="app-container">
- <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="120px">
- <el-form-item label="隡�凝�睃極�萇妍" prop="qwUserName">
- <el-input
- v-model="queryParams.qwUserName"
- placeholder="霂瑁��乩�敺桀�撌交猐蝘?
- clearable
- size="small"
- @keyup.enter.native="handleQuery"
- />
- </el-form-item>
- <el-form-item label="摰X��萇妍" prop="externalUserName">
- <el-input
- v-model="queryParams.externalUserName"
- placeholder="霂瑁��乩�敺桀恥�瑟猐蝘?
- clearable
- size="small"
- @keyup.enter.native="handleQuery"
- />
- </el-form-item>
- <el-form-item label="�煾�?�𣂼�)�嗆�? prop="sendStatus">
- <el-select v-model="queryParams.sendStatus" placeholder="霂琿�㗇𥋘�煾�?�𣂼�)�嗆�? clearable size="small">
- <el-option
- v-for="dict in sysQwSopLogsStatus"
- :key="dict.dictValue"
- :label="dict.dictLabel"
- :value="dict.dictValue"
- />
- </el-select>
- </el-form-item>
- <el-form-item label="�交𤣰(摰X�)�嗆�? prop="receivingStatus">
- <el-select v-model="queryParams.receivingStatus" placeholder="霂琿�㗇𥋘�交𤣰(摰X�)�嗆�? clearable size="small">
- <el-option
- v-for="dict in groupMsgSendStatusOptions"
- :key="dict.dictValue"
- :label="dict.dictLabel"
- :value="dict.dictValue"
- />
- </el-select>
- </el-form-item>
- <el-form-item>
- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">�𦦵揣</el-button>
- <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">�滨蔭</el-button>
- </el-form-item>
- </el-form>
- <el-row :gutter="10" class="mb8">
- <el-col :span="1.5">
- <el-button
- type="warning"
- plain
- icon="el-icon-download"
- size="mini"
- :loading="exportLoading"
- @click="handleExport"
- v-hasPermi="['course:sopLogs:export']"
- >撖澆枂</el-button>
- </el-col>
- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
- </el-row>
- <el-tabs type="card" v-model="defaultWatchStatus" @tab-click="handleClickX">
- <el-tab-pane v-for="(item,index) in sysFsSopWatchStatus" :label="item.dictLabel" :name="item.dictValue"></el-tab-pane>
- </el-tabs>
- <el-table v-loading="loading" :data="qwSopLogsList">
- <el-table-column label="隡�凝�𣂼��萇妍" align="center" prop="qwUserName" />
- <el-table-column label="蝟餌��𤾸蝱�萇妍" align="center" prop="userName" />
- <el-table-column label="摰X��萇妍" align="center" prop="externalUserName" />
- <el-table-column label="閫���嗆�? align="center" prop="watchStatus">
- <template slot-scope="scope">
- <dict-tag :options="sysFsSopWatchStatus" :value="scope.row.watchStatus"/>
- </template>
- </el-table-column>
- <el-table-column label="�煾���瘨��" align="center" prop="contentJson" >
- <template slot-scope="scope">
- <el-button type="text" @click="showContentDialog(scope.row.contentJson)">
- �亦�霂行�
- </el-button>
- </template>
- </el-table-column>
- <el-table-column label="�𣂼��嗆�? align="center" prop="sendStatus" >
- <template slot-scope="scope">
- <dict-tag :options="sysQwSopLogsStatus" :value="scope.row.sendStatus"/>
- </template>
- </el-table-column>
- <el-table-column label="憸�恣�煾��𧒄�? align="center" prop="sendTime" width="180"/>
- <el-table-column label="摰X��交𤣰" align="center" prop="receivingStatus" >
- <template slot-scope="scope">
- <dict-tag :options="groupMsgSendStatusOptions" :value="scope.row.receivingStatus"/>
- </template>
- </el-table-column>
- </el-table>
- <el-dialog :visible.sync="contentDialog.isDialogVisible" title="瘨��霂行�" width="30%" append-to-body>
- <el-card v-for="(item, index) in contentDialog.selectedContentJson" :key="index" class="box-card" style="margin-top: 2%">
- <div slot="header" class="clearfix">
- <span>瘨��{{index}}:</span>
- </div>
- <div v-safe-html="item.value"></div>
- </el-card>
- <span slot="footer" class="dialog-footer">
- <el-button @click="contentDialog.isDialogVisible = false">�喲𡡒</el-button>
- </span>
- </el-dialog>
- <!-- 憭批㦛憸��撖寡�獢?-->
- <el-dialog
- :visible.sync="dialogVisible"
- :modal="false"
- width="500"
- append-to-body>
- <img
- :src="this.dialogImageUrl"
- style="display: block; max-width: 100%; margin: 0 auto"
- />
- </el-dialog>
- <pagination
- v-show="total>0"
- :total="total"
- :page.sync="queryParams.pageNum"
- :limit.sync="queryParams.pageSize"
- @pagination="getList"
- />
- </div>
- </template>
- <script>
- import { listSopLogs } from '@/api/course/sopLogs'
- export default {
- name: "sopLogsList",
- data() {
- return {
- //�曄��曉之
- dialogVisible: false,
- dialogImageUrl:null,
- //暺䁅恕閫��
- defaultWatchStatus:"0",
- // �桃蔗撅?
- loading: true,
- // 撖澆枂�桃蔗撅?
- exportLoading: false,
- // �劐葉�啁�
- ids: [],
- // �𧼮�銝芰��?
- single: true,
- // �𧼮�銝芰��?
- multiple: true,
- // �曄內�𦦵揣�∩辣
- showSearch: true,
- // �餅辺�?
- total: 0,
- // 隡��敺桐縑SOP 摰𡁏𧒄隞餃𦛚銵冽聢�唳旿
- qwSopLogsList: [],
- //�𣂼��嗆�?
- sysQwSopLogsStatus:[],
- //摰X��交𤣰�嗆�?
- groupMsgSendStatusOptions:[],
- //SOP霂曄�閫���嗆�?
- sysFsSopWatchStatus:[],
- //�煾���瘨��
- contentDialog:{
- isDialogVisible:false,
- selectedContentJson: [],
- },
- // 撘孵枂撅��憸?
- title: "",
- // �臬炏�曄內撘孵枂撅?
- open: false,
- // �亥砭��㺭
- queryParams: {
- pageNum: 1,
- pageSize: 10,
- qwUserName: null,
- externalUserName: null,
- sendStatus: null,
- sendTime: null,
- receivingStatus: null,
- watchStatus:null,
- },
- // 銵典���㺭
- form: {},
- // 銵典��⊿�
- rules: {
- }
- };
- },
- created() {
- this.getList();
- //�𣂼��嗆�?
- this.getDicts("sys_qw_sopLogs_status").then(response => {
- this.sysQwSopLogsStatus = response.data;
- });
- //摰X��交𤣰�嗆�?
- this.getDicts("sys_qw_groupMsg_SendStatus").then(response => {
- this.groupMsgSendStatusOptions = response.data;
- });
- //摰X�閫���嗆�?
- this.getDicts("sys_fs_sop_watch_status").then(response => {
- this.sysFsSopWatchStatus = response.data;
- });
- },
- methods: {
- /** �亥砭隡��敺桐縑SOP 摰𡁏𧒄隞餃𦛚�𡑒” */
- getList() {
- this.loading = true;
- listSopLogs(this.queryParams).then(response => {
- this.qwSopLogsList = response.rows;
- this.total = response.total;
- this.loading = false;
- });
- },
- /**
- * �亦�閫��銝讠�閫��霂行�
- */
- selectSopLogsDetails(val){
- this.queryParams.sopId= val;
- this.getList();
- },
- handleClickX(tab, event) {
- this.queryParams.watchStatus=tab.name;
- this.handleQuery();
- },
- // �𡝗��厰僼
- cancel() {
- this.open = false;
- this.reset();
- },
- // 銵典��滨蔭
- reset() {
- this.form = {
- id: null,
- qwUserName: null,
- externalUserName: null,
- contentJson: null,
- watchStatus:null,
- sendStatus: null,
- sendTime: null,
- companyId: null,
- receivingStatus: null,
- msgId: null,
- sopId: null
- };
- this.resetForm("form");
- },
- openImageViewer(url) {
- // �枏�憭批㦛憸��撖寡�獢?
- this.dialogImageUrl=url
- this.dialogVisible = true;
- },
- //�亦��煾���瘨��雿?
- showContentDialog(contentJson) {
- this.contentDialog.selectedContentJson = JSON.parse(contentJson);
- this.contentDialog.isDialogVisible = true;
- },
- /** �𦦵揣�厰僼�滢� */
- handleQuery() {
- this.queryParams.pageNum = 1;
- this.getList();
- },
- /** �滨蔭�厰僼�滢� */
- resetQuery() {
- this.resetForm("queryForm");
- this.handleQuery();
- },
- /** 撖澆枂�厰僼�滢� */
- handleExport() {
- const queryParams = this.queryParams;
- this.$confirm('�臬炏蝖株恕撖澆枂���劐�銝𡁜凝靽﹖OP 摰𡁏𧒄隞餃𦛚�唳旿憿?', "霅血�", {
- confirmButtonText: "蝖桀�",
- cancelButtonText: "�𡝗�",
- type: "warning"
- }).then(() => {
- this.exportLoading = true;
- return exportQwSopLogs(queryParams);
- }).then(response => {
- this.download(response.msg);
- this.exportLoading = false;
- }).catch(() => {});
- }
- }
- };
- </script>
|