pm重传审批修改
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
810c786512
commit
269f9f9477
|
@ -172,17 +172,17 @@
|
|||
<el-table-column prop="AuditTime" :label="$t('trials:reuploadAudit:table:auditTime')"
|
||||
show-overflow-tooltip sortable="custom" min-width="150px" />
|
||||
<el-table-column :label="$t('common:action:action')" fixed="right"
|
||||
v-if="hasPermi(['trials:trials-panel:visit:reupload-audit:agree', 'trials:trials-panel:visit:reupload-audit:refuse'])"
|
||||
v-if="hasPermi(['trials:trials-panel:visit:reupload-audit:agree'])"
|
||||
min-width="120px">
|
||||
<template slot-scope="scope">
|
||||
<el-button :title="$t('trials:reuploadAudit:button:auditYes')"
|
||||
<el-button :title="$t('trials:reuploadAudit:button:imageBack')"
|
||||
v-hasPermi="['trials:trials-panel:visit:reupload-audit:agree']" circle
|
||||
:disabled="scope.row.ImageBackState > 0" icon="el-icon-check" size="mini"
|
||||
@click="audit(scope.row, 1)" />
|
||||
<el-button :title="$t('trials:reuploadAudit:button:auditNo')"
|
||||
:disabled="scope.row.ImageBackState > 0" icon="el-icon-edit-outline" size="mini"
|
||||
@click="audit(scope.row)" />
|
||||
<!-- <el-button :title="$t('trials:reuploadAudit:button:auditNo')"
|
||||
v-hasPermi="['trials:trials-panel:visit:reupload-audit:refuse']"
|
||||
:disabled="scope.row.ImageBackState > 0" circle icon="el-icon-close" size="mini"
|
||||
@click="audit(scope.row, 2)" />
|
||||
@click="audit(scope.row, 2)" /> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
@ -191,6 +191,35 @@
|
|||
<pagination class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize"
|
||||
@pagination="getList" />
|
||||
</template>
|
||||
<base-model v-if="config.visible" :config="config">
|
||||
<template slot="dialog-body">
|
||||
<div style="text-align: center;font-weight: bold;margin-bottom: 10px;">{{ rowData.title }}</div>
|
||||
<el-form ref="imageBackform" :model="form" class="demo-form-inline" :rules="rules" label-width="100px">
|
||||
<el-form-item :label="$t('trials:reuploadAudit:table:ApplyReason') + ': '" prop="ApplyReason">
|
||||
<span>{{ rowData.ApplyReason }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('trials:reuploadAudit:form:IsAgree') + ': '" prop="IsAgree">
|
||||
<el-radio-group v-model="form.IsAgree">
|
||||
<el-radio :label="true">{{ $t('trials:reuploadAudit:button:auditYes') }}</el-radio>
|
||||
<el-radio :label="false">{{ $t('trials:reuploadAudit:button:auditNo') }}</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('trials:reuploadAudit:table:ResultRemark') + ': '" prop="ResultRemark">
|
||||
<el-input type="textarea" :autosize="{ minRows: 2, maxRows: 4 }" placeholder=""
|
||||
v-model="form.ResultRemark">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
<template slot="dialog-footer">
|
||||
<el-button type="primary" @click="auditImageBack" :loading="loading">
|
||||
{{ $t('common:button:confirm') }}
|
||||
</el-button>
|
||||
<el-button @click="config.visible = false" :loading="loading">
|
||||
{{ $t('common:button:cancel') }}
|
||||
</el-button>
|
||||
</template>
|
||||
</base-model>
|
||||
</BaseContainer>
|
||||
</template>
|
||||
<script>
|
||||
|
@ -204,6 +233,7 @@ import {
|
|||
import BaseContainer from '@/components/BaseContainer'
|
||||
import Pagination from '@/components/Pagination'
|
||||
import moment from 'moment'
|
||||
import baseModel from '@/components/BaseModel'
|
||||
|
||||
const searchDataDefault = () => {
|
||||
return {
|
||||
|
@ -229,7 +259,8 @@ export default {
|
|||
name: 'QcCheck',
|
||||
components: {
|
||||
BaseContainer,
|
||||
Pagination
|
||||
Pagination,
|
||||
baseModel
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
@ -243,7 +274,27 @@ export default {
|
|||
timeListC: [],
|
||||
timeList: [],
|
||||
trialId: null,
|
||||
moment
|
||||
moment,
|
||||
rowData: {},
|
||||
config: {
|
||||
visible: false,
|
||||
title: this.$t("trials:reuploadAudit:confirmMessage:imageBack"),
|
||||
width: '500px',
|
||||
appendToBody: true,
|
||||
},
|
||||
form: {
|
||||
IsAgree: null,
|
||||
ResultRemark: null
|
||||
},
|
||||
rules: {
|
||||
IsAgree: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('common:ruleMessage:select'),
|
||||
trigger: ['blur', 'change'],
|
||||
},
|
||||
],
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
|
@ -259,48 +310,39 @@ export default {
|
|||
this.getVisitPlanOptions()
|
||||
},
|
||||
methods: {
|
||||
async audit(row, state) {
|
||||
async audit(row) {
|
||||
try {
|
||||
let status = state === 1 ? this.$t('trials:reuploadAudit:button:auditYes') : this.$t('trials:reuploadAudit:button:auditNo')
|
||||
let message = this.$t("trials:reuploadAudit:confirmMessage:imageBack").replace("xxx", status)
|
||||
this.$prompt(this.$t("trials:reuploadAudit:confirmMessage:ResultRemark"), message, {
|
||||
confirmButtonText: this.$t("common:button:save"),
|
||||
cancelButtonText: this.$t("common:button:cancel"),
|
||||
}).then(async ({ value }) => {
|
||||
let params = {
|
||||
IamgeBackRecordId: row.Id,
|
||||
IsAgree: state === 1 ? true : false,
|
||||
ResultRemark: value
|
||||
}
|
||||
// return console.log(params)
|
||||
this.loading = true
|
||||
let res = await auditImageBack(params)
|
||||
this.loading = false
|
||||
if (res.IsSuccess) {
|
||||
this.getList()
|
||||
}
|
||||
}).catch(() => {
|
||||
|
||||
});
|
||||
|
||||
// let confirm = await this.$confirm(message)
|
||||
// if (!confirm) return false
|
||||
// let params = {
|
||||
// IamgeBackRecordId: row.Id,
|
||||
// IsAgree: state === 1 ? true : false,
|
||||
// ResultRemark
|
||||
// }
|
||||
// this.loading = true
|
||||
// let res = await auditImageBack(params)
|
||||
// this.loading = false
|
||||
// if (res.IsSuccess) {
|
||||
// this.getList()
|
||||
// }
|
||||
this.rowData = Object.assign({}, row)
|
||||
this.rowData.title = `${row.CreateUserFullName} (${this.$fd('ImageBackApplyEnum', row.ApplyUserRole)}) ${this.$t('trials:reuploadAudit:title:imageBack').replace('xxx', row.SubjectCode).replace('yyy', row.VisitName)}`
|
||||
Object.keys(this.form).forEach(key => {
|
||||
this.form[key] = null
|
||||
})
|
||||
this.config.visible = true
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
this.loading = false
|
||||
}
|
||||
},
|
||||
async auditImageBack() {
|
||||
try {
|
||||
let validate = await this.$refs.imageBackform.validate()
|
||||
if (!validate) return false
|
||||
let params = Object.assign({}, this.form)
|
||||
params.IamgeBackRecordId = this.rowData.Id
|
||||
// return console.log(params)
|
||||
this.loading = true
|
||||
let res = await auditImageBack(params)
|
||||
this.loading = false
|
||||
if (res.IsSuccess) {
|
||||
this.config.visible = false
|
||||
this.getList()
|
||||
}
|
||||
} catch (err) {
|
||||
this.loading = false
|
||||
console.log(err)
|
||||
}
|
||||
|
||||
},
|
||||
getList() {
|
||||
this.loading = true
|
||||
this.searchData.TrialId = this.trialId
|
||||
|
|
Loading…
Reference in New Issue