Lugano 2014全局更新类型,配置时数据被清空
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
341a707c80
commit
7238b12424
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<div style="position: relative">
|
<div style="position: relative">
|
||||||
<el-form size="small" :inline="true" style="position: relative;">
|
<el-form size="small" :inline="true" style="position: relative;">
|
||||||
<!-- 阅片规则 -->
|
<!-- 阅片规则 -->
|
||||||
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:readingRules') }}</el-divider>
|
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:readingRules') }}</el-divider>
|
||||||
<!-- 是否必须全局阅片 -->
|
<!-- 是否必须全局阅片 -->
|
||||||
|
|
@ -8,68 +8,38 @@
|
||||||
{{ $fd('YesOrNo', IsMustGlobalReading) }}
|
{{ $fd('YesOrNo', IsMustGlobalReading) }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 配置 -->
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button size="mini" type="primary" style="position: absolute;right: 10px;top: 15px"
|
||||||
size="mini"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)" @click="handleAdd(1)">
|
||||||
type="primary"
|
|
||||||
style="position: absolute;right: 10px;top: 15px"
|
|
||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
|
||||||
@click="handleAdd(1)"
|
|
||||||
>
|
|
||||||
{{ $t('dictionary:template:globalConfig:config') }}
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-form size="small" :inline="true" style="position: relative">
|
<el-form size="small" :inline="true" style="position: relative">
|
||||||
<!-- 名称 -->
|
<!-- 名称 -->
|
||||||
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:name') }}</el-divider>
|
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:name') }}</el-divider>
|
||||||
<!-- 配置 -->
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button size="mini" type="primary" style="position: absolute;right: 10px;top: 15px"
|
||||||
size="mini"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)" @click="handleAdd(2)">
|
||||||
type="primary"
|
|
||||||
style="position: absolute;right: 10px;top: 15px"
|
|
||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
|
||||||
@click="handleAdd(2)"
|
|
||||||
>
|
|
||||||
{{ $t('dictionary:template:globalConfig:config') }}
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- 评估更新类型 -->
|
<!-- 评估更新类型 -->
|
||||||
<el-form-item :label="$t('dictionary:template:globalConfig:updateType')" style="width: 100%">
|
<el-form-item :label="$t('dictionary:template:globalConfig:updateType')" style="width: 100%">
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-table
|
<el-table v-loading="loading" style="width: 100%" :data="list" stripe>
|
||||||
v-loading="loading"
|
|
||||||
style="width: 100%"
|
|
||||||
:data="list"
|
|
||||||
stripe
|
|
||||||
>
|
|
||||||
<!-- 序号 -->
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column prop="" :label="$t('dictionary:template:globalConfig:order')" width="80">
|
||||||
prop=""
|
|
||||||
:label="$t('dictionary:template:globalConfig:order')"
|
|
||||||
width="80"
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{scope.$index + 1}}
|
{{ scope.$index + 1 }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 中文值 -->
|
<!-- 中文值 -->
|
||||||
<el-table-column
|
<el-table-column prop="ValueCN" :label="$t('dictionary:template:globalConfig:valueCN')" show-overflow-tooltip>
|
||||||
prop="ValueCN"
|
|
||||||
:label="$t('dictionary:template:globalConfig:valueCN')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 英文值 -->
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column prop="Value" :label="$t('dictionary:template:globalConfig:value')" show-overflow-tooltip>
|
||||||
prop="Value"
|
|
||||||
:label="$t('dictionary:template:globalConfig:value')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 是否基线评估 -->
|
<!-- 是否基线评估 -->
|
||||||
<el-table-column
|
<el-table-column prop="IsBaseLineUse" :label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
||||||
prop="IsBaseLineUse"
|
show-overflow-tooltip>
|
||||||
:label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!-- <el-switch-->
|
<!-- <el-switch-->
|
||||||
<!-- @change="(v) => {BaseLineUseChange(v, scope.row)}"-->
|
<!-- @change="(v) => {BaseLineUseChange(v, scope.row)}"-->
|
||||||
|
|
@ -81,92 +51,64 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 是否随访评估 -->
|
<!-- 是否随访评估 -->
|
||||||
<el-table-column
|
<el-table-column prop="IsFollowVisitUse" :label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
||||||
prop="IsFollowVisitUse"
|
show-overflow-tooltip>
|
||||||
:label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!-- <el-switch-->
|
<!-- <el-switch-->
|
||||||
<!-- @change="(v) => {FollowVisitUseChange(v, scope.row)}"-->
|
<!-- @change="(v) => {FollowVisitUseChange(v, scope.row)}"-->
|
||||||
<!-- v-model="scope.row.IsFollowVisitUse"-->
|
<!-- v-model="scope.row.IsFollowVisitUse"-->
|
||||||
<!-- >-->
|
<!-- >-->
|
||||||
<!-- </el-switch>-->
|
<!-- </el-switch>-->
|
||||||
<el-tag v-if="scope.row.IsFollowVisitUse" type="primary">{{ $fd('YesOrNo', scope.row.IsFollowVisitUse) }}</el-tag>
|
<el-tag v-if="scope.row.IsFollowVisitUse" type="primary">{{ $fd('YesOrNo', scope.row.IsFollowVisitUse)
|
||||||
|
}}</el-tag>
|
||||||
<el-tag v-else type="danger">{{ $fd('YesOrNo', scope.row.IsFollowVisitUse) }}</el-tag>
|
<el-tag v-else type="danger">{{ $fd('YesOrNo', scope.row.IsFollowVisitUse) }}</el-tag>
|
||||||
<!-- <span>{{$fd('YesOrNo', scope.row.IsFollowVisitUse)}}</span>-->
|
<!-- <span>{{$fd('YesOrNo', scope.row.IsFollowVisitUse)}}</span>-->
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-form>
|
</el-form>
|
||||||
<base-model
|
<base-model :config="config">
|
||||||
:config="config"
|
|
||||||
>
|
|
||||||
<template slot="dialog-body">
|
<template slot="dialog-body">
|
||||||
<el-form size="small" :inline="true" label-width="130px">
|
<el-form size="small" :inline="true" label-width="130px">
|
||||||
<!-- 是否必须全局阅片 -->
|
<!-- 是否必须全局阅片 -->
|
||||||
<el-form-item :label="$t('dictionary:template:globalConfig:isMustGlobalReading')" v-if="config.configType === 1">
|
<el-form-item :label="$t('dictionary:template:globalConfig:isMustGlobalReading')"
|
||||||
|
v-if="config.configType === 1">
|
||||||
<el-radio-group v-model="form.IsMustGlobalReading">
|
<el-radio-group v-model="form.IsMustGlobalReading">
|
||||||
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsMustGlobalReading' + item.value" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsMustGlobalReading' + item.value" :label="item.value">{{
|
||||||
|
item.label }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 评估更新类型 -->
|
<!-- 评估更新类型 @selection-change="handleSelectionChange"-->
|
||||||
<el-form-item v-if="config.configType === 2" :label="$t('dictionary:template:globalConfig:updateType')" style="width: 100%">
|
<el-form-item v-if="config.configType === 2" :label="$t('dictionary:template:globalConfig:updateType')"
|
||||||
|
style="width: 100%">
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-table
|
<el-table v-if="config.configType === 2" v-loading="loading" ref="multipleTable" :data="GlobalAssessType"
|
||||||
v-if="config.configType === 2"
|
stripe>
|
||||||
v-loading="loading"
|
<!-- <el-table-column type="selection" width="55">
|
||||||
ref="multipleTable"
|
</el-table-column> -->
|
||||||
:data="GlobalAssessType"
|
|
||||||
stripe
|
|
||||||
@selection-change="handleSelectionChange"
|
|
||||||
>
|
|
||||||
<el-table-column
|
|
||||||
type="selection"
|
|
||||||
width="55">
|
|
||||||
</el-table-column>
|
|
||||||
<!-- 中文值 -->
|
<!-- 中文值 -->
|
||||||
<el-table-column
|
<el-table-column prop="ValueCN" :label="$t('dictionary:template:globalConfig:valueCN')"
|
||||||
prop="ValueCN"
|
show-overflow-tooltip>
|
||||||
:label="$t('dictionary:template:globalConfig:valueCN')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 英文值 -->
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column prop="Value" :label="$t('dictionary:template:globalConfig:value')" show-overflow-tooltip>
|
||||||
prop="Value"
|
|
||||||
:label="$t('dictionary:template:globalConfig:value')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 是否基线评估 -->
|
<!-- 是否基线评估 -->
|
||||||
<el-table-column
|
<el-table-column prop="IsBaseLineUse" :label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
||||||
prop="IsBaseLineUse"
|
show-overflow-tooltip>
|
||||||
:label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-switch
|
<el-switch v-model="scope.row.IsBaseLineUse" @change="() => $forceUpdate()">
|
||||||
v-model="scope.row.IsBaseLineUse"
|
|
||||||
@change="() => $forceUpdate()"
|
|
||||||
>
|
|
||||||
</el-switch>
|
</el-switch>
|
||||||
<span>{{$fd('YesOrNo', scope.row.IsBaseLineUse)}}</span>
|
<span>{{ $fd('YesOrNo', scope.row.IsBaseLineUse) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 是否随访评估 -->
|
<!-- 是否随访评估 -->
|
||||||
<el-table-column
|
<el-table-column prop="IsFollowVisitUse" :label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
||||||
prop="IsFollowVisitUse"
|
show-overflow-tooltip>
|
||||||
:label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-switch
|
<el-switch v-model="scope.row.IsFollowVisitUse" @change="() => $forceUpdate()">
|
||||||
v-model="scope.row.IsFollowVisitUse"
|
|
||||||
@change="() => $forceUpdate()"
|
|
||||||
>
|
|
||||||
</el-switch>
|
</el-switch>
|
||||||
<span>{{$fd('YesOrNo', scope.row.IsFollowVisitUse)}}</span>
|
<span>{{ $fd('YesOrNo', scope.row.IsFollowVisitUse) }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
@ -226,7 +168,7 @@ export default {
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getSystemGlobalInfo()
|
this.getSystemGlobalInfo()
|
||||||
this.getCriterionDictionary()
|
// this.getCriterionDictionary()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getCriterionDictionary() {
|
getCriterionDictionary() {
|
||||||
|
|
@ -241,12 +183,12 @@ export default {
|
||||||
getSystemGlobalInfo({
|
getSystemGlobalInfo({
|
||||||
SystemCriterionId: this.criterionId
|
SystemCriterionId: this.criterionId
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
|
this.GlobalAssessType = res.Result.DictionaryList
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
FollowVisitUseChange(v, row) {
|
FollowVisitUseChange(v, row) {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
setDictionaryFollowVisitUse({Id:row.Id, IsFollowVisitUse: v}).then(res => {
|
setDictionaryFollowVisitUse({ Id: row.Id, IsFollowVisitUse: v }).then(res => {
|
||||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
this.loading = false
|
this.loading = false
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
|
|
@ -255,7 +197,7 @@ export default {
|
||||||
},
|
},
|
||||||
BaseLineUseChange(v, row) {
|
BaseLineUseChange(v, row) {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
setDictionaryBaseLineUse({Id:row.Id, isBaseLineUse: v}).then(res => {
|
setDictionaryBaseLineUse({ Id: row.Id, isBaseLineUse: v }).then(res => {
|
||||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
this.loading = false
|
this.loading = false
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
|
|
@ -273,6 +215,7 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleSelectionChange(val) {
|
handleSelectionChange(val) {
|
||||||
|
console.log(this.selectedList, 'this.selectedList')
|
||||||
this.selectedList = val
|
this.selectedList = val
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
|
|
@ -295,18 +238,6 @@ export default {
|
||||||
} else {
|
} else {
|
||||||
this.config.title = this.$t('dictionary:template:globalConfig:updateType')
|
this.config.title = this.$t('dictionary:template:globalConfig:updateType')
|
||||||
this.config.visible = true
|
this.config.visible = true
|
||||||
this.$nextTick(() => {
|
|
||||||
var a = this.$d.GlobalAssessType.filter(v => {
|
|
||||||
return !!this.list.find(v1 => {
|
|
||||||
if (v.id === v1.DictionaryId) {
|
|
||||||
v.IsBaseLineUse = v1.IsBaseLineUse
|
|
||||||
v.IsFollowVisitUse = v1.IsFollowVisitUse
|
|
||||||
}
|
|
||||||
return v1.DictionaryId === v.id
|
|
||||||
})
|
|
||||||
})
|
|
||||||
this.toggleSelection(a)
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleSave() {
|
handleSave() {
|
||||||
|
|
@ -319,11 +250,11 @@ export default {
|
||||||
var params = {
|
var params = {
|
||||||
SystemCriterionId: this.criterionId,
|
SystemCriterionId: this.criterionId,
|
||||||
IsMustGlobalReading: this.form.IsMustGlobalReading,
|
IsMustGlobalReading: this.form.IsMustGlobalReading,
|
||||||
DictionaryList: this.config.configType === 1 ? this.list : this.selectedList.map(v => {
|
DictionaryList: this.config.configType === 1 ? this.list : this.GlobalAssessType.map(v => {
|
||||||
return {
|
return {
|
||||||
DictionaryId: v.id,
|
DictionaryId: v.DictionaryId,
|
||||||
IsBaseLineUse: v.IsBaseLineUse,
|
IsBaseLineUse: v.IsBaseLineUse ? v.IsBaseLineUse : false,
|
||||||
IsFollowVisitUse: v.IsFollowVisitUse,
|
IsFollowVisitUse: v.IsFollowVisitUse ? v.IsFollowVisitUse : false,
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
}
|
}
|
||||||
|
|
@ -342,5 +273,3 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue