Merge branch 'main' of https://gitea.frp.extimaging.com/XCKJ/irc_web into main
continuous-integration/drone/push Build is passing Details

uat
caiyiling 2025-03-06 15:10:50 +08:00
commit d74da23d41
11 changed files with 565 additions and 341 deletions

View File

@ -56,6 +56,16 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item
:label="$t('dictionary:file:form:ShowOrder')"
prop="ShowOrder"
>
<el-input-number
v-model="form.ShowOrder"
:step="1"
step-strictly
></el-input-number>
</el-form-item>
<el-form-item :label="$t('dictionary:file:form:IsEnable')"> <el-form-item :label="$t('dictionary:file:form:IsEnable')">
<el-switch <el-switch
v-model="form.IsEnable" v-model="form.IsEnable"
@ -115,6 +125,7 @@ export default {
Name: null, Name: null,
NameCN: null, NameCN: null,
SubIdentificationEnum: null, SubIdentificationEnum: null,
ShowOrder: 0,
}, },
rules: { rules: {
Name: [ Name: [

View File

@ -144,6 +144,12 @@
{{ $fd('SubIdentification', scope.row.SubIdentificationEnum) }} {{ $fd('SubIdentification', scope.row.SubIdentificationEnum) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
prop="ShowOrder"
:label="$t('dictionary:file:table:ShowOrder')"
show-overflow-tooltip
sortable="custom"
/>
<el-table-column <el-table-column
:label="$t('dictionary:file:table:IsEnable')" :label="$t('dictionary:file:table:IsEnable')"
prop="IsEnable" prop="IsEnable"

View File

@ -160,25 +160,34 @@
show-overflow-tooltip show-overflow-tooltip
> >
<template slot-scope="scope"> <template slot-scope="scope">
<el-tooltip <el-button
class="item"
effect="dark"
:content="$t('trials:staff:tip:userTypeDisabled')"
placement="top"
style="margin-right: 2px"
v-if=" v-if="
scope.row.TrialUserRoleList.some( Array.isArray(scope.row.TrialUserRoleList) &&
(item) => item.IsDeleted || item.IsUserRoleDisabled scope.row.TrialUserRoleList.length > 0
)
" "
type="text"
@click.stop="openRoleList(scope.row)"
> >
<i class="el-icon-warning icon-i"></i> <el-tooltip
</el-tooltip> class="item"
<span>{{ effect="dark"
scope.row.TrialUserRoleList.map( :content="$t('trials:staff:tip:userTypeDisabled')"
(item) => item.UserTypeShortName placement="top"
).join(', ') style="margin-right: 2px"
}}</span> v-if="
scope.row.TrialUserRoleList.some(
(item) => item.IsDeleted || item.IsUserRoleDisabled
)
"
>
<i class="el-icon-warning icon-i"></i>
</el-tooltip>
<span>{{
scope.row.TrialUserRoleList.map(
(item) => item.UserTypeShortName
).join(', ')
}}</span>
</el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -230,6 +239,89 @@
:limit.sync="searchData.PageSize" :limit.sync="searchData.PageSize"
@pagination="getList" @pagination="getList"
/> />
<!-- 修改参与者人员角色 -->
<base-model v-if="role_model.visible" :config="role_model">
<template slot="dialog-body">
<el-table :data="roleList" style="width: 100%" max-height="300px">
<el-table-column type="index" width="60">
<template slot-scope="scope">
<span
style="
display: flex;
align-items: center;
justify-content: flex-end;
"
>
<el-tooltip
class="item"
effect="dark"
:content="$t('system:retrospect:tip:userTypeSysDisabled')"
placement="top"
style="margin-right: 3px"
v-if="scope.row.IsUserRoleDisabled"
>
<i
v-if="scope.row.IsUserRoleDisabled"
class="el-icon-warning icon-i"
></i>
</el-tooltip>
<span>{{ scope.$index + 1 }}</span>
</span>
</template>
</el-table-column>
<el-table-column
prop="UserTypeShortName"
:label="
$t(
'system:retrospect:table:UserTypeShortName'
)
"
/>
<el-table-column
prop="IsDeleted"
:label="
$t(
'system:retrospect:table:IsUserRoleDisabled'
)
"
>
<template slot-scope="scope">
<span> {{ $fd('IsDisable', scope.row.IsDeleted) }}</span>
</template>
</el-table-column>
<el-table-column
prop="IsDeleted"
:label="
$t(
'system:retrospect:table:enableTime'
)
"
min-width="120px"
>
<template slot-scope="scope">
<span>
{{ scope.row.CreateTime }}
</span>
</template>
</el-table-column>
<el-table-column
prop="IsDeleted"
:label="
$t(
'system:retrospect:table:forbiddenTime'
)
"
min-width="120px"
>
<template slot-scope="scope">
<span v-if="scope.row.IsDeleted">
{{ scope.row.UpdateTime }}
</span>
</template>
</el-table-column>
</el-table>
</template>
</base-model>
</box-content> </box-content>
</template> </template>
<script> <script>
@ -239,6 +331,7 @@ import {
} from '@/api/admin.js' } from '@/api/admin.js'
import Pagination from '@/components/Pagination' import Pagination from '@/components/Pagination'
import BoxContent from '@/components/BoxContent' import BoxContent from '@/components/BoxContent'
import BaseModel from '@/components/BaseModel'
const searchDataDefault = () => { const searchDataDefault = () => {
return { return {
TrialCode: null, TrialCode: null,
@ -253,7 +346,7 @@ const searchDataDefault = () => {
} }
} }
export default { export default {
components: { BoxContent, Pagination }, components: { BoxContent, Pagination, BaseModel },
props: { props: {
userId: { type: String, default: '' }, userId: { type: String, default: '' },
}, },
@ -271,6 +364,13 @@ export default {
list: [], list: [],
total: 0, total: 0,
userTypeOptions: [], userTypeOptions: [],
roleList: [],
role_model: {
visible: false,
title: this.$t('system:retrospect:dialogTitle:role'),
width: '800px',
},
} }
}, },
mounted() { mounted() {
@ -278,6 +378,10 @@ export default {
this.getList() this.getList()
}, },
methods: { methods: {
openRoleList(row) {
this.roleList = row.TrialUserRoleList
this.role_model.visible = true
},
getUserTypeList() { getUserTypeList() {
getUserTypeListByUserType(0).then((res) => { getUserTypeListByUserType(0).then((res) => {
if (res.IsSuccess) { if (res.IsSuccess) {

View File

@ -72,7 +72,7 @@
<!-- <el-button type="text" @click="isShow = !isShow">More</el-button> --> <!-- <el-button type="text" @click="isShow = !isShow">More</el-button> -->
<!-- Search --> <!-- Search -->
<el-button type="primary" icon="el-icon-search" @click="handleSearch"> <el-button type="primary" icon="el-icon-search" @click="handleSearch">
{{ $t("common:button:search") }} {{ $t('common:button:search') }}
</el-button> </el-button>
<!-- Reset --> <!-- Reset -->
<el-button <el-button
@ -80,7 +80,7 @@
icon="el-icon-refresh-left" icon="el-icon-refresh-left"
@click="handleReset" @click="handleReset"
> >
{{ $t("common:button:reset") }} {{ $t('common:button:reset') }}
</el-button> </el-button>
<!-- Export --> <!-- Export -->
<el-button <el-button
@ -90,7 +90,7 @@
:loading="exportLoading" :loading="exportLoading"
@click="handleExportTrial" @click="handleExportTrial"
> >
{{ $t("common:button:export") }} {{ $t('common:button:export') }}
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -102,7 +102,7 @@
type="primary" type="primary"
@click="handleNew" @click="handleNew"
> >
{{ $t("common:button:new") }} {{ $t('common:button:new') }}
</el-button> </el-button>
</span> </span>
</template> </template>
@ -293,10 +293,9 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" @click="handleSelectSearch"
type="primary" >Search</el-button
@click="handleSelectSearch" >
>Search</el-button>
<el-button type="primary" @click="handleReset">Reset</el-button> <el-button type="primary" @click="handleReset">Reset</el-button>
<el-button type="primary" @click="isShow = false">Back</el-button> <el-button type="primary" @click="isShow = false">Back</el-button>
</el-form-item> </el-form-item>
@ -358,19 +357,23 @@
<el-tag <el-tag
v-if="scope.row.TrialStatusStr === 'Initializing'" v-if="scope.row.TrialStatusStr === 'Initializing'"
type="info" type="info"
>{{ $fd("TrialStatusEnum", scope.row.TrialStatusStr) }}</el-tag> >{{ $fd('TrialStatusEnum', scope.row.TrialStatusStr) }}</el-tag
>
<el-tag <el-tag
v-if="scope.row.TrialStatusStr === 'Ongoing'" v-if="scope.row.TrialStatusStr === 'Ongoing'"
type="primary" type="primary"
>{{ $fd("TrialStatusEnum", scope.row.TrialStatusStr) }}</el-tag> >{{ $fd('TrialStatusEnum', scope.row.TrialStatusStr) }}</el-tag
>
<el-tag <el-tag
v-if="scope.row.TrialStatusStr === 'Completed'" v-if="scope.row.TrialStatusStr === 'Completed'"
type="warning" type="warning"
>{{ $fd("TrialStatusEnum", scope.row.TrialStatusStr) }}</el-tag> >{{ $fd('TrialStatusEnum', scope.row.TrialStatusStr) }}</el-tag
>
<el-tag <el-tag
v-if="scope.row.TrialStatusStr === 'Stopped'" v-if="scope.row.TrialStatusStr === 'Stopped'"
type="danger" type="danger"
>{{ $fd("TrialStatusEnum", scope.row.TrialStatusStr) }}</el-tag> >{{ $fd('TrialStatusEnum', scope.row.TrialStatusStr) }}</el-tag
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -437,7 +440,7 @@
min-width="160" min-width="160"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.IR_ReadingCriterionList.join(", ") }} {{ scope.row.IR_ReadingCriterionList.join(', ') }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -472,7 +475,7 @@
min-width="170" min-width="170"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.IR_PMEmailList.join(", ") }} {{ scope.row.IR_PMEmailList.join(', ') }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -579,7 +582,14 @@
:disabled=" :disabled="
(scope.row.TrialStatusStr === 'Initializing' && (scope.row.TrialStatusStr === 'Initializing' &&
!hasPermi(['role:pm'])) || !hasPermi(['role:pm'])) ||
scope.row.IsDeleted || ((scope.row.TrialStatusStr === 'Completed' || scope.row.TrialStatusStr === 'Stopped') && !(hasPermi(['role:qa']) || hasPermi(['role:ea']) || hasPermi(['role:pm']))) scope.row.IsDeleted ||
((scope.row.TrialStatusStr === 'Completed' ||
scope.row.TrialStatusStr === 'Stopped') &&
!(
hasPermi(['role:qa']) ||
hasPermi(['role:ea']) ||
hasPermi(['role:pm'])
))
" "
:title="$t('trials:trials-list:action:panel')" :title="$t('trials:trials-list:action:panel')"
@click.stop="handleDetail(scope.row)" @click.stop="handleDetail(scope.row)"
@ -602,6 +612,18 @@
:title="$t('trials:trials-list:action:status')" :title="$t('trials:trials-list:action:status')"
@click.stop="handleStatus(scope.row)" @click.stop="handleStatus(scope.row)"
/> />
<!--项目文档-->
<el-button
v-hasPermi="[
'trials:trials-panel:trial-summary:trial-document:inspect',
'trials:trials-panel:trial-summary:trial-document:manage',
]"
circle
icon="el-icon-folder-opened"
:disabled="scope.row.IsDeleted"
:title="$t('trials:trials-list:action:trialDocument')"
@click.stop="toTrialDocument(scope.row)"
/>
<!-- 废除项目 --> <!-- 废除项目 -->
<el-button <el-button
v-hasPermi="['trials:trials-list:abolish']" v-hasPermi="['trials:trials-list:abolish']"
@ -609,7 +631,7 @@
icon="el-icon-delete" icon="el-icon-delete"
:disabled=" :disabled="
scope.row.IsDeleted || scope.row.IsDeleted ||
scope.row.TrialStatusStr !== 'Initializing' scope.row.TrialStatusStr !== 'Initializing'
" "
:title="$t('trials:trials-list:action:abolition')" :title="$t('trials:trials-list:action:abolition')"
@click.stop="handleAbandon(scope.row)" @click.stop="handleAbandon(scope.row)"
@ -690,7 +712,7 @@
import { import {
abandonTrial, abandonTrial,
ifTrialCanOngoing, ifTrialCanOngoing,
getTrialToBeDoneList getTrialToBeDoneList,
} from '@/api/trials' } from '@/api/trials'
import { getTrialList_Export } from '@/api/export' import { getTrialList_Export } from '@/api/export'
import store from '@/store' import store from '@/store'
@ -721,7 +743,7 @@ const searchDataDefault = () => {
Asc: false, Asc: false,
SortField: '', SortField: '',
CriterionType: null, CriterionType: null,
PM_EMail: null PM_EMail: null,
} }
} }
export default { export default {
@ -731,7 +753,7 @@ export default {
BaseContainer, BaseContainer,
TrialForm, TrialForm,
TrialStatusForm, TrialStatusForm,
DoneList DoneList,
}, },
dicts: ['ReadingStandard', 'ReviewType', 'ReadingType'], dicts: ['ReadingStandard', 'ReviewType', 'ReadingType'],
data() { data() {
@ -756,7 +778,7 @@ export default {
{ value: 'I' }, { value: 'I' },
{ value: 'II' }, { value: 'II' },
{ value: 'III' }, { value: 'III' },
{ value: 'IV' } { value: 'IV' },
], ],
expeditedOption: this.$d.TrialExpeditedState, expeditedOption: this.$d.TrialExpeditedState,
beginPickerOption: { beginPickerOption: {
@ -766,7 +788,7 @@ export default {
} else { } else {
return time.getTime() > Date.now() return time.getTime() > Date.now()
} }
} },
}, },
endpickerOption: { endpickerOption: {
disabledDate: (time) => { disabledDate: (time) => {
@ -778,20 +800,20 @@ export default {
} else { } else {
return time.getTime() > Date.now() return time.getTime() > Date.now()
} }
} },
} },
} }
}, },
computed: { computed: {
...mapGetters(['sponsorList', 'croList']) ...mapGetters(['sponsorList', 'croList']),
}, },
created() { created() {
this.initPage() this.initPage()
}, },
mounted(){ mounted() {
this.$EventBus.$on("reload", (data) => { this.$EventBus.$on('reload', (data) => {
window.location.reload() window.location.reload()
}); })
}, },
methods: { methods: {
initPage() { initPage() {
@ -864,7 +886,7 @@ export default {
this.$confirm(res.ErrorMessage, { this.$confirm(res.ErrorMessage, {
type: 'warning', type: 'warning',
showCancelButton: false, showCancelButton: false,
callback: (action) => {} callback: (action) => {},
}) })
} }
}) })
@ -883,7 +905,7 @@ export default {
handleAbandon(row) { handleAbandon(row) {
this.$confirm(this.$t('trials:trials-list:message:abolition'), { this.$confirm(this.$t('trials:trials-list:message:abolition'), {
type: 'warning', type: 'warning',
distinguishCancelAndClose: true distinguishCancelAndClose: true,
}) })
.then(() => { .then(() => {
this.currentRow = { ...row } this.currentRow = { ...row }
@ -909,19 +931,37 @@ export default {
}) })
}, },
rowClick(row, col) { rowClick(row, col) {
if ((row.TrialStatusStr === 'Initializing' && !this.hasPermi(['role:pm'])) || row.IsDeleted) { if (
(row.TrialStatusStr === 'Initializing' &&
!this.hasPermi(['role:pm'])) ||
row.IsDeleted
) {
return return
} else if ((row.TrialStatusStr === 'Completed' || row.TrialStatusStr === 'Stopped') && !(this.hasPermi(['role:qa']) || this.hasPermi(['role:ea']) || this.hasPermi(['role:pm']))) { } else if (
(row.TrialStatusStr === 'Completed' ||
row.TrialStatusStr === 'Stopped') &&
!(
this.hasPermi(['role:qa']) ||
this.hasPermi(['role:ea']) ||
this.hasPermi(['role:pm'])
)
) {
return return
} }
this.$router.push({ this.$router.push({
path: `/trials/trials-panel?trialId=${row.Id}&trialCode=${row.TrialCode}&researchProgramNo=${row.ResearchProgramNo}` path: `/trials/trials-panel?trialId=${row.Id}&trialCode=${row.TrialCode}&researchProgramNo=${row.ResearchProgramNo}`,
}) })
}, },
// panel // panel
handleDetail(row) { handleDetail(row) {
this.$router.push({ this.$router.push({
path: `/trials/trials-panel?trialId=${row.Id}&trialCode=${row.TrialCode}&researchProgramNo=${row.ResearchProgramNo}` path: `/trials/trials-panel?trialId=${row.Id}&trialCode=${row.TrialCode}&researchProgramNo=${row.ResearchProgramNo}`,
})
},
//
toTrialDocument(row) {
this.$router.push({
path: `/trials/trials-panel/trial-summary/trial-document?trialId=${row.Id}&trialCode=${row.TrialCode}&researchProgramNo=${row.ResearchProgramNo}`,
}) })
}, },
// //
@ -951,7 +991,7 @@ export default {
handleExportTrial() { handleExportTrial() {
this.exportLoading = true this.exportLoading = true
const data = { const data = {
...this.searchData ...this.searchData,
} }
data.TrialIdList = this.selectArr.map((item) => item.Id) data.TrialIdList = this.selectArr.map((item) => item.Id)
return getTrialList_Export(data) return getTrialList_Export(data)
@ -961,7 +1001,7 @@ export default {
.catch(() => { .catch(() => {
this.exportLoading = false this.exportLoading = false
}) })
} },
} },
} }
</script> </script>

View File

@ -9,14 +9,14 @@
<!--style="margin:0"--> <!--style="margin:0"-->
<h4> <h4>
<!-- 提示 --> <!-- 提示 -->
{{ $t("trials:readingPeriod:cd:title:tips") }} {{ $t('trials:readingPeriod:cd:title:tips') }}
</h4> </h4>
<h5> <h5>
<!-- 当前访视/阅片期需要采集临床数据名称请采集临床数据后按照模板上传并签名确认 --> <!-- 当前访视/阅片期需要采集临床数据名称请采集临床数据后按照模板上传并签名确认 -->
{{ tips1 }} {{ tips1 }}
</h5> </h5>
<h5> <h5>
{{ $t("trials:readingPeriod:cd:title:tips2") }} {{ $t('trials:readingPeriod:cd:title:tips2') }}
</h5> </h5>
</div> </div>
<div class="top"> <div class="top">
@ -28,7 +28,7 @@
:disabled="list.length === 0" :disabled="list.length === 0"
@click="handlePreview()" @click="handlePreview()"
> >
{{ $t("trials:readingPeriod:cd:title:preview") }} {{ $t('trials:readingPeriod:cd:title:preview') }}
</el-button> </el-button>
<!-- 添加 --> <!-- 添加 -->
<el-button <el-button
@ -43,24 +43,22 @@
size="small" size="small"
@click="handleAdd" @click="handleAdd"
> >
{{ $t("common:button:add") }} {{ $t('common:button:add') }}
</el-button> </el-button>
<!--下载模板-->
<el-button <el-button
v-if=" v-if="
otherInfo.IsCanAddClinicalData &&
hasPermi(['trials:trials-panel:subject:readingPeriod:edit']) && hasPermi(['trials:trials-panel:subject:readingPeriod:edit']) &&
clinicalType === '2' && clinicalType === '1' &&
list.length > 0 &&
list[0].ReadingClinicalDataState !== 3 &&
!list[0].IsCRCApplicationRevoke &&
type !== 'consistencyAnalysis' type !== 'consistencyAnalysis'
" "
type="primary" type="primary"
icon="el-icon-plus" icon="el-icon-download"
size="small" size="small"
:disabled="list.length === 0" @click="downLoadTemplate"
@click="handleVerification(list[0], 'confirm')"
> >
{{ $t("trials:readingPeriod:cd:title:cdCheck") }} {{ $t('trials:readingPeriod:cd:title:downLoadTemplate') }}
</el-button> </el-button>
<el-button <el-button
v-if=" v-if="
@ -102,7 +100,7 @@
min-width="100" min-width="100"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalDataUploadRole", scope.row.UploadRole) }} {{ $fd('ClinicalDataUploadRole', scope.row.UploadRole) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 数据级别 --> <!-- 数据级别 -->
@ -112,7 +110,7 @@
min-width="100" min-width="100"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalLevel", scope.row.ClinicalDataLevel) }} {{ $fd('ClinicalLevel', scope.row.ClinicalDataLevel) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 传输方式 --> <!-- 传输方式 -->
@ -122,7 +120,7 @@
min-width="120" min-width="120"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalUploadType", scope.row.ClinicalUploadType) }} {{ $fd('ClinicalUploadType', scope.row.ClinicalUploadType) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 文件数量 --> <!-- 文件数量 -->
@ -133,7 +131,7 @@
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.ClinicalUploadType === 0 ? "NA" : scope.row.FileCount scope.row.ClinicalUploadType === 0 ? 'NA' : scope.row.FileCount
}} }}
</template> </template>
</el-table-column> </el-table-column>
@ -149,7 +147,7 @@
type="info" type="info"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -159,7 +157,7 @@
type="danger" type="danger"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -169,7 +167,7 @@
type="primary" type="primary"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -179,7 +177,7 @@
type="warning" type="warning"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -296,10 +294,10 @@
> >
<div slot="title"> <div slot="title">
<span style="font-size: 18px">{{ <span style="font-size: 18px">{{
$t("common:dialogTitle:sign") $t('common:dialogTitle:sign')
}}</span> }}</span>
<span style="font-size: 12px; margin-left: 5px">{{ <span style="font-size: 12px; margin-left: 5px">{{
`(${$t("common:label:sign")}${currentUser})` `(${$t('common:label:sign')}${currentUser})`
}}</span> }}</span>
</div> </div>
<SignForm <SignForm
@ -325,7 +323,7 @@
:disabled="list.length === 0" :disabled="list.length === 0"
@click="handlePreview()" @click="handlePreview()"
> >
{{ $t("trials:readingPeriod:cd:title:preview") }} {{ $t('trials:readingPeriod:cd:title:preview') }}
</el-button> </el-button>
<!-- 添加 --> <!-- 添加 -->
<el-button <el-button
@ -338,7 +336,7 @@
size="small" size="small"
@click="handleAdd" @click="handleAdd"
> >
{{ $t("common:button:add") }} {{ $t('common:button:add') }}
</el-button> </el-button>
</div> </div>
<div class="main"> <div class="main">
@ -361,7 +359,7 @@
show-overflow-tooltip show-overflow-tooltip
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalDataUploadRole", scope.row.UploadRole) }} {{ $fd('ClinicalDataUploadRole', scope.row.UploadRole) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 数据级别 --> <!-- 数据级别 -->
@ -370,7 +368,7 @@
:label="$t('trials:readingPeriod:cd:table:dataLevel')" :label="$t('trials:readingPeriod:cd:table:dataLevel')"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalLevel", scope.row.ClinicalDataLevel) }} {{ $fd('ClinicalLevel', scope.row.ClinicalDataLevel) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 传输方式 --> <!-- 传输方式 -->
@ -379,7 +377,7 @@
:label="$t('trials:readingPeriod:cd:table:transferType')" :label="$t('trials:readingPeriod:cd:table:transferType')"
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ $fd("ClinicalUploadType", scope.row.ClinicalUploadType) }} {{ $fd('ClinicalUploadType', scope.row.ClinicalUploadType) }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 文件数量 --> <!-- 文件数量 -->
@ -389,7 +387,7 @@
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ {{
scope.row.ClinicalUploadType === 0 ? "NA" : scope.row.FileCount scope.row.ClinicalUploadType === 0 ? 'NA' : scope.row.FileCount
}} }}
</template> </template>
</el-table-column> </el-table-column>
@ -405,7 +403,7 @@
type="info" type="info"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -415,7 +413,7 @@
type="danger" type="danger"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -425,7 +423,7 @@
type="primary" type="primary"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -435,7 +433,7 @@
type="warning" type="warning"
>{{ >{{
$fd( $fd(
"ReadingClinicalDataState", 'ReadingClinicalDataState',
scope.row.ReadingClinicalDataState scope.row.ReadingClinicalDataState
) )
}}</el-tag }}</el-tag
@ -550,10 +548,10 @@
> >
<div slot="title"> <div slot="title">
<span style="font-size: 18px">{{ <span style="font-size: 18px">{{
$t("common:dialogTitle:sign") $t('common:dialogTitle:sign')
}}</span> }}</span>
<span style="font-size: 12px; margin-left: 5px">{{ <span style="font-size: 12px; margin-left: 5px">{{
`(${$t("common:label:sign")}${currentUser})` `(${$t('common:label:sign')}${currentUser})`
}}</span> }}</span>
</div> </div>
<SignForm <SignForm
@ -574,35 +572,36 @@ import {
getTrialClinicalDataSelect, getTrialClinicalDataSelect,
getConsistencyAnalysisReadingClinicalDataList, getConsistencyAnalysisReadingClinicalDataList,
signConsistencyAnalysisReadingClinicalData, signConsistencyAnalysisReadingClinicalData,
} from "@/api/trials"; } from '@/api/trials'
import AddOrEditCD from "./AddOrEditCD"; import AddOrEditCD from './AddOrEditCD'
import Verification from "./Verification"; import Verification from './Verification'
import SignForm from "@/views/trials/components/newSignForm"; import SignForm from '@/views/trials/components/newSignForm'
import const_ from "@/const/sign-code"; import const_ from '@/const/sign-code'
import { getToken } from "@/utils/auth"; import { getToken } from '@/utils/auth'
import { downLoadFile } from '@/utils/stream.js'
export default { export default {
name: "ClinicalData", name: 'ClinicalData',
components: { AddOrEditCD, SignForm, Verification }, components: { AddOrEditCD, SignForm, Verification },
props: { props: {
trialReadingCriterionId: { trialReadingCriterionId: {
type: String, type: String,
default() { default() {
return ""; return ''
}, },
}, },
data: { data: {
type: Object, type: Object,
default() { default() {
return {}; return {}
}, },
}, },
type: { type: {
default: "readingPeriod", default: 'readingPeriod',
}, },
}, },
watch: { watch: {
clinicalType() { clinicalType() {
this.getList(); this.getList()
}, },
}, },
data() { data() {
@ -613,36 +612,63 @@ export default {
list: [], list: [],
total: 0, total: 0,
dialogVisible: false, dialogVisible: false,
addOrUpdateCD: { title: "", visible: false }, addOrUpdateCD: { title: '', visible: false },
verification: { title: "", visible: false }, verification: { title: '', visible: false },
currentData: {}, currentData: {},
currentOption: [], currentOption: [],
signCode: "", signCode: '',
currentUser: zzSessionStorage.getItem("userName"), currentUser: zzSessionStorage.getItem('userName'),
signVisible: false, signVisible: false,
otherInfo: {}, otherInfo: {},
spanArr: [], spanArr: [],
pos: 0, pos: 0,
tips1: null, tips1: null,
}; clinicalDatas: [],
}
}, },
mounted() { mounted() {
if (!(this.data.IsVisit || this.data.IsBaseLine)) { if (!(this.data.IsVisit || this.data.IsBaseLine)) {
// this.clinicalType = this.$d.GetClinicalType[0].value.toString(); // this.clinicalType = this.$d.GetClinicalType[0].value.toString();
this.clinicalType = '1'; this.clinicalType = '1'
} else { } else {
this.getList(true); this.getList(true)
} }
window.addEventListener("message", (res) => { window.addEventListener('message', (res) => {
if (res.data.type === "pmConfirmClinical") { if (res.data.type === 'pmConfirmClinical') {
this.getList(); this.getList()
} }
}); })
}, },
methods: { methods: {
//
async downLoadTemplate() {
try {
let { files, name } = this.formatDownloadFile()
let res = await downLoadFile(files, name, 'zip')
} catch (err) {
console.log(err)
}
},
//
formatDownloadFile() {
let files = [],
name = `${this.$route.query.trialId}_${
this.data.CriterionName
}_template_${new Date().getTime()}.zip`
this.clinicalDatas.forEach((item) => {
if (item.Path) {
let obj = {
name: item.FileName,
url: this.OSSclientConfig.basePath + item.Path,
}
files.push(obj)
}
})
return { files, name }
},
getClinicalDatas() { getClinicalDatas() {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
let message = ""; let message = ''
let currentData = Object.assign( let currentData = Object.assign(
{}, {},
{ {
@ -652,113 +678,114 @@ export default {
SubjectId: this.data.SubjectId, SubjectId: this.data.SubjectId,
IsBaseLine: this.data.IsBaseLine, IsBaseLine: this.data.IsBaseLine,
} }
); )
var param = { var param = {
trialId: currentData.TrialId, trialId: currentData.TrialId,
IsVisit: currentData.IsVisit, IsVisit: currentData.IsVisit,
ReadingId: currentData.ReadingId, ReadingId: currentData.ReadingId,
SubjectId: currentData.SubjectId, SubjectId: currentData.SubjectId,
ReadingClinicalDataId: currentData.Id ? currentData.Id : "", ReadingClinicalDataId: currentData.Id ? currentData.Id : '',
IsBaseLine: currentData.IsBaseLine, IsBaseLine: currentData.IsBaseLine,
TrialReadingCriterionId: this.trialReadingCriterionId, TrialReadingCriterionId: this.trialReadingCriterionId,
}; }
getTrialClinicalDataSelect(param) getTrialClinicalDataSelect(param)
.then((res) => { .then((res) => {
this.clinicalDatas = res.Result
res.Result.forEach((item, index) => { res.Result.forEach((item, index) => {
if (index < 1) { if (index < 1) {
message += item.ClinicalDataSetName; message += item.ClinicalDataSetName
} else { } else {
message = message + "、" + item.ClinicalDataSetName; message = message + '、' + item.ClinicalDataSetName
} }
}); })
resolve(message); resolve(message)
}) })
.catch(() => { .catch(() => {
reject(); reject()
}); })
}); })
}, },
objectSpanMethod({ row, column, rowIndex, columnIndex }) { objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 6 && row.IsNeedMerge) { if (columnIndex === 6 && row.IsNeedMerge) {
const _row = this.spanArr[rowIndex]; const _row = this.spanArr[rowIndex]
const _col = _row > 0 ? 1 : 0; const _col = _row > 0 ? 1 : 0
return { return {
rowspan: _row, rowspan: _row,
colspan: _col, colspan: _col,
}; }
} }
}, },
getSpanArr(data) { getSpanArr(data) {
for (var i = 0; i < data.length; i++) { for (var i = 0; i < data.length; i++) {
if (i === 0) { if (i === 0) {
this.spanArr.push(1); this.spanArr.push(1)
this.pos = 0; this.pos = 0
} else { } else {
// //
if (data[i].IsNeedMerge === data[i - 1].IsNeedMerge) { if (data[i].IsNeedMerge === data[i - 1].IsNeedMerge) {
this.spanArr[this.pos] += 1; this.spanArr[this.pos] += 1
this.spanArr.push(0); this.spanArr.push(0)
} else { } else {
this.spanArr.push(1); this.spanArr.push(1)
this.pos = i; this.pos = i
} }
} }
} }
}, },
getList(is) { getList(is) {
this.loading = true; this.loading = true
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
let data = { let data = {
SubjectId: this.data.SubjectId, SubjectId: this.data.SubjectId,
VisitTaskId: this.data.Id, VisitTaskId: this.data.Id,
TrialId: this.$route.query.trialId, TrialId: this.$route.query.trialId,
}; }
return getConsistencyAnalysisReadingClinicalDataList(data) return getConsistencyAnalysisReadingClinicalDataList(data)
.then((res) => { .then((res) => {
this.list = res.Result; this.list = res.Result
this.otherInfo = res.OtherInfo; this.otherInfo = res.OtherInfo
this.loading = false; this.loading = false
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
} }
this.searchData.ReadingId = this.data.Id; this.searchData.ReadingId = this.data.Id
this.searchData.SubjectId = this.data.SubjectId; this.searchData.SubjectId = this.data.SubjectId
this.searchData.IsVisit = this.data.IsVisit; this.searchData.IsVisit = this.data.IsVisit
this.searchData.TrialId = this.data.TrialId; this.searchData.TrialId = this.data.TrialId
this.searchData.IsBaseLine = this.data.IsBaseLine; this.searchData.IsBaseLine = this.data.IsBaseLine
this.searchData.TrialReadingCriterionId = this.trialReadingCriterionId; this.searchData.TrialReadingCriterionId = this.trialReadingCriterionId
if (!is) { if (!is) {
this.searchData.GetClinicalType = this.clinicalType; this.searchData.GetClinicalType = this.clinicalType
} }
getReadingClinicalDataList(this.searchData) getReadingClinicalDataList(this.searchData)
.then(async (res) => { .then(async (res) => {
this.list = res.Result; this.list = res.Result
let message = ""; let message = ''
this.list.forEach((item, index) => { this.list.forEach((item, index) => {
if (index < 1) { if (index < 1) {
message += item.ClinicalDataSetName; message += item.ClinicalDataSetName
} else { } else {
message = message + "、" + item.ClinicalDataSetName; message = message + '、' + item.ClinicalDataSetName
} }
}); })
if (message === "" || !message) { if (message === '' || !message) {
message = await this.getClinicalDatas(); message = await this.getClinicalDatas()
} }
this.tips1 = this.$t("trials:readingPeriod:cd:title:tips1").replace( this.tips1 = this.$t('trials:readingPeriod:cd:title:tips1').replace(
"临床数据名称", '临床数据名称',
message message
); )
this.tips1 = this.tips1.replace("xxx", message); this.tips1 = this.tips1.replace('xxx', message)
this.pos = 0; this.pos = 0
this.getSpanArr(this.list); this.getSpanArr(this.list)
this.otherInfo = res.OtherInfo; this.otherInfo = res.OtherInfo
this.loading = false; this.loading = false
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}, },
handleAdd() { handleAdd() {
this.currentData = Object.assign( this.currentData = Object.assign(
@ -770,136 +797,136 @@ export default {
SubjectId: this.data.SubjectId, SubjectId: this.data.SubjectId,
IsBaseLine: this.data.IsBaseLine, IsBaseLine: this.data.IsBaseLine,
} }
); )
this.addOrUpdateCD.title = this.$t("common:button:new"); this.addOrUpdateCD.title = this.$t('common:button:new')
this.addOrUpdateCD.visible = true; this.addOrUpdateCD.visible = true
}, },
handleEdit(row) { handleEdit(row) {
this.currentData = { ...row }; this.currentData = { ...row }
this.currentData.TrialId = this.data.TrialId; this.currentData.TrialId = this.data.TrialId
this.currentData.SubjectId = this.data.SubjectId; this.currentData.SubjectId = this.data.SubjectId
if (this.type === "readingPeriod") { if (this.type === 'readingPeriod') {
this.currentData.ReadingId = this.data.Id; this.currentData.ReadingId = this.data.Id
} }
this.currentData.IsVisit = this.data.IsVisit; this.currentData.IsVisit = this.data.IsVisit
this.currentData.IsBaseLine = this.data.IsBaseLine; this.currentData.IsBaseLine = this.data.IsBaseLine
this.addOrUpdateCD.title = this.$t("common:button:edit"); this.addOrUpdateCD.title = this.$t('common:button:edit')
this.currentOption = [ this.currentOption = [
{ {
ClinicalDataSetName: ClinicalDataSetName:
this.$i18n.locale === "zh" this.$i18n.locale === 'zh'
? row.ClinicalDataSetName ? row.ClinicalDataSetName
: row.ClinicalDataSetEnName, : row.ClinicalDataSetEnName,
Id: row.ClinicalDataTrialSetId, Id: row.ClinicalDataTrialSetId,
}, },
]; ]
this.addOrUpdateCD.visible = true; this.addOrUpdateCD.visible = true
}, },
handleVerification(row, type) { handleVerification(row, type) {
if (type === "unconfirm") { if (type === 'unconfirm') {
var token = getToken(); var token = getToken()
let routeData = this.$router.resolve({ let routeData = this.$router.resolve({
path: `/clinicalData?type=unconfirm&ClinicalDataTrialSetId=${ path: `/clinicalData?type=unconfirm&ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&readingId=${this.data.Id}&readingClinicalDataId=${ }&readingId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&readModuleId=${row.ReadModuleId}&getClinicalType=${ }&readModuleId=${row.ReadModuleId}&getClinicalType=${
this.clinicalType this.clinicalType
}&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}`, }&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}`,
}); })
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?type=unconfirm&ClinicalDataTrialSetId=${ path: `/clinicalData?type=unconfirm&ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&visitTaskId=${this.data.Id}&readingClinicalDataId=${ }&visitTaskId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&readModuleId=${row.ReadModuleId}&getClinicalType=${ }&readModuleId=${row.ReadModuleId}&getClinicalType=${
this.clinicalType this.clinicalType
}&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`, }&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`,
}); })
} }
window.open(routeData.href, "_blank"); window.open(routeData.href, '_blank')
return; return
} }
if (row.IsNeedMerge) { if (row.IsNeedMerge) {
var token = getToken(); var token = getToken()
let routeData = this.$router.resolve({ let routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&readingId=${this.data.Id}&readingClinicalDataId=${ }&readingId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&readModuleId=${row.ReadModuleId}&getClinicalType=${ }&readModuleId=${row.ReadModuleId}&getClinicalType=${
this.clinicalType this.clinicalType
}&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}`, }&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}`,
}); })
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&visitTaskId=${this.data.Id}&readingClinicalDataId=${ }&visitTaskId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&readModuleId=${row.ReadModuleId}&getClinicalType=${ }&readModuleId=${row.ReadModuleId}&getClinicalType=${
this.clinicalType this.clinicalType
}&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`, }&isConfirm=1&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`,
}); })
} }
window.open(routeData.href, "_blank"); window.open(routeData.href, '_blank')
} else { } else {
this.currentData = { ...row }; this.currentData = { ...row }
this.currentData.TrialId = this.data.TrialId; this.currentData.TrialId = this.data.TrialId
this.currentData.SubjectId = this.data.SubjectId; this.currentData.SubjectId = this.data.SubjectId
if (this.type === "readingPeriod") { if (this.type === 'readingPeriod') {
this.currentData.ReadingId = this.data.Id; this.currentData.ReadingId = this.data.Id
} }
this.currentData.IsVisit = this.data.IsVisit; this.currentData.IsVisit = this.data.IsVisit
this.currentData.IsBaseLine = this.data.IsBaseLine; this.currentData.IsBaseLine = this.data.IsBaseLine
this.verification.title = this.$t( this.verification.title = this.$t(
"trials:readingPeriod:cd:title:cdCheck" 'trials:readingPeriod:cd:title:cdCheck'
); // '' ) // ''
this.verification.visible = true; this.verification.visible = true
} }
}, },
handleDelete(row) { handleDelete(row) {
this.$confirm(this.$t("trials:readingPeriod:cd:message:delete"), { this.$confirm(this.$t('trials:readingPeriod:cd:message:delete'), {
type: "warning", type: 'warning',
distinguishCancelAndClose: true, distinguishCancelAndClose: true,
}) })
.then(() => { .then(() => {
this.loading = true; this.loading = true
deleteReadingClinicalData(row.Id) deleteReadingClinicalData(row.Id)
.then((res) => { .then((res) => {
this.loading = false; this.loading = false
if (res.IsSuccess) { if (res.IsSuccess) {
this.getList(); this.getList()
this.$message.success( this.$message.success(
this.$t("common:message:deletedSuccessfully") this.$t('common:message:deletedSuccessfully')
); )
} }
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}) })
.catch(() => {}); .catch(() => {})
}, },
handleSign(from) { handleSign(from) {
// this.currentData = { ...row } // this.currentData = { ...row }
this.currentData.IsBlind = from.IsBlind; this.currentData.IsBlind = from.IsBlind
this.currentData.IsComplete = from.IsComplete; this.currentData.IsComplete = from.IsComplete
const { CDQualityConfirmation } = const_.processSignature; const { CDQualityConfirmation } = const_.processSignature
this.signCode = CDQualityConfirmation; this.signCode = CDQualityConfirmation
this.signVisible = true; this.signVisible = true
}, },
signConfirm(signInfo) { signConfirm(signInfo) {
this.loading = true; this.loading = true
let params = { let params = {
data: { data: {
readingClinicalDataId: this.currentData.Id, readingClinicalDataId: this.currentData.Id,
@ -908,8 +935,8 @@ export default {
TrialReadingCriterionId: this.trialReadingCriterionId, TrialReadingCriterionId: this.trialReadingCriterionId,
}, },
signInfo: signInfo, signInfo: signInfo,
}; }
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
params = { params = {
data: { data: {
consistentClinicalDataId: this.currentData.Id, consistentClinicalDataId: this.currentData.Id,
@ -917,94 +944,90 @@ export default {
IsComplete: this.currentData.IsComplete, IsComplete: this.currentData.IsComplete,
}, },
signInfo: signInfo, signInfo: signInfo,
}; }
signConsistencyAnalysisReadingClinicalData(params) signConsistencyAnalysisReadingClinicalData(params)
.then((res) => { .then((res) => {
this.loading = false; this.loading = false
if (res.IsSuccess) { if (res.IsSuccess) {
this.$message.success( this.$message.success(this.$t('common:message:savedSuccessfully'))
this.$t("common:message:savedSuccessfully") this.$refs['signForm'].btnLoading = false
);
this.$refs["signForm"].btnLoading = false;
this.signVisible = false; this.signVisible = false
this.getList(); this.getList()
this.$emit("getList"); this.$emit('getList')
this.$nextTick(() => { this.$nextTick(() => {
this.verification.visible = false; this.verification.visible = false
}); })
} }
}) })
.catch((_) => { .catch((_) => {
this.loading = false; this.loading = false
this.$refs["signForm"].btnLoading = false; this.$refs['signForm'].btnLoading = false
}); })
} else { } else {
ReadClinicalDataSign(params) ReadClinicalDataSign(params)
.then((res) => { .then((res) => {
this.loading = false; this.loading = false
if (res.IsSuccess) { if (res.IsSuccess) {
this.$message.success( this.$message.success(this.$t('common:message:savedSuccessfully'))
this.$t("common:message:savedSuccessfully") this.$refs['signForm'].btnLoading = false
);
this.$refs["signForm"].btnLoading = false;
this.signVisible = false; this.signVisible = false
this.getList(); this.getList()
this.$emit("getList"); this.$emit('getList')
this.$nextTick(() => { this.$nextTick(() => {
this.verification.visible = false; this.verification.visible = false
}); })
} }
}) })
.catch((_) => { .catch((_) => {
this.loading = false; this.loading = false
this.$refs["signForm"].btnLoading = false; this.$refs['signForm'].btnLoading = false
}); })
} }
}, },
// //
closeSignDialog(isSign, signInfo) { closeSignDialog(isSign, signInfo) {
if (isSign) { if (isSign) {
this.signConfirm(signInfo); this.signConfirm(signInfo)
} else { } else {
this.signVisible = false; this.signVisible = false
this.loading = false; this.loading = false
} }
}, },
handlePreview(readingClinicalDataId, row) { handlePreview(readingClinicalDataId, row) {
if (row && row.IsNeedMerge) { if (row && row.IsNeedMerge) {
var token = getToken(); var token = getToken()
let routeData = this.$router.resolve({ let routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&readingId=${this.data.Id}&readingClinicalDataId=${ }&readingId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&getClinicalType=${this.clinicalType}&readModuleId=${ }&getClinicalType=${this.clinicalType}&readModuleId=${
row.ReadModuleId row.ReadModuleId
}&IsOnlyGetCRCReadModule=1&TokenKey=${token}`, }&IsOnlyGetCRCReadModule=1&TokenKey=${token}`,
}); })
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&visitTaskId=${this.data.Id}&readingClinicalDataId=${ }&visitTaskId=${this.data.Id}&readingClinicalDataId=${
row.readingClinicalDataId || "" row.readingClinicalDataId || ''
}&getClinicalType=${this.clinicalType}&readModuleId=${ }&getClinicalType=${this.clinicalType}&readModuleId=${
row.ReadModuleId row.ReadModuleId
}&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`, }&IsOnlyGetCRCReadModule=1&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`,
}); })
} }
window.open(routeData.href, "_blank"); window.open(routeData.href, '_blank')
} else { } else {
var token = getToken(); var token = getToken()
var routeData; var routeData
if (row) { if (row) {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
@ -1012,47 +1035,47 @@ export default {
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&readingId=${this.data.Id}&readingClinicalDataId=${ }&readingId=${this.data.Id}&readingClinicalDataId=${
readingClinicalDataId || "" readingClinicalDataId || ''
}&getClinicalType=${this.clinicalType}&TokenKey=${token}`, }&getClinicalType=${this.clinicalType}&TokenKey=${token}`,
}); })
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?ClinicalDataTrialSetId=${ path: `/clinicalData?ClinicalDataTrialSetId=${
row.ClinicalDataTrialSetId row.ClinicalDataTrialSetId
}&subjectId=${this.data.SubjectId}&trialId=${ }&subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&visitTaskId=${this.data.Id}&readingClinicalDataId=${ }&visitTaskId=${this.data.Id}&readingClinicalDataId=${
readingClinicalDataId || "" readingClinicalDataId || ''
}&getClinicalType=${ }&getClinicalType=${
this.clinicalType this.clinicalType
}&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`, }&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`,
}); })
} }
} else { } else {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?subjectId=${this.data.SubjectId}&trialId=${ path: `/clinicalData?subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&readingId=${this.data.Id}&readingClinicalDataId=${ }&readingId=${this.data.Id}&readingClinicalDataId=${
readingClinicalDataId || "" readingClinicalDataId || ''
}&getClinicalType=${this.clinicalType}&TokenKey=${token}`, }&getClinicalType=${this.clinicalType}&TokenKey=${token}`,
}); })
if (this.type === "consistencyAnalysis") { if (this.type === 'consistencyAnalysis') {
routeData = this.$router.resolve({ routeData = this.$router.resolve({
path: `/clinicalData?subjectId=${this.data.SubjectId}&trialId=${ path: `/clinicalData?subjectId=${this.data.SubjectId}&trialId=${
this.data.TrialId this.data.TrialId
}&visitTaskId=${this.data.Id}&readingClinicalDataId=${ }&visitTaskId=${this.data.Id}&readingClinicalDataId=${
readingClinicalDataId || "" readingClinicalDataId || ''
}&getClinicalType=${ }&getClinicalType=${
this.clinicalType this.clinicalType
}&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`, }&TokenKey=${token}&&isGetAllConsistencyAnalysis=${0}`,
}); })
} }
} }
window.open(routeData.href, "_blank"); window.open(routeData.href, '_blank')
} }
}, },
}, },
}; }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.clinical-data_content { .clinical-data_content {

View File

@ -3,7 +3,7 @@
<div class="title"> <div class="title">
{{ TITLE }} {{ TITLE }}
</div> </div>
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form topForm">
<el-form-item <el-form-item
:label="$t('trials:trialDocument:fileRecord:form:isConfirmRecord')" :label="$t('trials:trialDocument:fileRecord:form:isConfirmRecord')"
v-if="isManage && hasEdit && !viewStatus" v-if="isManage && hasEdit && !viewStatus"
@ -39,7 +39,6 @@
<el-form-item v-if="isManage && hasEdit && !viewStatus"> <el-form-item v-if="isManage && hasEdit && !viewStatus">
<el-button <el-button
type="primary" type="primary"
size="mini"
@click="rowBtnStatus = 'save'" @click="rowBtnStatus = 'save'"
v-if="rowBtnStatus === 'edit'" v-if="rowBtnStatus === 'edit'"
> >
@ -47,7 +46,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
:loading="rowBtnLoading" :loading="rowBtnLoading"
@click="saveRowData" @click="saveRowData"
v-if="rowBtnStatus === 'save'" v-if="rowBtnStatus === 'save'"
@ -56,9 +54,10 @@
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="line"></div>
<!-- 搜索框 --> <!-- 搜索框 -->
<div class="search" style="position: relative"> <div class="search" style="position: relative">
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form">
<el-form-item <el-form-item
:label="$t('trials:trialDocument:fileRecord:search:name')" :label="$t('trials:trialDocument:fileRecord:search:name')"
> >
@ -104,7 +103,6 @@
<el-button <el-button
type="primary" type="primary"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
size="mini"
v-if="hasAccredit && isManage && !viewStatus" v-if="hasAccredit && isManage && !viewStatus"
@click.stop="auth" @click.stop="auth"
> >
@ -112,7 +110,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(false)" @click.stop="openFile(false)"
> >
@ -120,7 +117,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(true)" @click.stop="openFile(true)"
> >
@ -129,7 +125,6 @@
<el-button <el-button
type="primary" type="primary"
icon="el-icon-bottom" icon="el-icon-bottom"
size="mini"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
@click.stop="downLoad" @click.stop="downLoad"
@ -138,7 +133,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
@click.stop="delList" @click.stop="delList"
@ -314,7 +308,6 @@
<el-button <el-button
icon="el-icon-view" icon="el-icon-view"
:title="$t('common:button:view')" :title="$t('common:button:view')"
size="mini"
circle circle
:disabled=" :disabled="
!scope.row.TrialFileRecord || !scope.row.TrialFileRecord.FilePath !scope.row.TrialFileRecord || !scope.row.TrialFileRecord.FilePath
@ -325,7 +318,6 @@
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
icon="el-icon-download" icon="el-icon-download"
:title="$t('trials:trialDocument:fileRecord:button:download')" :title="$t('trials:trialDocument:fileRecord:button:download')"
size="mini"
circle circle
@click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')" @click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')"
/> />
@ -333,7 +325,6 @@
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
icon="el-icon-delete" icon="el-icon-delete"
:title="$t('trials:trialDocument:fileRecord:button:delete')" :title="$t('trials:trialDocument:fileRecord:button:delete')"
size="mini"
circle circle
@click.stop="handleDel(scope.row)" @click.stop="handleDel(scope.row)"
/> />

View File

@ -12,7 +12,7 @@
></i> ></i>
</div> </div>
<div <div
:class="{ menu: true, selected: Id === data.Id }" :class="{ menu: true, selected: menuId === data.Id }"
v-for="data in item.TrialFileTypeList" v-for="data in item.TrialFileTypeList"
:key="data.SysFileTypeId" :key="data.SysFileTypeId"
@click.stop="handleSelect(data, item.ArchiveTypeEnum)" @click.stop="handleSelect(data, item.ArchiveTypeEnum)"
@ -126,7 +126,7 @@ export default {
type: Boolean, type: Boolean,
default: true, default: true,
}, },
Id: { menuId: {
type: String, type: String,
default: '', default: '',
}, },
@ -218,12 +218,49 @@ export default {
this.loading = false this.loading = false
if (res.IsSuccess) { if (res.IsSuccess) {
this.menu = res.Result.TrialFileTypeDataList this.menu = res.Result.TrialFileTypeDataList
this.$nextTick(() => {
this.defaultSelect()
})
} }
} catch (err) { } catch (err) {
this.loading = false this.loading = false
console.log(err) console.log(err)
} }
}, },
defaultSelect() {
if (!this.menu || this.menu.length <= 0) return false
if (this.menuId) {
let Id = this.menuId
let f = this.menu.some((item) => {
let flag = false
if (item.TrialFileTypeList && item.TrialFileTypeList.length > 0) {
flag = item.TrialFileTypeList.some((data) => {
if (data.Id === Id) {
this.$emit('update:menuId', null)
this.$nextTick(() => {
this.handleSelect(data, item.ArchiveTypeEnum)
})
}
return data.Id === Id
})
}
return flag
})
if (!f) {
this.$emit('update:menuId', null)
this.$nextTick(() => {
this.defaultSelect()
})
}
} else {
this.menu.some((item) => {
if (item.TrialFileTypeList && item.TrialFileTypeList.length > 0) {
this.handleSelect(item.TrialFileTypeList[0], item.ArchiveTypeEnum)
}
return item.TrialFileTypeList && item.TrialFileTypeList.length > 0
})
}
},
// //
async changeIsEnble(val, item) { async changeIsEnble(val, item) {
try { try {
@ -242,7 +279,7 @@ export default {
}, },
// //
handleSelect(data, ArchiveTypeEnum) { handleSelect(data, ArchiveTypeEnum) {
this.$emit('update:Id', data.Id) this.$emit('update:menuId', data.Id)
this.$emit('update:SubIdentificationEnum', data.SubIdentificationEnum) this.$emit('update:SubIdentificationEnum', data.SubIdentificationEnum)
this.$emit('update:ArchiveTypeEnum', ArchiveTypeEnum) this.$emit('update:ArchiveTypeEnum', ArchiveTypeEnum)
this.$emit('update:rowData', data) this.$emit('update:rowData', data)

View File

@ -3,7 +3,7 @@
<div class="title"> <div class="title">
{{ TITLE }} {{ TITLE }}
</div> </div>
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form topForm">
<el-form-item <el-form-item
:label="$t('trials:trialDocument:reportDoc:form:firstFinalDate')" :label="$t('trials:trialDocument:reportDoc:form:firstFinalDate')"
> >
@ -52,7 +52,6 @@
<el-form-item v-if="isManage && hasEdit && !viewStatus"> <el-form-item v-if="isManage && hasEdit && !viewStatus">
<el-button <el-button
type="primary" type="primary"
size="mini"
@click="rowBtnStatus = 'save'" @click="rowBtnStatus = 'save'"
v-if="rowBtnStatus === 'edit'" v-if="rowBtnStatus === 'edit'"
> >
@ -60,7 +59,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
:loading="rowBtnLoading" :loading="rowBtnLoading"
@click="saveRowData" @click="saveRowData"
v-if="rowBtnStatus === 'save'" v-if="rowBtnStatus === 'save'"
@ -69,9 +67,10 @@
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="line"></div>
<!-- 搜索框 --> <!-- 搜索框 -->
<div class="search" style="position: relative"> <div class="search" style="position: relative">
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form">
<el-form-item :label="$t('trials:trialDocument:reportDoc:search:name')"> <el-form-item :label="$t('trials:trialDocument:reportDoc:search:name')">
<el-input v-model="searchData.Name" style="width: 100px" clearable /> <el-input v-model="searchData.Name" style="width: 100px" clearable />
</el-form-item> </el-form-item>
@ -120,7 +119,6 @@
<el-button <el-button
type="primary" type="primary"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
size="mini"
v-if="hasAccredit && isManage && !viewStatus" v-if="hasAccredit && isManage && !viewStatus"
@click.stop="auth" @click.stop="auth"
> >
@ -128,7 +126,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasAdd && isManage && !viewStatus" v-if="hasAdd && isManage && !viewStatus"
@click.stop="handleAdd" @click.stop="handleAdd"
> >
@ -137,7 +134,6 @@
<el-button <el-button
type="primary" type="primary"
icon="el-icon-bottom" icon="el-icon-bottom"
size="mini"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
@click.stop="downLoad" @click.stop="downLoad"
@ -349,6 +345,7 @@
:label="$t('trials:trialDocument:reportDoc:table:isAuthorizedView')" :label="$t('trials:trialDocument:reportDoc:table:isAuthorizedView')"
show-overflow-tooltip show-overflow-tooltip
sortable="custom" sortable="custom"
v-if="isManage && !viewStatus"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
@ -381,7 +378,6 @@
<el-button <el-button
icon="el-icon-view" icon="el-icon-view"
:title="$t('common:button:view')" :title="$t('common:button:view')"
size="mini"
circle circle
:disabled=" :disabled="
!scope.row.PDFFileRecord || !scope.row.PDFFileRecord.FilePath !scope.row.PDFFileRecord || !scope.row.PDFFileRecord.FilePath
@ -392,7 +388,6 @@
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
icon="el-icon-edit-outline" icon="el-icon-edit-outline"
:title="$t('common:button:edit')" :title="$t('common:button:edit')"
size="mini"
circle circle
@click.stop="handleEdit(scope.row)" @click.stop="handleEdit(scope.row)"
/> />
@ -400,7 +395,6 @@
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
icon="el-icon-download" icon="el-icon-download"
:title="$t('trials:trialDocument:reportDoc:button:download')" :title="$t('trials:trialDocument:reportDoc:button:download')"
size="mini"
circle circle
@click.stop="downLoad(false, scope.row)" @click.stop="downLoad(false, scope.row)"
/> />
@ -408,7 +402,6 @@
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
icon="el-icon-delete" icon="el-icon-delete"
:title="$t('trials:trialDocument:reportDoc:button:delete')" :title="$t('trials:trialDocument:reportDoc:button:delete')"
size="mini"
circle circle
@click.stop="handleDel(scope.row)" @click.stop="handleDel(scope.row)"
/> />

View File

@ -3,7 +3,7 @@
<div class="title"> <div class="title">
{{ TITLE }} {{ TITLE }}
</div> </div>
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form topForm">
<el-form-item <el-form-item
:label="$t('trials:trialDocument:temp:form:isEnable')" :label="$t('trials:trialDocument:temp:form:isEnable')"
v-if="isManage && hasEdit && !viewStatus" v-if="isManage && hasEdit && !viewStatus"
@ -23,7 +23,6 @@
<el-form-item v-if="isManage && hasEdit && !viewStatus"> <el-form-item v-if="isManage && hasEdit && !viewStatus">
<el-button <el-button
type="primary" type="primary"
size="mini"
@click="rowBtnStatus = 'save'" @click="rowBtnStatus = 'save'"
v-if="rowBtnStatus === 'edit'" v-if="rowBtnStatus === 'edit'"
> >
@ -31,7 +30,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
:loading="rowBtnLoading" :loading="rowBtnLoading"
@click="saveRowData" @click="saveRowData"
v-if="rowBtnStatus === 'save'" v-if="rowBtnStatus === 'save'"
@ -40,9 +38,10 @@
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="line"></div>
<!-- 搜索框 --> <!-- 搜索框 -->
<div class="search" style="position: relative"> <div class="search" style="position: relative">
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form">
<el-form-item :label="$t('trials:trialDocument:temp:search:name')"> <el-form-item :label="$t('trials:trialDocument:temp:search:name')">
<el-input <el-input
v-model="searchData.FileName" v-model="searchData.FileName"
@ -86,7 +85,6 @@
<el-button <el-button
type="primary" type="primary"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
size="mini"
v-if="hasAccredit && isManage && !viewStatus" v-if="hasAccredit && isManage && !viewStatus"
@click.stop="auth" @click.stop="auth"
> >
@ -94,7 +92,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(false)" @click.stop="openFile(false)"
> >
@ -102,7 +99,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(true)" @click.stop="openFile(true)"
> >
@ -111,7 +107,6 @@
<el-button <el-button
type="primary" type="primary"
icon="el-icon-bottom" icon="el-icon-bottom"
size="mini"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
@click.stop="downLoad" @click.stop="downLoad"
@ -120,7 +115,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
@click.stop="delList" @click.stop="delList"
@ -247,23 +241,38 @@
/> />
<el-table-column :label="$t('common:action:action')" width="200"> <el-table-column :label="$t('common:action:action')" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <viewer
icon="el-icon-view" :ref="scope.row.TrialFileRecord.FilePath"
:title="$t('common:button:view')" style="margin: 0 10px;display: inline-block;"
size="mini" :images="[
circle `${OSSclientConfig.basePath}${scope.row.TrialFileRecord.FilePath}`,
:disabled=" ]"
!scope.row.TrialFileRecord || >
!scope.row.TrialFileRecord.FilePath || <el-button
!~scope.row.TrialFileRecord.FileFormat.indexOf('pdf') icon="el-icon-view"
" :title="$t('common:button:view')"
@click.stop="preview(scope.row.TrialFileRecord)" circle
/> :disabled="
!scope.row.TrialFileRecord ||
!scope.row.TrialFileRecord.FilePath ||
(!~scope.row.TrialFileRecord.FileFormat.indexOf('pdf') &&
!~scope.row.TrialFileRecord.FileFormat.indexOf('jpg') &&
!~scope.row.TrialFileRecord.FileFormat.indexOf('jpeg') &&
!~scope.row.TrialFileRecord.FileFormat.indexOf('png'))
"
@click.stop="preview(scope.row.TrialFileRecord)"
/>
<img
v-show="false"
crossorigin="anonymous"
:src="`${OSSclientConfig.basePath}${scope.row.TrialFileRecord.FilePath}`"
alt="Image"
/>
</viewer>
<el-button <el-button
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
icon="el-icon-download" icon="el-icon-download"
:title="$t('trials:trialDocument:temp:button:download')" :title="$t('trials:trialDocument:temp:button:download')"
size="mini"
circle circle
@click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')" @click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')"
/> />
@ -271,7 +280,6 @@
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
icon="el-icon-delete" icon="el-icon-delete"
:title="$t('trials:trialDocument:temp:button:delete')" :title="$t('trials:trialDocument:temp:button:delete')"
size="mini"
circle circle
@click.stop="handleDel(scope.row)" @click.stop="handleDel(scope.row)"
/> />
@ -661,11 +669,15 @@ export default {
// //
preview(row) { preview(row) {
if (!row.FilePath) return false if (!row.FilePath) return false
this.$preview({ if (!!~row.FileFormat.indexOf('pdf')) {
path: row.FilePath || row.fullPath, return this.$preview({
type: 'pdf', path: row.FilePath || row.fullPath,
title: row.FileName, type: 'pdf',
}) title: row.FileName,
})
}
this.$refs[row.FilePath].$viewer.show()
}, },
close() { close() {
this.config.visible = false this.config.visible = false
@ -786,4 +798,9 @@ export default {
} }
} }
} }
.topForm {
.el-form-item {
margin-right: 30px;
}
}
</style> </style>

View File

@ -3,7 +3,7 @@
<div class="title"> <div class="title">
{{ TITLE }} {{ TITLE }}
</div> </div>
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form topForm">
<el-form-item <el-form-item
:label="$t('trials:trialDocument:trainRecord:form:isConfirmRecord')" :label="$t('trials:trialDocument:trainRecord:form:isConfirmRecord')"
v-if="isManage && hasEdit && !viewStatus" v-if="isManage && hasEdit && !viewStatus"
@ -39,7 +39,6 @@
<el-form-item v-if="isManage && hasEdit && !viewStatus"> <el-form-item v-if="isManage && hasEdit && !viewStatus">
<el-button <el-button
type="primary" type="primary"
size="mini"
@click="rowBtnStatus = 'save'" @click="rowBtnStatus = 'save'"
v-if="rowBtnStatus === 'edit'" v-if="rowBtnStatus === 'edit'"
> >
@ -47,7 +46,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
:loading="rowBtnLoading" :loading="rowBtnLoading"
@click="saveRowData" @click="saveRowData"
v-if="rowBtnStatus === 'save'" v-if="rowBtnStatus === 'save'"
@ -56,9 +54,10 @@
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="line"></div>
<!-- 搜索框 --> <!-- 搜索框 -->
<div class="search" style="position: relative"> <div class="search" style="position: relative">
<el-form :inline="true" size="mini" class="base-search-form"> <el-form :inline="true" class="base-search-form">
<!--培训日期--> <!--培训日期-->
<el-form-item <el-form-item
:label="$t('trials:trialDocument:trainRecord:search:TrianingDate')" :label="$t('trials:trialDocument:trainRecord:search:TrianingDate')"
@ -139,7 +138,6 @@
<el-button <el-button
type="primary" type="primary"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
size="mini"
v-if="hasAccredit && isManage && !viewStatus" v-if="hasAccredit && isManage && !viewStatus"
@click.stop="auth" @click.stop="auth"
> >
@ -147,7 +145,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(false)" @click.stop="openFile(false)"
> >
@ -155,7 +152,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
@click.stop="openFile(true)" @click.stop="openFile(true)"
> >
@ -163,7 +159,6 @@
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
size="mini"
v-if="hasAdd && isManage && !viewStatus" v-if="hasAdd && isManage && !viewStatus"
@click.stop="handleAdd" @click.stop="handleAdd"
> >
@ -172,7 +167,6 @@
<el-button <el-button
type="primary" type="primary"
icon="el-icon-bottom" icon="el-icon-bottom"
size="mini"
:disabled="selectTable.length <= 0" :disabled="selectTable.length <= 0"
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
@click.stop="downLoad" @click.stop="downLoad"
@ -366,7 +360,6 @@
<el-button <el-button
icon="el-icon-view" icon="el-icon-view"
:title="$t('common:button:view')" :title="$t('common:button:view')"
size="mini"
circle circle
:disabled=" :disabled="
!scope.row.TrialFileRecord || !scope.row.TrialFileRecord.FilePath !scope.row.TrialFileRecord || !scope.row.TrialFileRecord.FilePath
@ -377,7 +370,6 @@
v-if="hasEdit && isManage && !viewStatus" v-if="hasEdit && isManage && !viewStatus"
icon="el-icon-edit-outline" icon="el-icon-edit-outline"
:title="$t('common:button:edit')" :title="$t('common:button:edit')"
size="mini"
circle circle
@click.stop="handleEdit(scope.row)" @click.stop="handleEdit(scope.row)"
/> />
@ -385,7 +377,6 @@
v-if="hasDownLoad && isManage && !viewStatus" v-if="hasDownLoad && isManage && !viewStatus"
icon="el-icon-download" icon="el-icon-download"
:title="$t('trials:trialDocument:trainRecord:button:download')" :title="$t('trials:trialDocument:trainRecord:button:download')"
size="mini"
circle circle
@click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')" @click.stop="downLoad(false, scope.row.TrialFileRecord, 'file')"
/> />
@ -393,7 +384,6 @@
v-if="hasDel && isManage && !viewStatus" v-if="hasDel && isManage && !viewStatus"
icon="el-icon-delete" icon="el-icon-delete"
:title="$t('trials:trialDocument:trainRecord:button:delete')" :title="$t('trials:trialDocument:trainRecord:button:delete')"
size="mini"
circle circle
@click.stop="handleDel(scope.row)" @click.stop="handleDel(scope.row)"
/> />

View File

@ -26,7 +26,7 @@
<Menu <Menu
ref="Menu" ref="Menu"
:viewStatus="viewStatus" :viewStatus="viewStatus"
:Id.sync="Id" :menuId.sync="Id"
:SubIdentificationEnum.sync="SubIdentificationEnum" :SubIdentificationEnum.sync="SubIdentificationEnum"
:ArchiveTypeEnum.sync="ArchiveTypeEnum" :ArchiveTypeEnum.sync="ArchiveTypeEnum"
:rowData.sync="rowData" :rowData.sync="rowData"
@ -82,7 +82,7 @@ export default {
components: { BaseContainer, Menu, reportDoc, fileRecord, trainRecord, temp }, components: { BaseContainer, Menu, reportDoc, fileRecord, trainRecord, temp },
data() { data() {
return { return {
viewStatus: false, viewStatus: true,
Id: null, Id: null,
SubIdentificationEnum: null, SubIdentificationEnum: null,
ArchiveTypeEnum: null, ArchiveTypeEnum: null,
@ -103,7 +103,7 @@ export default {
}, },
methods: { methods: {
handleChange() { handleChange() {
this.Id = null // this.Id = null
this.SubIdentificationEnum = null this.SubIdentificationEnum = null
this.ArchiveTypeEnum = null this.ArchiveTypeEnum = null
this.rowData = {} this.rowData = {}
@ -157,4 +157,16 @@ export default {
padding: 10px; padding: 10px;
} }
} }
::v-deep .topForm {
.el-form-item {
margin-right: 30px;
margin-bottom: 22px;
}
}
::v-deep .line {
width: 100%;
height: 1px;
margin: 0 0 22px 0;
border-top: 1px solid #ebeef5;
}
</style> </style>