Compare commits
274 Commits
v1.8.0
..
c0eab7e896
| Author | SHA1 | Date | |
|---|---|---|---|
| c0eab7e896 | |||
| 4ba4d7cf00 | |||
| bfe9817544 | |||
| f5fd1252c9 | |||
| 596ea8f658 | |||
| b24548dd8b | |||
| 4a479258f2 | |||
| 29d0cc7653 | |||
| 6de9cd26a4 | |||
| caf3f41465 | |||
| 8896737a9e | |||
| 1be46686a3 | |||
| 0cd07b76f8 | |||
| d74c0028f6 | |||
| ab5645f28a | |||
| efb88b7ad1 | |||
| 129548031c | |||
| 5dbddbea57 | |||
| 689782bf36 | |||
| 89fe4e4c00 | |||
| a582daf686 | |||
| 3e680d0033 | |||
| af343d43d8 | |||
| 4b9216229c | |||
| 2952762ce7 | |||
| 361aed4a0c | |||
| 19b419c29e | |||
| 7e9a9b62f6 | |||
| 3921f369c3 | |||
| 0ffe7ff1a7 | |||
| 5ec969c2f9 | |||
| dba4466ac2 | |||
| 9187bbe64f | |||
| a0f593a22f | |||
| 89f7aee973 | |||
| ced57cbfe4 | |||
| 99d099496e | |||
| d3afa7b676 | |||
| c08d701143 | |||
| a2d06ba72f | |||
| 148aa4908b | |||
| 53738c2da4 | |||
| 3513c08adf | |||
| 9eb3f2f322 | |||
| b16e351779 | |||
| b176ab0716 | |||
| c7eb323eaa | |||
| 7b3fe42654 | |||
| 21c96300ad | |||
| 8f46819b9a | |||
| 6e66dd8bbe | |||
| b209c6566b | |||
| f8bd826c9c | |||
| e3f6f9107d | |||
| f1c72c66e8 | |||
| 79caed3fd9 | |||
| e56440634e | |||
| ac657a162f | |||
| 9d362e13de | |||
| d04898dc28 | |||
| e0f42e815e | |||
| efe3d937b4 | |||
| 5cf6ab24bd | |||
| ff0ddeea9a | |||
| 42083afb8d | |||
| de1b22ff48 | |||
| 66cbbbbb75 | |||
| 3d89939a98 | |||
| ade4ab3e03 | |||
| a3550c44bd | |||
| 9e85e9705e | |||
| e1d5db8cf5 | |||
| 6f3381c267 | |||
| 0c52bde525 | |||
| 102089c16f | |||
| 6e1d07ee95 | |||
| 55ae6bac7e | |||
| 823ac2f085 | |||
| 73e0a13e91 | |||
| 7f179fb393 | |||
| 3441793bcb | |||
| dbe651fe98 | |||
| f54ff927ec | |||
| 535b37e830 | |||
| 13191c914e | |||
| 70735f2c47 | |||
| 8ad77f1679 | |||
| 3a76a7c24d | |||
| 5393ca571c | |||
| 4cef62ccba | |||
| 2772168c3b | |||
| 89be8d8a12 | |||
| 041266c250 | |||
| cbcb84a768 | |||
| 830718c228 | |||
| 6977ed3713 | |||
| 28ea52797e | |||
| 1348d5f864 | |||
| cd34ad7ef7 | |||
| 5af7e8dd3c | |||
| 455f808f49 | |||
| a0d5e58311 | |||
| 84dbcd49f0 | |||
| a4ec387814 | |||
| 3a6c3d451c | |||
| f396901731 | |||
| 0b00f4bc7e | |||
| e58695aeff | |||
| 65a9dd3cf1 | |||
| 63743dbbc1 | |||
| b5643d3774 | |||
| 4c1a770969 | |||
| 7ff0273c29 | |||
| 3f2a339cba | |||
| d3dd4ecffc | |||
| d636813210 | |||
| 66d09ca284 | |||
| e672e6bd18 | |||
| 9c964f11a1 | |||
| 0a473dcae3 | |||
| 85b3960f97 | |||
| b96f5b9910 | |||
| 31196e850e | |||
| c309410c04 | |||
| 0a671fb330 | |||
| febdfd7b4f | |||
| e1da0c9ea5 | |||
| 54be84c300 | |||
| 78c1b57770 | |||
| 39ce8fd355 | |||
| 130862518f | |||
| a129adbc4b | |||
| 3066781ee6 | |||
| df4880dc08 | |||
| 29e2a6ea65 | |||
| ae12c3d517 | |||
| cbe346a049 | |||
| c8c5ab72bb | |||
| 37dc4a960f | |||
| 05cf250c21 | |||
| b2ca803f94 | |||
| 2ff2f5106e | |||
| 67c2d47689 | |||
| 67a3c4f926 | |||
| 9ab7afa06f | |||
| e5a17d20b1 | |||
| 3c664e9ba6 | |||
| 50dd74b4ce | |||
| b22b9d338e | |||
| a13ef6e5d2 | |||
| 58141aaca9 | |||
| 17b868e7ed | |||
| bbc4da7b9e | |||
| c14079efe3 | |||
| ecf5119269 | |||
| b35ff2b7dc | |||
| bae5b9c51c | |||
| be5b9efa7b | |||
| efab56f6bd | |||
| a239bccc90 | |||
| 7dd15434bf | |||
| 437b4377ed | |||
| 7229bc65a9 | |||
| bf95ea96e2 | |||
| 013a657f78 | |||
| 8d4e9368c6 | |||
| d71fff7393 | |||
| d243d3cd11 | |||
| 221ad89fd4 | |||
| af42a3aec0 | |||
| b0529dca5f | |||
| 17ee60de81 | |||
| b9ef4fd3f3 | |||
| 252333ea5b | |||
| a5445804e2 | |||
| 0cabf49c43 | |||
| 5ee7ba9820 | |||
| 4f2419fe03 | |||
| 28bb98099c | |||
| 5963fc629d | |||
| 44feb21f63 | |||
| 343813158f | |||
| 5e80fe2c3f | |||
| 2e8095939b | |||
| b0dc5400aa | |||
| 7f18e717b7 | |||
| 6e66b77857 | |||
| 5328217853 | |||
| 0f4819f5db | |||
| 907371b693 | |||
| f65042a5c2 | |||
| 518ce72fd2 | |||
| ba54da2814 | |||
| d381b10bcd | |||
| d127637922 | |||
| 0e0c2ca55d | |||
| 98502230c3 | |||
| 2b987fb1ae | |||
| f1dee25987 | |||
| 8799431f7a | |||
| a8fe3d6073 | |||
| 3578882ec0 | |||
| d5c9298aab | |||
| 59df7214d4 | |||
| 6c50257972 | |||
| 58b8cf1391 | |||
| 1f6ee08a8b | |||
| c5fb53a05f | |||
| 24e05ebc3e | |||
| a78d848424 | |||
| 75f3b37c05 | |||
| ca4f2c4a8e | |||
| 4defa157ee | |||
| 13ba919484 | |||
| bf407a49fd | |||
| 3c50254a2d | |||
| 41ac3d562a | |||
| d790a95952 | |||
| 328359dfde | |||
| 1286cd1212 | |||
| f739563fe9 | |||
| 2f4ace45b8 | |||
| 407f0b85d2 | |||
| 3052b269e9 | |||
| a7c3bf09f8 | |||
| 65d9c7b711 | |||
| 3ca1e9d8ed | |||
| f27fda4a5f | |||
| 27352f572c | |||
| 47c6b30d4a | |||
| 91bd50d565 | |||
| d1ed8b39f0 | |||
| 3925652428 | |||
| 37f8f2fff1 | |||
| 32551e3faa | |||
| 43f99b02c4 | |||
| 9c22809bae | |||
| be9e78ec73 | |||
| d645df58c2 | |||
| 5d9adab706 | |||
| 291f9b5d66 | |||
| 5dedcbc2ef | |||
| 940a860352 | |||
| 9cd540d1ec | |||
| 9e8d537358 | |||
| 7882c9b631 | |||
| 5dd1935997 | |||
| 47d60769be | |||
| 8225eacb7e | |||
| 57a8bb4e24 | |||
| 36ffd8b371 | |||
| 7fc6f4494b | |||
| 9d3ba7eb57 | |||
| 7ed4dd7e24 | |||
| b233535d95 | |||
| 9bdb8f64b3 | |||
| f637f746cb | |||
| dec01d779d | |||
| 7363b0049d | |||
| a95a129dde | |||
| 177510643d | |||
| eeac5b76c4 | |||
| a17359a56e | |||
| 28c7cf7d67 | |||
| d9091fbb79 | |||
| 7e52005dab | |||
| 5866535fb5 | |||
| 862c6d64cc | |||
| 2c0c2e8111 | |||
| c24c98b334 | |||
| 97caeae753 | |||
| 6725f6e276 | |||
| 38ad4e72a2 | |||
| c9c4826274 |
@@ -5,3 +5,6 @@ npm install
|
|||||||
# 启动服务
|
# 启动服务
|
||||||
npm run dev
|
npm run dev
|
||||||
|
|
||||||
|
# v1.9.0修改
|
||||||
|
1. 角色修改,全局userId实际意义修改为userRoleId(用户角色id),新增identityUserId(新的用户id)
|
||||||
|
|
||||||
|
|||||||
@@ -30,7 +30,6 @@
|
|||||||
</script>
|
</script>
|
||||||
<% } else { %>
|
<% } else { %>
|
||||||
<script>
|
<script>
|
||||||
console.log(2)
|
|
||||||
window.zzSessionStorage = {
|
window.zzSessionStorage = {
|
||||||
setItem: (item, value) => {
|
setItem: (item, value) => {
|
||||||
return sessionStorage.setItem(item, value)
|
return sessionStorage.setItem(item, value)
|
||||||
|
|||||||
+109
-22
@@ -23,12 +23,38 @@
|
|||||||
>
|
>
|
||||||
i18n
|
i18n
|
||||||
</div>
|
</div>
|
||||||
<el-drawer title="国际化" :visible.sync="drawer" direction="rtl" size="80%">
|
<el-drawer
|
||||||
<div style="width: 320px">
|
:title="$t('il8n:title')"
|
||||||
<el-form label-width="100px" @submit.native.prevent size="small">
|
:visible.sync="drawer"
|
||||||
<el-form-item label="关键字">
|
direction="rtl"
|
||||||
|
size="80%"
|
||||||
|
>
|
||||||
|
<div style="width: 620px">
|
||||||
|
<el-form
|
||||||
|
label-width="100px"
|
||||||
|
@submit.native.prevent
|
||||||
|
size="small"
|
||||||
|
:inline="true"
|
||||||
|
class="demo-form-inline"
|
||||||
|
>
|
||||||
|
<el-form-item :label="$t('il8n:search:keyword')">
|
||||||
<el-input v-model="key" @input="keyChange" />
|
<el-input v-model="key" @input="keyChange" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item :label="$t('il8n:search:state')">
|
||||||
|
<el-select
|
||||||
|
v-model="State"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
@change="handleStateChange"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.InternationalizationKeyState"
|
||||||
|
:key="'InternationalizationKeyState' + item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<el-table
|
<el-table
|
||||||
@@ -39,7 +65,7 @@
|
|||||||
>
|
>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Code"
|
prop="Code"
|
||||||
label="标签"
|
:label="$t('il8n:table:label')"
|
||||||
width="300"
|
width="300"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -53,7 +79,7 @@
|
|||||||
<!-- {{scope.row.Description}}-->
|
<!-- {{scope.row.Description}}-->
|
||||||
<!-- </template>-->
|
<!-- </template>-->
|
||||||
<!-- </el-table-column>-->
|
<!-- </el-table-column>-->
|
||||||
<el-table-column prop="Value" label="英文">
|
<el-table-column prop="Value" :label="$t('il8n:table:en')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="scope.row.Value"
|
v-model="scope.row.Value"
|
||||||
@@ -66,7 +92,7 @@
|
|||||||
></el-input>
|
></el-input>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="ValueCN" label="中文">
|
<el-table-column prop="ValueCN" :label="$t('il8n:table:cn')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="scope.row.ValueCN"
|
v-model="scope.row.ValueCN"
|
||||||
@@ -79,12 +105,33 @@
|
|||||||
></el-input>
|
></el-input>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column prop="ValueCN" :label="$t('il8n:table:state')">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-select
|
||||||
|
v-model="scope.row.State"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
size="mini"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.InternationalizationKeyState"
|
||||||
|
:key="'InternationalizationKeyState' + item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="Version" :label="$t('il8n:table:Version')">
|
||||||
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<div style="text-align: right; padding-top: 10px; padding-right: 10px">
|
<div style="text-align: right; padding-top: 10px; padding-right: 10px">
|
||||||
<el-button size="mini" @click="drawer = false">取消 </el-button>
|
<el-button size="mini" @click="drawer = false"
|
||||||
<el-button size="mini" type="primary" @click="handleSave"
|
>{{ $t('common:button:cancel') }}
|
||||||
>保存</el-button
|
</el-button>
|
||||||
>
|
<el-button size="mini" type="primary" @click="handleSave">{{
|
||||||
|
$t('common:button:save')
|
||||||
|
}}</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-drawer>
|
</el-drawer>
|
||||||
<feedBack v-if="$route.matched.length > 0" />
|
<feedBack v-if="$route.matched.length > 0" />
|
||||||
@@ -110,10 +157,13 @@ export default {
|
|||||||
show: false,
|
show: false,
|
||||||
key: null,
|
key: null,
|
||||||
arr: [],
|
arr: [],
|
||||||
|
il8nExternal: false,
|
||||||
|
State: null,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.show = process.env.VUE_APP_OSS_PATH === '/test/dist'
|
this.show = process.env.VUE_APP_OSS_PATH === '/test/dist'
|
||||||
|
Vue.prototype.$openI18n = this.openI18n
|
||||||
},
|
},
|
||||||
// watch: {
|
// watch: {
|
||||||
// '$route.query': {
|
// '$route.query': {
|
||||||
@@ -145,6 +195,11 @@ export default {
|
|||||||
// },
|
// },
|
||||||
// },
|
// },
|
||||||
methods: {
|
methods: {
|
||||||
|
handleStateChange() {
|
||||||
|
this.tableData.forEach((item) => {
|
||||||
|
item.State = this.State
|
||||||
|
})
|
||||||
|
},
|
||||||
changeValue(target, attr, e) {
|
changeValue(target, attr, e) {
|
||||||
this.$set(target, attr, e)
|
this.$set(target, attr, e)
|
||||||
},
|
},
|
||||||
@@ -154,9 +209,9 @@ export default {
|
|||||||
[],
|
[],
|
||||||
this.arr.filter(
|
this.arr.filter(
|
||||||
(v) =>
|
(v) =>
|
||||||
~v.Code.indexOf(this.key) ||
|
~v.Code.toLowerCase().indexOf(this.key.toLowerCase()) ||
|
||||||
~v.Value.indexOf(this.key) ||
|
~v.Value.toLowerCase().indexOf(this.key.toLowerCase()) ||
|
||||||
~v.ValueCN.indexOf(this.key)
|
~v.ValueCN.toLowerCase().indexOf(this.key.toLowerCase())
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
@@ -181,22 +236,52 @@ export default {
|
|||||||
i18n.mergeLocaleMessage('en', enMessages)
|
i18n.mergeLocaleMessage('en', enMessages)
|
||||||
this.drawer = false
|
this.drawer = false
|
||||||
this.$message.success('国际化修改成功')
|
this.$message.success('国际化修改成功')
|
||||||
|
if (this.il8nExternal) {
|
||||||
|
this.$EventBus.$emit('il8nUpdate')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
openI18n() {
|
openI18n(ARRAY) {
|
||||||
this.tableData = []
|
this.tableData = []
|
||||||
|
this.il8nExternal = false
|
||||||
|
this.State = null
|
||||||
this.key = null
|
this.key = null
|
||||||
this.drawer = true
|
this.drawer = true
|
||||||
let arr = []
|
let arr = []
|
||||||
let tableData = this.$tl.map((v) => {
|
let tableData = []
|
||||||
let a = { ...v }
|
if (ARRAY && Array.isArray(ARRAY)) {
|
||||||
// if (!a.Description) {
|
this.il8nExternal = true
|
||||||
// a.Description = this.$route.path
|
let data = ARRAY.map((v) => {
|
||||||
// }
|
let a = { ...v }
|
||||||
return a
|
|
||||||
})
|
return a
|
||||||
|
})
|
||||||
|
tableData = data.map((item) => {
|
||||||
|
return {
|
||||||
|
Code: item.Code,
|
||||||
|
Description: item.Description,
|
||||||
|
FrontType: item.FrontType,
|
||||||
|
Module: item.Module,
|
||||||
|
Value: item.Value,
|
||||||
|
ValueCN: item.ValueCN,
|
||||||
|
State: item.State,
|
||||||
|
Version: item.Version,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
this.tableData = Object.assign([], tableData)
|
||||||
|
this.arr = Object.assign([], tableData)
|
||||||
|
return false
|
||||||
|
} else {
|
||||||
|
tableData = this.$tl.map((v) => {
|
||||||
|
let a = { ...v }
|
||||||
|
// if (!a.Description) {
|
||||||
|
// a.Description = this.$route.path
|
||||||
|
// }
|
||||||
|
return a
|
||||||
|
})
|
||||||
|
}
|
||||||
tableData = tableData.filter((v) => {
|
tableData = tableData.filter((v) => {
|
||||||
// return ~this.$path.indexOf(v.Description + '_' + v.Code)
|
// return ~this.$path.indexOf(v.Description + '_' + v.Code)
|
||||||
return ~this.$path.indexOf(v.Code)
|
return ~this.$path.indexOf(v.Code)
|
||||||
@@ -213,6 +298,8 @@ export default {
|
|||||||
Description: null,
|
Description: null,
|
||||||
Value: null,
|
Value: null,
|
||||||
ValueCN: null,
|
ValueCN: null,
|
||||||
|
State: 0,
|
||||||
|
Version: this.$version.Version,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
+29
-4
@@ -44,11 +44,19 @@ export function updateUser(param) {
|
|||||||
data: param
|
data: param
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
export function updateUserBasicInfo(param) {
|
||||||
export function getUser(userId) {
|
|
||||||
return request({
|
return request({
|
||||||
url: `/user/getUser/${userId}`,
|
url: `/user/updateUserBasicInfo`,
|
||||||
method: 'get'
|
method: 'put',
|
||||||
|
data: param
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getUser(params) {
|
||||||
|
return request({
|
||||||
|
url: `/user/getUser`,
|
||||||
|
method: 'get',
|
||||||
|
params
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -317,3 +325,20 @@ export function useUserIDGetDoctorID(data) {
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 管理端修改用户角色
|
||||||
|
export function updateUserRoleInfo(data) {
|
||||||
|
return request({
|
||||||
|
url: `/User/updateUserRoleInfo`,
|
||||||
|
method: 'put',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 管理端新增用户发送邮件
|
||||||
|
export function addNewUserSendEmail(data) {
|
||||||
|
return request({
|
||||||
|
url: `/User/addNewUserSendEmail`,
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -251,3 +251,37 @@ export function uploadOCTLipidAngleTemplate(param) {
|
|||||||
data: param
|
data: param
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function saveTableQuestionMark(param, type) {
|
||||||
|
return request({
|
||||||
|
url: `/saveTableQuestionMark/${type}`,
|
||||||
|
method: 'post',
|
||||||
|
data: param
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function deleteTableQuestionMark(param, type) {
|
||||||
|
return request({
|
||||||
|
url: `/deleteTableQuestionMark/${type}`,
|
||||||
|
method: 'post',
|
||||||
|
data: param
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function submitTaskRowInfo(param, type) {
|
||||||
|
return request({
|
||||||
|
url: `/SubmitTaskRowInfo/${type}`,
|
||||||
|
method: 'post',
|
||||||
|
data: param
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function deleteSingleTableQuestionMark(param, type) {
|
||||||
|
return request({
|
||||||
|
url: `/DeleteSingleTableQuestionMark/${type}`,
|
||||||
|
method: 'post',
|
||||||
|
data: param
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1081,6 +1081,13 @@ export function setSeriesStatus(trialId, subjectVisitId, studyId, seriesId, stat
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function setInstanceStatus(trialId, subjectVisitId, seriesId, instanceId, state) {
|
||||||
|
return request({
|
||||||
|
url: `/QCOperation/setInstanceState/${trialId}/${subjectVisitId}/${seriesId}/${instanceId}/${state}`,
|
||||||
|
method: 'put'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
export function getVisitQCStudyAndSeriesList(subjectVisitId) {
|
export function getVisitQCStudyAndSeriesList(subjectVisitId) {
|
||||||
return request({
|
return request({
|
||||||
url: `/QCList/getVisitQCStudyAndSeriesList/${subjectVisitId}`,
|
url: `/QCList/getVisitQCStudyAndSeriesList/${subjectVisitId}`,
|
||||||
@@ -3914,4 +3921,48 @@ export function getVisitClinicalDataName(data) {
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data
|
data
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
// 修改外部人员权限配置
|
||||||
|
export function configTrialSPMInfo(data) {
|
||||||
|
return request({
|
||||||
|
url: `/TrialConfig/configTrialSPMInfo`,
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 项目添加角色修改权限
|
||||||
|
export function updateTrialUserRole(data) {
|
||||||
|
return request({
|
||||||
|
url: `/TrialMaintenance/updateTrialUserRole`,
|
||||||
|
method: 'put',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// 获取报表配置
|
||||||
|
export function getTrialQuestionExportResult(data) {
|
||||||
|
return request({
|
||||||
|
url: `/ReadingQuestion/getTrialQuestionExportResult`,
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 修改报表配置
|
||||||
|
export function setTrialQuestionExportResult(data) {
|
||||||
|
return request({
|
||||||
|
url: `/ReadingQuestion/SetTrialQuestionExportResult`,
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 项目加入人员发送邮件
|
||||||
|
export function trialUserSendJoinEmail(data) {
|
||||||
|
return request({
|
||||||
|
url: `/TrialMaintenance/trialUserSendJoinEmail`,
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
}
|
}
|
||||||
+18
-2
@@ -179,11 +179,11 @@ export function verifyMFACode(params) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 发送MFA邮件
|
// 发送MFA邮件
|
||||||
export function sendMFAEmail(params) {
|
export function sendMFAEmail(data) {
|
||||||
return request({
|
return request({
|
||||||
url: `/User/sendMFAEmail`,
|
url: `/User/sendMFAEmail`,
|
||||||
method: 'post',
|
method: 'post',
|
||||||
params
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 获取公钥
|
// 获取公钥
|
||||||
@@ -193,3 +193,19 @@ export function getPublicKey() {
|
|||||||
method: 'get',
|
method: 'get',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 登陆获取角色
|
||||||
|
export function getUserLoginRoleList(data) {
|
||||||
|
return request({
|
||||||
|
url: `/User/getUserLoginRoleList`,
|
||||||
|
method: 'post',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 登陆角色id获取token
|
||||||
|
export function loginSelectUserRole(params) {
|
||||||
|
return request({
|
||||||
|
url: `/User/loginSelectUserRole`,
|
||||||
|
method: 'get',
|
||||||
|
params,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
v-model="searchData[item.prop]"
|
v-model="searchData[item.prop]"
|
||||||
:placeholder="item.placeholder"
|
:placeholder="item.placeholder"
|
||||||
size="mini"
|
size="mini"
|
||||||
|
clearable
|
||||||
:style="{ width: item.width }"
|
:style="{ width: item.width }"
|
||||||
:readonly="item.readonly"
|
:readonly="item.readonly"
|
||||||
/>
|
/>
|
||||||
@@ -22,6 +23,7 @@
|
|||||||
v-model="searchData[item.prop]"
|
v-model="searchData[item.prop]"
|
||||||
:placeholder="item.placeholder"
|
:placeholder="item.placeholder"
|
||||||
size="mini"
|
size="mini"
|
||||||
|
clearable
|
||||||
:style="{ width: item.width }"
|
:style="{ width: item.width }"
|
||||||
@change="item.change && item.change(that, searchData[item.prop])"
|
@change="item.change && item.change(that, searchData[item.prop])"
|
||||||
>
|
>
|
||||||
@@ -37,6 +39,7 @@
|
|||||||
v-model="searchData[item.prop]"
|
v-model="searchData[item.prop]"
|
||||||
:placeholder="item.placeholder"
|
:placeholder="item.placeholder"
|
||||||
size="mini"
|
size="mini"
|
||||||
|
clearable
|
||||||
:style="{ width: item.width }"
|
:style="{ width: item.width }"
|
||||||
@change="item.change && item.change(that, searchData[item.prop])"
|
@change="item.change && item.change(that, searchData[item.prop])"
|
||||||
>
|
>
|
||||||
@@ -96,6 +99,7 @@
|
|||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
format="yyyy-MM-dd"
|
format="yyyy-MM-dd"
|
||||||
:picker-options="item.pickerOption"
|
:picker-options="item.pickerOption"
|
||||||
|
clearable
|
||||||
/>
|
/>
|
||||||
<!-- 时间 -->
|
<!-- 时间 -->
|
||||||
<el-time-select
|
<el-time-select
|
||||||
@@ -104,6 +108,7 @@
|
|||||||
:placeholder="item.placeholder"
|
:placeholder="item.placeholder"
|
||||||
type=""
|
type=""
|
||||||
:style="{ width: item.width }"
|
:style="{ width: item.width }"
|
||||||
|
clearable
|
||||||
/>
|
/>
|
||||||
<!-- 日期时间 -->
|
<!-- 日期时间 -->
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
@@ -114,12 +119,14 @@
|
|||||||
value-format="yyyy-MM-dd HH:mm:ss"
|
value-format="yyyy-MM-dd HH:mm:ss"
|
||||||
:disabled="item.disable && item.disable(searchData[item.prop])"
|
:disabled="item.disable && item.disable(searchData[item.prop])"
|
||||||
:style="{ width: item.width }"
|
:style="{ width: item.width }"
|
||||||
|
clearable
|
||||||
/>
|
/>
|
||||||
<!-- 日期时间段 -->
|
<!-- 日期时间段 -->
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-if="item.type === 'Daterange'"
|
v-if="item.type === 'Daterange'"
|
||||||
v-model="searchData[item.prop]"
|
v-model="searchData[item.prop]"
|
||||||
type="datetimerange"
|
type="datetimerange"
|
||||||
|
:default-time="['00:00:00', '23:59:59']"
|
||||||
:range-separator="$t('baseForm:daterange:rangeSeparator')"
|
:range-separator="$t('baseForm:daterange:rangeSeparator')"
|
||||||
:start-placeholder="$t('baseForm:daterange:startPlaceholder')"
|
:start-placeholder="$t('baseForm:daterange:startPlaceholder')"
|
||||||
:end-placeholder="$t('baseForm:daterange:startendPlaceholder')"
|
:end-placeholder="$t('baseForm:daterange:startendPlaceholder')"
|
||||||
|
|||||||
@@ -48,6 +48,7 @@
|
|||||||
:show-overflow-tooltip="column.showOverflowTooltip || false"
|
:show-overflow-tooltip="column.showOverflowTooltip || false"
|
||||||
:sortable="column.sortable || false"
|
:sortable="column.sortable || false"
|
||||||
:prop="column.prop"
|
:prop="column.prop"
|
||||||
|
:fixed="column.fixed"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!-- 仅仅显示文字 -->
|
<!-- 仅仅显示文字 -->
|
||||||
@@ -63,6 +64,10 @@
|
|||||||
<el-button
|
<el-button
|
||||||
:size="operate.size || 'mini'"
|
:size="operate.size || 'mini'"
|
||||||
:type="operate.type || 'primary'"
|
:type="operate.type || 'primary'"
|
||||||
|
v-if="
|
||||||
|
(operate.show && scope.row[operate.show]) ||
|
||||||
|
!operate.show
|
||||||
|
"
|
||||||
style="margin-right: 5px"
|
style="margin-right: 5px"
|
||||||
@click="handleClick(operate, scope.row)"
|
@click="handleClick(operate, scope.row)"
|
||||||
>{{ operate.name }}</el-button
|
>{{ operate.name }}</el-button
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
label-width="100px"
|
label-width="100px"
|
||||||
>
|
>
|
||||||
<!-- 邮箱 -->
|
<!-- 邮箱 -->
|
||||||
<p class="tip">
|
<p class="tip_mfa">
|
||||||
<i class="el-icon-warning" style="color: #409eff"></i>
|
<i class="el-icon-warning" style="color: #409eff"></i>
|
||||||
<span>{{ tip }}</span>
|
<span>{{ tip }}</span>
|
||||||
</p>
|
</p>
|
||||||
@@ -83,7 +83,7 @@ export default {
|
|||||||
second: 60,
|
second: 60,
|
||||||
form: {
|
form: {
|
||||||
Code: null,
|
Code: null,
|
||||||
UserId: null,
|
IdentityUserId: null,
|
||||||
EMail: null,
|
EMail: null,
|
||||||
username: null,
|
username: null,
|
||||||
},
|
},
|
||||||
@@ -115,7 +115,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
open(data) {
|
open(data) {
|
||||||
let { UserId, status, username, EMail } = data;
|
let { UserId, status, username, EMail } = data;
|
||||||
this.form.UserId = UserId;
|
this.form.IdentityUserId = UserId;
|
||||||
this.status = status ? status : "login";
|
this.status = status ? status : "login";
|
||||||
this.form.username = username;
|
this.form.username = username;
|
||||||
this.form.EMail = EMail;
|
this.form.EMail = EMail;
|
||||||
@@ -134,10 +134,10 @@ export default {
|
|||||||
let res = await verifyMFACode(this.form);
|
let res = await verifyMFACode(this.form);
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
if (this.status === "login") {
|
// if (this.status === "login") {
|
||||||
this.$message.success(this.$t("mfa:message:verifySuccess"));
|
// this.$message.success(this.$t("mfa:message:verifySuccess"));
|
||||||
}
|
// }
|
||||||
this.$emit("success", this.form.UserId);
|
this.$emit("success", this.form.IdentityUserId);
|
||||||
this.cancel();
|
this.cancel();
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
@@ -154,7 +154,7 @@ export default {
|
|||||||
this.timer = null;
|
this.timer = null;
|
||||||
}
|
}
|
||||||
let data = {
|
let data = {
|
||||||
UserId: this.form.UserId,
|
IdentityUserId: this.form.IdentityUserId,
|
||||||
};
|
};
|
||||||
if (this.status === "lock") {
|
if (this.status === "lock") {
|
||||||
data.MfaType = 1;
|
data.MfaType = 1;
|
||||||
@@ -189,7 +189,7 @@ export default {
|
|||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.tip {
|
.tip_mfa {
|
||||||
width: 86%;
|
width: 86%;
|
||||||
margin: auto;
|
margin: auto;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<div class="trialsTab">
|
<div class="trialsTab">
|
||||||
<el-tabs v-model="trialsTab" @tab-click="clickTab">
|
<el-tabs v-model="trialsTab" @tab-click="clickTab">
|
||||||
<el-tab-pane v-for="item of trialsRouter.children.find(v => {return v.name == 'TrialsPanel'}).children" :key="`tab${item.path}`" :disabled="TotalNeedSignTrialDocCount !== 0 && item.path !== '/trials/trials-panel/attachments'" :label="$t(item.LanguageMark)" :name="item.path">
|
<el-tab-pane v-for="item of trialsRouter.children.find(v => {return v.name == 'TrialsPanel'}).children" :key="`tab${item.path}`" :disabled="TotalNeedSignTrialDocCount !== 0 && item.path !== '/trials/trials-panel/attachments'" :label="$t(item.LanguageMark)" :name="item.path">
|
||||||
<el-tabs v-if="!item.tabHiddn" v-model="trialsTabChild" @tab-click="clickTab">
|
<el-tabs v-if="!item.tabHiddn" v-model="trialsTabChild" @tab-click="clickTab" style="background-color: #f5f7fa;">
|
||||||
<template v-for="item1 of item.children">
|
<template v-for="item1 of item.children">
|
||||||
<el-tab-pane
|
<el-tab-pane
|
||||||
v-if="TrialConfig && isShow(item1.path)"
|
v-if="TrialConfig && isShow(item1.path)"
|
||||||
@@ -22,11 +22,14 @@
|
|||||||
<i class="iconfont" style="font-size: 30px;color:#ccc"></i>
|
<i class="iconfont" style="font-size: 30px;color:#ccc"></i>
|
||||||
</div>
|
</div>
|
||||||
<!-- 返回项目列表 -->
|
<!-- 返回项目列表 -->
|
||||||
<div class="my_icon_box" :title="$t('trials:trials:title:backTrialList')" @click="goBack">
|
<el-button type="primary" size="small" @click="goBack">
|
||||||
<i class="iconfont"></i>
|
<i class="iconfont"></i>
|
||||||
<!-- 返回 -->
|
|
||||||
<span>{{ $t('trials:trials:title:back') }}</span>
|
<span>{{ $t('trials:trials:title:back') }}</span>
|
||||||
</div>
|
</el-button>
|
||||||
|
<!-- <div class="my_icon_box" :title="$t('trials:trials:title:backTrialList')" @click="goBack">
|
||||||
|
<i class="iconfont"></i>
|
||||||
|
<span>{{ $t('trials:trials:title:back') }}</span>
|
||||||
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -146,6 +149,7 @@ export default {
|
|||||||
return isShow
|
return isShow
|
||||||
},
|
},
|
||||||
goBack() {
|
goBack() {
|
||||||
|
zzSessionStorage.removeItem('lastWorkbench')
|
||||||
this.$router.push({ path: '/trials/trials-list' })
|
this.$router.push({ path: '/trials/trials-list' })
|
||||||
},
|
},
|
||||||
selectTrials(v) {
|
selectTrials(v) {
|
||||||
@@ -221,6 +225,9 @@ export default {
|
|||||||
.el-tabs__header{
|
.el-tabs__header{
|
||||||
margin-bottom: 3px;
|
margin-bottom: 3px;
|
||||||
}
|
}
|
||||||
|
.el-tabs__item.is-active{
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
position: relative;
|
position: relative;
|
||||||
.el-input--medium .el-input__inner{
|
.el-input--medium .el-input__inner{
|
||||||
height: 44px;line-height: 44px;width: 280px;
|
height: 44px;line-height: 44px;width: 280px;
|
||||||
|
|||||||
@@ -0,0 +1,126 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog
|
||||||
|
v-if="visible"
|
||||||
|
:visible.sync="visible"
|
||||||
|
v-dialogDrag
|
||||||
|
width="540px"
|
||||||
|
:close-on-click-modal="false"
|
||||||
|
:close-on-press-escape="false"
|
||||||
|
append-to-body
|
||||||
|
:title="$t('toggleRole:tip:title')"
|
||||||
|
center
|
||||||
|
top="30vh"
|
||||||
|
:show-close="false"
|
||||||
|
:before-close="cancel"
|
||||||
|
>
|
||||||
|
<template v-if="hasRole">
|
||||||
|
<el-radio-group v-model="form.userRoleId" class="roles">
|
||||||
|
<el-radio
|
||||||
|
v-for="item in roles"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="item.Id"
|
||||||
|
:disabled="item.IsUserRoleDisabled"
|
||||||
|
style="margin-bottom: 10px"
|
||||||
|
>
|
||||||
|
{{ item.UserTypeShortName }}
|
||||||
|
</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<div v-else style="text-align: center">
|
||||||
|
{{ $t('toggleRole:tip:noRole') }}
|
||||||
|
</div>
|
||||||
|
<div slot="footer">
|
||||||
|
<!-- 取消 -->
|
||||||
|
<el-button size="small" @click="cancel()">
|
||||||
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
<!-- 保存 -->
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
size="small"
|
||||||
|
@click="save"
|
||||||
|
:disabled="saveDisabled"
|
||||||
|
:loading="loading"
|
||||||
|
v-if="hasRole"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:confirm') }}
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'toggleRole',
|
||||||
|
props: {
|
||||||
|
visible: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
loading: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {
|
||||||
|
userRoleId: null,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.form.userRoleId = zzSessionStorage.getItem('userId')
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
roles() {
|
||||||
|
return this.$store.state.user.roles
|
||||||
|
},
|
||||||
|
hasRole() {
|
||||||
|
return this.roles && this.roles.length > 0
|
||||||
|
},
|
||||||
|
saveDisabled() {
|
||||||
|
return this.form.userRoleId === zzSessionStorage.getItem('userId')
|
||||||
|
},
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
cancel() {
|
||||||
|
this.$emit('update:visible', false)
|
||||||
|
this.$emit('cancel')
|
||||||
|
},
|
||||||
|
async save() {
|
||||||
|
try {
|
||||||
|
if (!this.form.userRoleId)
|
||||||
|
return this.$message.warning(this.$t('toggleRole:ruleMessage:select'))
|
||||||
|
zzSessionStorage.removeItem('lastWorkbench')
|
||||||
|
this.$emit('save', this.form.userRoleId)
|
||||||
|
} catch (err) {
|
||||||
|
console.log(err)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.roles {
|
||||||
|
max-width: 365px;
|
||||||
|
width: fit-content;
|
||||||
|
display: flex;
|
||||||
|
align-content: center;
|
||||||
|
// justify-content: center;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .el-radio__original {
|
||||||
|
display: none !important; /* 隐藏原生 radio 输入,但仍然允许交互 */
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/.el-radio:focus:not(.is-focus):not(:active):not(.is-disabled)
|
||||||
|
.el-radio__inner {
|
||||||
|
box-shadow: none !important;
|
||||||
|
}
|
||||||
|
.el-radio {
|
||||||
|
width: 60px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,6 +1,5 @@
|
|||||||
import { SubjectCheckConfig } from './module/Subject'
|
import { SubjectCheckConfig } from './module/Subject'
|
||||||
|
|
||||||
console.log(SubjectCheckConfig.moduleType)
|
|
||||||
export const checkConfig = {
|
export const checkConfig = {
|
||||||
ModuleType: {
|
ModuleType: {
|
||||||
...SubjectCheckConfig.ModuleType
|
...SubjectCheckConfig.ModuleType
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ const dialogDrag = Vue.directive('dialogDrag', {
|
|||||||
dragDom.style.cssText += ';top:0px;'
|
dragDom.style.cssText += ';top:0px;'
|
||||||
|
|
||||||
// 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
|
// 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
|
||||||
const sty = (function() {
|
const sty = (function () {
|
||||||
if (window.document.currentStyle) {
|
if (window.document.currentStyle) {
|
||||||
return (dom, attr) => dom.currentStyle[attr]
|
return (dom, attr) => dom.currentStyle[attr]
|
||||||
} else {
|
} else {
|
||||||
@@ -47,8 +47,10 @@ const dialogDrag = Vue.directive('dialogDrag', {
|
|||||||
styL = +styL.replace(/\px/g, '')
|
styL = +styL.replace(/\px/g, '')
|
||||||
styT = +styT.replace(/\px/g, '')
|
styT = +styT.replace(/\px/g, '')
|
||||||
}
|
}
|
||||||
|
const oldMousemove = document.onmousemove
|
||||||
|
|
||||||
document.onmousemove = function(e) {
|
document.onmousemove = function (e) {
|
||||||
|
oldMousemove(e)
|
||||||
// 通过事件委托,计算移动的距离
|
// 通过事件委托,计算移动的距离
|
||||||
let left = e.clientX - disX
|
let left = e.clientX - disX
|
||||||
const top = e.clientY - disY
|
const top = e.clientY - disY
|
||||||
@@ -70,8 +72,8 @@ const dialogDrag = Vue.directive('dialogDrag', {
|
|||||||
dragDom.style.cssText += `;left:${left + styL}px;top:${top + styT}px;`
|
dragDom.style.cssText += `;left:${left + styL}px;top:${top + styT}px;`
|
||||||
}
|
}
|
||||||
|
|
||||||
document.onmouseup = function(e) {
|
document.onmouseup = function (e) {
|
||||||
document.onmousemove = null
|
document.onmousemove = oldMousemove
|
||||||
document.onmouseup = null
|
document.onmouseup = null
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,13 +14,13 @@
|
|||||||
|
|
||||||
<div class="right-menu">
|
<div class="right-menu">
|
||||||
<div class="navbar-flex-wrapper">
|
<div class="navbar-flex-wrapper">
|
||||||
<template v-if="device!=='mobile'">
|
<template v-if="device !== 'mobile'">
|
||||||
<screenfull id="screenfull" class="right-menu-item hover-effect" />
|
<screenfull id="screenfull" class="right-menu-item hover-effect" />
|
||||||
</template>
|
</template>
|
||||||
<!-- <div class="avatar-container">
|
<!-- <div class="avatar-container">
|
||||||
<img src="@/assets/avatar.png" class="user-avatar">
|
<img src="@/assets/avatar.png" class="user-avatar">
|
||||||
</div> -->
|
</div> -->
|
||||||
<div style="margin-left:20px;">
|
<div style="margin-left: 20px">
|
||||||
<el-dropdown class="dropdown-container" trigger="click">
|
<el-dropdown class="dropdown-container" trigger="click">
|
||||||
<span class="el-dropdown-link">
|
<span class="el-dropdown-link">
|
||||||
{{ `${name} (${userTypeShortName})` }}
|
{{ `${name} (${userTypeShortName})` }}
|
||||||
@@ -30,10 +30,20 @@
|
|||||||
</span>
|
</span>
|
||||||
<el-dropdown-menu slot="dropdown" class="user-dropdown">
|
<el-dropdown-menu slot="dropdown" class="user-dropdown">
|
||||||
<el-dropdown-item v-if="!isReviewer">
|
<el-dropdown-item v-if="!isReviewer">
|
||||||
<span style="display:block;" @click="editInfo">{{$t('system:navbar:button:Profile')}}</span>
|
<span style="display: block" @click="editInfo">{{
|
||||||
|
$t('system:navbar:button:Profile')
|
||||||
|
}}</span>
|
||||||
|
</el-dropdown-item>
|
||||||
|
<!-- 切换角色 -->
|
||||||
|
<el-dropdown-item divided v-if="hasRole">
|
||||||
|
<span style="display: block" @click="openToggleRole">{{
|
||||||
|
$t('system:navbar:button:toggleRole')
|
||||||
|
}}</span>
|
||||||
</el-dropdown-item>
|
</el-dropdown-item>
|
||||||
<el-dropdown-item divided>
|
<el-dropdown-item divided>
|
||||||
<span style="display:block;" @click="logout">{{$t('system:navbar:button:Log Out')}}</span>
|
<span style="display: block" @click="logout">{{
|
||||||
|
$t('system:navbar:button:Log Out')
|
||||||
|
}}</span>
|
||||||
</el-dropdown-item>
|
</el-dropdown-item>
|
||||||
</el-dropdown-menu>
|
</el-dropdown-menu>
|
||||||
</el-dropdown>
|
</el-dropdown>
|
||||||
@@ -41,38 +51,119 @@
|
|||||||
<TopLang></TopLang>
|
<TopLang></TopLang>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<toggleRole
|
||||||
|
v-if="toggleRoleVisible"
|
||||||
|
:visible.sync="toggleRoleVisible"
|
||||||
|
:loading="toggleRoleLoading"
|
||||||
|
@save="loginByRole"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {mapGetters, mapMutations} from 'vuex'
|
import { mapGetters, mapMutations } from 'vuex'
|
||||||
import Breadcrumb from '@/components/Breadcrumb'
|
import Breadcrumb from '@/components/Breadcrumb'
|
||||||
import Hamburger from '@/components/Hamburger'
|
import Hamburger from '@/components/Hamburger'
|
||||||
import Screenfull from '@/components/Screenfull'
|
import Screenfull from '@/components/Screenfull'
|
||||||
import TopLang from './topLang'
|
import TopLang from './topLang'
|
||||||
|
import toggleRole from '@/components/toggleRole'
|
||||||
|
import { resetRouter } from '@/router'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
Breadcrumb,
|
Breadcrumb,
|
||||||
Hamburger,
|
Hamburger,
|
||||||
Screenfull,
|
Screenfull,
|
||||||
TopLang
|
TopLang,
|
||||||
|
toggleRole,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
isReviewer: false,
|
isReviewer: false,
|
||||||
userTypeShortName: zzSessionStorage.getItem('userTypeShortName')
|
toggleRoleVisible: false,
|
||||||
|
toggleRoleLoading: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters(['sidebar', 'name', 'device'])
|
...mapGetters(['sidebar', 'name', 'device', 'userTypeShortName']),
|
||||||
|
roles() {
|
||||||
|
return this.$store.state.user.roles
|
||||||
|
},
|
||||||
|
hasRole() {
|
||||||
|
return this.roles && this.roles.length > 1
|
||||||
|
},
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.isReviewer = JSON.parse(zzSessionStorage.getItem('IsReviewer'))
|
// this.isReviewer = JSON.parse(zzSessionStorage.getItem('IsReviewer'))
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
||||||
|
openToggleRole() {
|
||||||
|
this.$store.dispatch('user/getUserInfo').then((res) => {
|
||||||
|
this.toggleRoleVisible = true
|
||||||
|
})
|
||||||
|
},
|
||||||
|
loginByRole(userRoleId) {
|
||||||
|
if (this.$store.state.user.userId === userRoleId) {
|
||||||
|
this.toggleRoleVisible = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
this.toggleRoleLoading = true
|
||||||
|
this.$store
|
||||||
|
.dispatch('user/loginByRole', { userRoleId })
|
||||||
|
.then((res) => {
|
||||||
|
if (res) {
|
||||||
|
this.$store
|
||||||
|
.dispatch('permission/generateRoutes')
|
||||||
|
.then(async (res) => {
|
||||||
|
if (res && res.length > 0) {
|
||||||
|
resetRouter()
|
||||||
|
await this.$store.dispatch('global/getNoticeList')
|
||||||
|
this.$router.addRoutes(res)
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
if (this.loginType === 'DevOps') {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.hasPermi(['role:radmin'])) {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (
|
||||||
|
this.hasPermi([
|
||||||
|
'role:air',
|
||||||
|
'role:rpm',
|
||||||
|
'role:rcrc',
|
||||||
|
'role:rir',
|
||||||
|
])
|
||||||
|
) {
|
||||||
|
history.replaceState(null, null, '/trials/trials-list')
|
||||||
|
history.go(0)
|
||||||
|
} else {
|
||||||
|
history.replaceState(null, null, '/trials/trials-workbench')
|
||||||
|
history.go(0)
|
||||||
|
}
|
||||||
|
this.toggleRoleVisible = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
this.$EventBus.$emit('reload')
|
||||||
|
} else {
|
||||||
|
// 此账户暂未配置菜单权限,请联系管理员处理后再登录。
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
this.$message.warning(this.$t('login:message:login2'))
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((err) => {
|
||||||
|
console.log(err)
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
toggleSideBar() {
|
toggleSideBar() {
|
||||||
this.$store.dispatch('app/toggleSideBar')
|
this.$store.dispatch('app/toggleSideBar')
|
||||||
},
|
},
|
||||||
@@ -84,23 +175,23 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
}
|
}
|
||||||
this.$i18n.locale = 'zh'
|
// //this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
// //this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
editInfo() {
|
editInfo() {
|
||||||
this.$router.push({ name: 'BaiscInfo' })
|
this.$router.push({ name: 'BaiscInfo' })
|
||||||
},
|
},
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.navbar-flex-wrapper{
|
.navbar-flex-wrapper {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
.navbar {
|
.navbar {
|
||||||
height: 50px;
|
height: 50px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|||||||
+8
-3
@@ -174,7 +174,7 @@ var _vm
|
|||||||
async function VueInit() {
|
async function VueInit() {
|
||||||
var params
|
var params
|
||||||
var res
|
var res
|
||||||
if (~window.location.href.indexOf('/readingDicoms') || ~window.location.href.indexOf('/noneDicomReading') || ~window.location.href.indexOf('/criterionquestions') || ~window.location.href.indexOf('/petct')) {
|
if (~window.location.href.indexOf('/readingDicoms') || ~window.location.href.indexOf('/noneDicomReading') || ~window.location.href.indexOf('/criterionquestions') || ~window.location.href.indexOf('/petct') || ~window.location.href.indexOf('/fusion')) {
|
||||||
params = $q('TrialReadingCriterionId')
|
params = $q('TrialReadingCriterionId')
|
||||||
res = await getBasicDataAllSelect(params)
|
res = await getBasicDataAllSelect(params)
|
||||||
} else if (~window.location.href.indexOf('/ecrfPreview')) {
|
} else if (~window.location.href.indexOf('/ecrfPreview')) {
|
||||||
@@ -293,6 +293,7 @@ async function VueInit() {
|
|||||||
}()
|
}()
|
||||||
_vm.$forceUpdate()
|
_vm.$forceUpdate()
|
||||||
}
|
}
|
||||||
|
Vue.prototype.$EventBus = new Vue()
|
||||||
Vue.prototype.$path = []
|
Vue.prototype.$path = []
|
||||||
var t = function (key) {
|
var t = function (key) {
|
||||||
if (!~Vue.prototype.$path.indexOf(key)) {
|
if (!~Vue.prototype.$path.indexOf(key)) {
|
||||||
@@ -402,8 +403,12 @@ async function VueInit() {
|
|||||||
}
|
}
|
||||||
_vm.$store.dispatch('user/logout').then(res => {
|
_vm.$store.dispatch('user/logout').then(res => {
|
||||||
// window.location.href = `/login`
|
// window.location.href = `/login`
|
||||||
if (_vm.$msgbox) {
|
try {
|
||||||
_vm.$msgbox.close();
|
if (_vm.$msgbox && _vm.$msgbox.close) {
|
||||||
|
_vm.$msgbox.close();
|
||||||
|
}
|
||||||
|
} catch (err) {
|
||||||
|
console.log(err)
|
||||||
}
|
}
|
||||||
_vm.$FB.close();
|
_vm.$FB.close();
|
||||||
_vm.$FBT.close();
|
_vm.$FBT.close();
|
||||||
|
|||||||
+21
-5
@@ -1,9 +1,10 @@
|
|||||||
import router from './router'
|
import router from './router'
|
||||||
|
import { resetRouter } from '@/router'
|
||||||
import store from './store'
|
import store from './store'
|
||||||
// import { Message } from 'element-ui'
|
// import { Message } from 'element-ui'
|
||||||
import NProgress from 'nprogress'
|
import NProgress from 'nprogress'
|
||||||
import 'nprogress/nprogress.css'
|
import 'nprogress/nprogress.css'
|
||||||
import { getToken } from '@/utils/auth'
|
import { getToken, removeToken } from '@/utils/auth'
|
||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import { OSSclient } from './utils/oss'
|
import { OSSclient } from './utils/oss'
|
||||||
import WHITELIST from "./utils/whiteList"
|
import WHITELIST from "./utils/whiteList"
|
||||||
@@ -26,7 +27,6 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
to.query.trialId !==
|
to.query.trialId !==
|
||||||
store.state.trials.config.trialId
|
store.state.trials.config.trialId
|
||||||
) {
|
) {
|
||||||
console.log(to.query.path)
|
|
||||||
let res = await getTrialExtralConfig({
|
let res = await getTrialExtralConfig({
|
||||||
TrialId: to.query.trialId,
|
TrialId: to.query.trialId,
|
||||||
})
|
})
|
||||||
@@ -70,6 +70,16 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
}
|
}
|
||||||
next()
|
next()
|
||||||
NProgress.done()
|
NProgress.done()
|
||||||
|
} else if (from.path === '/researchForm') {
|
||||||
|
removeToken()
|
||||||
|
let lang = to.query.lang || zzSessionStorage.getItem('lang')
|
||||||
|
next(`/researchLogin?trialId=${to.query.trialId}&lang=${lang}`)
|
||||||
|
NProgress.done()
|
||||||
|
} else if (from.path === '/researchDetail_m') {
|
||||||
|
removeToken()
|
||||||
|
let lang = to.query.lang || zzSessionStorage.getItem('lang')
|
||||||
|
next(`/researchLogin_m?trialId=${to.query.trialId}&lang=${lang}`)
|
||||||
|
NProgress.done()
|
||||||
} else {
|
} else {
|
||||||
await OSSclient()
|
await OSSclient()
|
||||||
const hasGetUserInfo = store.getters.userId
|
const hasGetUserInfo = store.getters.userId
|
||||||
@@ -79,10 +89,13 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
try {
|
try {
|
||||||
// 获取用户信息
|
// 获取用户信息
|
||||||
await store.dispatch('user/getInfo')
|
await store.dispatch('user/getInfo')
|
||||||
|
await store.dispatch('user/getUserInfo')
|
||||||
const accessRoutes = await store.dispatch('permission/generateRoutes')
|
const accessRoutes = await store.dispatch('permission/generateRoutes')
|
||||||
|
resetRouter()
|
||||||
router.addRoutes(accessRoutes)
|
router.addRoutes(accessRoutes)
|
||||||
next({ ...to, replace: true })
|
next({ ...to, replace: true })
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
console.log(error)
|
||||||
// 删除token并进入登录页面以重新登录
|
// 删除token并进入登录页面以重新登录
|
||||||
await store.dispatch('user/resetToken')
|
await store.dispatch('user/resetToken')
|
||||||
next(`/login?redirect=${to.path}`)
|
next(`/login?redirect=${to.path}`)
|
||||||
@@ -94,9 +107,10 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
/* has no token*/
|
/* has no token*/
|
||||||
if (whiteList.indexOf(to.path) !== -1) {
|
if (whiteList.indexOf(to.path) !== -1) {
|
||||||
if (to.path === '/researchLogin') {
|
if (to.path === '/researchLogin') {
|
||||||
|
let lang = to.query.lang || zzSessionStorage.getItem('lang')
|
||||||
const flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)
|
const flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)
|
||||||
if (flag) {
|
if (flag) {
|
||||||
next(`/researchLogin_m?trialId=${to.query.trialId}&lang=${to.query.lang}`)
|
next(`/researchLogin_m?trialId=${to.query.trialId}&lang=${lang}`)
|
||||||
} else {
|
} else {
|
||||||
next()
|
next()
|
||||||
}
|
}
|
||||||
@@ -109,10 +123,12 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (to.path === '/researchForm') {
|
if (to.path === '/researchForm') {
|
||||||
next(`/researchLogin?`)
|
let lang = to.query.lang || zzSessionStorage.getItem('lang')
|
||||||
|
next(`/researchLogin?trialId=${to.query.trialId}&lang=${lang}`)
|
||||||
NProgress.done()
|
NProgress.done()
|
||||||
} else if (to.path === '/researchDetail_m') {
|
} else if (to.path === '/researchDetail_m') {
|
||||||
next(`/researchLogin_m?`)
|
let lang = to.query.lang || zzSessionStorage.getItem('lang')
|
||||||
|
next(`/researchLogin_m?trialId=${to.query.trialId}&lang=${lang}`)
|
||||||
NProgress.done()
|
NProgress.done()
|
||||||
} else if (to.path === '/ReviewersResearchForm') {
|
} else if (to.path === '/ReviewersResearchForm') {
|
||||||
next(`/ReviewersResearch?`)
|
next(`/ReviewersResearch?`)
|
||||||
|
|||||||
@@ -139,6 +139,12 @@ export const constantRoutes = [
|
|||||||
hidden: true,
|
hidden: true,
|
||||||
component: () => import('@/views/trials/trials-panel/reading/dicoms/components/Fusion/PetCt')
|
component: () => import('@/views/trials/trials-panel/reading/dicoms/components/Fusion/PetCt')
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/fusion',
|
||||||
|
name: 'fusion',
|
||||||
|
hidden: true,
|
||||||
|
component: () => import('@/views/trials/trials-panel/reading/dicoms/components/Fusion/demo/index')
|
||||||
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
path: '/historyScreenshot',
|
path: '/historyScreenshot',
|
||||||
|
|||||||
@@ -3,10 +3,12 @@ const getters = {
|
|||||||
device: state => state.app.device,
|
device: state => state.app.device,
|
||||||
token: state => state.user.token,
|
token: state => state.user.token,
|
||||||
name: state => state.user.name,
|
name: state => state.user.name,
|
||||||
|
userTypeShortName: state => state.user.userTypeShortName,
|
||||||
permissions: state => state.user.permissions,
|
permissions: state => state.user.permissions,
|
||||||
tree: state => state.user.tree,
|
tree: state => state.user.tree,
|
||||||
userName: state => state.user.userName,
|
userName: state => state.user.userName,
|
||||||
userId: state => state.user.userId,
|
userId: state => state.user.userId,
|
||||||
|
identityUserId: state => state.user.identityUserId,
|
||||||
routes: state => state.permission.routes,
|
routes: state => state.permission.routes,
|
||||||
asyncRoutes: state => state.permission.addRoutes,
|
asyncRoutes: state => state.permission.addRoutes,
|
||||||
visitedViews: state => state.tagsView.visitedViews,
|
visitedViews: state => state.tagsView.visitedViews,
|
||||||
@@ -45,6 +47,7 @@ const getters = {
|
|||||||
language: state => state.lang.language,
|
language: state => state.lang.language,
|
||||||
TotalNeedSignSystemDocCount: state => state.user.TotalNeedSignSystemDocCount,
|
TotalNeedSignSystemDocCount: state => state.user.TotalNeedSignSystemDocCount,
|
||||||
TotalNeedSignTrialDocCount: state => state.user.TotalNeedSignTrialDocCount,
|
TotalNeedSignTrialDocCount: state => state.user.TotalNeedSignTrialDocCount,
|
||||||
|
IsFirstSysDocNeedSign: state => state.user.IsFirstSysDocNeedSign,
|
||||||
TrialStatusStr: state => state.user.TrialStatusStr
|
TrialStatusStr: state => state.user.TrialStatusStr
|
||||||
}
|
}
|
||||||
export default getters
|
export default getters
|
||||||
|
|||||||
@@ -70,6 +70,12 @@ function getQuestions(questions) {
|
|||||||
answerObj.angle = angle
|
answerObj.angle = angle
|
||||||
answerObj.saveTypeEnum = isNaN(parseFloat(angle)) ? 1 : 2
|
answerObj.saveTypeEnum = isNaN(parseFloat(angle)) ? 1 : 2
|
||||||
}
|
}
|
||||||
|
} else if (criterionType === 21) {
|
||||||
|
// MRI-PDFF
|
||||||
|
let isMeasurable = getQuestionAnswer(item.TableQuestions.Questions, 1105, answerObj)
|
||||||
|
answerObj.isMeasurable = isMeasurable
|
||||||
|
answerObj.mean = getQuestionAnswer(item.TableQuestions.Questions, 1104, answerObj)
|
||||||
|
answerObj.saveTypeEnum = parseInt(isMeasurable) === 1 && isNaN(parseFloat(answerObj.mean)) ? 1 : 2
|
||||||
} else {
|
} else {
|
||||||
answerObj.lesionPart = getQuestionAnswer(item.TableQuestions.Questions, 8, answerObj)
|
answerObj.lesionPart = getQuestionAnswer(item.TableQuestions.Questions, 8, answerObj)
|
||||||
answerObj.loctation = getQuestionAnswer(item.TableQuestions.Questions, 6, answerObj)
|
answerObj.loctation = getQuestionAnswer(item.TableQuestions.Questions, 6, answerObj)
|
||||||
@@ -507,6 +513,7 @@ const actions = {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
getMeasuredData({ state }, visitTaskId) {
|
getMeasuredData({ state }, visitTaskId) {
|
||||||
|
console.log('getMeasuredData')
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === visitTaskId)
|
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === visitTaskId)
|
||||||
if (state.visitTaskList[index].measureDataInit) {
|
if (state.visitTaskList[index].measureDataInit) {
|
||||||
@@ -523,6 +530,13 @@ const actions = {
|
|||||||
el.OtherMeasureData = JSON.parse(el.OtherMeasureData)
|
el.OtherMeasureData = JSON.parse(el.OtherMeasureData)
|
||||||
el.OtherMeasureData.data.remark = el.OrderMarkName
|
el.OtherMeasureData.data.remark = el.OrderMarkName
|
||||||
}
|
}
|
||||||
|
// if (el.TableQuestionMarkList.length > 0) {
|
||||||
|
// let list = el.TableQuestionMarkList.map(i=>{
|
||||||
|
// i.MeasureData = i.MeasureData ? JSON.parse(i.MeasureData) : ''
|
||||||
|
// return i
|
||||||
|
// })
|
||||||
|
// el.TableQuestionMarkList = list
|
||||||
|
// }
|
||||||
arr.push(el)
|
arr.push(el)
|
||||||
})
|
})
|
||||||
state.visitTaskList[index].MeasureData = arr
|
state.visitTaskList[index].MeasureData = arr
|
||||||
@@ -606,6 +620,13 @@ const actions = {
|
|||||||
el.MeasureData = JSON.parse(el.MeasureData)
|
el.MeasureData = JSON.parse(el.MeasureData)
|
||||||
el.MeasureData.data.remark = el.OrderMarkName
|
el.MeasureData.data.remark = el.OrderMarkName
|
||||||
}
|
}
|
||||||
|
// if (el.TableQuestionMarkList.length > 0) {
|
||||||
|
// let list = el.TableQuestionMarkList.map(i=>{
|
||||||
|
// i.MeasureData = i.MeasureData ? JSON.parse(i.MeasureData) : ''
|
||||||
|
// return i
|
||||||
|
// })
|
||||||
|
// el.TableQuestionMarkList = list
|
||||||
|
// }
|
||||||
arr.push(el)
|
arr.push(el)
|
||||||
})
|
})
|
||||||
state.visitTaskList[index].MeasureData = arr
|
state.visitTaskList[index].MeasureData = arr
|
||||||
@@ -623,27 +644,40 @@ const actions = {
|
|||||||
resolve(noneDicomMeasureData)
|
resolve(noneDicomMeasureData)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
addMeasuredData({ state }, obj) {
|
addMeasuredData({ state }, obj) {
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
|
const criterionType = parseInt(localStorage.getItem('CriterionType'))
|
||||||
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
||||||
var measureData = state.visitTaskList[index].MeasureData
|
var measureData = state.visitTaskList[index].MeasureData
|
||||||
// var idx = measureData.findIndex(item => item.MeasureData.uuid === obj.data.MeasureData.data.uuid)
|
// var idx = measureData.findIndex(item => item.MeasureData.uuid === obj.data.MeasureData.data.uuid)
|
||||||
var idx = measureData.findIndex(item => item.QuestionId === obj.data.QuestionId && item.RowIndex === obj.data.RowIndex)
|
|
||||||
if (idx > -1) {
|
if (criterionType === 21) {
|
||||||
for (const k in state.visitTaskList[index].MeasureData[idx]) {
|
let i = measureData.findIndex(i=>i.TableQuestionId === obj.data.TableQuestionId)
|
||||||
if (k !== 'Id' && obj.data[k]) {
|
if (i > -1) {
|
||||||
state.visitTaskList[index].MeasureData[idx][k] = obj.data[k]
|
for (const k in state.visitTaskList[index].MeasureData[i]) {
|
||||||
|
if (k !== 'Id' && obj.data[k]) {
|
||||||
|
state.visitTaskList[index].MeasureData[i][k] = obj.data[k]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
state.visitTaskList[index].MeasureData.push(obj.data)
|
||||||
}
|
}
|
||||||
|
|
||||||
// state.visitTaskList[index].MeasureData[idx].MeasureData = obj.data.MeasureData
|
|
||||||
console.log('更新标记成功', idx)
|
|
||||||
} else {
|
} else {
|
||||||
state.visitTaskList[index].MeasureData.push(obj.data)
|
var idx = measureData.findIndex(item => item.QuestionId === obj.data.QuestionId && item.RowIndex === obj.data.RowIndex)
|
||||||
console.log('新增标记成功')
|
if (idx > -1) {
|
||||||
|
for (const k in state.visitTaskList[index].MeasureData[idx]) {
|
||||||
|
if (k !== 'Id' && obj.data[k]) {
|
||||||
|
state.visitTaskList[index].MeasureData[idx][k] = obj.data[k]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
console.log('更新标记成功', idx)
|
||||||
|
} else {
|
||||||
|
state.visitTaskList[index].MeasureData.push(obj.data)
|
||||||
|
console.log('新增标记成功')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// sessionStorage.setItem('visitTaskList', state.visitTaskList.length > 0 ? JSON.stringify(state.visitTaskList) : '')
|
// sessionStorage.setItem('visitTaskList', state.visitTaskList.length > 0 ? JSON.stringify(state.visitTaskList) : '')
|
||||||
console.log(state.visitTaskList)
|
|
||||||
resolve()
|
resolve()
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@@ -738,32 +772,45 @@ const actions = {
|
|||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
||||||
var measureData = state.visitTaskList[index].MeasureData
|
var measureData = state.visitTaskList[index].MeasureData
|
||||||
|
const criterionType = parseInt(localStorage.getItem('CriterionType'))
|
||||||
// var uuid = obj.measureData.data.uuid
|
if (criterionType === 21) {
|
||||||
// var idx = measureData.findIndex(item => item.MeasureData && item.MeasureData.data && item.MeasureData.data.uuid === uuid)
|
|
||||||
var idx = measureData.findIndex(item => item.QuestionId === obj.questionId && item.RowIndex === obj.rowIndex)
|
|
||||||
if (idx > -1) {
|
|
||||||
if (measureData[idx].FristAddTaskId) {
|
|
||||||
measureData[idx].MeasureData = ''
|
|
||||||
console.log('清除标记成功', idx)
|
|
||||||
} else {
|
|
||||||
measureData.splice(idx, 1)
|
|
||||||
console.log('移除标记成功', idx)
|
|
||||||
}
|
|
||||||
state.visitTaskList[index].MeasureData = measureData
|
|
||||||
} else if (obj.orderMarkName) {
|
|
||||||
const i = measureData.findIndex(item => item.QuestionId === obj.questionId && item.OrderMarkName === obj.orderMarkName)
|
const i = measureData.findIndex(item => item.QuestionId === obj.questionId && item.OrderMarkName === obj.orderMarkName)
|
||||||
if (i > -1) {
|
if (i > -1) {
|
||||||
if (measureData[i].FristAddTaskId) {
|
if (measureData[i].FristAddTaskId) {
|
||||||
measureData[i].MeasureData = ''
|
measureData[i].MeasureData = ''
|
||||||
console.log('清除标记成功', i)
|
console.log('清除标记成功', i)
|
||||||
} else {
|
} else {
|
||||||
measureData.splice(i, 1)
|
measureData.splice(i, 1)
|
||||||
console.log('移除标记成功', i)
|
console.log('移除标记成功', i)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
state.visitTaskList[index].MeasureData = measureData
|
state.visitTaskList[index].MeasureData = measureData
|
||||||
|
} else {
|
||||||
|
var idx = measureData.findIndex(item => item.QuestionId === obj.questionId && item.RowIndex === obj.rowIndex)
|
||||||
|
if (idx > -1) {
|
||||||
|
if (measureData[idx].FristAddTaskId) {
|
||||||
|
measureData[idx].MeasureData = ''
|
||||||
|
console.log('清除标记成功', idx)
|
||||||
|
} else {
|
||||||
|
measureData.splice(idx, 1)
|
||||||
|
console.log('移除标记成功', idx)
|
||||||
|
}
|
||||||
|
state.visitTaskList[index].MeasureData = measureData
|
||||||
|
} else if (obj.orderMarkName) {
|
||||||
|
const i = measureData.findIndex(item => item.QuestionId === obj.questionId && item.OrderMarkName === obj.orderMarkName)
|
||||||
|
if (i > -1) {
|
||||||
|
if (measureData[i].FristAddTaskId) {
|
||||||
|
measureData[i].MeasureData = ''
|
||||||
|
console.log('清除标记成功', i)
|
||||||
|
} else {
|
||||||
|
measureData.splice(i, 1)
|
||||||
|
console.log('移除标记成功', i)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
state.visitTaskList[index].MeasureData = measureData
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// if (idx > -1) {
|
// if (idx > -1) {
|
||||||
// measureData.splice(idx, 1)
|
// measureData.splice(idx, 1)
|
||||||
|
|
||||||
@@ -840,6 +887,12 @@ const actions = {
|
|||||||
const imageId = `wadouri:${localStorage.getItem('location') !== 'USA' ? Vue.prototype.OSSclientConfig.basePath : Vue.prototype.OSSclientConfig.basePath}${instance.Path}?frame=${i}&instanceId=${instance.Id}&visitTaskId=${obj.visitTaskId}&idx=${studyIndex}|${seriesIndex}|${index}`
|
const imageId = `wadouri:${localStorage.getItem('location') !== 'USA' ? Vue.prototype.OSSclientConfig.basePath : Vue.prototype.OSSclientConfig.basePath}${instance.Path}?frame=${i}&instanceId=${instance.Id}&visitTaskId=${obj.visitTaskId}&idx=${studyIndex}|${seriesIndex}|${index}`
|
||||||
imageIds.push(imageId)
|
imageIds.push(imageId)
|
||||||
})
|
})
|
||||||
|
} else if (study.IsCriticalSequence && instance.KeyFramesList.length === 0) {
|
||||||
|
// 兼容保存标记数据未存NumberOfFrames的情况,按序列展示
|
||||||
|
for (let i = 0; i < instance.NumberOfFrames; i++) {
|
||||||
|
const imageId = `wadouri:${localStorage.getItem('location') !== 'USA' ? Vue.prototype.OSSclientConfig.basePath : Vue.prototype.OSSclientConfig.basePath}${instance.Path}?frame=${i}&instanceId=${instance.Id}&visitTaskId=${obj.visitTaskId}&idx=${studyIndex}|${seriesIndex}|${index}`
|
||||||
|
imageIds.push(imageId)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
for (let i = 0; i < instance.NumberOfFrames; i++) {
|
for (let i = 0; i < instance.NumberOfFrames; i++) {
|
||||||
const imageId = `wadouri:${localStorage.getItem('location') !== 'USA' ? Vue.prototype.OSSclientConfig.basePath : Vue.prototype.OSSclientConfig.basePath}${instance.Path}?frame=${i}&instanceId=${instance.Id}&visitTaskId=${obj.visitTaskId}&idx=${studyIndex}|${seriesIndex}|${index}`
|
const imageId = `wadouri:${localStorage.getItem('location') !== 'USA' ? Vue.prototype.OSSclientConfig.basePath : Vue.prototype.OSSclientConfig.basePath}${instance.Path}?frame=${i}&instanceId=${instance.Id}&visitTaskId=${obj.visitTaskId}&idx=${studyIndex}|${seriesIndex}|${index}`
|
||||||
@@ -1034,7 +1087,7 @@ const actions = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
setImageloadedInfo({ state }, obj) {
|
setImageloadedInfo({ state }, obj) {
|
||||||
console.log('setImageloadedInfo', obj)
|
// console.log('setImageloadedInfo', obj)
|
||||||
// if(obj.instance === '20dd8fc9-51b0-ec63-942b-cb3006c72650')
|
// if(obj.instance === '20dd8fc9-51b0-ec63-942b-cb3006c72650')
|
||||||
// var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
// var index = state.visitTaskList.findIndex(i => i.VisitTaskId === obj.visitTaskId)
|
||||||
// // const prefetchInstanceCount = state.visitTaskList[index].StudyList[obj.studyIndex].SeriesList[obj.seriesIndex].prefetchInstanceCount
|
// // const prefetchInstanceCount = state.visitTaskList[index].StudyList[obj.studyIndex].SeriesList[obj.seriesIndex].prefetchInstanceCount
|
||||||
|
|||||||
+131
-25
@@ -1,5 +1,6 @@
|
|||||||
import { getToken, setToken, removeToken, setName, removeName } from '@/utils/auth'
|
import { getToken, setToken, removeToken, setName, removeName } from '@/utils/auth'
|
||||||
import { login, loginOut, getUserMenuTree, getUserPermissions } from '@/api/user'
|
import { login, loginOut, getUserMenuTree, getUserPermissions, getUserLoginRoleList, loginSelectUserRole } from '@/api/user'
|
||||||
|
import { getUser } from '@/api/admin'
|
||||||
|
|
||||||
import { resetRouter } from '@/router'
|
import { resetRouter } from '@/router'
|
||||||
import md5 from 'js-md5'
|
import md5 from 'js-md5'
|
||||||
@@ -7,22 +8,29 @@ const getDefaultState = () => {
|
|||||||
return {
|
return {
|
||||||
token: getToken(),
|
token: getToken(),
|
||||||
name: '',
|
name: '',
|
||||||
|
userTypeShortName: "",
|
||||||
userName: '',
|
userName: '',
|
||||||
userId: '',
|
userId: '',
|
||||||
|
identityUserId: '',
|
||||||
avatar: '',
|
avatar: '',
|
||||||
permissions: [],
|
permissions: [],
|
||||||
tree: [],
|
tree: [],
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
TotalNeedSignSystemDocCount: eval(process.env.VUE_APP_WORD_FOR_PERMISSION) ? null : 0,
|
TotalNeedSignSystemDocCount: eval(process.env.VUE_APP_WORD_FOR_PERMISSION) ? null : 0,
|
||||||
TotalNeedSignTrialDocCount: eval(process.env.VUE_APP_WORD_FOR_PERMISSION) ? null : 0,
|
TotalNeedSignTrialDocCount: eval(process.env.VUE_APP_WORD_FOR_PERMISSION) ? null : 0,
|
||||||
|
IsFirstSysDocNeedSign: false,
|
||||||
TrialStatusStr: null,
|
TrialStatusStr: null,
|
||||||
isTestUser: false
|
isTestUser: false,
|
||||||
|
roles: []
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const state = getDefaultState()
|
const state = getDefaultState()
|
||||||
|
|
||||||
const mutations = {
|
const mutations = {
|
||||||
|
SET_ROLES: (state, roles) => {
|
||||||
|
state.roles = roles
|
||||||
|
},
|
||||||
RESET_STATE: (state) => {
|
RESET_STATE: (state) => {
|
||||||
Object.assign(state, getDefaultState())
|
Object.assign(state, getDefaultState())
|
||||||
},
|
},
|
||||||
@@ -34,6 +42,9 @@ const mutations = {
|
|||||||
SET_NAME: (state, name) => {
|
SET_NAME: (state, name) => {
|
||||||
state.name = name
|
state.name = name
|
||||||
},
|
},
|
||||||
|
SET_USERTYPESHORTNAME: (state, userTypeShortName) => {
|
||||||
|
state.userTypeShortName = userTypeShortName
|
||||||
|
},
|
||||||
SET_USERNAME: (state, name) => {
|
SET_USERNAME: (state, name) => {
|
||||||
state.userName = name
|
state.userName = name
|
||||||
},
|
},
|
||||||
@@ -49,9 +60,16 @@ const mutations = {
|
|||||||
SET_USERID: (state, id) => {
|
SET_USERID: (state, id) => {
|
||||||
state.userId = id
|
state.userId = id
|
||||||
},
|
},
|
||||||
|
SET_IDENTITYUSERID: (state, id) => {
|
||||||
|
state.identityUserId = id
|
||||||
|
},
|
||||||
SET_ISTESTUSER: (state, isTestUser) => {
|
SET_ISTESTUSER: (state, isTestUser) => {
|
||||||
state.isTestUser = eval(isTestUser)
|
state.isTestUser = eval(isTestUser)
|
||||||
},
|
},
|
||||||
|
SET_IS_FIRST_SYSTEM_DOC_SIGN: (state, IsFirstSysDocNeedSign) => {
|
||||||
|
zzSessionStorage.setItem('IsFirstSysDocNeedSign', IsFirstSysDocNeedSign)
|
||||||
|
state.IsFirstSysDocNeedSign = IsFirstSysDocNeedSign
|
||||||
|
},
|
||||||
SET_NEED_SIGN_SYSTEM_DOC_COUNT: (state, TotalNeedSignSystemDocCount) => {
|
SET_NEED_SIGN_SYSTEM_DOC_COUNT: (state, TotalNeedSignSystemDocCount) => {
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
if (eval(process.env.VUE_APP_WORD_FOR_PERMISSION) && !state.isTestUser) {
|
if (eval(process.env.VUE_APP_WORD_FOR_PERMISSION) && !state.isTestUser) {
|
||||||
@@ -78,6 +96,9 @@ const mutations = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const actions = {
|
const actions = {
|
||||||
|
setRoles({ commit }, roles) {
|
||||||
|
commit('SET_ROLES', roles)
|
||||||
|
},
|
||||||
changeUserName({ commit }, userName) {
|
changeUserName({ commit }, userName) {
|
||||||
commit('SET_USERNAME', userName)
|
commit('SET_USERNAME', userName)
|
||||||
},
|
},
|
||||||
@@ -91,7 +112,7 @@ const actions = {
|
|||||||
if (UserId) {
|
if (UserId) {
|
||||||
data.UserId = UserId;
|
data.UserId = UserId;
|
||||||
}
|
}
|
||||||
login(data).then(async response => {
|
getUserLoginRoleList(data).then(async response => {
|
||||||
if (response.IsSuccess) {
|
if (response.IsSuccess) {
|
||||||
zzSessionStorage.removeItem('lastWorkbench')
|
zzSessionStorage.removeItem('lastWorkbench')
|
||||||
zzSessionStorage.setItem('my_username', username.trim())
|
zzSessionStorage.setItem('my_username', username.trim())
|
||||||
@@ -99,6 +120,7 @@ const actions = {
|
|||||||
zzSessionStorage.setItem('my_EMail', response.Result.BasicInfo.EMail)
|
zzSessionStorage.setItem('my_EMail', response.Result.BasicInfo.EMail)
|
||||||
localStorage.setItem('CompanyInfo', JSON.stringify(response.Result.CompanyInfo))
|
localStorage.setItem('CompanyInfo', JSON.stringify(response.Result.CompanyInfo))
|
||||||
const data = response.Result
|
const data = response.Result
|
||||||
|
commit('SET_ROLES', data.BasicInfo.AccountList)
|
||||||
if (data.BasicInfo.IsFirstAdd || data.BasicInfo.LoginState === 1) {
|
if (data.BasicInfo.IsFirstAdd || data.BasicInfo.LoginState === 1) {
|
||||||
try {
|
try {
|
||||||
zzSessionStorage.setItem('userId', data.BasicInfo.Id)
|
zzSessionStorage.setItem('userId', data.BasicInfo.Id)
|
||||||
@@ -114,25 +136,24 @@ const actions = {
|
|||||||
zzSessionStorage.setItem('IsReviewer', data.BasicInfo.IsReviewer)
|
zzSessionStorage.setItem('IsReviewer', data.BasicInfo.IsReviewer)
|
||||||
zzSessionStorage.setItem('userName', data.BasicInfo.UserName)
|
zzSessionStorage.setItem('userName', data.BasicInfo.UserName)
|
||||||
commit('SET_TOKEN', data.JWTStr)
|
commit('SET_TOKEN', data.JWTStr)
|
||||||
commit('SET_NAME', data.BasicInfo.RealName)
|
// commit('SET_NAME', data.BasicInfo.UserName)
|
||||||
zzSessionStorage.setItem('realName', data.BasicInfo.RealName)
|
|
||||||
zzSessionStorage.setItem('isTestUser', data.BasicInfo.IsTestUser)
|
zzSessionStorage.setItem('isTestUser', data.BasicInfo.IsTestUser)
|
||||||
commit('SET_ISTESTUSER', data.BasicInfo.IsTestUser)
|
commit('SET_ISTESTUSER', data.BasicInfo.IsTestUser)
|
||||||
commit('SET_USERNAME', data.BasicInfo.UserName)
|
commit('SET_USERNAME', data.BasicInfo.UserName)
|
||||||
commit('SET_USERID', data.BasicInfo.Id)
|
|
||||||
setToken(data.JWTStr)
|
setToken(data.JWTStr)
|
||||||
setName(data.BasicInfo.RealName)
|
// setName(data.BasicInfo.RealName)
|
||||||
const userString = decodeURIComponent(escape(window.atob(data.JWTStr.split('.')[1].replace(/-/g, '+').replace(/_/g, '/'))))
|
// const userString = decodeURIComponent(escape(window.atob(data.JWTStr.split('.')[1].replace(/-/g, '+').replace(/_/g, '/'))))
|
||||||
const user = JSON.parse(userString)
|
// const user = JSON.parse(userString)
|
||||||
zzSessionStorage.setItem('userTypeShortName', user.userTypeShortName)
|
// zzSessionStorage.setItem('userId', user.identityUserId)
|
||||||
zzSessionStorage.setItem('userId', user.id)
|
// commit('SET_IDENTITYUSERID', user.identityUserId)
|
||||||
zzSessionStorage.setItem('userTypeEnumInt', user.userTypeEnumInt)
|
// zzSessionStorage.setItem('identityUserId', user.identityUserId)
|
||||||
var permissions = await getUserPermissions()
|
// zzSessionStorage.setItem('userTypeEnumInt', user.userTypeEnumInt)
|
||||||
var menuTree = await getUserMenuTree()
|
// var permissions = await getUserPermissions()
|
||||||
commit('SET_TREE', menuTree.Result)
|
// var menuTree = await getUserMenuTree()
|
||||||
commit('SET_PERMISSIONS', permissions.Result)
|
// commit('SET_TREE', menuTree.Result)
|
||||||
zzSessionStorage.setItem('newTree', JSON.stringify(menuTree.Result))
|
// commit('SET_PERMISSIONS', permissions.Result)
|
||||||
zzSessionStorage.setItem('permissions', JSON.stringify(permissions.Result))
|
// zzSessionStorage.setItem('newTree', JSON.stringify(menuTree.Result))
|
||||||
|
// zzSessionStorage.setItem('permissions', JSON.stringify(permissions.Result))
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.log(e)
|
console.log(e)
|
||||||
}
|
}
|
||||||
@@ -146,6 +167,51 @@ const actions = {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
loginByRole({ commit }, userInfo) {
|
||||||
|
const { userRoleId } = userInfo
|
||||||
|
let params = {
|
||||||
|
userRoleId
|
||||||
|
}
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
|
||||||
|
loginSelectUserRole(params).then(async response => {
|
||||||
|
if (response.IsSuccess) {
|
||||||
|
const data = response.Result
|
||||||
|
|
||||||
|
try {
|
||||||
|
commit('SET_TOKEN', data)
|
||||||
|
setToken(data)
|
||||||
|
commit('SET_USERID', userRoleId)
|
||||||
|
zzSessionStorage.setItem('userId', userRoleId)
|
||||||
|
const userString = decodeURIComponent(escape(window.atob(data.split('.')[1].replace(/-/g, '+').replace(/_/g, '/'))))
|
||||||
|
const user = JSON.parse(userString)
|
||||||
|
zzSessionStorage.setItem('userTypeShortName', user.userTypeShortName)
|
||||||
|
commit('SET_USERTYPESHORTNAME', user.userTypeShortName)
|
||||||
|
commit('SET_NAME', user.fullName)
|
||||||
|
setName(user.fullName)
|
||||||
|
commit('SET_IDENTITYUSERID', user.identityUserId)
|
||||||
|
zzSessionStorage.setItem('identityUserId', user.identityUserId)
|
||||||
|
zzSessionStorage.setItem('userTypeEnumInt', user.userTypeEnumInt)
|
||||||
|
var permissions = await getUserPermissions()
|
||||||
|
var menuTree = await getUserMenuTree()
|
||||||
|
commit('SET_TREE', menuTree.Result)
|
||||||
|
commit('SET_PERMISSIONS', permissions.Result)
|
||||||
|
zzSessionStorage.setItem('newTree', JSON.stringify(menuTree.Result))
|
||||||
|
zzSessionStorage.setItem('permissions', JSON.stringify(permissions.Result))
|
||||||
|
zzSessionStorage.removeItem('lastWorkbench')
|
||||||
|
} catch (e) {
|
||||||
|
console.log(e)
|
||||||
|
}
|
||||||
|
resolve(response.Result)
|
||||||
|
|
||||||
|
} else {
|
||||||
|
reject(response.ErrorMessage)
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
reject()
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
setTree({ commit }, tree) {
|
setTree({ commit }, tree) {
|
||||||
commit('SET_TREE', tree)
|
commit('SET_TREE', tree)
|
||||||
},
|
},
|
||||||
@@ -155,6 +221,9 @@ const actions = {
|
|||||||
setTotalNeedSignSystemDocCount({ commit }, TotalNeedSignSystemDocCount) {
|
setTotalNeedSignSystemDocCount({ commit }, TotalNeedSignSystemDocCount) {
|
||||||
commit('SET_NEED_SIGN_SYSTEM_DOC_COUNT', TotalNeedSignSystemDocCount)
|
commit('SET_NEED_SIGN_SYSTEM_DOC_COUNT', TotalNeedSignSystemDocCount)
|
||||||
},
|
},
|
||||||
|
setIsFirstSysDocNeedSign({ commit }, IsFirstSysDocNeedSign) {
|
||||||
|
commit('SET_IS_FIRST_SYSTEM_DOC_SIGN', IsFirstSysDocNeedSign)
|
||||||
|
},
|
||||||
setTotalNeedSignTrialDocCount({ commit }, TotalNeedSignTrialDocCount) {
|
setTotalNeedSignTrialDocCount({ commit }, TotalNeedSignTrialDocCount) {
|
||||||
commit('SET_NEED_SIGN_TRIALS_DOC_COUNT', TotalNeedSignTrialDocCount)
|
commit('SET_NEED_SIGN_TRIALS_DOC_COUNT', TotalNeedSignTrialDocCount)
|
||||||
},
|
},
|
||||||
@@ -170,32 +239,69 @@ const actions = {
|
|||||||
commit('SET_PERMISSIONS', JSON.parse(zzSessionStorage.getItem('permissions')))
|
commit('SET_PERMISSIONS', JSON.parse(zzSessionStorage.getItem('permissions')))
|
||||||
commit('SET_ISTESTUSER', zzSessionStorage.getItem('isTestUser'))
|
commit('SET_ISTESTUSER', zzSessionStorage.getItem('isTestUser'))
|
||||||
const user = JSON.parse(userString)
|
const user = JSON.parse(userString)
|
||||||
commit('SET_NAME', zzSessionStorage.getItem('realName'))
|
commit('SET_NAME', zzSessionStorage.getItem('Name'))
|
||||||
commit('SET_USERID', user.id)
|
commit('SET_USERTYPESHORTNAME', user.userTypeShortName)
|
||||||
|
commit('SET_IDENTITYUSERID', user.identityUserId)
|
||||||
|
commit('SET_USERID', user.userRoleId)
|
||||||
commit('SET_USERNAME', zzSessionStorage.getItem('userName'))
|
commit('SET_USERNAME', zzSessionStorage.getItem('userName'))
|
||||||
commit('SET_NEED_SIGN_SYSTEM_DOC_COUNT', parseInt(zzSessionStorage.getItem('TotalNeedSignSystemDocCount')))
|
commit('SET_NEED_SIGN_SYSTEM_DOC_COUNT', parseInt(zzSessionStorage.getItem('TotalNeedSignSystemDocCount')))
|
||||||
commit('SET_NEED_SIGN_TRIALS_DOC_COUNT', parseInt(zzSessionStorage.getItem('TotalNeedSignTrialDocCount')))
|
commit('SET_NEED_SIGN_TRIALS_DOC_COUNT', parseInt(zzSessionStorage.getItem('TotalNeedSignTrialDocCount')))
|
||||||
console.log(zzSessionStorage.getItem('TotalNeedSignSystemDocCount'))
|
commit('SET_IS_FIRST_SYSTEM_DOC_SIGN', zzSessionStorage.getItem('IsFirstSysDocNeedSign'))
|
||||||
console.log(zzSessionStorage.getItem('TotalNeedSignTrialDocCount'))
|
// console.log(zzSessionStorage.getItem('TotalNeedSignSystemDocCount'))
|
||||||
|
// console.log(zzSessionStorage.getItem('TotalNeedSignTrialDocCount'))
|
||||||
zzSessionStorage.setItem('userName', user.name)
|
zzSessionStorage.setItem('userName', user.name)
|
||||||
zzSessionStorage.setItem('userId', user.id)
|
zzSessionStorage.setItem('userId', user.userRoleId)
|
||||||
|
zzSessionStorage.setItem('identityUserId', user.identityUserId)
|
||||||
zzSessionStorage.setItem('userTypeShortName', user.userTypeShortName)
|
zzSessionStorage.setItem('userTypeShortName', user.userTypeShortName)
|
||||||
zzSessionStorage.setItem('userTypeEnumInt', user.userTypeEnumInt)
|
zzSessionStorage.setItem('userTypeEnumInt', user.userTypeEnumInt)
|
||||||
return user
|
return user
|
||||||
},
|
},
|
||||||
updateInfo({ commit, state }) {
|
updateInfo({ commit, state }) {
|
||||||
commit('SET_NAME', zzSessionStorage.getItem('realName'))
|
commit('SET_NAME', zzSessionStorage.getItem('Name'))
|
||||||
|
},
|
||||||
|
// 获取用户信息
|
||||||
|
getUserInfo({ commit, state }) {
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
getUser().then(res => {
|
||||||
|
if (res.Result) {
|
||||||
|
commit('SET_ROLES', res.Result.AccountList)
|
||||||
|
}
|
||||||
|
resolve(res.Result)
|
||||||
|
}).catch(err => {
|
||||||
|
reject(err)
|
||||||
|
})
|
||||||
|
})
|
||||||
},
|
},
|
||||||
// user logout
|
// user logout
|
||||||
async logout({ commit, state }) {
|
async logout({ commit, state }) {
|
||||||
try {
|
try {
|
||||||
removeToken() // must remove token first
|
removeToken() // must remove token first
|
||||||
await loginOut({
|
await loginOut({
|
||||||
Userd: zzSessionStorage.getItem('userId')
|
UserRoleId: zzSessionStorage.getItem('userId'),
|
||||||
|
IdentityUserId: zzSessionStorage.getItem('identityUserId'),
|
||||||
})
|
})
|
||||||
resetRouter()
|
resetRouter()
|
||||||
removeName()
|
removeName()
|
||||||
|
let lang = zzSessionStorage.getItem('lang')
|
||||||
zzSessionStorage.clear()
|
zzSessionStorage.clear()
|
||||||
|
zzSessionStorage.setItem('lang', lang)
|
||||||
|
commit('RESET_STATE')
|
||||||
|
} catch (e) {
|
||||||
|
console.log(e)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async resetData({ commit, state }) {
|
||||||
|
try {
|
||||||
|
removeToken() // must remove token first
|
||||||
|
// await loginOut({
|
||||||
|
// UserRoleId: zzSessionStorage.getItem('userId'),
|
||||||
|
// IdentityUserId: zzSessionStorage.getItem('identityUserId'),
|
||||||
|
// })
|
||||||
|
resetRouter()
|
||||||
|
removeName()
|
||||||
|
let lang = zzSessionStorage.getItem('lang')
|
||||||
|
zzSessionStorage.clear()
|
||||||
|
zzSessionStorage.setItem('lang', lang)
|
||||||
commit('RESET_STATE')
|
commit('RESET_STATE')
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.log(e)
|
console.log(e)
|
||||||
|
|||||||
@@ -47,3 +47,6 @@
|
|||||||
.el-range-separator {
|
.el-range-separator {
|
||||||
box-sizing: content-box;
|
box-sizing: content-box;
|
||||||
}
|
}
|
||||||
|
.el-select-dropdown__wrap{
|
||||||
|
max-height: 350px;
|
||||||
|
}
|
||||||
+3
-2
@@ -40,8 +40,9 @@ Vue.directive('dialogDrag', {
|
|||||||
styL = +styL.replace(/\px/g, '')
|
styL = +styL.replace(/\px/g, '')
|
||||||
styT = +styT.replace(/\px/g, '')
|
styT = +styT.replace(/\px/g, '')
|
||||||
}
|
}
|
||||||
|
const oldMousemove = document.onmousemove
|
||||||
document.onmousemove = function(e) {
|
document.onmousemove = function(e) {
|
||||||
|
oldMousemove(e)
|
||||||
// 通过事件委托,计算移动的距离
|
// 通过事件委托,计算移动的距离
|
||||||
let left = e.clientX - disX
|
let left = e.clientX - disX
|
||||||
let top = e.clientY - disY
|
let top = e.clientY - disY
|
||||||
@@ -63,7 +64,7 @@ Vue.directive('dialogDrag', {
|
|||||||
}
|
}
|
||||||
|
|
||||||
document.onmouseup = function(e) {
|
document.onmouseup = function(e) {
|
||||||
document.onmousemove = null
|
document.onmousemove = oldMousemove
|
||||||
document.onmouseup = null
|
document.onmouseup = null
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
|
|||||||
@@ -89,9 +89,9 @@ service.interceptors.response.use(
|
|||||||
})
|
})
|
||||||
store.dispatch('user/logout').then(() => {
|
store.dispatch('user/logout').then(() => {
|
||||||
router.push(`/login`)
|
router.push(`/login`)
|
||||||
this.$i18n.locale = 'zh'
|
//this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
//this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
// this.$updateDictionary()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
+20
-9
@@ -1,11 +1,11 @@
|
|||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import _vm from '@/main'
|
|
||||||
import { Message, MessageBox, Alert } from 'element-ui'
|
import { Message, MessageBox, Alert } from 'element-ui'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import router from '@/router'
|
import router from '@/router'
|
||||||
import WHITELIST from "./whiteList"
|
import WHITELIST from "./whiteList"
|
||||||
import moment from 'moment-timezone';
|
import moment from 'moment-timezone';
|
||||||
import { encryptConfig } from "@/utils/encrypt"
|
import { encryptConfig } from "@/utils/encrypt"
|
||||||
|
const ROUTER = require('@/router');
|
||||||
axios.defaults.withCredentials = false
|
axios.defaults.withCredentials = false
|
||||||
const service = axios.create({
|
const service = axios.create({
|
||||||
baseURL: '/api',
|
baseURL: '/api',
|
||||||
@@ -91,13 +91,20 @@ service.interceptors.response.use(
|
|||||||
const status = error.response.status
|
const status = error.response.status
|
||||||
if (error.response.data && (error.response.data.Code === -1 || error.response.data.Code === -2)) {
|
if (error.response.data && (error.response.data.Code === -1 || error.response.data.Code === -2)) {
|
||||||
store.dispatch('user/logout').then(() => {
|
store.dispatch('user/logout').then(() => {
|
||||||
if (_vm.$msgbox) {
|
let _vm = ROUTER.default.app
|
||||||
_vm.$msgbox.close();
|
try {
|
||||||
|
if (_vm.$msgbox && _vm.$msgbox.close) {
|
||||||
|
_vm.$msgbox.close();
|
||||||
|
}
|
||||||
|
} catch (err) {
|
||||||
|
console.log(err)
|
||||||
}
|
}
|
||||||
router.push(`/login`)
|
router.push(`/login`)
|
||||||
this.$i18n.locale = 'zh'
|
// if (!this.$i18n.locale) {
|
||||||
this.setLanguage('zh')
|
// //this.$i18n.locale = 'zh'
|
||||||
this.$updateDictionary()
|
// //this.setLanguage('zh')
|
||||||
|
// }
|
||||||
|
// this.$updateDictionary()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
switch (status) {
|
switch (status) {
|
||||||
@@ -127,9 +134,9 @@ service.interceptors.response.use(
|
|||||||
}
|
}
|
||||||
store.dispatch('user/logout').then(() => {
|
store.dispatch('user/logout').then(() => {
|
||||||
router.push(`/login`)
|
router.push(`/login`)
|
||||||
this.$i18n.locale = 'zh'
|
// //this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
// //this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
// this.$updateDictionary()
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
setTimer({
|
setTimer({
|
||||||
@@ -143,6 +150,7 @@ service.interceptors.response.use(
|
|||||||
setTimer([message, store.state.lang.language === 'en' ? 'Warning' : '警告', {
|
setTimer([message, store.state.lang.language === 'en' ? 'Warning' : '警告', {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
showCancelButton: false,
|
showCancelButton: false,
|
||||||
|
confirmButtonText: store.state.lang.language === 'en' ? 'ok' : "确定",
|
||||||
callback: action => { }
|
callback: action => { }
|
||||||
}], 'confirm')
|
}], 'confirm')
|
||||||
}
|
}
|
||||||
@@ -153,6 +161,7 @@ service.interceptors.response.use(
|
|||||||
[store.state.lang.language === 'en' ? 'Please check your network,and try again later!' : '请检查网络,稍后重试!', store.state.lang.language === 'en' ? 'Warning' : '警告', {
|
[store.state.lang.language === 'en' ? 'Please check your network,and try again later!' : '请检查网络,稍后重试!', store.state.lang.language === 'en' ? 'Warning' : '警告', {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
showCancelButton: false,
|
showCancelButton: false,
|
||||||
|
confirmButtonText: store.state.lang.language === 'en' ? 'ok' : "确定",
|
||||||
callback: action => { }
|
callback: action => { }
|
||||||
}], "confirm"
|
}], "confirm"
|
||||||
)
|
)
|
||||||
@@ -171,6 +180,8 @@ const setTimer = (obj, type) => {
|
|||||||
Message(obj)
|
Message(obj)
|
||||||
}
|
}
|
||||||
if (type === 'confirm') {
|
if (type === 'confirm') {
|
||||||
|
obj[2].closeOnClickModal = false
|
||||||
|
obj[2].closeOnPressEscape = false
|
||||||
MessageBox.confirm(...obj)
|
MessageBox.confirm(...obj)
|
||||||
}
|
}
|
||||||
clearTimeout(timer);
|
clearTimeout(timer);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
:model="user"
|
:model="user"
|
||||||
:rules="userFormRules"
|
:rules="userFormRules"
|
||||||
label-width="150px"
|
label-width="150px"
|
||||||
style="width:800px;"
|
style="width: 800px"
|
||||||
>
|
>
|
||||||
<el-card class="Basic" shadow="never" size="small">
|
<el-card class="Basic" shadow="never" size="small">
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
@@ -25,7 +25,7 @@
|
|||||||
<el-form-item label="Given Name: " prop="FirstName">
|
<el-form-item label="Given Name: " prop="FirstName">
|
||||||
<el-input v-model="user.FirstName" />
|
<el-input v-model="user.FirstName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="Gender: " prop="Sex" style="margin-right:40px;">
|
<el-form-item label="Gender: " prop="Sex" style="margin-right: 40px">
|
||||||
<el-radio-group v-model="user.Sex">
|
<el-radio-group v-model="user.Sex">
|
||||||
<el-radio :label="1">Male</el-radio>
|
<el-radio :label="1">Male</el-radio>
|
||||||
<el-radio :label="0">Female</el-radio>
|
<el-radio :label="0">Female</el-radio>
|
||||||
@@ -37,13 +37,24 @@
|
|||||||
<el-form-item label="Phone: " prop="Phone">
|
<el-form-item label="Phone: " prop="Phone">
|
||||||
<el-input v-model="user.Phone" />
|
<el-input v-model="user.Phone" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="type==1" label="Disable:">
|
<el-form-item v-if="type == 1" label="Disable:">
|
||||||
<el-switch v-model="user.Status" :active-value="0" :inactive-value="1" />
|
<el-switch
|
||||||
|
v-model="user.Status"
|
||||||
|
:active-value="0"
|
||||||
|
:inactive-value="1"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="User Type: " prop="UserTypeId">
|
<el-form-item label="User Type: " prop="UserTypeId">
|
||||||
<el-select ref="userType" v-model="user.UserTypeId" size="small" placeholder="Please select" style="width:100%;" :disabled="user.CanEditUserType === false">
|
<el-select
|
||||||
|
ref="userType"
|
||||||
|
v-model="user.UserTypeId"
|
||||||
|
size="small"
|
||||||
|
placeholder="Please select"
|
||||||
|
style="width: 100%"
|
||||||
|
:disabled="user.CanEditUserType === false"
|
||||||
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="(userType,key) of userTypeOptions"
|
v-for="(userType, key) of userTypeOptions"
|
||||||
:key="key"
|
:key="key"
|
||||||
:label="userType.UserType"
|
:label="userType.UserType"
|
||||||
:value="userType.Id"
|
:value="userType.Id"
|
||||||
@@ -52,17 +63,28 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<el-card class="Affiliation" shadow="never" style="margin-top:10px;" size="small">
|
<el-card
|
||||||
|
class="Affiliation"
|
||||||
|
shadow="never"
|
||||||
|
style="margin-top: 10px"
|
||||||
|
size="small"
|
||||||
|
>
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>Affiliation</span>
|
<span>Affiliation</span>
|
||||||
</div>
|
</div>
|
||||||
<el-form-item prop="IsZhiZhun">
|
<el-form-item prop="IsZhiZhun">
|
||||||
<el-radio-group v-model="user.IsZhiZhun" @change="OrgnizationTypeChanged">
|
<el-radio-group
|
||||||
|
v-model="user.IsZhiZhun"
|
||||||
|
@change="OrgnizationTypeChanged"
|
||||||
|
>
|
||||||
<el-radio :label="true">Internal</el-radio>
|
<el-radio :label="true">Internal</el-radio>
|
||||||
<el-radio :label="false">External</el-radio>
|
<el-radio :label="false">External</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-show="user.IsZhiZhun === false" label="Organization Name: ">
|
<el-form-item
|
||||||
|
v-show="user.IsZhiZhun === false"
|
||||||
|
label="Organization Name: "
|
||||||
|
>
|
||||||
<el-input v-model="user.OrganizationName" />
|
<el-input v-model="user.OrganizationName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
@@ -78,19 +100,24 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
:disabled="isDisabled"
|
:disabled="isDisabled"
|
||||||
style="margin:10px 15px"
|
style="margin: 10px 15px"
|
||||||
@click="handleSave"
|
@click="handleSave"
|
||||||
>Save</el-button>
|
>Save</el-button
|
||||||
|
>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getUser, addUser, updateUser, getUserTypeListByUserType } from '@/api/admin.js'
|
import {
|
||||||
|
getUser,
|
||||||
|
addUser,
|
||||||
|
updateUser,
|
||||||
|
getUserTypeListByUserType,
|
||||||
|
} from '@/api/admin.js'
|
||||||
export default {
|
export default {
|
||||||
name: 'UserInfo',
|
name: 'UserInfo',
|
||||||
props: {
|
props: {
|
||||||
userId: { type: String, default: '' }
|
userId: { type: String, default: '' },
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -105,60 +132,69 @@ export default {
|
|||||||
IsZhiZhun: '',
|
IsZhiZhun: '',
|
||||||
OrganizationName: '',
|
OrganizationName: '',
|
||||||
DepartmentName: '',
|
DepartmentName: '',
|
||||||
PositionName: ''
|
PositionName: '',
|
||||||
},
|
},
|
||||||
userFormRules: {
|
userFormRules: {
|
||||||
UserName: [
|
UserName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' },
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
],
|
||||||
UserTypeId: [
|
UserTypeId: [
|
||||||
{ required: true, message: 'Please Select', trigger: ['blur', 'change'] }
|
{
|
||||||
|
required: true,
|
||||||
|
message: 'Please Select',
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
IsZhiZhun: [
|
IsZhiZhun: [
|
||||||
{ required: true, message: 'Please Select', trigger: ['blur', 'change'] }
|
{
|
||||||
|
required: true,
|
||||||
|
message: 'Please Select',
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
OrganizationName: [
|
OrganizationName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
],
|
],
|
||||||
LastName: [
|
LastName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' },
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
],
|
||||||
FirstName: [
|
FirstName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' },
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
],
|
||||||
Phone: [
|
Phone: [
|
||||||
{ max: 20, min: 7, message: 'The length is 7 to 20', trigger: ['blur'] }
|
{
|
||||||
|
max: 20,
|
||||||
|
min: 7,
|
||||||
|
message: 'The length is 7 to 20',
|
||||||
|
trigger: ['blur'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
EMail: [
|
EMail: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please input the email address',
|
message: 'Please input the email address',
|
||||||
trigger: 'blur'
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
type: 'email',
|
type: 'email',
|
||||||
message: 'Please input the correct email address',
|
message: 'Please input the correct email address',
|
||||||
trigger: ['blur']
|
trigger: ['blur'],
|
||||||
},
|
},
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
|
||||||
Sex: [
|
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
|
||||||
],
|
],
|
||||||
|
Sex: [{ required: true, message: 'Please specify', trigger: 'blur' }],
|
||||||
Status: [
|
Status: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
],
|
],
|
||||||
DepartmentName: [
|
DepartmentName: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
{ max: 50, message: 'The maximum length is 50' }],
|
PositionName: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
PositionName: [{ max: 50, message: 'The maximum length is 50' }
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
userTypeOptions: [],
|
userTypeOptions: [],
|
||||||
isDisabled: false,
|
isDisabled: false,
|
||||||
type: 0 // 1为编辑,0为新增
|
type: 0, // 1为编辑,0为新增
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
@@ -172,46 +208,58 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleSave() {
|
handleSave() {
|
||||||
this.$refs.userForm.validate(valid => {
|
this.$refs.userForm.validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.isDisabled = true
|
this.isDisabled = true
|
||||||
const selectedUserType = this.userTypeOptions.filter(item => item.Id === this.user.UserTypeId)
|
const selectedUserType = this.userTypeOptions.filter(
|
||||||
|
(item) => item.Id === this.user.UserTypeId
|
||||||
|
)
|
||||||
if (selectedUserType.length > 0) {
|
if (selectedUserType.length > 0) {
|
||||||
this.user.UserTypeEnum = selectedUserType[0].UserTypeEnum
|
this.user.UserTypeEnum = selectedUserType[0].UserTypeEnum
|
||||||
}
|
}
|
||||||
if (this.user.Id) {
|
if (this.user.Id) {
|
||||||
updateUser(this.user).then(res => {
|
updateUser(this.user)
|
||||||
this.isDisabled = false
|
.then((res) => {
|
||||||
this.$message.success('Updated successfully')
|
this.isDisabled = false
|
||||||
}).catch(() => { this.isDisabled = false })
|
this.$message.success('Updated successfully')
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.isDisabled = false
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
addUser(this.user).then(res => {
|
addUser(this.user)
|
||||||
this.isDisabled = false
|
.then((res) => {
|
||||||
this.user.Id = res.Result.Id
|
this.isDisabled = false
|
||||||
this.user.UserCode = res.Result.UserCode
|
this.user.Id = res.Result.Id
|
||||||
this.$emit('getUserId', res.Result.Id)
|
this.user.UserCode = res.Result.UserCode
|
||||||
this.$message.success('Added successfully')
|
this.$emit('getUserId', res.Result.Id)
|
||||||
this.$router.push({ path: '/system/user/list' })
|
this.$message.success('Added successfully')
|
||||||
}).catch(() => { this.isDisabled = false })
|
this.$router.push({ path: '/system/user/list' })
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.isDisabled = false
|
||||||
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getUserTypeList() {
|
getUserTypeList() {
|
||||||
getUserTypeListByUserType(0).then(res => {
|
getUserTypeListByUserType(0).then((res) => {
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
this.userTypeOptions = res.Result
|
this.userTypeOptions = res.Result
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getUserInfo() {
|
getUserInfo() {
|
||||||
getUser(this.userId).then(res => {
|
getUser({
|
||||||
|
IdentityUserId: this.userId,
|
||||||
|
}).then((res) => {
|
||||||
this.user = res.Result
|
this.user = res.Result
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
OrgnizationTypeChanged(val) {
|
OrgnizationTypeChanged(val) {
|
||||||
this.user.OrganizationName = ''
|
this.user.OrganizationName = ''
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -131,8 +131,8 @@ export default {
|
|||||||
.then(() => {
|
.then(() => {
|
||||||
this.$store.dispatch('user/logout').then(res => {
|
this.$store.dispatch('user/logout').then(res => {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
this.$i18n.locale = 'zh'
|
//this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
//this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -52,10 +52,14 @@
|
|||||||
</div>
|
</div>
|
||||||
<div v-if="item.isExistMutiFrames && item.instanceCount > 1">
|
<div v-if="item.isExistMutiFrames && item.instanceCount > 1">
|
||||||
<el-popover
|
<el-popover
|
||||||
placement="right"
|
v-model="item.isShowPopper"
|
||||||
trigger="hover"
|
placement="right-start"
|
||||||
|
trigger="manual"
|
||||||
popper-class="instance_frame_wrapper"
|
popper-class="instance_frame_wrapper"
|
||||||
>
|
>
|
||||||
|
<div style="text-align: right;">
|
||||||
|
<i class="el-icon-circle-close" style="font-size: 20px;cursor: pointer;color:#ddd;" @click="item.isShowPopper = false" />
|
||||||
|
</div>
|
||||||
<div class="frame_list">
|
<div class="frame_list">
|
||||||
<div
|
<div
|
||||||
v-for="(instance, idx) in item.instanceInfoList"
|
v-for="(instance, idx) in item.instanceInfoList"
|
||||||
@@ -66,11 +70,27 @@
|
|||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
<div>{{ instance.InstanceNumber }}</div>
|
<div>{{ instance.InstanceNumber }}</div>
|
||||||
<div>{{ `${instance.NumberOfFrames > 0 ? instance.NumberOfFrames : 1} frame` }}</div>
|
<div>
|
||||||
|
{{ `${instance.NumberOfFrames > 0 ? instance.NumberOfFrames : 1} frame` }}
|
||||||
|
</div>
|
||||||
|
<div v-if="showDelete">
|
||||||
|
<span>{{ $t('trials:audit:table:isDelete') }}</span>
|
||||||
|
<el-switch
|
||||||
|
v-model="instance.IsDeleted"
|
||||||
|
size="mini"
|
||||||
|
@change="changeInstanceDeleteStatus($event, item, instance)"
|
||||||
|
/>
|
||||||
|
<span style="margin-left:10px;">{{ $t('trials:audit:table:isReading') }}</span>
|
||||||
|
<el-switch
|
||||||
|
v-model="instance.IsReading"
|
||||||
|
size="mini"
|
||||||
|
@change="changeInstanceReadingStatus($event, item, instance)"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<i slot="reference" class="el-icon-connection" style="font-size: 15px;cursor: pointer;" />
|
<i slot="reference" class="el-icon-connection" style="font-size: 15px;cursor: pointer;" @click="popperClick(seriesList, item)" />
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -138,13 +158,13 @@ import * as cornerstone from 'cornerstone-core'
|
|||||||
import * as cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader'
|
import * as cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader'
|
||||||
import dicomViewer from '@/components/Dicom/DicomViewer'
|
import dicomViewer from '@/components/Dicom/DicomViewer'
|
||||||
import { getStudyInfo, getSeriesList } from '@/api/reading'
|
import { getStudyInfo, getSeriesList } from '@/api/reading'
|
||||||
import { getInstanceList, getPatientSeriesList, setSeriesStatus } from '@/api/trials'
|
import { getInstanceList, getPatientSeriesList, setSeriesStatus, setInstanceStatus } from '@/api/trials'
|
||||||
|
|
||||||
import requestPoolManager from '@/utils/request-pool'
|
import requestPoolManager from '@/utils/request-pool'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { changeURLStatic } from '@/utils/history.js'
|
import { changeURLStatic } from '@/utils/history.js'
|
||||||
import metaDataProvider from '@/utils/metaDataProvider'
|
import metaDataProvider from '@/utils/metaDataProvider'
|
||||||
cornerstone.metaData.addProvider(metaDataProvider, { priority: 10 });
|
cornerstone.metaData.addProvider(metaDataProvider, { priority: 10 })
|
||||||
var config = {
|
var config = {
|
||||||
maxWebWorkers: 4,
|
maxWebWorkers: 4,
|
||||||
startWebWorkersOnDemand: true,
|
startWebWorkersOnDemand: true,
|
||||||
@@ -296,7 +316,8 @@ export default {
|
|||||||
tpCode: this.tpCode,
|
tpCode: this.tpCode,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: [],
|
imageloadedArr: [],
|
||||||
isExistMutiFrames: item.IsExistMutiFrames
|
isExistMutiFrames: item.IsExistMutiFrames,
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.seriesList = seriesList
|
this.seriesList = seriesList
|
||||||
@@ -355,7 +376,8 @@ export default {
|
|||||||
tpCode: this.tpCode,
|
tpCode: this.tpCode,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: [],
|
imageloadedArr: [],
|
||||||
isExistMutiFrames: item.IsExistMutiFrames
|
isExistMutiFrames: item.IsExistMutiFrames,
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.seriesList = seriesList
|
this.seriesList = seriesList
|
||||||
@@ -384,8 +406,8 @@ export default {
|
|||||||
if (!res.Result || (res.Result && res.Result.length === 0)) return
|
if (!res.Result || (res.Result && res.Result.length === 0)) return
|
||||||
var seriesInstanceUid = res.Result[0].SeriesInstanceUid
|
var seriesInstanceUid = res.Result[0].SeriesInstanceUid
|
||||||
var sliceThickness = res.Result[0].SliceThickness
|
var sliceThickness = res.Result[0].SliceThickness
|
||||||
var isReading = res.Result[0].IsReading
|
var isReading = res.OtherInfo.IsReading
|
||||||
var isDeleted = res.Result[0].IsDeleted
|
var isDeleted = res.OtherInfo.IsDeleted
|
||||||
var seriesList = []
|
var seriesList = []
|
||||||
var imageIds = []
|
var imageIds = []
|
||||||
let isExistMutiFrames = false
|
let isExistMutiFrames = false
|
||||||
@@ -403,7 +425,7 @@ export default {
|
|||||||
imageIds.push(path)
|
imageIds.push(path)
|
||||||
imageId = path
|
imageId = path
|
||||||
}
|
}
|
||||||
instanceInfoList.push({ Id: instance.Id, InstanceNumber: instance.InstanceNumber, NumberOfFrames: instance.NumberOfFrames, Path: instance.Path, ImageId: imageId })
|
instanceInfoList.push({ Id: instance.Id, InstanceNumber: instance.InstanceNumber, NumberOfFrames: instance.NumberOfFrames, Path: instance.Path, ImageId: imageId, IsDeleted: instance.IsDeleted, IsReading: instance.IsReading })
|
||||||
})
|
})
|
||||||
seriesList.push({
|
seriesList.push({
|
||||||
trialId,
|
trialId,
|
||||||
@@ -424,7 +446,8 @@ export default {
|
|||||||
prefetchInstanceCount: 0,
|
prefetchInstanceCount: 0,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: [],
|
imageloadedArr: [],
|
||||||
isExistMutiFrames: isExistMutiFrames
|
isExistMutiFrames: isExistMutiFrames,
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
this.seriesList = seriesList
|
this.seriesList = seriesList
|
||||||
if (this.seriesList.length > 0) {
|
if (this.seriesList.length > 0) {
|
||||||
@@ -573,7 +596,8 @@ export default {
|
|||||||
hasLabel: seriesInfo.HasLabel,
|
hasLabel: seriesInfo.HasLabel,
|
||||||
keySeries: seriesInfo.KeySeries,
|
keySeries: seriesInfo.KeySeries,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: []
|
imageloadedArr: [],
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
this.seriesList = seriesList
|
this.seriesList = seriesList
|
||||||
if (this.seriesList.length > 0) {
|
if (this.seriesList.length > 0) {
|
||||||
@@ -671,6 +695,81 @@ export default {
|
|||||||
this.loading = false
|
this.loading = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
async changeInstanceReadingStatus(callback, series, instance) {
|
||||||
|
let statusStr = ''
|
||||||
|
if (callback) {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesReading')
|
||||||
|
instance.IsReading = false
|
||||||
|
} else {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesNotReading')
|
||||||
|
instance.IsReading = true
|
||||||
|
}
|
||||||
|
var message = this.$t('trials:audit:message:changeSeriesStatus').replace('xxx', statusStr)
|
||||||
|
message = message.replace('yyy', this.$fd('YesOrNo', !instance.IsReading))
|
||||||
|
const confirm = await this.$confirm(
|
||||||
|
message,
|
||||||
|
{
|
||||||
|
type: 'warning',
|
||||||
|
distinguishCancelAndClose: true
|
||||||
|
}
|
||||||
|
)
|
||||||
|
if (confirm !== 'confirm') return
|
||||||
|
const state = instance.IsReading ? 1 : 2
|
||||||
|
this.loading = true
|
||||||
|
try {
|
||||||
|
const res = await setInstanceStatus(series.trialId, series.subjectVisitId, series.seriesId, instance.Id, state)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
instance.IsReading = !instance.IsReading
|
||||||
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
|
window.opener.postMessage({ type: 'refreshSeriesList', data: '' }, window.location)
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
this.loading = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async changeInstanceDeleteStatus(callback, series, instance) {
|
||||||
|
let statusStr = ''
|
||||||
|
if (callback) {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesDeleted')
|
||||||
|
instance.IsDeleted = false
|
||||||
|
} else {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesNotDelete')
|
||||||
|
instance.IsDeleted = true
|
||||||
|
}
|
||||||
|
var message = this.$t('trials:audit:message:changeSeriesStatus').replace('xxx', statusStr)
|
||||||
|
message = message.replace('yyy', this.$fd('YesOrNo', !instance.IsDeleted))
|
||||||
|
const confirm = await this.$confirm(
|
||||||
|
message,
|
||||||
|
{
|
||||||
|
type: 'warning',
|
||||||
|
distinguishCancelAndClose: true
|
||||||
|
}
|
||||||
|
)
|
||||||
|
if (confirm !== 'confirm') return
|
||||||
|
|
||||||
|
const state = instance.IsDeleted ? 5 : 4
|
||||||
|
this.loading = true
|
||||||
|
try {
|
||||||
|
const res = await setInstanceStatus(series.trialId, series.subjectVisitId, series.seriesId, instance.Id, state)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
instance.IsDeleted = !instance.IsDeleted
|
||||||
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
|
window.opener.postMessage({ type: 'refreshSeriesList', data: '' }, window.location)
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
this.loading = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
popperClick(seriesList, series) {
|
||||||
|
for (let i = 0; i < seriesList.length; i++) {
|
||||||
|
if (seriesList[i].isShowPopper) {
|
||||||
|
seriesList[i].isShowPopper = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
series.isShowPopper = !series.isShowPopper
|
||||||
|
},
|
||||||
loadAllImages() {
|
loadAllImages() {
|
||||||
const seriesIndex = this.seriesList.findIndex(i => i.loadStatus === false)
|
const seriesIndex = this.seriesList.findIndex(i => i.loadStatus === false)
|
||||||
if (seriesIndex === -1) return
|
if (seriesIndex === -1) return
|
||||||
@@ -948,8 +1047,8 @@ export default {
|
|||||||
background: #d0d0d0;
|
background: #d0d0d0;
|
||||||
}
|
}
|
||||||
.frame_content{
|
.frame_content{
|
||||||
height: 50px;
|
/* height: 50px; */
|
||||||
padding: 5px;
|
padding: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
color: #ddd;
|
color: #ddd;
|
||||||
|
|||||||
@@ -59,34 +59,56 @@
|
|||||||
<div>#{{ series.seriesNumber }}</div>
|
<div>#{{ series.seriesNumber }}</div>
|
||||||
<div v-if="series.isExistMutiFrames && series.instanceCount > 1">
|
<div v-if="series.isExistMutiFrames && series.instanceCount > 1">
|
||||||
<el-popover
|
<el-popover
|
||||||
placement="right"
|
v-model="series.isShowPopper"
|
||||||
trigger="hover"
|
placement="right-start"
|
||||||
|
trigger="manual"
|
||||||
popper-class="instance_frame_wrapper"
|
popper-class="instance_frame_wrapper"
|
||||||
>
|
>
|
||||||
<div
|
<div style="text-align: right;">
|
||||||
v-for="(instance, idx) in series.instanceInfoList"
|
<i class="el-icon-circle-close" style="font-size: 20px;cursor: pointer;color:#ddd;" @click="series.isShowPopper = false" />
|
||||||
:key="instance.Id"
|
|
||||||
class="frame_content"
|
|
||||||
:style="{'margin-bottom':idx<series.instanceInfoList.length-1? '5px':'0px'}"
|
|
||||||
@click="showMultiFrames(index,series, i, instance)"
|
|
||||||
>
|
|
||||||
<!-- <div>
|
|
||||||
<img
|
|
||||||
class="image-preview"
|
|
||||||
:src="series.previewImageUrl"
|
|
||||||
crossorigin="anonymous"
|
|
||||||
alt=""
|
|
||||||
style="width: 40px;height:40px;"
|
|
||||||
fit="fill"
|
|
||||||
>
|
|
||||||
</div> -->
|
|
||||||
<div>
|
|
||||||
<div>{{ instance.InstanceNumber }}</div>
|
|
||||||
<div>{{ `${instance.NumberOfFrames > 0 ? instance.NumberOfFrames : 1} frame` }}</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<i slot="reference" class="el-icon-connection" style="font-size: 15px;cursor: pointer;" />
|
<div class="frame_list">
|
||||||
|
<div
|
||||||
|
v-for="(instance, idx) in series.instanceInfoList"
|
||||||
|
:key="instance.Id"
|
||||||
|
class="frame_content"
|
||||||
|
:style="{'margin-bottom':idx<series.instanceInfoList.length-1? '5px':'0px'}"
|
||||||
|
@click="showMultiFrames(index,series, i, instance)"
|
||||||
|
>
|
||||||
|
<!-- <div>
|
||||||
|
<img
|
||||||
|
class="image-preview"
|
||||||
|
:src="series.previewImageUrl"
|
||||||
|
crossorigin="anonymous"
|
||||||
|
alt=""
|
||||||
|
style="width: 40px;height:40px;"
|
||||||
|
fit="fill"
|
||||||
|
>
|
||||||
|
</div> -->
|
||||||
|
<div>
|
||||||
|
<div>{{ instance.InstanceNumber }}</div>
|
||||||
|
<div>
|
||||||
|
{{ `${instance.NumberOfFrames > 0 ? instance.NumberOfFrames : 1} frame` }}
|
||||||
|
</div>
|
||||||
|
<div v-if="showDelete">
|
||||||
|
<span>{{ $t('trials:audit:table:isDelete') }}</span>
|
||||||
|
<el-switch
|
||||||
|
v-model="instance.IsDeleted"
|
||||||
|
size="mini"
|
||||||
|
@change="changeInstanceDeleteStatus($event, series, instance)"
|
||||||
|
/>
|
||||||
|
<span style="margin-left:10px;">{{ $t('trials:audit:table:isReading') }}</span>
|
||||||
|
<el-switch
|
||||||
|
v-model="instance.IsReading"
|
||||||
|
size="mini"
|
||||||
|
@change="changeInstanceReadingStatus($event, series, instance)"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<i slot="reference" class="el-icon-connection" style="font-size: 15px;cursor: pointer;" @click="popperClick(studyList, series)" />
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -143,7 +165,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane :label="$t('trials:dicom-show:relatedVisit')" name="relation-study" class="pane-relation-wrapper" v-if="!visitTaskId">
|
<el-tab-pane v-if="!visitTaskId" :label="$t('trials:dicom-show:relatedVisit')" name="relation-study" class="pane-relation-wrapper">
|
||||||
<div class="viewerSidethumbinner">
|
<div class="viewerSidethumbinner">
|
||||||
<el-collapse v-model="relationActiveName" @change="handelRelationActiveChange">
|
<el-collapse v-model="relationActiveName" @change="handelRelationActiveChange">
|
||||||
<el-collapse-item v-for="(study,studyIndex) in relationStudyList" :key="`${study.StudyId}`" :name="`${study.StudyId}`">
|
<el-collapse-item v-for="(study,studyIndex) in relationStudyList" :key="`${study.StudyId}`" :name="`${study.StudyId}`">
|
||||||
@@ -196,8 +218,8 @@
|
|||||||
<div v-else>#{{ seriesItem.seriesNumber }}</div>
|
<div v-else>#{{ seriesItem.seriesNumber }}</div>
|
||||||
<div v-if="seriesItem.isExistMutiFrames && seriesItem.instanceCount > 1">
|
<div v-if="seriesItem.isExistMutiFrames && seriesItem.instanceCount > 1">
|
||||||
<el-popover
|
<el-popover
|
||||||
placement="right"
|
placement="right-start"
|
||||||
trigger="hover"
|
trigger="click"
|
||||||
popper-class="instance_frame_wrapper"
|
popper-class="instance_frame_wrapper"
|
||||||
>
|
>
|
||||||
<div class="frame_list">
|
<div class="frame_list">
|
||||||
@@ -260,13 +282,13 @@ import * as cornerstone from 'cornerstone-core'
|
|||||||
import * as cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader'
|
import * as cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader'
|
||||||
import dicomViewer from '@/components/Dicom/DicomViewer'
|
import dicomViewer from '@/components/Dicom/DicomViewer'
|
||||||
import { getVisitStudyList, getAllRelationStudyList, getSeriesList } from '@/api/reading'
|
import { getVisitStudyList, getAllRelationStudyList, getSeriesList } from '@/api/reading'
|
||||||
import { setSeriesStatus } from '@/api/trials'
|
import { setSeriesStatus, setInstanceStatus } from '@/api/trials'
|
||||||
import { getTaskUploadedDicomStudyList } from '@/api/reading'
|
import { getTaskUploadedDicomStudyList } from '@/api/reading'
|
||||||
import requestPoolManager from '@/utils/request-pool'
|
import requestPoolManager from '@/utils/request-pool'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { changeURLStatic } from '@/utils/history.js'
|
import { changeURLStatic } from '@/utils/history.js'
|
||||||
import metaDataProvider from '@/utils/metaDataProvider'
|
import metaDataProvider from '@/utils/metaDataProvider'
|
||||||
cornerstone.metaData.addProvider(metaDataProvider, { priority: 10 });
|
cornerstone.metaData.addProvider(metaDataProvider, { priority: 10 })
|
||||||
// import * as cornerstoneTools from 'cornerstone-tools'
|
// import * as cornerstoneTools from 'cornerstone-tools'
|
||||||
var config = {
|
var config = {
|
||||||
maxWebWorkers: 4,
|
maxWebWorkers: 4,
|
||||||
@@ -348,7 +370,7 @@ export default {
|
|||||||
let res = null
|
let res = null
|
||||||
if (this.page === 'upload') {
|
if (this.page === 'upload') {
|
||||||
res = await getTaskUploadedDicomStudyList({ visitTaskId: this.visitTaskId })
|
res = await getTaskUploadedDicomStudyList({ visitTaskId: this.visitTaskId })
|
||||||
} else if (this.page === 'download'){
|
} else if (this.page === 'download') {
|
||||||
res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading, this.visitTaskId)
|
res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading, this.visitTaskId)
|
||||||
} else {
|
} else {
|
||||||
res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading)
|
res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading)
|
||||||
@@ -399,7 +421,8 @@ export default {
|
|||||||
prefetchInstanceCount: 0,
|
prefetchInstanceCount: 0,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: [],
|
imageloadedArr: [],
|
||||||
isExistMutiFrames: series.IsExistMutiFrames
|
isExistMutiFrames: series.IsExistMutiFrames,
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
data.SeriesList = seriesList
|
data.SeriesList = seriesList
|
||||||
@@ -595,6 +618,83 @@ export default {
|
|||||||
this.loading = false
|
this.loading = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
async changeInstanceReadingStatus(callback, series, instance) {
|
||||||
|
let statusStr = ''
|
||||||
|
if (callback) {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesReading')
|
||||||
|
instance.IsReading = false
|
||||||
|
} else {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesNotReading')
|
||||||
|
instance.IsReading = true
|
||||||
|
}
|
||||||
|
var message = this.$t('trials:audit:message:changeSeriesStatus').replace('xxx', statusStr)
|
||||||
|
message = message.replace('yyy', this.$fd('YesOrNo', !instance.IsReading))
|
||||||
|
const confirm = await this.$confirm(
|
||||||
|
message,
|
||||||
|
{
|
||||||
|
type: 'warning',
|
||||||
|
distinguishCancelAndClose: true
|
||||||
|
}
|
||||||
|
)
|
||||||
|
if (confirm !== 'confirm') return
|
||||||
|
const state = instance.IsReading ? 1 : 2
|
||||||
|
this.loading = true
|
||||||
|
try {
|
||||||
|
const res = await setInstanceStatus(series.trialId, series.subjectVisitId, series.seriesId, instance.Id, state)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
instance.IsReading = !instance.IsReading
|
||||||
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
|
window.opener.postMessage({ type: 'refreshSeriesList', data: '' }, window.location)
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
this.loading = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async changeInstanceDeleteStatus(callback, series, instance) {
|
||||||
|
let statusStr = ''
|
||||||
|
if (callback) {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesDeleted')
|
||||||
|
instance.IsDeleted = false
|
||||||
|
} else {
|
||||||
|
statusStr = this.$t('trials:audit:label:setSeriesNotDelete')
|
||||||
|
instance.IsDeleted = true
|
||||||
|
}
|
||||||
|
var message = this.$t('trials:audit:message:changeSeriesStatus').replace('xxx', statusStr)
|
||||||
|
message = message.replace('yyy', this.$fd('YesOrNo', !instance.IsDeleted))
|
||||||
|
const confirm = await this.$confirm(
|
||||||
|
message,
|
||||||
|
{
|
||||||
|
type: 'warning',
|
||||||
|
distinguishCancelAndClose: true
|
||||||
|
}
|
||||||
|
)
|
||||||
|
if (confirm !== 'confirm') return
|
||||||
|
|
||||||
|
const state = instance.IsDeleted ? 5 : 4
|
||||||
|
this.loading = true
|
||||||
|
try {
|
||||||
|
const res = await setInstanceStatus(series.trialId, series.subjectVisitId, series.seriesId, instance.Id, state)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
instance.IsDeleted = !instance.IsDeleted
|
||||||
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
|
window.opener.postMessage({ type: 'refreshSeriesList', data: '' }, window.location)
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
this.loading = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
popperClick(studyList, series) {
|
||||||
|
for (let i = 0; i < studyList.length; i++) {
|
||||||
|
for (let j = 0; j < studyList[i].SeriesList.length; j++) {
|
||||||
|
if (studyList[i].SeriesList[j].isShowPopper) {
|
||||||
|
studyList[i].SeriesList[j].isShowPopper = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
series.isShowPopper = !series.isShowPopper
|
||||||
|
},
|
||||||
// 切换关联检查Tab时获取关联检查信息
|
// 切换关联检查Tab时获取关联检查信息
|
||||||
async handleTabClick(tab, event) {
|
async handleTabClick(tab, event) {
|
||||||
if (tab.name === 'relation-study' && this.relationStudyList.length <= 0) {
|
if (tab.name === 'relation-study' && this.relationStudyList.length <= 0) {
|
||||||
@@ -671,7 +771,8 @@ export default {
|
|||||||
keySeries: item.KeySeries,
|
keySeries: item.KeySeries,
|
||||||
loadStatus: false,
|
loadStatus: false,
|
||||||
imageloadedArr: [],
|
imageloadedArr: [],
|
||||||
isExistMutiFrames: item.IsExistMutiFrames
|
isExistMutiFrames: item.IsExistMutiFrames,
|
||||||
|
isShowPopper: false
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
scope.relationStudyList[index].seriesCount = seriesList.length
|
scope.relationStudyList[index].seriesCount = seriesList.length
|
||||||
@@ -978,9 +1079,21 @@ export default {
|
|||||||
border: 1px solid #2c2c2c;
|
border: 1px solid #2c2c2c;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
}
|
}
|
||||||
|
.frame_list{
|
||||||
|
max-height: 500px;
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
|
.instance_frame_wrapper ::-webkit-scrollbar {
|
||||||
|
width: 7px;
|
||||||
|
height: 7px;
|
||||||
|
}
|
||||||
|
.instance_frame_wrapper ::-webkit-scrollbar-thumb {
|
||||||
|
border-radius: 10px;
|
||||||
|
background: #d0d0d0;
|
||||||
|
}
|
||||||
.frame_content{
|
.frame_content{
|
||||||
height: 50px;
|
/* height: 50px; */
|
||||||
padding: 5px;
|
padding: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
color: #ddd;
|
color: #ddd;
|
||||||
|
|||||||
@@ -98,7 +98,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UpdateTime"
|
prop="UpdateTime"
|
||||||
label="更新时间"
|
label="上传时间"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -108,7 +108,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UpdateTime"
|
prop="UpdateTime"
|
||||||
label="更新时间"
|
label="上传时间"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -3,13 +3,16 @@
|
|||||||
ref="sysAttachmentFrom"
|
ref="sysAttachmentFrom"
|
||||||
v-loading="loading"
|
v-loading="loading"
|
||||||
:model="form"
|
:model="form"
|
||||||
label-width="170px"
|
label-width="190px"
|
||||||
size="small"
|
size="small"
|
||||||
:rules="rules"
|
:rules="rules"
|
||||||
class="upload-temporary-file"
|
class="upload-temporary-file"
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<el-form-item label="文件类型: " prop="FileTypeId">
|
<el-form-item
|
||||||
|
:label="$t('dictionary:signature:form:FileTypeId')"
|
||||||
|
prop="FileTypeId"
|
||||||
|
>
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.FileTypeId"
|
v-model="form.FileTypeId"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@@ -25,7 +28,7 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="文件: ">
|
<el-form-item :label="$t('dictionary:signature:form:File')">
|
||||||
<div class="upload-container">
|
<div class="upload-container">
|
||||||
<el-upload
|
<el-upload
|
||||||
class="upload-demo"
|
class="upload-demo"
|
||||||
@@ -46,16 +49,16 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
:disabled="form.FileTypeId === ''"
|
:disabled="form.FileTypeId === ''"
|
||||||
:loading="btnLoading"
|
:loading="btnLoading"
|
||||||
>Select</el-button
|
>{{ $t('common:button:check') }}</el-button
|
||||||
>
|
>
|
||||||
<span slot="tip" style="margin-left: 10px" class="el-upload__tip">
|
<span slot="tip" style="margin-left: 10px" class="el-upload__tip">
|
||||||
(must be in pdf format)
|
({{ $t('trials:signature:label:mustBepdf') }})
|
||||||
</span>
|
</span>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="需要签署的用户类型: "
|
:label="$t('dictionary:signature:form:NeedConfirmedUserTypeIdList')"
|
||||||
prop="NeedConfirmedUserTypeIdList"
|
prop="NeedConfirmedUserTypeIdList"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -71,7 +74,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否仅内部签署: " prop="DocUserSignType">
|
<el-form-item
|
||||||
|
:label="$t('dictionary:signature:form:DocUserSignType')"
|
||||||
|
prop="DocUserSignType"
|
||||||
|
>
|
||||||
<el-switch
|
<el-switch
|
||||||
v-model="form.DocUserSignType"
|
v-model="form.DocUserSignType"
|
||||||
:active-value="1"
|
:active-value="1"
|
||||||
@@ -80,7 +86,7 @@
|
|||||||
</el-switch>
|
</el-switch>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="查看最短时间(分钟): "
|
:label="$t('dictionary:signature:form:SignViewMinimumMinutes')"
|
||||||
prop="SignViewMinimumMinutes"
|
prop="SignViewMinimumMinutes"
|
||||||
>
|
>
|
||||||
<el-input-number
|
<el-input-number
|
||||||
@@ -105,7 +111,7 @@
|
|||||||
:disabled="form.FileTypeId === '' || form.Name === ''"
|
:disabled="form.FileTypeId === '' || form.Name === ''"
|
||||||
:loading="saveBtnLoading"
|
:loading="saveBtnLoading"
|
||||||
@click="handleSave"
|
@click="handleSave"
|
||||||
>Save</el-button
|
>{{ $t('common:button:save') }}</el-button
|
||||||
>
|
>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
@@ -138,13 +144,25 @@ export default {
|
|||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
FileTypeId: [
|
FileTypeId: [
|
||||||
{ required: true, message: 'Please select', trigger: ['blur'] },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:select'),
|
||||||
|
trigger: ['blur'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
SignViewMinimumMinutes: [
|
SignViewMinimumMinutes: [
|
||||||
{ required: true, message: 'Please specify', trigger: ['change'] },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:specify'),
|
||||||
|
trigger: ['change'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
NeedConfirmedUserTypeIdList: [
|
NeedConfirmedUserTypeIdList: [
|
||||||
{ required: true, message: 'Please select', trigger: ['blur'] },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:select'),
|
||||||
|
trigger: ['blur'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
fileList: [],
|
fileList: [],
|
||||||
@@ -211,7 +229,7 @@ export default {
|
|||||||
this.fileList = []
|
this.fileList = []
|
||||||
return true
|
return true
|
||||||
} else {
|
} else {
|
||||||
this.$alert('must be in pdf format')
|
this.$alert(this.$t('trials:signature:label:mustBepdf'))
|
||||||
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
@@ -236,7 +254,7 @@ export default {
|
|||||||
this.$refs.sysAttachmentFrom.validate((valid) => {
|
this.$refs.sysAttachmentFrom.validate((valid) => {
|
||||||
if (!valid) return
|
if (!valid) return
|
||||||
if (!this.form.Name) {
|
if (!this.form.Name) {
|
||||||
this.$alert('Please select file.')
|
this.$alert(this.$t('trials:signature:message:selectFile'))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.saveBtnLoading = true
|
this.saveBtnLoading = true
|
||||||
@@ -245,7 +263,7 @@ export default {
|
|||||||
this.saveBtnLoading = false
|
this.saveBtnLoading = false
|
||||||
this.$emit('closeDialog')
|
this.$emit('closeDialog')
|
||||||
this.$emit('getList')
|
this.$emit('getList')
|
||||||
this.$message.success('Uploaded successfully')
|
this.$message.success(this.$t('common:message:updatedSuccessfully'))
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.saveBtnLoading = false
|
this.saveBtnLoading = false
|
||||||
@@ -263,7 +281,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleExceed(files, fileList) {
|
handleExceed(files, fileList) {
|
||||||
this.$message.warning(`Upload is currently limited to 1 file`)
|
this.$message.warning(this.$t('upload:rule:maxFile1'))
|
||||||
},
|
},
|
||||||
checkFileSuffix(fileName) {
|
checkFileSuffix(fileName) {
|
||||||
var typeArr = ['pdf']
|
var typeArr = ['pdf']
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<BaseContainer>
|
<BaseContainer>
|
||||||
<template slot="search-container">
|
<template slot="search-container">
|
||||||
<el-form :inline="true" size="small">
|
<el-form :inline="true" size="small">
|
||||||
<el-form-item label="文件类型:">
|
<el-form-item :label="$t('dictionary:signature:search:FileTypeId')">
|
||||||
<el-select v-model="searchData.FileTypeId" style="width: 150px">
|
<el-select v-model="searchData.FileTypeId" style="width: 150px">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of dict.type.Sys_Document"
|
v-for="item of dict.type.Sys_Document"
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="文件名称">
|
<el-form-item :label="$t('dictionary:signature:search:Name')">
|
||||||
<el-input v-model="searchData.Name" style="width: 130px" clearable />
|
<el-input v-model="searchData.Name" style="width: 130px" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
style="margin-left: auto"
|
style="margin-left: auto; margin-bottom: 10px"
|
||||||
size="small"
|
size="small"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>
|
>
|
||||||
@@ -53,26 +53,27 @@
|
|||||||
<el-table-column type="index" width="40" />
|
<el-table-column type="index" width="40" />
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="FileType"
|
prop="FileType"
|
||||||
label="文件类型"
|
:label="$t('dictionary:signature:table:FileType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Name"
|
prop="Name"
|
||||||
label="文件名称"
|
:label="$t('dictionary:signature:table:Name')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="SignViewMinimumMinutes"
|
prop="SignViewMinimumMinutes"
|
||||||
label="查看最短时间(分钟)"
|
:label="$t('dictionary:signature:table:SignViewMinimumMinutes')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
|
min-width="110"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="NeedConfirmedUserTypes"
|
prop="NeedConfirmedUserTypes"
|
||||||
label="需要签署的用户类型"
|
:label="$t('dictionary:signature:table:NeedConfirmedUserTypes')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -85,48 +86,54 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsDeleted"
|
prop="IsDeleted"
|
||||||
label="是否废除"
|
:label="$t('dictionary:signature:table:IsDeleted')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.IsDeleted ? 'Yes' : 'No' }}
|
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
||||||
|
$fd('TrainingStatus', scope.row.IsDeleted)
|
||||||
|
}}</el-tag>
|
||||||
|
<el-tag v-else type="primary">{{
|
||||||
|
$fd('TrainingStatus', scope.row.IsDeleted)
|
||||||
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="DocUserSignType"
|
prop="DocUserSignType"
|
||||||
label="是否仅内部签署"
|
:label="$t('dictionary:signature:table:DocUserSignType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
|
min-width="90"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('ReadingYesOrNo', Number(scope.row.DocUserSignType)) }}
|
{{ $fd('ReadingYesOrNo', Number(scope.row.DocUserSignType)) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UpdateTime"
|
prop="CreateTime"
|
||||||
label="更新时间"
|
:label="$t('dictionary:signature:table:CreateTime')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<el-table-column label="Action">
|
<el-table-column :label="$t('common:action:action')" min-width="100">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button type="text" @click="handlePreview(scope.row)">
|
<el-button type="text" @click="handlePreview(scope.row)">
|
||||||
预览
|
{{ $t('common:button:preview') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="text" @click="handleEdit(scope.row)">
|
<el-button type="text" @click="handleEdit(scope.row)">
|
||||||
编辑
|
{{ $t('common:button:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
:disabled="scope.row.IsDeleted"
|
:disabled="scope.row.IsDeleted"
|
||||||
type="text"
|
type="text"
|
||||||
@click="handleRepeal(scope.row)"
|
@click="handleRepeal(scope.row)"
|
||||||
>
|
>
|
||||||
废除
|
{{ $t('common:button:revoke') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="text" @click="handleDelete(scope.row)">
|
<el-button type="text" @click="handleDelete(scope.row)">
|
||||||
删除
|
{{ $t('common:button:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -261,7 +268,7 @@ export default {
|
|||||||
},
|
},
|
||||||
// 废除
|
// 废除
|
||||||
handleRepeal(row) {
|
handleRepeal(row) {
|
||||||
this.$confirm('是否确认废除此文件?', {
|
this.$confirm(this.$t('dictionary:signature:confirm:delFile'), {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true,
|
distinguishCancelAndClose: true,
|
||||||
})
|
})
|
||||||
@@ -298,7 +305,9 @@ export default {
|
|||||||
this.list.findIndex((item) => item.Id === row.Id),
|
this.list.findIndex((item) => item.Id === row.Id),
|
||||||
1
|
1
|
||||||
)
|
)
|
||||||
this.$message.success('删除成功!')
|
this.$message.success(
|
||||||
|
this.$t('common:message:deletedSuccessfully')
|
||||||
|
)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
|
|||||||
@@ -111,7 +111,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UpdateTime"
|
prop="UpdateTime"
|
||||||
label="更新时间"
|
label="上传时间"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -73,13 +73,13 @@
|
|||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -9,8 +9,19 @@
|
|||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<el-form-item label="Site: ">
|
<el-form-item label="Site: ">
|
||||||
<el-select v-model="form.SiteId" style="width: 100%" clearable filterable @change="siteChange">
|
<el-select
|
||||||
<el-option v-for="item of siteList" :value="item.Id" :key="item.Id" :label="item.SiteName">
|
v-model="form.SiteId"
|
||||||
|
style="width: 100%"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
@change="siteChange"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item of siteList"
|
||||||
|
:value="item.Id"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="item.SiteName"
|
||||||
|
>
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -20,10 +31,16 @@
|
|||||||
<el-form-item label="Hospital EN: " prop="HospitalName">
|
<el-form-item label="Hospital EN: " prop="HospitalName">
|
||||||
<el-input v-model="form.HospitalName" />
|
<el-input v-model="form.HospitalName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="Affiliated University CN: " prop="UniversityAffiliatedCN">
|
<el-form-item
|
||||||
|
label="Affiliated University CN: "
|
||||||
|
prop="UniversityAffiliatedCN"
|
||||||
|
>
|
||||||
<el-input v-model="form.UniversityAffiliatedCN" />
|
<el-input v-model="form.UniversityAffiliatedCN" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="Affiliated University EN: " prop="UniversityAffiliated">
|
<el-form-item
|
||||||
|
label="Affiliated University EN: "
|
||||||
|
prop="UniversityAffiliated"
|
||||||
|
>
|
||||||
<el-input v-model="form.UniversityAffiliated" />
|
<el-input v-model="form.UniversityAffiliated" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="Country CN: " prop="CountryCN">
|
<el-form-item label="Country CN: " prop="CountryCN">
|
||||||
@@ -45,10 +62,22 @@
|
|||||||
<el-input v-model="form.City" />
|
<el-input v-model="form.City" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div class="base-dialog-footer" style="text-align:right;margin-top:10px;">
|
<div class="base-dialog-footer" style="text-align: right; margin-top: 10px">
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button :disabled="btnLoading" size="small" type="primary" @click="handleCancel">Cancel</el-button>
|
<el-button
|
||||||
<el-button size="small" type="primary" :loading="btnLoading" @click="handleSave">Save</el-button>
|
:disabled="btnLoading"
|
||||||
|
size="small"
|
||||||
|
type="primary"
|
||||||
|
@click="handleCancel"
|
||||||
|
>Cancel</el-button
|
||||||
|
>
|
||||||
|
<el-button
|
||||||
|
size="small"
|
||||||
|
type="primary"
|
||||||
|
:loading="btnLoading"
|
||||||
|
@click="handleSave"
|
||||||
|
>Save</el-button
|
||||||
|
>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
@@ -63,14 +92,14 @@ export default {
|
|||||||
type: Object,
|
type: Object,
|
||||||
default() {
|
default() {
|
||||||
return {}
|
return {}
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
model: {
|
model: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default() {
|
default() {
|
||||||
return {}
|
return {}
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -87,23 +116,36 @@ export default {
|
|||||||
Province: '',
|
Province: '',
|
||||||
ProvinceCN: '',
|
ProvinceCN: '',
|
||||||
City: '',
|
City: '',
|
||||||
CityCN: ''
|
CityCN: '',
|
||||||
},
|
},
|
||||||
siteList: [],
|
siteList: [],
|
||||||
rules: {
|
rules: {
|
||||||
HospitalNameCN: [{ required: true, message: 'Please specify', trigger: 'blur' }, { max: 50, message: 'The maximum length is 50' }],
|
HospitalNameCN: [
|
||||||
UniversityAffiliated: [{ max: 100, message: 'The maximum length is 100' }],
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
UniversityAffiliatedCN: [{ max: 100, message: 'The maximum length is 100' }],
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
Country: [{ required: true, message: 'Please specify', trigger: 'blur' },
|
],
|
||||||
{ max: 50, message: 'The maximum length is 50' }],
|
UniversityAffiliated: [
|
||||||
CountryCN: [{ max: 50, message: 'The maximum length is 50' }],
|
{ max: 100, message: 'The maximum length is 100' },
|
||||||
Province: [{ required: true, message: 'Please specify', trigger: 'blur' },
|
],
|
||||||
{ max: 50, message: 'The maximum length is 50' }],
|
UniversityAffiliatedCN: [
|
||||||
ProvinceCN: [{ max: 50, message: 'The maximum length is 50' }],
|
{ max: 100, message: 'The maximum length is 100' },
|
||||||
City: [{ required: true, message: 'Please specify', trigger: 'blur' },
|
],
|
||||||
{ max: 50, message: 'The maximum length is 50' }],
|
Country: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
CityCN: [{ max: 50, message: 'The maximum length is 50' }]
|
CountryCN: [
|
||||||
}
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
|
],
|
||||||
|
Province: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
|
ProvinceCN: [
|
||||||
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
|
],
|
||||||
|
City: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
|
CityCN: [
|
||||||
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
|
],
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -114,7 +156,7 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
siteChange(v) {
|
siteChange(v) {
|
||||||
this.siteList.forEach(o => {
|
this.siteList.forEach((o) => {
|
||||||
if (o.Id === v) {
|
if (o.Id === v) {
|
||||||
this.form.CityCN = o.City
|
this.form.CityCN = o.City
|
||||||
this.form.HospitalNameCN = o.SiteNameCN
|
this.form.HospitalNameCN = o.SiteNameCN
|
||||||
@@ -125,34 +167,37 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
getAllSiteList() {
|
getAllSiteList() {
|
||||||
getAllSiteList().then(res => {
|
getAllSiteList()
|
||||||
this.siteList = res.Result
|
.then((res) => {
|
||||||
console.log(this.siteList)
|
this.siteList = res.Result
|
||||||
}).catch(() => {
|
console.log(this.siteList)
|
||||||
reject()
|
})
|
||||||
})
|
.catch(() => {
|
||||||
|
reject()
|
||||||
|
})
|
||||||
},
|
},
|
||||||
handleSave() {
|
handleSave() {
|
||||||
this.$refs.hospitalForm.validate(valid => {
|
this.$refs.hospitalForm.validate((valid) => {
|
||||||
if (!valid) return
|
if (!valid) return
|
||||||
this.btnLoading = true
|
this.btnLoading = true
|
||||||
addOrUpdateHospital(this.form).then(res => {
|
addOrUpdateHospital(this.form)
|
||||||
this.btnLoading = false
|
.then((res) => {
|
||||||
if (res.IsSuccess) {
|
this.btnLoading = false
|
||||||
this.$message.success('Saved successfully')
|
if (res.IsSuccess) {
|
||||||
this.$refs['hospitalForm'].resetFields()
|
this.$message.success('Saved successfully')
|
||||||
this.$emit('getList')
|
this.$refs['hospitalForm'].resetFields()
|
||||||
this.$emit('close')
|
this.$emit('getList')
|
||||||
}
|
this.$emit('close')
|
||||||
}).catch(() => {
|
}
|
||||||
this.btnLoading = false
|
})
|
||||||
})
|
.catch(() => {
|
||||||
|
this.btnLoading = false
|
||||||
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
this.$emit('close')
|
this.$emit('close')
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -113,13 +113,13 @@
|
|||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -32,9 +32,9 @@
|
|||||||
<el-input v-model="form.AliasName" />
|
<el-input v-model="form.AliasName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="组织机构代码: ">
|
<!-- <el-form-item label="组织机构代码: ">
|
||||||
<el-input v-model="form.UniqueCode" />
|
<el-input v-model="form.UniqueCode" />
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
|
|
||||||
<el-form-item label="Country: " prop="Country">
|
<el-form-item label="Country: " prop="Country">
|
||||||
<el-input v-model="form.Country" />
|
<el-input v-model="form.Country" />
|
||||||
|
|||||||
@@ -74,13 +74,13 @@
|
|||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<!-- <el-table-column
|
||||||
prop="UniqueCode"
|
prop="UniqueCode"
|
||||||
label="组织机构代码"
|
label="组织机构代码"
|
||||||
min-width="130"
|
min-width="130"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/> -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Country"
|
prop="Country"
|
||||||
label="Country"
|
label="Country"
|
||||||
@@ -149,13 +149,13 @@
|
|||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -73,13 +73,13 @@
|
|||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -10,12 +10,16 @@
|
|||||||
<el-input v-model="searchData.Version" style="width: 100px" />
|
<el-input v-model="searchData.Version" style="width: 100px" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">{{
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
$t("dictionary:browser:button:reset")
|
{{ $t('common:button:search') }}
|
||||||
}}</el-button>
|
</el-button>
|
||||||
<el-button type="primary" @click="handleSearch">{{
|
<el-button
|
||||||
$t("dictionary:browser:button:search")
|
type="primary"
|
||||||
}}</el-button>
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left: auto">
|
<span style="margin-left: auto">
|
||||||
|
|||||||
@@ -8,13 +8,14 @@
|
|||||||
:rules="rules"
|
:rules="rules"
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<el-form-item label="标准名称" prop="CriterionName">
|
<!-- 标准名称 -->
|
||||||
|
<el-form-item :label="$t('trials:auditRecord:table:criterion')" prop="CriterionName">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.CriterionName"
|
v-model="form.CriterionName"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 标准类型 -->
|
||||||
<el-form-item label="标准类型" prop="CriterionType">
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:criterionType')" prop="CriterionType">
|
||||||
<el-select v-model="form.CriterionType">
|
<el-select v-model="form.CriterionType">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of $d.CriterionType"
|
v-for="item of $d.CriterionType"
|
||||||
@@ -24,23 +25,37 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 标准分组 -->
|
||||||
<el-form-item v-if="form.Id !== ''" label="是否配置完成">
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:criterionGroup')" prop="CriterionGroup">
|
||||||
|
<el-select v-model="form.CriterionGroup">
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.CriterionGroup"
|
||||||
|
:key="item.id"
|
||||||
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 是否配置完成 -->
|
||||||
|
<el-form-item v-if="form.Id !== ''" :label="$t('dictionary:template:criterionConfig:table:isCompleteConfig')">
|
||||||
<el-switch v-model="form.IsCompleteConfig" />
|
<el-switch v-model="form.IsCompleteConfig" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="描述">
|
<!-- 描述 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:description')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.Description"
|
v-model="form.Description"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 显示序号 -->
|
||||||
<el-form-item label="显示序号: " prop="ShowOrder">
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:showOrder')" prop="ShowOrder">
|
||||||
<el-input-number v-model="form.ShowOrder" :min="0" style="width:100%;" />
|
<el-input-number v-model="form.ShowOrder" :min="0" style="width:100%;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.Id !== ''" label="是否启用">
|
<!-- 是否启用 -->
|
||||||
|
<el-form-item v-if="form.Id !== ''" :label="$t('dictionary:template:criterionConfig:table:isEnable')">
|
||||||
<el-switch v-model="form.IsEnable" />
|
<el-switch v-model="form.IsEnable" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.Id !== ''" label="eCRF是否显示在影像阅片页面">
|
<!-- eICRF仅展示阅片Tab -->
|
||||||
|
<el-form-item v-if="form.Id !== ''" :label="$t('dictionary:template:criterionConfig:table:isECRFShowInDicomReading')">
|
||||||
<el-switch v-model="form.IseCRFShowInDicomReading" />
|
<el-switch v-model="form.IseCRFShowInDicomReading" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
@@ -72,6 +87,7 @@ export default {
|
|||||||
Id: '',
|
Id: '',
|
||||||
CriterionName: '',
|
CriterionName: '',
|
||||||
CriterionType: null,
|
CriterionType: null,
|
||||||
|
CriterionGroup: null,
|
||||||
IsEnable: true,
|
IsEnable: true,
|
||||||
IsCompleteConfig: false,
|
IsCompleteConfig: false,
|
||||||
ShowOrder: null,
|
ShowOrder: null,
|
||||||
@@ -80,7 +96,8 @@ export default {
|
|||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
CriterionName: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: ['blur'] }],
|
CriterionName: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: ['blur'] }],
|
||||||
CriterionType: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur'] }]
|
CriterionType: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur'] }],
|
||||||
|
CriterionGroup: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur'] }]
|
||||||
},
|
},
|
||||||
|
|
||||||
loading: false,
|
loading: false,
|
||||||
|
|||||||
@@ -16,8 +16,16 @@
|
|||||||
<el-input v-model="searchData.TagDescriptionCN" clearable style="width:120px;" />
|
<el-input v-model="searchData.TagDescriptionCN" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">Reset</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">Search</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
|
|||||||
@@ -27,8 +27,16 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">重置</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">查询</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
@@ -101,6 +109,15 @@
|
|||||||
{{ scope.row.FileName }}
|
{{ scope.row.FileName }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
prop="EnFileName"
|
||||||
|
label="模板英文名称"
|
||||||
|
show-overflow-tooltip
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.EnFileName }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsEnable"
|
prop="IsEnable"
|
||||||
label="状态"
|
label="状态"
|
||||||
@@ -128,10 +145,20 @@
|
|||||||
问题配置
|
问题配置
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-if="$i18n.locale === 'zh'"
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
:disabled="!scope.row.FileName"
|
:disabled="!scope.row.FileName"
|
||||||
@click="handleDownloadTpl(scope.row)"
|
@click="handleDownloadTpl(scope.row.Path)"
|
||||||
|
>
|
||||||
|
下载
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
v-else
|
||||||
|
type="primary"
|
||||||
|
size="mini"
|
||||||
|
:disabled="!scope.row.EnFileName"
|
||||||
|
@click="handleDownloadTpl(scope.row.EnPath)"
|
||||||
>
|
>
|
||||||
下载
|
下载
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -250,8 +277,8 @@ export default {
|
|||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleDownloadTpl(row) {
|
handleDownloadTpl(path) {
|
||||||
window.open(this.OSSclientConfig.basePath + row.Path, '_blank')
|
window.open(this.OSSclientConfig.basePath + path, '_blank')
|
||||||
},
|
},
|
||||||
// 排序
|
// 排序
|
||||||
handleSortByColumn(column) {
|
handleSortByColumn(column) {
|
||||||
|
|||||||
@@ -113,6 +113,34 @@
|
|||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item v-if="form.ClinicalUploadType === 1" label="英文模板: ">
|
||||||
|
<div class="upload-container">
|
||||||
|
<el-upload
|
||||||
|
class="upload-demo"
|
||||||
|
action
|
||||||
|
accept=".doc,.docx"
|
||||||
|
:before-upload="beforeUploadEnFile"
|
||||||
|
:http-request="handleUploadEnFile"
|
||||||
|
:on-preview="handlePreview"
|
||||||
|
:on-remove="handleRemoveEnFile"
|
||||||
|
:show-file-list="true"
|
||||||
|
:file-list="enFileList"
|
||||||
|
:limit="1"
|
||||||
|
:on-exceed="handleExceed"
|
||||||
|
:disabled="form.Type === ''"
|
||||||
|
>
|
||||||
|
<el-button size="small" type="primary">选择</el-button>
|
||||||
|
<span
|
||||||
|
slot="tip"
|
||||||
|
style="margin-left:10px;"
|
||||||
|
class="el-upload__tip"
|
||||||
|
>
|
||||||
|
(必须是doc/docx格式)
|
||||||
|
</span>
|
||||||
|
</el-upload>
|
||||||
|
</div>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item v-if="form.Id !== ''" label="是否启用">
|
<el-form-item v-if="form.Id !== ''" label="是否启用">
|
||||||
<el-switch v-model="form.IsEnable" />
|
<el-switch v-model="form.IsEnable" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -160,6 +188,8 @@ export default {
|
|||||||
UploadRole: null,
|
UploadRole: null,
|
||||||
FileName: '',
|
FileName: '',
|
||||||
Path: '',
|
Path: '',
|
||||||
|
EnFileName: '',
|
||||||
|
EnPath: '',
|
||||||
IsEnable: true,
|
IsEnable: true,
|
||||||
CriterionEnumList: []
|
CriterionEnumList: []
|
||||||
},
|
},
|
||||||
@@ -173,6 +203,7 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
btnLoading: false,
|
btnLoading: false,
|
||||||
fileList: [],
|
fileList: [],
|
||||||
|
enFileList: [],
|
||||||
systemCriterionSelectList: []
|
systemCriterionSelectList: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -195,6 +226,14 @@ export default {
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
if (this.data.EnPath) {
|
||||||
|
this.enFileList = [
|
||||||
|
{
|
||||||
|
name: this.data.EnFileName,
|
||||||
|
path: this.data.EnPath
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
save() {
|
save() {
|
||||||
@@ -249,6 +288,32 @@ export default {
|
|||||||
handleExceed(files, fileList) {
|
handleExceed(files, fileList) {
|
||||||
this.$message.warning(`只允许上传一个文件`)
|
this.$message.warning(`只允许上传一个文件`)
|
||||||
},
|
},
|
||||||
|
beforeUploadEnFile(file) {
|
||||||
|
// 检测文件类型是否符合要求
|
||||||
|
if (this.checkFileSuffix(file.name)) {
|
||||||
|
this.enFileList = []
|
||||||
|
return true
|
||||||
|
} else {
|
||||||
|
this.$alert('(必须是doc/docx格式)')
|
||||||
|
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async handleUploadEnFile(param) {
|
||||||
|
this.loading = true
|
||||||
|
var fileBlob = await this.fileToBlob(param.file)
|
||||||
|
const res = await this.OSSclient.put(`/System/ClinicalDataTemplate/${param.file.name}`, fileBlob)
|
||||||
|
this.form.EnFileName = res.name
|
||||||
|
this.form.EnPath = this.$getObjectName(res.url)
|
||||||
|
let file = { name: res.name, path: this.$getObjectName(res.url), url:this.$getObjectName(res.url) }
|
||||||
|
this.enFileList.push(file)
|
||||||
|
this.loading = false
|
||||||
|
},
|
||||||
|
handleRemoveEnFile() {
|
||||||
|
this.enFileList = []
|
||||||
|
this.form.EnPath = ''
|
||||||
|
this.form.EnFileName = ''
|
||||||
|
},
|
||||||
checkFileSuffix(fileName) {
|
checkFileSuffix(fileName) {
|
||||||
var typeArr = ['doc', 'docx']
|
var typeArr = ['doc', 'docx']
|
||||||
var extendName = fileName.substring(fileName.lastIndexOf('.') + 1).toLocaleLowerCase()
|
var extendName = fileName.substring(fileName.lastIndexOf('.') + 1).toLocaleLowerCase()
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
:prop="question.Id"
|
:prop="question.Id"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: (question.IsRequired === 0 || (question.IsRequired ===1 && question.RelevanceId && question.RelevanceValueList.includes(questionForm[question.RelevanceId]))) && question.Type!=='group' && question.Type!=='summary',
|
{ required: (question.IsRequired === 0 || (question.IsRequired ===1 && question.RelevanceId && question.RelevanceValueList.includes(questionForm[question.RelevanceId]))) && question.Type!=='group' && question.Type!=='summary',
|
||||||
message: '请注明', trigger: ['blur', 'change']},
|
message: this.$t('common:ruleMessage:specify'), trigger: ['blur', 'change']},
|
||||||
]"
|
]"
|
||||||
:class="[question.Type==='group'?'mb':question.Type==='upload'?'uploadWrapper':'']"
|
:class="[question.Type==='group'?'mb':question.Type==='upload'?'uploadWrapper':'']"
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
<div class="base-dialog-body" style="height: 550px; display:flex;flex-direction: column;">
|
<div class="base-dialog-body" style="height: 550px; display:flex;flex-direction: column;">
|
||||||
<div style="height: 150px;">
|
<div style="height: 150px;">
|
||||||
<!-- 类型 -->
|
<!-- 类型 -->
|
||||||
<el-form-item label="类型" prop="Type">
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:type')" prop="Type">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.Type"
|
v-model="form.Type"
|
||||||
clearable
|
clearable
|
||||||
@@ -33,22 +33,23 @@
|
|||||||
<!-- 分组名称 -->
|
<!-- 分组名称 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'group'"
|
v-if="form.Type === 'group'"
|
||||||
label="分组名称"
|
:label="$t('trials:readingUnit:qsList:title:groupNameEn')"
|
||||||
prop="GroupName"
|
prop="GroupName"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.GroupName" />
|
<el-input v-model="form.GroupName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 分组名称(EN) -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'group'"
|
v-if="form.Type === 'group'"
|
||||||
label="分组名称(EN)"
|
:label="$t('trials:readingUnit:qsList:title:groupNameEn')"
|
||||||
prop="GroupEnName"
|
prop="GroupEnName"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.GroupEnName" />
|
<el-input v-model="form.GroupEnName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题名称 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="问题名称"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
prop="QuestionName"
|
prop="QuestionName"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
@@ -57,10 +58,10 @@
|
|||||||
>
|
>
|
||||||
<el-input v-model="form.QuestionName" />
|
<el-input v-model="form.QuestionName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题名称(EN) -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="问题名称(EN)"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
prop="QuestionEnName"
|
prop="QuestionEnName"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ max: form.Type === 'summary' ? 300 : 100, message: `${this.$t('common:ruleMessage:maxLength')} ${form.Type === 'summary' ? 300 : 100}` }
|
{ max: form.Type === 'summary' ? 300 : 100, message: `${this.$t('common:ruleMessage:maxLength')} ${form.Type === 'summary' ? 300 : 100}` }
|
||||||
@@ -70,10 +71,12 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div style="flex: 1;overflow-y:auto;">
|
<div style="flex: 1;overflow-y:auto;">
|
||||||
<el-divider content-position="left">公有属性</el-divider>
|
<!-- 公有属性 -->
|
||||||
|
<el-divider content-position="left">{{$t('trials:readingUnit:title:publicProperties')}}</el-divider>
|
||||||
|
<!-- 问题分组 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="问题分组"
|
:label="$t('trials:readingUnit:qsList:title:qsGroupName')"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: form.ShowQuestion === 1 ? false : true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: form.ShowQuestion === 1 ? false : true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
]"
|
]"
|
||||||
@@ -91,9 +94,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 是否显示 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="是否显示"
|
:label="$t('trials:readingUnit:qsList:title:isShow')"
|
||||||
prop="ShowQuestion"
|
prop="ShowQuestion"
|
||||||
>
|
>
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
@@ -117,7 +121,7 @@
|
|||||||
<!-- 显示时依赖父问题 -->
|
<!-- 显示时依赖父问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.ShowQuestion === 1"
|
v-if="form.Type !== 'group' && form.ShowQuestion === 1"
|
||||||
label="显示依赖父问题"
|
:label="$t('trials:readingUnit:qsList:title:parentId')"
|
||||||
prop="ParentId"
|
prop="ParentId"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -140,7 +144,7 @@
|
|||||||
<!-- 显示时依赖父问题触发值 -->
|
<!-- 显示时依赖父问题触发值 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.ParentId && form.ShowQuestion === 1"
|
v-if="form.ParentId && form.ShowQuestion === 1"
|
||||||
label="显示触发值"
|
:label="$t('trials:readingUnit:qsList:title:parentTriggerValueList')"
|
||||||
prop="ParentTriggerValueList"
|
prop="ParentTriggerValueList"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
||||||
@@ -152,10 +156,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 是否必填 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'basicTable' && form.Type !== 'summary'"
|
v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'basicTable' && form.Type !== 'summary'"
|
||||||
label="是否必填"
|
:label="$t('trials:readingUnit:qsList:title:isRequired')" prop="IsRequired"
|
||||||
prop="IsRequired"
|
|
||||||
>
|
>
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.IsRequired"
|
v-model="form.IsRequired"
|
||||||
@@ -176,10 +180,10 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<!-- 父问题 -->
|
<!-- 必填依赖父问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.IsRequired === 1"
|
v-if="form.Type !== 'group' && form.IsRequired === 1"
|
||||||
label="必填依赖父问题"
|
:label="$t('trials:readingUnit:qsList:title:relevanceId')"
|
||||||
prop="RelevanceId"
|
prop="RelevanceId"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -199,10 +203,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 必填依赖的父问题触发值 -->
|
<!-- 必填触发值 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.RelevanceId && form.IsRequired === 1"
|
v-if="form.RelevanceId && form.IsRequired === 1"
|
||||||
label="必填触发值"
|
:label="$t('trials:readingUnit:qsList:title:relevanceValueList')"
|
||||||
prop="RelevanceValueList"
|
prop="RelevanceValueList"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.RelevanceValueList" clearable multiple>
|
<el-select v-model="form.RelevanceValueList" clearable multiple>
|
||||||
@@ -214,6 +218,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 是否裁判问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="
|
v-if="
|
||||||
form.Type === 'select' ||
|
form.Type === 'select' ||
|
||||||
@@ -221,7 +226,7 @@
|
|||||||
form.Type === 'calculation' ||
|
form.Type === 'calculation' ||
|
||||||
form.Type === 'number'
|
form.Type === 'number'
|
||||||
"
|
"
|
||||||
label="是否裁判问题"
|
:label="$t('trials:readingUnit:qsList:title:isJudgeQuestion')"
|
||||||
prop="IsJudgeQuestion"
|
prop="IsJudgeQuestion"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -243,7 +248,7 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="导出标识"
|
<!-- <el-form-item label="导出标识"
|
||||||
prop="ExportIdentification"
|
prop="ExportIdentification"
|
||||||
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
||||||
>
|
>
|
||||||
@@ -262,8 +267,12 @@
|
|||||||
>{{ item.label }}
|
>{{ item.label }}
|
||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<el-form-item label="导出结果" v-if="form.ExportIdentification" prop="ExportResult">
|
<!-- 导出结果 -->
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:ExportResult')"
|
||||||
|
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
||||||
|
>
|
||||||
<el-select v-model="form.ExportResult" multiple>
|
<el-select v-model="form.ExportResult" multiple>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in CriterionDictionaryList.ExportResult"
|
v-for="item in CriterionDictionaryList.ExportResult"
|
||||||
@@ -274,9 +283,9 @@
|
|||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 限制编辑 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="限制编辑"
|
:label="$t('trials:readingUnit:qsList:title:limitEdit')"
|
||||||
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'upload' || form.Type === 'number' || form.Type === 'screenshot'"
|
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'upload' || form.Type === 'number' || form.Type === 'screenshot'"
|
||||||
prop="LimitEdit"
|
prop="LimitEdit"
|
||||||
:rules="[
|
:rules="[
|
||||||
@@ -292,8 +301,9 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 全局阅片是否显示 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="全局阅片是否显示"
|
:label="$t('trials:readingUnit:qsList:title:globalReadingShowType')"
|
||||||
prop="GlobalReadingShowType"
|
prop="GlobalReadingShowType"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -308,8 +318,9 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题标识 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="问题标识"
|
:label="$t('dictionary:template:criterionConfig:table:questionType')"
|
||||||
v-if="form.Type !== 'group' && form.Type !== 'summary'"
|
v-if="form.Type !== 'group' && form.Type !== 'summary'"
|
||||||
prop="QuestionType"
|
prop="QuestionType"
|
||||||
>
|
>
|
||||||
@@ -322,8 +333,9 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 是否在阅片页面显示 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="是否在阅片页面显示"
|
:label="$t('trials:readingUnit:qsList:title:isShowInDicom')"
|
||||||
prop="IsShowInDicom"
|
prop="IsShowInDicom"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -338,14 +350,16 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 注释 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="注释"
|
:label="$t('trials:readingUnit:qsList:title:Remark')"
|
||||||
prop="Remark"
|
prop="Remark"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.Remark" />
|
<el-input v-model="form.Remark" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="序号"
|
:label="$t('trials:readingUnit:qsList:title:order')"
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -358,7 +372,8 @@
|
|||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 适用于Lugano 2014标准 -->
|
<!-- 适用于Lugano 2014标准 -->
|
||||||
<el-form-item label="问题分类" v-if="form.Type !== 'group' && criterionType === 2">
|
<!-- 问题分类 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:questionClassify')" v-if="form.Type !== 'group' && criterionType === 2">
|
||||||
<el-select v-model="form.QuestionClassify" clearable>
|
<el-select v-model="form.QuestionClassify" clearable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of $d.QuestionClassify"
|
v-for="item of $d.QuestionClassify"
|
||||||
@@ -369,7 +384,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 适用于iRECST标准 -->
|
<!-- 适用于iRECST标准 -->
|
||||||
<el-form-item label="转化显示类型" prop="ConvertShowType" v-if="criterionType === 3">
|
<!-- 转化显示类型 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:convertType')" prop="ConvertShowType" v-if="criterionType === 3">
|
||||||
<el-radio-group v-model="form.ConvertShowType">
|
<el-radio-group v-model="form.ConvertShowType">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.ConvertShowType"
|
v-for="item of $d.ConvertShowType"
|
||||||
@@ -380,16 +396,18 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-divider content-position="left">私有属性</el-divider>
|
<!-- 私有属性 -->
|
||||||
|
<el-divider content-position="left">{{$t('trials:readingUnit:title:privateProperties')}}</el-divider>
|
||||||
|
<!-- 选项类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="
|
v-if="
|
||||||
form.Type === 'select' ||
|
form.Type === 'select' ||
|
||||||
form.Type === 'radio' ||
|
form.Type === 'radio' ||
|
||||||
form.Type === 'calculation'
|
form.Type === 'calculation'
|
||||||
"
|
"
|
||||||
label="选项类型"
|
:label="$t('trials:readingUnit:label:QuestionGenre')"
|
||||||
prop="QuestionGenre"
|
prop="QuestionGenre"
|
||||||
:rules="[{ required: form.Type !== 'calculation', message: '请选择' }]"
|
:rules="[{ required: form.Type !== 'calculation', message: this.$t('common:ruleMessage:select') }]"
|
||||||
>
|
>
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.QuestionGenre"
|
v-model="form.QuestionGenre"
|
||||||
@@ -399,7 +417,7 @@
|
|||||||
}
|
}
|
||||||
"
|
"
|
||||||
>
|
>
|
||||||
<el-radio :label="-1"> 无 </el-radio>
|
<el-radio :label="-1"> {{ this.$t('common:title:none') }} </el-radio>
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.TableQuestionType"
|
v-for="item of $d.TableQuestionType"
|
||||||
v-show="item.value === 0 || item.value === 3"
|
v-show="item.value === 0 || item.value === 3"
|
||||||
@@ -410,23 +428,23 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 选项 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.QuestionGenre === 0 || form.Type === 'class'"
|
v-if="form.QuestionGenre === 0 || form.Type === 'class'"
|
||||||
label="选项"
|
:label="$t('trials:qcCfg:table:typeValue')"
|
||||||
prop="TypeValue"
|
prop="TypeValue"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.TypeValue"
|
v-model="form.TypeValue"
|
||||||
placeholder="选项请用‘|’分割多个选项"
|
:placeholder="$t('trials:qcCfg:message:typeValue')"
|
||||||
@change="typeValueChange"
|
@change="typeValueChange"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
<!-- 关联字典 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.QuestionGenre === 3"
|
v-if="form.QuestionGenre === 3"
|
||||||
label="关联字典"
|
:label="$t('trials:readingUnit:label:DictionaryCode')"
|
||||||
prop="DictionaryCode"
|
prop="DictionaryCode"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -446,17 +464,19 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.QuestionGenre === 3" label="默认值">
|
<!-- 默认值 -->
|
||||||
|
<el-form-item v-if="form.QuestionGenre === 3" :label="$t('trials:readingUnit:qsList:title:defaultValue')">
|
||||||
<el-select v-model="form.DefaultValue" clearable>
|
<el-select v-model="form.DefaultValue" clearable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of form.DictionaryCode ? $d[form.DictionaryCode] : []"
|
v-for="item of highlightAnswers"
|
||||||
:key="item.id"
|
:key="item.Id"
|
||||||
:label="item.label"
|
:label="$i18n.locale === 'zh' ? item.ValueCN : item.Value"
|
||||||
:value="item.value.toString()"
|
:value="item.Code"
|
||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.QuestionGenre === 0" label="默认值">
|
<!-- 默认值 -->
|
||||||
|
<el-form-item v-if="form.QuestionGenre === 0" :label="$t('trials:readingUnit:qsList:title:defaultValue')">
|
||||||
<el-select v-model="form.DefaultValue" clearable>
|
<el-select v-model="form.DefaultValue" clearable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of form.TypeValue ? form.TypeValue.split('|') : []"
|
v-for="item of form.TypeValue ? form.TypeValue.split('|') : []"
|
||||||
@@ -466,9 +486,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 高亮标记值 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'select' || form.Type === 'radio'"
|
v-if="form.Type === 'select' || form.Type === 'radio'"
|
||||||
label="高亮标记值"
|
:label="$t('trials:readingUnit:qsList:title:highlightAnswers')"
|
||||||
prop="HighlightAnswerList"
|
prop="HighlightAnswerList"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.HighlightAnswerList" clearable multiple>
|
<el-select v-model="form.HighlightAnswerList" clearable multiple>
|
||||||
@@ -490,8 +511,9 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 分组标识 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="分组标识"
|
:label="$t('dictionary:template:criterionConfig:table:groupClassify')"
|
||||||
v-if="form.Type === 'group'"
|
v-if="form.Type === 'group'"
|
||||||
prop="GroupClassify"
|
prop="GroupClassify"
|
||||||
>
|
>
|
||||||
@@ -504,9 +526,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 最大长度 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'input' || form.Type === 'textarea'"
|
v-if="form.Type === 'input' || form.Type === 'textarea'"
|
||||||
label="最大长度"
|
:label="$t('trials:readingUnit:qsList:title:MaxAnswerLength')"
|
||||||
prop="MaxAnswerLength"
|
prop="MaxAnswerLength"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
||||||
@@ -514,9 +537,10 @@
|
|||||||
>
|
>
|
||||||
<el-input-number v-model="form.MaxAnswerLength" :min="0"></el-input-number>
|
<el-input-number v-model="form.MaxAnswerLength" :min="0"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 最大行数 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'table' || form.Type === 'basicTable'"
|
v-if="form.Type === 'table' || form.Type === 'basicTable'"
|
||||||
label="最大行数"
|
:label="$t('trials:readingUnit:qsList:title:maxQuestionCount')"
|
||||||
prop="MaxQuestionCount"
|
prop="MaxQuestionCount"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
||||||
@@ -529,16 +553,16 @@
|
|||||||
:max="10"
|
:max="10"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.Type === 'table' || form.Type === 'basicTable'" label="自增序号前缀">
|
<el-form-item v-if="form.Type === 'table' || form.Type === 'basicTable'" :label="$t('trials:readingUnit:qsList:title:orderMark')">
|
||||||
<el-input v-model="form.OrderMark" />
|
<el-input v-model="form.OrderMark" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<!-- 数值类型 -->
|
<!-- 数值类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
||||||
label="数值类型"
|
:label="$t('trials:readingUnit:qsList:title:valueType')"
|
||||||
prop="ValueType"
|
prop="ValueType"
|
||||||
:rules="[{ required: true, message: '请选择' }]"
|
:rules="[{ required: true, message: this.$t('common:ruleMessage:select') }]"
|
||||||
>
|
>
|
||||||
<el-radio-group v-model="form.ValueType">
|
<el-radio-group v-model="form.ValueType">
|
||||||
<el-radio
|
<el-radio
|
||||||
@@ -551,10 +575,10 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<!-- 数值单位 -->
|
<!-- 单位 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
||||||
label="单位"
|
:label="$t('trials:readingUnit:qsList:title:unit')"
|
||||||
prop="Unit"
|
prop="Unit"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -570,9 +594,10 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 表格类型标识 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'table'"
|
v-if="form.Type === 'table'"
|
||||||
label="表格类型标识"
|
:label="$t('dictionary:template:criterionConfig:table:tableType')"
|
||||||
prop="LesionType"
|
prop="LesionType"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.LesionType" clearable>
|
<el-select v-model="form.LesionType" clearable>
|
||||||
@@ -584,9 +609,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 表格类型标识 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'basicTable'"
|
v-if="form.Type === 'basicTable'"
|
||||||
label="表格类型标识"
|
:label="$t('dictionary:template:criterionConfig:table:tableType')"
|
||||||
prop="LesionType"
|
prop="LesionType"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.LesionType" clearable>
|
<el-select v-model="form.LesionType" clearable>
|
||||||
@@ -598,9 +624,32 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 关联字典 -->
|
||||||
|
<el-form-item
|
||||||
|
v-if="form.Type === 'table' || form.Type === 'basicTable'"
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:relatedDictionaryCode')"
|
||||||
|
>
|
||||||
|
<el-select
|
||||||
|
v-model="form.DictionaryCode"
|
||||||
|
clearable
|
||||||
|
@change="
|
||||||
|
() => {
|
||||||
|
form.DefaultValue = null
|
||||||
|
}
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item of dicList"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="item.Code"
|
||||||
|
:value="item.Code"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 最大上传个数 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'upload'"
|
v-if="form.Type === 'upload'"
|
||||||
label="最大上传个数"
|
:label="$t('trials:readingUnit:qsList:title:imageCount')"
|
||||||
>
|
>
|
||||||
<el-input-number
|
<el-input-number
|
||||||
v-model="form.ImageCount"
|
v-model="form.ImageCount"
|
||||||
@@ -612,7 +661,7 @@
|
|||||||
<!-- 文件类型 -->
|
<!-- 文件类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'upload'"
|
v-if="form.Type === 'upload'"
|
||||||
label="文件类型"
|
:label="$t('trials:readingUnit:qsList:title:FileType')"
|
||||||
prop="FileType"
|
prop="FileType"
|
||||||
:rules="[{ type: 'array', required: true, message: this.$t('common:ruleMessage:specify'), trigger: [ 'change'] }]"
|
:rules="[{ type: 'array', required: true, message: this.$t('common:ruleMessage:specify'), trigger: [ 'change'] }]"
|
||||||
>
|
>
|
||||||
@@ -635,10 +684,10 @@
|
|||||||
</el-checkbox>
|
</el-checkbox>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 分类 -->
|
<!-- 分类数据来源 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'class'"
|
v-if="form.Type === 'class'"
|
||||||
label="分类数据来源"
|
:label="$t('dictionary:template:criterionConfig:table:classifyQuestion')"
|
||||||
prop="ClassifyQuestionId"
|
prop="ClassifyQuestionId"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.ClassifyQuestionId" clearable>
|
<el-select v-model="form.ClassifyQuestionId" clearable>
|
||||||
@@ -646,9 +695,10 @@
|
|||||||
:value="item.Id"/>
|
:value="item.Id"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 分类算法 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'class'"
|
v-if="form.Type === 'class'"
|
||||||
label="分类算法"
|
:label="$t('dictionary:template:criterionConfig:table:classifyAlgorithms')"
|
||||||
prop="ClassifyAlgorithms"
|
prop="ClassifyAlgorithms"
|
||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
@@ -760,7 +810,7 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
var arr = value.split('|')
|
var arr = value.split('|')
|
||||||
if (new Set(arr).size !== arr.length) {
|
if (new Set(arr).size !== arr.length) {
|
||||||
callback(new Error('选项不允许存在相同值'))
|
callback(new Error(this.$t('trials:readingUnit:qsList:message:msg0')))
|
||||||
} else {
|
} else {
|
||||||
callback()
|
callback()
|
||||||
}
|
}
|
||||||
@@ -807,7 +857,7 @@ export default {
|
|||||||
ConvertShowType: 0,
|
ConvertShowType: 0,
|
||||||
QuestionClassify: null,
|
QuestionClassify: null,
|
||||||
HighlightAnswerList: [],
|
HighlightAnswerList: [],
|
||||||
ExportIdentification: 0,
|
// ExportIdentification: 0,
|
||||||
ExportResult: [],
|
ExportResult: [],
|
||||||
MaxAnswerLength: null,
|
MaxAnswerLength: null,
|
||||||
FileType: [],
|
FileType: [],
|
||||||
@@ -815,46 +865,47 @@ export default {
|
|||||||
ClassifyAlgorithms: null,
|
ClassifyAlgorithms: null,
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
Type: [{ required: true, message: '请选择', trigger: 'blur' }],
|
Type: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
LesionType: [{ required: true, message: '请选择', trigger: 'blur' }],
|
LesionType: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
// QuestionName: [
|
// QuestionName: [
|
||||||
// { required: true, message: '请注明', trigger: 'blur' },
|
// { required: true, message: '请注明', trigger: 'blur' },
|
||||||
// { max: 300, message: '最大长度为 300' },
|
// { max: 300, message: '最大长度为 300' },
|
||||||
// ],
|
// ],
|
||||||
QuestionGenre: [{ required: true, message: '请选择', trigger: 'blur' }],
|
QuestionGenre: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
TypeValue: [
|
TypeValue: [
|
||||||
{ required: true, message: '请注明', trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
{ validator: validateTypeVal, trigger: 'blur' },
|
{ validator: validateTypeVal, trigger: 'blur' },
|
||||||
{ max: 500, message: '最大长度为 500' },
|
{ max: 500, message: `${this.$t('common:ruleMessage:maxLength')} 500` },
|
||||||
],
|
],
|
||||||
DictionaryCode: [
|
DictionaryCode: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
||||||
],
|
],
|
||||||
ShowQuestion: [{ required: true, message: '请选择', trigger: 'blur' }],
|
ShowQuestion: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
IsRequired: [{ required: true, message: '请选择', trigger: 'blur' }],
|
IsRequired: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
ParentId: [{ required: true, message: '请选择', trigger: 'blur' }],
|
ParentId: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
ParentTriggerValueList: [
|
ParentTriggerValueList: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
||||||
],
|
],
|
||||||
RelevanceId: [{ required: true, message: '请选择', trigger: 'blur' }],
|
RelevanceId: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
RelevanceValueList: [
|
RelevanceValueList: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
||||||
],
|
],
|
||||||
GroupName: [
|
GroupName: [
|
||||||
{ required: true, message: '请注明', trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
{ max: 50, message: '最大长度为 50' },
|
{ max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50` },
|
||||||
],
|
],
|
||||||
ExportIdentification: [
|
// ExportIdentification: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' },
|
// { required: true, message: '请选择', trigger: 'blur' },
|
||||||
],
|
// ],
|
||||||
ExportResult: [
|
// ExportResult: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' },
|
// { required: true, message: '请选择', trigger: 'blur' },
|
||||||
]
|
// ]
|
||||||
},
|
},
|
||||||
loading: false,
|
loading: false,
|
||||||
btnLoading: false,
|
btnLoading: false,
|
||||||
parentOptions: [],
|
parentOptions: [],
|
||||||
parentTriggerValOptions: [],
|
parentTriggerValOptions: [],
|
||||||
|
reParentTriggerValOptions: [],
|
||||||
groupOptions: [],
|
groupOptions: [],
|
||||||
isParentExistGroup: false,
|
isParentExistGroup: false,
|
||||||
lesionTypes: [],
|
lesionTypes: [],
|
||||||
@@ -890,6 +941,7 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
this.initForm()
|
this.initForm()
|
||||||
this.getCalculateQuestions('number')
|
this.getCalculateQuestions('number')
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
typeValueChange(v) {
|
typeValueChange(v) {
|
||||||
@@ -905,6 +957,14 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
getBasicConfigSelect() {
|
||||||
|
getCriterionDictionaryList({
|
||||||
|
CriterionId: this.criterionId,
|
||||||
|
SystemCriterionId: this.criterionId
|
||||||
|
}).then(res => {
|
||||||
|
this.dicList = res.Result
|
||||||
|
})
|
||||||
|
},
|
||||||
getCalculateQuestions(type) {
|
getCalculateQuestions(type) {
|
||||||
getSystemCalculateQuestions({
|
getSystemCalculateQuestions({
|
||||||
systemCriterionId: this.criterionId,
|
systemCriterionId: this.criterionId,
|
||||||
@@ -944,6 +1004,7 @@ export default {
|
|||||||
await this.getParentQuestions()
|
await this.getParentQuestions()
|
||||||
await this.getLesionTypeDictionary()
|
await this.getLesionTypeDictionary()
|
||||||
await this.getLesionType()
|
await this.getLesionType()
|
||||||
|
await this.getBasicConfigSelect()
|
||||||
if (Object.keys(this.data).length > 0) {
|
if (Object.keys(this.data).length > 0) {
|
||||||
for (const k in this.form) {
|
for (const k in this.form) {
|
||||||
if (this.data.hasOwnProperty(k)) {
|
if (this.data.hasOwnProperty(k)) {
|
||||||
@@ -969,8 +1030,15 @@ export default {
|
|||||||
})
|
})
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
this.parentTriggerValOptions =
|
// this.parentTriggerValOptions =
|
||||||
this.$d[this.parentOptions[index].DictionaryCode]
|
// this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.data.ReadingQuestionCriterionSystemId,DictionaryCode: dicCode})
|
||||||
|
|
||||||
|
this.parentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach(
|
this.parentOptions[index].TypeValue.split('|').forEach(
|
||||||
@@ -988,8 +1056,13 @@ export default {
|
|||||||
})
|
})
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
this.reParentTriggerValOptions =
|
// this.reParentTriggerValOptions =
|
||||||
this.$d[this.parentOptions[index].DictionaryCode]
|
// this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.data.ReadingQuestionCriterionSystemId,DictionaryCode: dicCode})
|
||||||
|
this.reParentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach(
|
this.parentOptions[index].TypeValue.split('|').forEach(
|
||||||
@@ -1114,7 +1187,7 @@ export default {
|
|||||||
data.ConvertShowType = 0
|
data.ConvertShowType = 0
|
||||||
data.QuestionClassify = null
|
data.QuestionClassify = null
|
||||||
data.HighlightAnswerList = []
|
data.HighlightAnswerList = []
|
||||||
data.ExportIdentification = 0
|
// data.ExportIdentification = 0
|
||||||
data.ExportResult = []
|
data.ExportResult = []
|
||||||
data.FileType = []
|
data.FileType = []
|
||||||
data.ClassifyQuestionId = null
|
data.ClassifyQuestionId = null
|
||||||
@@ -1180,15 +1253,21 @@ export default {
|
|||||||
}
|
}
|
||||||
form.ParentTriggerValue = ''
|
form.ParentTriggerValue = ''
|
||||||
},
|
},
|
||||||
relevanceQuestionChange(val, form) {
|
async relevanceQuestionChange(val, form) {
|
||||||
if (val) {
|
if (val) {
|
||||||
var index = this.parentOptions.findIndex((item) => {
|
var index = this.parentOptions.findIndex((item) => {
|
||||||
return item.QuestionId === val
|
return item.QuestionId === val
|
||||||
})
|
})
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
this.reParentTriggerValOptions =
|
// this.reParentTriggerValOptions =
|
||||||
this.$d[this.parentOptions[index].DictionaryCode]
|
// this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.data.ReadingQuestionCriterionSystemId,DictionaryCode: dicCode})
|
||||||
|
|
||||||
|
this.reParentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
var options = []
|
var options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach(
|
this.parentOptions[index].TypeValue.split('|').forEach(
|
||||||
|
|||||||
@@ -1,13 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-tabs v-model="activeName" @tab-click="handleClick">
|
<el-tabs v-model="activeName" @tab-click="handleClick">
|
||||||
<el-tab-pane label="器官" name="organs">
|
<!-- 器官 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:basicData:organs')" name="organs">
|
||||||
|
|
||||||
<OrgansTbl
|
<OrgansTbl
|
||||||
:criterion-id="criterionId"
|
:criterion-id="criterionId"
|
||||||
:is-complete-config="isCompleteConfig"
|
:is-complete-config="isCompleteConfig"
|
||||||
/>
|
/>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="疗效评估" name="efficacyAssessment">
|
<!-- 疗效评估 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:basicData:efficacyAssessment')" name="efficacyAssessment">
|
||||||
<EfficacyAssessment
|
<EfficacyAssessment
|
||||||
v-if="tabs.includes('efficacyAssessment')"
|
v-if="tabs.includes('efficacyAssessment')"
|
||||||
:criterion-id="criterionId"
|
:criterion-id="criterionId"
|
||||||
@@ -15,7 +17,8 @@
|
|||||||
:is-complete-config="isCompleteConfig"
|
:is-complete-config="isCompleteConfig"
|
||||||
/>
|
/>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="标准字典" name="criterionDictionary">
|
<!-- 标准字典 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:basicData:criterionDictionary')" name="criterionDictionary">
|
||||||
<CriterionDictionary
|
<CriterionDictionary
|
||||||
v-if="tabs.includes('criterionDictionary')"
|
v-if="tabs.includes('criterionDictionary')"
|
||||||
:criterion-id="criterionId"
|
:criterion-id="criterionId"
|
||||||
|
|||||||
@@ -1,16 +1,25 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="criterion-config">
|
<div class="criterion-config">
|
||||||
<el-tabs v-model="activeName">
|
<el-tabs v-model="activeName">
|
||||||
<el-tab-pane :label="'访视阅片'" name="0">
|
<!-- 访视阅片 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:criterionConfig:tab:visitReview')" name="0">
|
||||||
<div class="search-form" style="display:flex;justify-content: space-between;">
|
<div class="search-form" style="display:flex;justify-content: space-between;">
|
||||||
<el-form :inline="true" size="mini" class="base-search-form">
|
<el-form :inline="true" size="mini" class="base-search-form">
|
||||||
<el-form-item label="名称">
|
<!-- 问题名称 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:qsNameEn')">
|
||||||
<el-input v-model="searchData.QuestionName" clearable style="width:120px;" />
|
<el-input v-model="searchData.QuestionName" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">重置</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">查询</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div>
|
<div>
|
||||||
@@ -20,7 +29,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
@click="handlePreview"
|
@click="handlePreview"
|
||||||
>
|
>
|
||||||
预览
|
{{ $t('common:button:preview') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@@ -28,7 +37,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>
|
>
|
||||||
添加
|
{{ $t('common:button:add') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -42,61 +51,70 @@
|
|||||||
stripe
|
stripe
|
||||||
@sort-change="handleSortByColumn"
|
@sort-change="handleSortByColumn"
|
||||||
>
|
>
|
||||||
|
<!-- 显示序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
label=""
|
label=""
|
||||||
width="50"
|
width="50"
|
||||||
/>
|
/>
|
||||||
|
<!-- 分组 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="GroupName"
|
prop="GroupName"
|
||||||
label="分组"
|
:label="$t('trials:readingUnit:qsList:title:groupNameEn')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 分组(EN) -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="GroupEnName"
|
prop="GroupEnName"
|
||||||
label="分组(EN)"
|
:label="$t('trials:readingUnit:qsList:title:groupNameEn')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 名称 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionName"
|
prop="QuestionName"
|
||||||
label="名称"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 名称(EN) -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionEnName"
|
prop="QuestionEnName"
|
||||||
label="名称(EN)"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 题型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Type"
|
prop="Type"
|
||||||
label="题型"
|
:label="$t('trials:readingUnit:qsList:title:type')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('Criterion_Question_Type',scope.row.Type) }}
|
{{ $fd('Criterion_Question_Type',scope.row.Type) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<!-- 是否显示 -->
|
||||||
prop="IsRequired"
|
|
||||||
label="是否必填"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ $fd('QuestionRequired',scope.row.IsRequired) }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowQuestion"
|
prop="ShowQuestion"
|
||||||
label="是否显示"
|
:label="$t('trials:readingUnit:qsList:title:isShow')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('ShowQuestion',scope.row.ShowQuestion) }}
|
{{ $fd('ShowQuestion',scope.row.ShowQuestion) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否必填 -->
|
||||||
|
<el-table-column
|
||||||
|
prop="IsRequired"
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:isRequired')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ $fd('QuestionRequired',scope.row.IsRequired) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<!-- 是否裁判问题 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsJudgeQuestion"
|
prop="IsJudgeQuestion"
|
||||||
label="是否裁判问题"
|
:label="$t('trials:readingUnit:qsList:title:isJudgeQuestion')"
|
||||||
width="120"
|
width="120"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -104,9 +122,10 @@
|
|||||||
{{ $fd('YesOrNo', scope.row.IsJudgeQuestion) }}
|
{{ $fd('YesOrNo', scope.row.IsJudgeQuestion) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否在阅片页面显示 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsShowInDicom"
|
prop="IsShowInDicom"
|
||||||
label="是否在阅片页面显示"
|
:label="$t('trials:readingUnit:qsList:title:isShowInDicom')"
|
||||||
width="150"
|
width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -122,9 +141,10 @@
|
|||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column> -->
|
</el-table-column> -->
|
||||||
|
<!-- 是否在全局阅片显示 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="GlobalReadingShowType"
|
prop="GlobalReadingShowType"
|
||||||
label="是否在全局阅片显示"
|
:label="$t('trials:readingUnit:qsList:title:globalReadingShowType')"
|
||||||
width="160"
|
width="160"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -146,7 +166,7 @@
|
|||||||
<!-- 问题标识 -->
|
<!-- 问题标识 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionType"
|
prop="QuestionType"
|
||||||
label="问题标识"
|
:label="$t('dictionary:template:criterionConfig:table:questionType')"
|
||||||
width="140"
|
width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -178,7 +198,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop=""
|
prop=""
|
||||||
label="操作"
|
:label="$t('common:action:action')"
|
||||||
width="250"
|
width="250"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
fixed="right"
|
fixed="right"
|
||||||
@@ -190,7 +210,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
>
|
>
|
||||||
编辑
|
{{ $t('trials:readingUnit:qsList:title:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-else
|
v-else
|
||||||
@@ -198,7 +218,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleLook(scope.row)"
|
@click="handleLook(scope.row)"
|
||||||
>
|
>
|
||||||
查看
|
{{ $t('trials:readingUnit:qsList:title:view') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -206,7 +226,7 @@
|
|||||||
:disabled="!(scope.row.Type === 'table' || scope.row.Type === 'basicTable')"
|
:disabled="!(scope.row.Type === 'table' || scope.row.Type === 'basicTable')"
|
||||||
@click="handleConfig(scope.row)"
|
@click="handleConfig(scope.row)"
|
||||||
>
|
>
|
||||||
表格问题
|
{{ $t('trials:readingUnit:qsList:title:tableQs') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@@ -215,17 +235,19 @@
|
|||||||
:disabled="scope.row.IsEnable"
|
:disabled="scope.row.IsEnable"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
>
|
>
|
||||||
删除
|
{{ $t('trials:readingUnit:qsList:title:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<pagination style="text-align: right;margin-top: 10px;" class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize" @pagination="getList" />
|
<pagination style="text-align: right;margin-top: 10px;" class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize" @pagination="getList" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="全局阅片" name="Global">
|
<!-- 全局阅片 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:criterionConfig:tab:globalReview')" name="Global">
|
||||||
<EvaluationOfGlobalConfig v-if="activeName === 'Global'" :data="data" :criterion-id="criterionId" />
|
<EvaluationOfGlobalConfig v-if="activeName === 'Global'" :data="data" :criterion-id="criterionId" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="肿瘤学阅片" name="Oncology">
|
<!-- 肿瘤学阅片 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:criterionConfig:tab:oncologyReview')" name="Oncology">
|
||||||
<EvaluationOfOncologyConfig v-if="activeName === 'Oncology'" :data="data" :criterion-id="criterionId" />
|
<EvaluationOfOncologyConfig v-if="activeName === 'Oncology'" :data="data" :criterion-id="criterionId" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
@@ -354,19 +376,19 @@ export default {
|
|||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.rowData = { ReadingQuestionCriterionSystemId: this.criterionId, Id: ''}
|
this.rowData = { ReadingQuestionCriterionSystemId: this.criterionId, Id: ''}
|
||||||
this.type = 'add'
|
this.type = 'add'
|
||||||
this.addOrEdit.title = '添加'
|
this.addOrEdit.title = this.$t('common:button:new')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
handleLook(row) {
|
handleLook(row) {
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.type = 'look'
|
this.type = 'look'
|
||||||
this.addOrEdit.title = '查看'
|
this.addOrEdit.title = this.$t('common:button:view')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.type = 'edit'
|
this.type = 'edit'
|
||||||
this.addOrEdit.title = '编辑'
|
this.addOrEdit.title = this.$t('common:button:edit')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
@@ -381,7 +403,7 @@ export default {
|
|||||||
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'))
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -8,13 +8,74 @@
|
|||||||
>
|
>
|
||||||
<el-input v-model="searchData.CriterionName" clearable style="width:120px;" />
|
<el-input v-model="searchData.CriterionName" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 标准类型 -->
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:criterionType')"
|
||||||
|
>
|
||||||
|
<el-select v-model="searchData.CriterionType" clearable style="width:120px;">
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.CriterionType"
|
||||||
|
:key="item.id"
|
||||||
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 标准分组 -->
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:criterionGroup')"
|
||||||
|
>
|
||||||
|
<el-select v-model="searchData.CriterionGroup" clearable style="width:120px;">
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.CriterionGroup"
|
||||||
|
:key="item.id"
|
||||||
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 是否配置完成 -->
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:isCompleteConfig')"
|
||||||
|
>
|
||||||
|
<el-select v-model="searchData.IsCompleteConfig" clearable style="width:120px;">
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="item.id"
|
||||||
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 是否启用 -->
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:isEnable')"
|
||||||
|
>
|
||||||
|
<el-select v-model="searchData.IsEnable" clearable style="width:120px;">
|
||||||
|
<el-option
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="item.id"
|
||||||
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">重置</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">查询</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
<el-button type="primary" size="mini" @click="handleAdd">添加</el-button>
|
<!-- 添加 -->
|
||||||
|
<el-button type="primary" size="mini" @click="handleAdd">{{$t('common:button:new')}}</el-button>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -25,27 +86,44 @@
|
|||||||
stripe
|
stripe
|
||||||
size="small"
|
size="small"
|
||||||
height="100"
|
height="100"
|
||||||
|
@sort-change="handleSortByColumn"
|
||||||
|
ref="criterionsTbl"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="60" />
|
<el-table-column type="index" width="60" />
|
||||||
|
<!-- 标准名称 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="CriterionName"
|
prop="CriterionName"
|
||||||
label="标准名称"
|
:label="$t('trials:auditRecord:table:criterion')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
<!-- 标准类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="CriterionType"
|
prop="CriterionType"
|
||||||
label="标准类型"
|
:label="$t('dictionary:template:criterionConfig:table:criterionType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('CriterionType',scope.row.CriterionType) }}
|
{{ $fd('CriterionType',scope.row.CriterionType) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 标准分组 -->
|
||||||
|
<el-table-column
|
||||||
|
prop="CriterionGroup"
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:criterionGroup')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ $fd('CriterionGroup',scope.row.CriterionGroup) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<!-- 是否配置完成 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsCompleteConfig"
|
prop="IsCompleteConfig"
|
||||||
label="是否配置完成"
|
:label="$t('dictionary:template:criterionConfig:table:isCompleteConfig')"
|
||||||
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
|
|
||||||
@@ -57,57 +135,75 @@
|
|||||||
{{ $fd('YesOrNo', scope.row.IsCompleteConfig) }}
|
{{ $fd('YesOrNo', scope.row.IsCompleteConfig) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 描述 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Description"
|
prop="Description"
|
||||||
label="描述"
|
:label="$t('dictionary:template:criterionConfig:table:description')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 是否启用 -->
|
||||||
<el-table-column
|
|
||||||
prop="ShowOrder"
|
|
||||||
label="显示序号"
|
|
||||||
show-overflow-tooltip
|
|
||||||
/>
|
|
||||||
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsEnable"
|
prop="IsEnable"
|
||||||
label="是否启用"
|
:label="$t('dictionary:template:criterionConfig:table:isEnable')"
|
||||||
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('YesOrNo', scope.row.IsEnable) }}
|
{{ $fd('YesOrNo', scope.row.IsEnable) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 显示序号 -->
|
||||||
<el-table-column label="Action" min-width="200px">
|
<el-table-column
|
||||||
|
prop="ShowOrder"
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:showOrder')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
|
/>
|
||||||
|
<!-- eICRF仅展示阅片Tab -->
|
||||||
|
<el-table-column
|
||||||
|
prop="IseCRFShowInDicomReading"
|
||||||
|
:label="$t('dictionary:template:criterionConfig:table:isECRFShowInDicomReading')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
|
width="210"
|
||||||
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
|
{{ $fd('YesOrNo', scope.row.IseCRFShowInDicomReading) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column :label="$t('common:action:action')" min-width="200px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<!-- 编辑 -->
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
>
|
>
|
||||||
编辑
|
{{ $t('common:button:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<!-- eCRF -->
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleConfig(scope.row)"
|
@click="handleConfig(scope.row)"
|
||||||
>
|
>
|
||||||
eCRF
|
{{ $t('dictionary:template:criterionConfig:button:eCRF') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<!-- 基础数据 -->
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBaseDataConfig(scope.row)"
|
@click="handleBaseDataConfig(scope.row)"
|
||||||
>
|
>
|
||||||
基础数据
|
{{ $t('dictionary:template:criterionConfig:button:basicData') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<!-- 删除 -->
|
||||||
<el-button
|
<el-button
|
||||||
type="danger"
|
type="danger"
|
||||||
size="mini"
|
size="mini"
|
||||||
:disabled="scope.row.IsCompleteConfig"
|
:disabled="scope.row.IsCompleteConfig"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
>
|
>
|
||||||
删除
|
{{ $t('common:button:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
@@ -146,7 +242,7 @@
|
|||||||
|
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-if="configBaseDataVisible"
|
v-if="configBaseDataVisible"
|
||||||
:title="'基础数据配置' + `(${rowData.CriterionName})`"
|
:title="`${this.$t('trials:readingUnit:readingCriterion:title:baseDataCfg')} (${rowData.CriterionName})`"
|
||||||
:visible.sync="configBaseDataVisible"
|
:visible.sync="configBaseDataVisible"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
:fullscreen="true"
|
:fullscreen="true"
|
||||||
@@ -172,8 +268,14 @@ import AddCriterion from './AddCriterion'
|
|||||||
const searchDataDefault = () => {
|
const searchDataDefault = () => {
|
||||||
return {
|
return {
|
||||||
CriterionName: '',
|
CriterionName: '',
|
||||||
|
CriterionType: null,
|
||||||
|
CriterionGroup: null,
|
||||||
|
IsCompleteConfig: null,
|
||||||
|
IsEnable: null,
|
||||||
PageIndex: 1,
|
PageIndex: 1,
|
||||||
PageSize: 20
|
PageSize: 20,
|
||||||
|
Asc: true,
|
||||||
|
SortField: ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
export default {
|
export default {
|
||||||
@@ -205,17 +307,17 @@ export default {
|
|||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
},
|
},
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.addDialog.title = '添加'
|
this.addDialog.title = this.$t('common:button:new')
|
||||||
this.addDialog.visible = true
|
this.addDialog.visible = true
|
||||||
this.rowData = {}
|
this.rowData = {}
|
||||||
},
|
},
|
||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.addDialog.title = '编辑'
|
this.addDialog.title = this.$t('common:button:edit')
|
||||||
this.addDialog.visible = true
|
this.addDialog.visible = true
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
},
|
},
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
this.$confirm('是否确认删除', {
|
this.$confirm(this.$t('trials:readingUnit:baseDataCfg:message:deleteConfirm'), {
|
||||||
distinguishCancelAndClose: true,
|
distinguishCancelAndClose: true,
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
@@ -223,7 +325,7 @@ export default {
|
|||||||
deleteReadingQuestionCriterionSystem(row.Id).then(res => {
|
deleteReadingQuestionCriterionSystem(row.Id).then(res => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
this.$message.success(this.$t('common:message:deletedSuccessfully'))
|
||||||
this.getList()
|
this.getList()
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
@@ -232,10 +334,10 @@ export default {
|
|||||||
changeStatus(callback, row) {
|
changeStatus(callback, row) {
|
||||||
var message = ''
|
var message = ''
|
||||||
if (callback) {
|
if (callback) {
|
||||||
message = '是否确认更改?'
|
message = this.$t('trials:readingUnit:baseDataCfg:message:updateConfirm')
|
||||||
row.IsCompleteConfig = false
|
row.IsCompleteConfig = false
|
||||||
} else {
|
} else {
|
||||||
message = '是否确认更改?'
|
message = this.$t('trials:readingUnit:baseDataCfg:message:updateConfirm')
|
||||||
row.IsCompleteConfig = true
|
row.IsCompleteConfig = true
|
||||||
}
|
}
|
||||||
this.$confirm(message, {
|
this.$confirm(message, {
|
||||||
@@ -271,6 +373,18 @@ export default {
|
|||||||
// 重置
|
// 重置
|
||||||
handleReset() {
|
handleReset() {
|
||||||
this.searchData = searchDataDefault()
|
this.searchData = searchDataDefault()
|
||||||
|
this.$refs['criterionsTbl'].clearSort()
|
||||||
|
this.getList()
|
||||||
|
},
|
||||||
|
// 指定排序字段,对列表进行排序
|
||||||
|
handleSortByColumn(column) {
|
||||||
|
if (column.order === 'ascending') {
|
||||||
|
this.searchData.Asc = true
|
||||||
|
} else {
|
||||||
|
this.searchData.Asc = false
|
||||||
|
}
|
||||||
|
this.searchData.SortField = column.prop
|
||||||
|
this.searchData.PageIndex = 1
|
||||||
this.getList()
|
this.getList()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,13 @@
|
|||||||
<template>
|
<template>
|
||||||
<div style="position: relative">
|
<div style="position: relative">
|
||||||
<el-form size="small" :inline="true" label-width="130px" style="position: relative;">
|
<el-form size="small" :inline="true" label-width="130px" style="position: relative;">
|
||||||
<el-divider content-position="left">阅片规则</el-divider>
|
<!-- 阅片规则 -->
|
||||||
<el-form-item label="是否必须全局阅片">
|
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:readingRules') }}</el-divider>
|
||||||
|
<!-- 是否必须全局阅片 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:globalConfig:isMustGlobalReading')">
|
||||||
{{ $fd('YesOrNo', IsMustGlobalReading) }}
|
{{ $fd('YesOrNo', IsMustGlobalReading) }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -12,11 +15,13 @@
|
|||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@click="handleAdd(1)"
|
@click="handleAdd(1)"
|
||||||
>
|
>
|
||||||
配置
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-form size="small" :inline="true" label-width="110px" style="position: relative">
|
<el-form size="small" :inline="true" label-width="110px" style="position: relative">
|
||||||
<el-divider content-position="left">名称</el-divider>
|
<!-- 名称 -->
|
||||||
|
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:name') }}</el-divider>
|
||||||
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -24,9 +29,10 @@
|
|||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@click="handleAdd(2)"
|
@click="handleAdd(2)"
|
||||||
>
|
>
|
||||||
配置
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-form-item label="评估更新类型" 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"
|
v-loading="loading"
|
||||||
@@ -34,30 +40,34 @@
|
|||||||
:data="list"
|
:data="list"
|
||||||
stripe
|
stripe
|
||||||
>
|
>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop=""
|
prop=""
|
||||||
label="序号"
|
:label="$t('dictionary:template:globalConfig:order')"
|
||||||
width="50"
|
width="50"
|
||||||
>
|
>
|
||||||
<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"
|
prop="ValueCN"
|
||||||
label="中文值"
|
:label="$t('dictionary:template:globalConfig:valueCN')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Value"
|
prop="Value"
|
||||||
label="英文值"
|
:label="$t('dictionary:template:globalConfig:value')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否基线评估 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsBaseLineUse"
|
prop="IsBaseLineUse"
|
||||||
label="是否基线评估"
|
:label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -70,9 +80,10 @@
|
|||||||
<el-tag v-else type="danger">{{ $fd('YesOrNo', scope.row.IsBaseLineUse) }}</el-tag>
|
<el-tag v-else type="danger">{{ $fd('YesOrNo', scope.row.IsBaseLineUse) }}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否随访评估 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsFollowVisitUse"
|
prop="IsFollowVisitUse"
|
||||||
label="是否随访评估"
|
:label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -93,12 +104,14 @@
|
|||||||
>
|
>
|
||||||
<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="是否必须全局阅片" 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>
|
||||||
<el-form-item v-if="config.configType === 2" label="评估更新类型" 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-if="config.configType === 2"
|
||||||
@@ -112,21 +125,24 @@
|
|||||||
type="selection"
|
type="selection"
|
||||||
width="55">
|
width="55">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 中文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ValueCN"
|
prop="ValueCN"
|
||||||
label="中文值"
|
:label="$t('dictionary:template:globalConfig:valueCN')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Value"
|
prop="Value"
|
||||||
label="英文值"
|
:label="$t('dictionary:template:globalConfig:value')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否基线评估 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsBaseLineUse"
|
prop="IsBaseLineUse"
|
||||||
label="是否基线评估"
|
:label="$t('dictionary:template:globalConfig:isBaseLineUse')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -138,9 +154,10 @@
|
|||||||
<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"
|
prop="IsFollowVisitUse"
|
||||||
label="是否随访评估"
|
:label="$t('dictionary:template:globalConfig:isFollowVisitUse')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -156,8 +173,12 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<template slot="dialog-footer">
|
<template slot="dialog-footer">
|
||||||
<el-button :disabled="loading" size="small" type="primary" @click="config.visible = false">取消</el-button>
|
<el-button :disabled="loading" size="small" type="primary" @click="config.visible = false">
|
||||||
<el-button size="small" type="primary" :loading="loading" @click="handleSave">保存</el-button>
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button size="small" type="primary" :loading="loading" @click="handleSave">
|
||||||
|
{{ $t('common:button:save') }}
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</base-model>
|
</base-model>
|
||||||
</div>
|
</div>
|
||||||
@@ -186,8 +207,8 @@ export default {
|
|||||||
rowData: {},
|
rowData: {},
|
||||||
activeName: '0',
|
activeName: '0',
|
||||||
addOrEdit: { visible: false, title: '' },
|
addOrEdit: { visible: false, title: '' },
|
||||||
preview: { visible: false, title: 'eCRF预览' },
|
// preview: { visible: false, title: 'eCRF预览' },
|
||||||
config: { visible: false, title: '评估更新类型', appendToBody: true, width: '600px', configType: 0 },
|
config: { visible: false, title: this.$t('dictionary:template:globalConfig:updateType'), appendToBody: true, width: '600px', configType: 0 },
|
||||||
selectedList: [],
|
selectedList: [],
|
||||||
IsMustGlobalReading: false,
|
IsMustGlobalReading: false,
|
||||||
form: {
|
form: {
|
||||||
@@ -269,10 +290,10 @@ export default {
|
|||||||
this.config.configType = n
|
this.config.configType = n
|
||||||
this.form.IsMustGlobalReading = this.IsMustGlobalReading
|
this.form.IsMustGlobalReading = this.IsMustGlobalReading
|
||||||
if (n === 1) {
|
if (n === 1) {
|
||||||
this.config.title = '是否必须全局阅片'
|
this.config.title = this.$t('dictionary:template:globalConfig:isMustGlobalReading')
|
||||||
this.config.visible = true
|
this.config.visible = true
|
||||||
} else {
|
} else {
|
||||||
this.config.title = '评估更新类型'
|
this.config.title = this.$t('dictionary:template:globalConfig:updateType')
|
||||||
this.config.visible = true
|
this.config.visible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
var a = this.$d.GlobalAssessType.filter(v => {
|
var a = this.$d.GlobalAssessType.filter(v => {
|
||||||
@@ -322,8 +343,4 @@ export default {
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
/deep/ .el-form-item__content{
|
|
||||||
width: calc(100% - 130px);
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|||||||
@@ -1,10 +1,13 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<el-form size="small" :inline="true" label-width="110px" style="position: relative;">
|
<el-form size="small" :inline="true" label-width="110px" style="position: relative;">
|
||||||
<el-divider content-position="left">阅片规则</el-divider>
|
<!-- 阅片规则 -->
|
||||||
<el-form-item label="是否肿瘤学阅片" style="width: 100%">
|
<el-divider content-position="left">{{ $t('dictionary:template:globalConfig:readingRules') }}</el-divider>
|
||||||
|
<!-- 是否肿瘤学阅片 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:oncologyConfig:isOncologyReading')" style="width: 100%">
|
||||||
{{ $fd('YesOrNo', IsOncologyReading)}}
|
{{ $fd('YesOrNo', IsOncologyReading)}}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -12,11 +15,13 @@
|
|||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@click="handleAdd(1)"
|
@click="handleAdd(1)"
|
||||||
>
|
>
|
||||||
配置
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-form size="small" :inline="true" label-width="110px" style="position: relative">
|
<el-form size="small" :inline="true" label-width="110px" style="position: relative">
|
||||||
<el-divider content-position="left">阅片问题</el-divider>
|
<!-- 阅片问题 -->
|
||||||
|
<el-divider content-position="left">{{ $t('dictionary:template:oncologyConfig:reviewQs') }}</el-divider>
|
||||||
|
<!-- 配置 -->
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -24,9 +29,10 @@
|
|||||||
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
v-if="Object.keys(data).length > 0 && !(data.IsCompleteConfig || data.IsBeUsed)"
|
||||||
@click="handleAdd(2)"
|
@click="handleAdd(2)"
|
||||||
>
|
>
|
||||||
配置
|
{{ $t('dictionary:template:globalConfig:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-form-item label="肿瘤学阅片结果" style="width: 100%">
|
<!-- 肿瘤学阅片结果 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:oncologyConfig:reviewResult')" style="width: 100%">
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-table
|
<el-table
|
||||||
@@ -35,24 +41,27 @@
|
|||||||
:data="list"
|
:data="list"
|
||||||
stripe
|
stripe
|
||||||
>
|
>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop=""
|
prop=""
|
||||||
label="序号"
|
:label="$t('dictionary:template:globalConfig:order')"
|
||||||
width="50"
|
width="50"
|
||||||
>
|
>
|
||||||
<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"
|
prop="ValueCN"
|
||||||
label="中文值"
|
:label="$t('dictionary:template:globalConfig:valueCN')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Value"
|
prop="Value"
|
||||||
label="英文值"
|
:label="$t('dictionary:template:globalConfig:value')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -60,12 +69,14 @@
|
|||||||
<base-model :config="config">
|
<base-model :config="config">
|
||||||
<template slot="dialog-body">
|
<template slot="dialog-body">
|
||||||
<el-form size="small" :inline="true" label-width="110px">
|
<el-form size="small" :inline="true" label-width="110px">
|
||||||
<el-form-item label="是否肿瘤学阅片" v-if="config.configType === 1">
|
<!-- 是否肿瘤学阅片 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:oncologyConfig:isOncologyReading')" v-if="config.configType === 1">
|
||||||
<el-radio-group v-model="form.IsOncologyReading">
|
<el-radio-group v-model="form.IsOncologyReading">
|
||||||
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsOncologyReading' + item.value" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio v-for="item of $d.YesOrNo" :key="'form.IsOncologyReading' + item.value" :label="item.value">{{ item.label }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="肿瘤学阅片结果" style="width: 100%" v-if="config.configType === 2">
|
<!-- 肿瘤学阅片结果 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:oncologyConfig:reviewResult')" style="width: 100%" v-if="config.configType === 2">
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-table
|
<el-table
|
||||||
v-if="config.configType === 2"
|
v-if="config.configType === 2"
|
||||||
@@ -80,15 +91,17 @@
|
|||||||
type="selection"
|
type="selection"
|
||||||
width="55">
|
width="55">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 中文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ValueCN"
|
prop="ValueCN"
|
||||||
label="中文值"
|
:label="$t('dictionary:template:globalConfig:valueCN')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 英文值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Value"
|
prop="Value"
|
||||||
label="英文值"
|
:label="$t('dictionary:template:globalConfig:value')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -96,8 +109,12 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<template slot="dialog-footer">
|
<template slot="dialog-footer">
|
||||||
<el-button :disabled="loading" size="small" type="primary" @click="config.visible = false">取消</el-button>
|
<el-button :disabled="loading" size="small" type="primary" @click="config.visible = false">
|
||||||
<el-button size="small" type="primary" :loading="loading" @click="handleSave">保存</el-button>
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button size="small" type="primary" :loading="loading" @click="handleSave">
|
||||||
|
{{ $t('common:button:save') }}
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</base-model>
|
</base-model>
|
||||||
</div>
|
</div>
|
||||||
@@ -129,8 +146,7 @@ export default {
|
|||||||
rowData: {},
|
rowData: {},
|
||||||
activeName: '0',
|
activeName: '0',
|
||||||
addOrEdit: { visible: false, title: '' },
|
addOrEdit: { visible: false, title: '' },
|
||||||
preview: { visible: false, title: 'eCRF预览' },
|
config: { visible: false, title: this.$t('dictionary:template:oncologyConfig:reviewResult'), appendToBody: true, width: '600px', configType: 0 },
|
||||||
config: { visible: false, title: '肿瘤学阅片结果', appendToBody: true, width: '600px', configType: 0 },
|
|
||||||
selectedList: [],
|
selectedList: [],
|
||||||
OncologyAssessType: [],
|
OncologyAssessType: [],
|
||||||
IsOncologyReading: true
|
IsOncologyReading: true
|
||||||
@@ -177,10 +193,10 @@ export default {
|
|||||||
handleAdd(n) {
|
handleAdd(n) {
|
||||||
this.config.configType = n
|
this.config.configType = n
|
||||||
if (n === 1) {
|
if (n === 1) {
|
||||||
this.config.title = '是否肿瘤学阅片'
|
this.config.title = this.$t('dictionary:template:oncologyConfig:isOncologyReading')
|
||||||
this.config.visible = true
|
this.config.visible = true
|
||||||
} else {
|
} else {
|
||||||
this.config.title = '肿瘤学阅片结果'
|
this.config.title = this.$t('dictionary:template:oncologyConfig:reviewResult')
|
||||||
this.config.visible = true
|
this.config.visible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
var a = this.OncologyAssessType.filter(v => {
|
var a = this.OncologyAssessType.filter(v => {
|
||||||
@@ -221,9 +237,3 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
/deep/ .el-form-item__content{
|
|
||||||
width: calc(100% - 110px);
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|||||||
@@ -16,8 +16,16 @@
|
|||||||
<el-input v-model="searchData.TagDescriptionCN" clearable style="width:120px;" />
|
<el-input v-model="searchData.TagDescriptionCN" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">Reset</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">Search</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
|
|||||||
@@ -8,7 +8,8 @@
|
|||||||
:rules="rules"
|
:rules="rules"
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<el-form-item label="病灶类型" prop="LesionType">
|
<!-- 病灶类型 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:basicData:lesionType')" prop="LesionType">
|
||||||
<el-select v-model="form.LesionType">
|
<el-select v-model="form.LesionType">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of CriterionDictionaryList.LesionType"
|
v-for="item of CriterionDictionaryList.LesionType"
|
||||||
@@ -18,7 +19,8 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="器官类型" prop="OrganType">
|
<!-- 器官类型 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:organType')" prop="OrganType">
|
||||||
<el-select v-model="form.OrganType">
|
<el-select v-model="form.OrganType">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of CriterionDictionaryOrganTypeList.OrganType"
|
v-for="item of CriterionDictionaryOrganTypeList.OrganType"
|
||||||
|
|||||||
@@ -43,28 +43,30 @@
|
|||||||
height="100"
|
height="100"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="90" />
|
<el-table-column type="index" width="90" />
|
||||||
|
<!-- 病灶类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="LesionType"
|
prop="LesionType"
|
||||||
label="病灶类型"
|
:label="$t('dictionary:template:basicData:lesionType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('LesionType',scope.row.LesionType) }}
|
{{ $fd('LesionType',scope.row.LesionType) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 器官类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="OrganType"
|
prop="OrganType"
|
||||||
label="器官类型"
|
:label="$t('trials:readingUnit:baseDataCfg:title:organType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd('OrganType',scope.row.OrganType) }}
|
{{ $fd('OrganType',scope.row.OrganType) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 创建时间 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="CreateTime"
|
prop="CreateTime"
|
||||||
label="创建时间"
|
:label="$t('dictionary:template:basicData:createTime')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -76,13 +78,13 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
@@ -163,18 +165,18 @@ export default {
|
|||||||
// 新增
|
// 新增
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.rowData = { CriterionId: this.criterionId }
|
this.rowData = { CriterionId: this.criterionId }
|
||||||
this.editDialog.title = '新增'
|
this.editDialog.title = this.$t('common:button:new')
|
||||||
this.editDialog.visible = true
|
this.editDialog.visible = true
|
||||||
},
|
},
|
||||||
// 编辑
|
// 编辑
|
||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.editDialog.title = '编辑'
|
this.editDialog.title = this.$t('common:button:edit')
|
||||||
this.editDialog.visible = true
|
this.editDialog.visible = true
|
||||||
},
|
},
|
||||||
// 删除
|
// 删除
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
this.$confirm('是否确认删除', {
|
this.$confirm(this.$t('trials:readingUnit:baseDataCfg:message:deleteConfirm'), {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true
|
distinguishCancelAndClose: true
|
||||||
})
|
})
|
||||||
@@ -185,7 +187,7 @@ export default {
|
|||||||
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'))
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -38,8 +38,16 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">重置</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">查询</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
|
|||||||
@@ -3,13 +3,13 @@
|
|||||||
ref="organForm"
|
ref="organForm"
|
||||||
v-loading="loading"
|
v-loading="loading"
|
||||||
:model="form"
|
:model="form"
|
||||||
label-width="100px"
|
label-width="120px"
|
||||||
size="small"
|
size="small"
|
||||||
:rules="rules"
|
:rules="rules"
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<!-- 类型 -->
|
<!-- 类型 -->
|
||||||
<el-form-item label="器官类型" prop="OrganType">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:organType')" prop="OrganType">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.OrganType"
|
v-model="form.OrganType"
|
||||||
>
|
>
|
||||||
@@ -21,35 +21,37 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="分类" prop="Classification">
|
<!-- 分类 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:classification')" prop="Classification">
|
||||||
<el-input v-model="form.Classification" />
|
<el-input v-model="form.Classification" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="分类(英文)">
|
<!-- 分类(英文) -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:classificationEn')">
|
||||||
<el-input v-model="form.ClassificationEN" />
|
<el-input v-model="form.ClassificationEN" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 部位 -->
|
<!-- 部位 -->
|
||||||
<el-form-item label="部位" prop="Part">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:bodyPart')" prop="Part">
|
||||||
<el-input v-model="form.Part" />
|
<el-input v-model="form.Part" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="部位(英文)">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:bodyPartEn')">
|
||||||
<el-input v-model="form.PartEN" />
|
<el-input v-model="form.PartEN" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- TULOC -->
|
<!-- 器官 -->
|
||||||
<el-form-item label="器官" prop="TULOC">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:organ')" prop="TULOC">
|
||||||
<el-input v-model="form.TULOC" />
|
<el-input v-model="form.TULOC" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="器官(英文)" prop="TULOCEN">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:TULOCEN')" prop="TULOCEN">
|
||||||
<el-input v-model="form.TULOCEN" />
|
<el-input v-model="form.TULOCEN" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- TULAT -->
|
<!-- 位置 -->
|
||||||
<el-form-item label="位置">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:TULAT')">
|
||||||
<el-input v-model="form.TULAT" />
|
<el-input v-model="form.TULAT" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="位置(英文)">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:TULATEn')">
|
||||||
<el-input v-model="form.TULATEN" />
|
<el-input v-model="form.TULATEN" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 是否淋巴结 -->
|
<!-- 是否淋巴结 -->
|
||||||
<el-form-item label="是否淋巴结" prop="IsLymphNodes">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:isLymphNodes')" prop="IsLymphNodes">
|
||||||
<el-radio-group v-model="form.IsLymphNodes">
|
<el-radio-group v-model="form.IsLymphNodes">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.ReadingYesOrNo"
|
v-for="item of $d.ReadingYesOrNo"
|
||||||
@@ -60,7 +62,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<!-- 是否可以编辑 -->
|
<!-- 是否可以编辑 -->
|
||||||
<el-form-item label="是否可以编辑" prop="IsCanEditPosition">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:isCanEditPosition')" prop="IsCanEditPosition">
|
||||||
<el-radio-group v-model="form.IsCanEditPosition">
|
<el-radio-group v-model="form.IsCanEditPosition">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.YesOrNo"
|
v-for="item of $d.YesOrNo"
|
||||||
@@ -69,11 +71,11 @@
|
|||||||
>{{ item.label }}</el-radio>
|
>{{ item.label }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="序号" prop="ShowOrder">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:showOrder')" prop="ShowOrder">
|
||||||
<el-input v-model="form.ShowOrder" type="number" />
|
<el-input v-model="form.ShowOrder" type="number" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 描述 -->
|
<!-- 描述 -->
|
||||||
<el-form-item label="描述" prop="Remark">
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:remark')" prop="Remark">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.Remark"
|
v-model="form.Remark"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
|
|||||||
@@ -3,18 +3,22 @@
|
|||||||
<!-- 搜索框 -->
|
<!-- 搜索框 -->
|
||||||
<template slot="search-container">
|
<template slot="search-container">
|
||||||
<el-form :inline="true" size="mini">
|
<el-form :inline="true" size="mini">
|
||||||
<el-form-item label="器官类型">
|
<!-- 器官类型 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:organType')">
|
||||||
<el-select v-model="searchData.OrganType" clearable style="width:130px;">
|
<el-select v-model="searchData.OrganType" clearable style="width:130px;">
|
||||||
<el-option v-for="item of CriterionDictionaryOrganTypeList && CriterionDictionaryOrganTypeList.OrganType" :key="item.Id" :value="parseInt(item.Code)" :label="item.ValueCN" />
|
<el-option v-for="item of CriterionDictionaryOrganTypeList && CriterionDictionaryOrganTypeList.OrganType" :key="item.Id" :value="parseInt(item.Code)" :label="item.ValueCN" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="部位">
|
<!-- 部位 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:bodyPart')">
|
||||||
<el-input v-model="searchData.Part" clearable style="width:130px;" />
|
<el-input v-model="searchData.Part" clearable style="width:130px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="器官">
|
<!-- 器官 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:organ')">
|
||||||
<el-input v-model="searchData.TULOC" clearable style="width:130px;" />
|
<el-input v-model="searchData.TULOC" clearable style="width:130px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否淋巴结">
|
<!-- 是否淋巴结 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:baseDataCfg:title:isLymphNodes')">
|
||||||
<el-select v-model="searchData.IsLymphNodes" clearable style="width:130px;">
|
<el-select v-model="searchData.IsLymphNodes" clearable style="width:130px;">
|
||||||
<el-option v-for="item of $d.ReadingYesOrNo" :key="item.id" :value="item.value" :label="item.label" />
|
<el-option v-for="item of $d.ReadingYesOrNo" :key="item.id" :value="item.value" :label="item.label" />
|
||||||
</el-select>
|
</el-select>
|
||||||
@@ -54,7 +58,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="lesionType.visible = true"
|
@click="lesionType.visible = true"
|
||||||
>
|
>
|
||||||
病灶关联配置
|
{{ this.$t('dictionary:template:basicData:config') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- <el-button-->
|
<!-- <el-button-->
|
||||||
<!-- v-if="!isCompleteConfig"-->
|
<!-- v-if="!isCompleteConfig"-->
|
||||||
@@ -91,7 +95,7 @@
|
|||||||
<!-- 类型 -->
|
<!-- 类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="OrganType"
|
prop="OrganType"
|
||||||
label="器官类型"
|
:label="$t('trials:readingUnit:baseDataCfg:title:organType')"
|
||||||
min-width="120"
|
min-width="120"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
@@ -103,13 +107,13 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Classification"
|
prop="Classification"
|
||||||
label="分类"
|
:label="$t('trials:readingUnit:baseDataCfg:title:classification')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ClassificationEN"
|
prop="ClassificationEN"
|
||||||
label="分类(英文)"
|
:label="$t('trials:readingUnit:baseDataCfg:title:classificationEn')"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
@@ -117,46 +121,49 @@
|
|||||||
<!-- 部位 -->
|
<!-- 部位 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Part"
|
prop="Part"
|
||||||
label="部位"
|
:label="$t('trials:readingUnit:baseDataCfg:title:bodyPart')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="PartEN"
|
prop="PartEN"
|
||||||
label="部位(英文)"
|
:label="$t('trials:readingUnit:baseDataCfg:title:bodyPartEn')"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
<!-- 器官 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="TULOC"
|
prop="TULOC"
|
||||||
label="器官"
|
:label="$t('trials:readingUnit:baseDataCfg:title:organ')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="TULOCEN"
|
prop="TULOCEN"
|
||||||
label="器官(英文)"
|
:label="$t('trials:readingUnit:baseDataCfg:title:TULOCEN')"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
<!-- 位置 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="TULAT"
|
prop="TULAT"
|
||||||
label="位置"
|
:label="$t('trials:readingUnit:baseDataCfg:title:TULAT')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="TULATEN"
|
prop="TULATEN"
|
||||||
label="位置(英文)"
|
:label="$t('trials:readingUnit:baseDataCfg:title:TULATEn')"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
<!-- 是否淋巴结 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsLymphNodes"
|
prop="IsLymphNodes"
|
||||||
label="是否淋巴结"
|
:label="$t('trials:readingUnit:baseDataCfg:title:isLymphNodes')"
|
||||||
min-width="160"
|
min-width="160"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
@@ -168,9 +175,10 @@
|
|||||||
<el-tag v-else type="primary">{{ $fd('ReadingYesOrNo', scope.row.IsLymphNodes) }}</el-tag>
|
<el-tag v-else type="primary">{{ $fd('ReadingYesOrNo', scope.row.IsLymphNodes) }}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否可以编辑 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsCanEditPosition"
|
prop="IsCanEditPosition"
|
||||||
label="是否可以编辑"
|
:label="$t('trials:readingUnit:baseDataCfg:title:isCanEditPosition')"
|
||||||
min-width="160"
|
min-width="160"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
@@ -182,15 +190,17 @@
|
|||||||
<el-tag v-else type="primary">{{ $fd('YesOrNo', scope.row.IsCanEditPosition) }}</el-tag>
|
<el-tag v-else type="primary">{{ $fd('YesOrNo', scope.row.IsCanEditPosition) }}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
label="序号"
|
:label="$t('trials:readingUnit:baseDataCfg:title:showOrder')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
min-width="80"
|
min-width="80"
|
||||||
/>
|
/>
|
||||||
|
<!-- 备注 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Remark"
|
prop="Remark"
|
||||||
label="备注"
|
:label="$t('trials:readingUnit:baseDataCfg:title:remark')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
|
||||||
@@ -203,13 +213,13 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
title="编辑"
|
:title="$t('common:button:edit')"
|
||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
title="删除"
|
:title="$t('common:button:delete')"
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
/>
|
/>
|
||||||
@@ -227,7 +237,7 @@
|
|||||||
:visible.sync="editDialog.visible"
|
:visible.sync="editDialog.visible"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
:title="editDialog.title"
|
:title="editDialog.title"
|
||||||
width="500px"
|
width="600px"
|
||||||
custom-class="base-dialog-wrapper"
|
custom-class="base-dialog-wrapper"
|
||||||
append-to-body
|
append-to-body
|
||||||
>
|
>
|
||||||
@@ -273,9 +283,9 @@
|
|||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
<!-- 类型 -->
|
<!-- 标准 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="标准"
|
:label="$t('trials:auditRecord:table:criterion')"
|
||||||
prop="CriterionId"
|
prop="CriterionId"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur'] },
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: ['blur'] },
|
||||||
@@ -345,9 +355,8 @@ export default {
|
|||||||
total: 0,
|
total: 0,
|
||||||
rowData: {},
|
rowData: {},
|
||||||
editDialog: { title: '', visible: false },
|
editDialog: { title: '', visible: false },
|
||||||
lesionType: { title: '病灶器官关联关系', visible: false },
|
lesionType: { title: this.$t('dictionary:template:basicData:title1'), visible: false },//病灶器官关联关系
|
||||||
// lesionTypes: [],
|
criterion: { title: this.$t('dictionary:template:basicData:title2'), visible: false },//默认数据配置
|
||||||
criterion: { title: '默认数据配置', visible: false },
|
|
||||||
formLoading: false,
|
formLoading: false,
|
||||||
form: { CriterionId: '' },
|
form: { CriterionId: '' },
|
||||||
criterions: [],
|
criterions: [],
|
||||||
@@ -382,7 +391,7 @@ export default {
|
|||||||
TrialReadingCriterionId: this.criterionId
|
TrialReadingCriterionId: this.criterionId
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
this.$message.success('同步成功')
|
this.$message.success(this.$t('dictionary:template:basicData:message1'))
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
})
|
})
|
||||||
@@ -411,18 +420,18 @@ export default {
|
|||||||
// 新增
|
// 新增
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.rowData = { SystemCriterionId: this.criterionId }
|
this.rowData = { SystemCriterionId: this.criterionId }
|
||||||
this.editDialog.title = '新增'
|
this.editDialog.title = this.$t('common:button:new')
|
||||||
this.editDialog.visible = true
|
this.editDialog.visible = true
|
||||||
},
|
},
|
||||||
// 编辑
|
// 编辑
|
||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.editDialog.title = '编辑'
|
this.editDialog.title = this.$t('common:button:edit')
|
||||||
this.editDialog.visible = true
|
this.editDialog.visible = true
|
||||||
},
|
},
|
||||||
// 删除
|
// 删除
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
this.$confirm('是否确认删除', {
|
this.$confirm(this.$t('trials:readingUnit:baseDataCfg:message:deleteConfirm'), {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true
|
distinguishCancelAndClose: true
|
||||||
})
|
})
|
||||||
@@ -433,7 +442,7 @@ export default {
|
|||||||
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'))
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -9,7 +9,8 @@
|
|||||||
label-width="130px"
|
label-width="130px"
|
||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<el-form-item label="问题名称" prop="QuestionName">
|
<!-- 问题名称 -->
|
||||||
|
<el-form-item :label="$t('trials:qcCfg:table:questionName')" prop="QuestionName">
|
||||||
<el-input v-model="form.QuestionName" />
|
<el-input v-model="form.QuestionName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
@@ -27,24 +28,28 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="类型">
|
<!-- 类型 -->
|
||||||
|
<el-form-item :label="$t('trials:qcCfg:table:type')">
|
||||||
<el-select v-model="form.Type" @change="((val)=>{typeChange(val, form)})">
|
<el-select v-model="form.Type" @change="((val)=>{typeChange(val, form)})">
|
||||||
<el-option value="select" label="下拉框" />
|
<el-option
|
||||||
<el-option value="input" label="单行文本框" />
|
v-for="item of $d.QcType"
|
||||||
<el-option value="textarea" label="多行文本框" />
|
:key="item.value"
|
||||||
<el-option value="radio" label="单选框" />
|
:value="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 选项 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'select' || form.Type === 'radio'"
|
v-if="form.Type === 'select' || form.Type === 'radio'"
|
||||||
label="选项: "
|
:label="$t('trials:qcCfg:table:typeValue')"
|
||||||
prop="TypeValue"
|
prop="TypeValue"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.TypeValue" placeholder="选项请用‘|’分割多个选项" />
|
<el-input v-model="form.TypeValue" :placeholder="$t('trials:qcCfg:message:typeValue')" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 父问题 -->
|
<!-- 父问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="父问题"
|
:label="$t('trials:qcCfg:table:parentQs')"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.ParentId"
|
v-model="form.ParentId"
|
||||||
@@ -62,7 +67,7 @@
|
|||||||
<!-- 父问题触发值 -->
|
<!-- 父问题触发值 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.ParentId"
|
v-if="form.ParentId"
|
||||||
label="父问题触发值"
|
:label="$t('trials:qcCfg:table:parentTriggerValue')"
|
||||||
prop="ParentTriggerValue"
|
prop="ParentTriggerValue"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -76,27 +81,47 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否必填">
|
<!-- 是否必填 -->
|
||||||
<el-radio-group v-model="form.IsRequired">
|
<el-form-item :label="$t('trials:qcCfg:table:isRequired')">
|
||||||
<el-radio :label="true">是</el-radio>
|
<el-radio-group
|
||||||
<el-radio :label="false">否</el-radio>
|
v-model="form.IsRequired"
|
||||||
|
>
|
||||||
|
<el-radio
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="`IsRequired${item.value}`"
|
||||||
|
:label="item.value"
|
||||||
|
>
|
||||||
|
{{ item.label }}
|
||||||
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="启用状态">
|
<!-- 启用状态 -->
|
||||||
<el-radio-group v-model="form.IsEnable">
|
<el-form-item :label="$t('trials:qcCfg:table:isEnable')">
|
||||||
<el-radio :label="true">启用</el-radio>
|
<el-radio-group
|
||||||
<el-radio :label="false">停用</el-radio>
|
v-model="form.IsEnable"
|
||||||
|
>
|
||||||
|
<el-radio
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.value"
|
||||||
|
>
|
||||||
|
{{ item.label }}
|
||||||
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="序号" prop="ShowOrder">
|
<el-form-item :label="$t('trials:qcCfg:table:order')" prop="ShowOrder">
|
||||||
<el-input-number v-model="form.ShowOrder" controls-position="right" :min="0" />
|
<el-input-number v-model="form.ShowOrder" controls-position="right" :min="0" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<template slot="dialog-footer">
|
<template slot="dialog-footer">
|
||||||
<el-button :disabled="btnLoading" size="small" type="primary" @click="handleCancle">Cancel</el-button>
|
<el-button :disabled="btnLoading" size="small" type="primary" @click="handleCancle">
|
||||||
<el-button size="small" type="primary" :loading="btnLoading" @click="handleSave">Save</el-button>
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button size="small" type="primary" :loading="btnLoading" @click="handleSave">
|
||||||
|
{{ $t('common:button:save') }}
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</base-model>
|
</base-model>
|
||||||
</template>
|
</template>
|
||||||
@@ -128,7 +153,8 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
var arr = value.split('|')
|
var arr = value.split('|')
|
||||||
if (new Set(arr).size !== arr.length) {
|
if (new Set(arr).size !== arr.length) {
|
||||||
callback(new Error('选项不允许存在相同值'))
|
// '选项不允许存在相同值'
|
||||||
|
callback(new Error(this.$t('trials:qcCfg:message:msg1')))
|
||||||
} else {
|
} else {
|
||||||
callback()
|
callback()
|
||||||
}
|
}
|
||||||
@@ -138,13 +164,13 @@ export default {
|
|||||||
btnLoading: false,
|
btnLoading: false,
|
||||||
form: formDataDefault(),
|
form: formDataDefault(),
|
||||||
rules: {
|
rules: {
|
||||||
QuestionName: [{ required: true, message: 'Please specify', trigger: 'blur' },
|
QuestionName: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
{ max: 300, message: 'The maximum length is 300' }],
|
{ max: 300, message: `${this.$t('common:ruleMessage:maxLength')} 300` }],
|
||||||
TypeValue: [{ required: true, message: 'Please specify', trigger: 'blur' },
|
TypeValue: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
{ validator: validateTypeVal, trigger: 'blur' },
|
{ validator: validateTypeVal, trigger: 'blur' },
|
||||||
{ max: 200, message: 'The maximum length is 200' }],
|
{ max: 200, message: `${this.$t('common:ruleMessage:maxLength')} 200` }],
|
||||||
ParentTriggerValue: [{ required: true, message: 'Please select', trigger: 'blur' }],
|
ParentTriggerValue: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
LanguageType: [{ required: true, message: 'Please select', trigger: 'blur' }]
|
LanguageType: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }]
|
||||||
},
|
},
|
||||||
model_cfg: { visible: false, showClose: true, width: '600px', title: '' },
|
model_cfg: { visible: false, showClose: true, width: '600px', title: '' },
|
||||||
parentOptions: [],
|
parentOptions: [],
|
||||||
@@ -185,7 +211,7 @@ export default {
|
|||||||
this.btnLoading = true
|
this.btnLoading = true
|
||||||
addOrUpdateQCQuestionConfigure(this.form).then(res => {
|
addOrUpdateQCQuestionConfigure(this.form).then(res => {
|
||||||
this.btnLoading = false
|
this.btnLoading = false
|
||||||
this.$message.success('Saved successfully!')
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
// this.$refs['qcQuestionForm'].resetFields()
|
// this.$refs['qcQuestionForm'].resetFields()
|
||||||
this.model_cfg.visible = false
|
this.model_cfg.visible = false
|
||||||
this.$emit('getList')
|
this.$emit('getList')
|
||||||
|
|||||||
@@ -3,7 +3,8 @@
|
|||||||
<!-- 搜索框 -->
|
<!-- 搜索框 -->
|
||||||
<div class="search">
|
<div class="search">
|
||||||
<el-form :inline="true" size="mini" class="base-search-form">
|
<el-form :inline="true" size="mini" class="base-search-form">
|
||||||
<el-form-item label="问题名称:">
|
<!-- 问题名称 -->
|
||||||
|
<el-form-item :label="$t('trials:qcCfg:table:questionName')">
|
||||||
<el-input v-model="searchData.QuestionName" clearable style="width:120px;" />
|
<el-input v-model="searchData.QuestionName" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 语言类型 -->
|
<!-- 语言类型 -->
|
||||||
@@ -22,12 +23,20 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="类型:">
|
<el-form-item :label="$t('trials:qcCfg:table:type')">
|
||||||
<el-input v-model="searchData.Type" clearable style="width:120px;" />
|
<el-input v-model="searchData.Type" clearable style="width:120px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">Reset</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">Search</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto">
|
<span style="margin-left:auto">
|
||||||
@@ -37,9 +46,9 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
@click="preview.visible = true"
|
@click="preview.visible = true"
|
||||||
>
|
>
|
||||||
Preview
|
{{$t('common:button:preview')}}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="primary" size="mini" @click="handleAdd">New</el-button>
|
<el-button type="primary" size="mini" @click="handleAdd">{{$t('common:button:new')}}</el-button>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -51,14 +60,16 @@
|
|||||||
size="small"
|
size="small"
|
||||||
height="100"
|
height="100"
|
||||||
>
|
>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
label="序号"
|
:label="$t('trials:qcCfg:table:order')"
|
||||||
min-width="70"
|
min-width="70"
|
||||||
/>
|
/>
|
||||||
|
<!-- 问题名称 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionName"
|
prop="QuestionName"
|
||||||
label="问题名称"
|
:label="$t('trials:qcCfg:table:questionName')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<!-- 审核问题 -->
|
<!-- 审核问题 -->
|
||||||
@@ -71,68 +82,73 @@
|
|||||||
{{ $fd('LanguageType', scope.row.LanguageType) }}
|
{{ $fd('LanguageType', scope.row.LanguageType) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Type"
|
prop="Type"
|
||||||
label="类型"
|
:label="$t('trials:qcCfg:table:type')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.Type=== 'radio'?'单选框':scope.row.Type=== 'select'?'下拉框':scope.row.Type=== 'input'?'文本框':scope.row.Type=== 'textarea'?'多行文本框':'' }}
|
{{ $fd('QcType', scope.row.Type) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 选项 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="TypeValue"
|
prop="TypeValue"
|
||||||
label="选项"
|
:label="$t('trials:qcCfg:table:typeValue')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
min-width="110"
|
min-width="110"
|
||||||
/>
|
/>
|
||||||
|
<!-- 父问题 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ParentShowOrder"
|
prop="ParentShowOrder"
|
||||||
label="父问题"
|
:label="$t('trials:qcCfg:table:parentQs')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
min-width="110"
|
min-width="110"
|
||||||
/>
|
/>
|
||||||
|
<!-- 父问题触发值 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ParentTriggerValue"
|
prop="ParentTriggerValue"
|
||||||
label="父问题触发值"
|
:label="$t('trials:qcCfg:table:parentTriggerValue')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
min-width="110"
|
min-width="110"
|
||||||
/>
|
/>
|
||||||
|
<!-- 是否必填 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsRequired"
|
prop="IsRequired"
|
||||||
label="是否必填"
|
:label="$t('trials:qcCfg:table:isRequired')"
|
||||||
min-width="90"
|
min-width="90"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.IsRequired?'是':'否' }}
|
{{ $fd('YesOrNo', scope.row.IsRequired) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 启用状态 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsEnable"
|
prop="IsEnable"
|
||||||
label="启用状态"
|
:label="$t('trials:qcCfg:table:isEnable')"
|
||||||
min-width="120"
|
min-width="120"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.IsEnable?'启用':'停用' }}
|
{{ $fd('YesOrNo', scope.row.IsEnable) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="Action" width="200" fixed="right">
|
<el-table-column :label="$t('common:action:action')" width="200" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
>
|
>
|
||||||
Edit
|
{{ $t('common:button:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="danger"
|
type="danger"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
>
|
>
|
||||||
Delete
|
{{ $t('common:button:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -10,7 +10,8 @@
|
|||||||
>
|
>
|
||||||
<div class="base-dialog-body" style="height: 550px; display:flex;flex-direction: column;">
|
<div class="base-dialog-body" style="height: 550px; display:flex;flex-direction: column;">
|
||||||
<div style="height: 150px;">
|
<div style="height: 150px;">
|
||||||
<el-form-item label="类型" prop="Type">
|
<!-- 类型 -->
|
||||||
|
<el-form-item :label="$t('trials:readingUnit:qsList:title:type')" prop="Type">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.Type"
|
v-model="form.Type"
|
||||||
@change="((val)=>{qsTypeChange(val, form)})"
|
@change="((val)=>{qsTypeChange(val, form)})"
|
||||||
@@ -24,9 +25,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题名称 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="问题名称"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
prop="QuestionName"
|
prop="QuestionName"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
@@ -37,9 +39,10 @@
|
|||||||
v-model="form.QuestionName"
|
v-model="form.QuestionName"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题名称(EN) -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group'"
|
v-if="form.Type !== 'group'"
|
||||||
label="问题名称(EN)"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
prop="QuestionEnName"
|
prop="QuestionEnName"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ max: form.Type === 'summary' ? 300 : 100, message: `${this.$t('common:ruleMessage:maxLength')} ${form.Type === 'summary' ? 300 : 100}` }
|
{ max: form.Type === 'summary' ? 300 : 100, message: `${this.$t('common:ruleMessage:maxLength')} ${form.Type === 'summary' ? 300 : 100}` }
|
||||||
@@ -51,8 +54,10 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div style="flex: 1;overflow-y:auto;">
|
<div style="flex: 1;overflow-y:auto;">
|
||||||
<el-divider content-position="left">公有属性</el-divider>
|
<!-- 公有属性 -->
|
||||||
<el-form-item v-if="form.Type !== 'group'" label="是否显示" prop="ShowQuestion">
|
<el-divider content-position="left">{{$t('trials:readingUnit:title:publicProperties')}}</el-divider>
|
||||||
|
<!-- 是否显示 -->
|
||||||
|
<el-form-item v-if="form.Type !== 'group'" :label="$t('trials:readingUnit:qsList:title:isShow')" prop="ShowQuestion">
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.ShowQuestion"
|
v-model="form.ShowQuestion"
|
||||||
@change="((val)=>{isShowQuestionChange(val, form)})"
|
@change="((val)=>{isShowQuestionChange(val, form)})"
|
||||||
@@ -70,7 +75,7 @@
|
|||||||
<!-- 显示时依赖父问题 -->
|
<!-- 显示时依赖父问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.ShowQuestion===1"
|
v-if="form.Type !== 'group' && form.ShowQuestion===1"
|
||||||
label="显示依赖父问题"
|
:label="$t('trials:readingUnit:qsList:title:parentId')"
|
||||||
prop="ParentId"
|
prop="ParentId"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -87,7 +92,7 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 显示时依赖父问题触发值 -->
|
<!-- 显示时依赖父问题触发值 -->
|
||||||
<el-form-item v-if="form.ParentId && form.ShowQuestion===1" label="显示触发值" prop="ParentTriggerValueList">
|
<el-form-item v-if="form.ParentId && form.ShowQuestion===1" :label="$t('trials:readingUnit:qsList:title:parentTriggerValueList')" prop="ParentTriggerValueList">
|
||||||
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
<el-select v-model="form.ParentTriggerValueList" clearable multiple>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of parentTriggerValOptions"
|
v-for="item of parentTriggerValOptions"
|
||||||
@@ -97,7 +102,8 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'basicTable' && form.Type !== 'summary'" label="是否必填" prop="IsRequired">
|
<!-- 是否必填 -->
|
||||||
|
<el-form-item v-if="form.Type !== 'group' && form.Type !== 'table' && form.Type !== 'basicTable' && form.Type !== 'summary'" :label="$t('trials:readingUnit:qsList:title:isRequired')" prop="IsRequired">
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
v-model="form.IsRequired"
|
v-model="form.IsRequired"
|
||||||
:disabled="form.IsJudgeQuestion===true || form.ShowQuestion===2"
|
:disabled="form.IsJudgeQuestion===true || form.ShowQuestion===2"
|
||||||
@@ -112,10 +118,10 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 父问题 -->
|
<!-- 必填依赖父问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.IsRequired === 1"
|
v-if="form.Type !== 'group' && form.IsRequired === 1"
|
||||||
label="必填依赖父问题"
|
:label="$t('trials:readingUnit:qsList:title:relevanceId')"
|
||||||
prop="RelevanceId"
|
prop="RelevanceId"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -131,10 +137,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 必填依赖的父问题触发值 -->
|
<!-- 必填触发值 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.RelevanceId && form.IsRequired === 1"
|
v-if="form.RelevanceId && form.IsRequired === 1"
|
||||||
label="必填触发值"
|
:label="$t('trials:readingUnit:qsList:title:relevanceValueList')"
|
||||||
prop="RelevanceValueList"
|
prop="RelevanceValueList"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.RelevanceValueList" clearable multiple>
|
<el-select v-model="form.RelevanceValueList" clearable multiple>
|
||||||
@@ -147,7 +153,7 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 导出标识 -->
|
<!-- 导出标识 -->
|
||||||
<el-form-item
|
<!-- <el-form-item
|
||||||
:label="$t('trials:readingUnit:qsList:title:ExportIdentification')" prop="ExportIdentification"
|
:label="$t('trials:readingUnit:qsList:title:ExportIdentification')" prop="ExportIdentification"
|
||||||
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
||||||
>
|
>
|
||||||
@@ -166,9 +172,12 @@
|
|||||||
>{{ item.label }}
|
>{{ item.label }}
|
||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<!-- 导出结果 -->
|
<!-- 导出结果 -->
|
||||||
<el-form-item :label="$t('trials:readingUnit:qsList:title:ExportResult')" v-if="form.ExportIdentification" prop="ExportResult">
|
<el-form-item
|
||||||
|
:label="$t('trials:readingUnit:qsList:title:ExportResult')"
|
||||||
|
v-if="form.Type === 'radio' || form.Type === 'select' || form.Type === 'input' || form.Type === 'textarea' || form.Type === 'number' || form.Type === 'class' || form.Type === 'calculation'"
|
||||||
|
>
|
||||||
<el-select v-model="form.ExportResult" multiple>
|
<el-select v-model="form.ExportResult" multiple>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in CriterionDictionaryList.ExportResult"
|
v-for="item in CriterionDictionaryList.ExportResult"
|
||||||
@@ -179,8 +188,9 @@
|
|||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 限制编辑 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="限制编辑"
|
:label="$t('trials:readingUnit:qsList:title:limitEdit')"
|
||||||
v-if="form.Type !== 'summary'"
|
v-if="form.Type !== 'summary'"
|
||||||
prop="LimitEdit"
|
prop="LimitEdit"
|
||||||
:rules="[
|
:rules="[
|
||||||
@@ -191,9 +201,10 @@
|
|||||||
<el-radio v-for="item of $d.LimitEdit" :key="item.value" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio v-for="item of $d.LimitEdit" :key="item.value" :label="item.value">{{ item.label }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 问题标识 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type !== 'group' && form.Type !== 'summary'"
|
v-if="form.Type !== 'group' && form.Type !== 'summary'"
|
||||||
label="问题标识"
|
:label="$t('dictionary:template:criterionConfig:table:questionMark')"
|
||||||
prop="QuestionMark"
|
prop="QuestionMark"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -208,14 +219,16 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 注释 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="注释"
|
:label="$t('trials:readingUnit:qsList:title:Remark')"
|
||||||
prop="Remark"
|
prop="Remark"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.Remark" />
|
<el-input v-model="form.Remark" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="序号"
|
:label="$t('trials:readingUnit:qsList:title:order')"
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -227,7 +240,8 @@
|
|||||||
:min="0"
|
:min="0"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="重复出现最大次数" v-if="form.Type !== 'summary' && form.Type !== 'screenshot' && form.Type !== 'upload'">
|
<!-- 重复出现最大次数 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:maxRowCount')" v-if="form.Type !== 'summary' && form.Type !== 'screenshot' && form.Type !== 'upload'">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
v-model="form.MaxRowCount"
|
v-model="form.MaxRowCount"
|
||||||
controls-position="right"
|
controls-position="right"
|
||||||
@@ -235,7 +249,8 @@
|
|||||||
:max="10"
|
:max="10"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="问题分类" v-if="criterionType === 2">
|
<!-- 问题分类 -->
|
||||||
|
<el-form-item :label="$t('dictionary:template:criterionConfig:table:questionClassify')" v-if="criterionType === 2">
|
||||||
<el-select v-model="form.QuestionClassify" clearable>
|
<el-select v-model="form.QuestionClassify" clearable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of $d.QuestionClassify"
|
v-for="item of $d.QuestionClassify"
|
||||||
@@ -245,15 +260,15 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 私有属性 -->
|
||||||
<el-divider content-position="left">私有属性</el-divider>
|
<el-divider content-position="left">{{$t('trials:readingUnit:title:privateProperties')}}</el-divider>
|
||||||
<!-- 选项类型 -->
|
<!-- 选项类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'select' || form.Type === 'radio' || form.Type === 'input'"
|
v-if="form.Type === 'select' || form.Type === 'radio' || form.Type === 'input'"
|
||||||
label="选项类型"
|
:label="$t('trials:readingUnit:label:QuestionGenre')"
|
||||||
prop="TableQuestionType"
|
prop="TableQuestionType"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: form.Type !== 'input', message: '请选择'}
|
{ required: form.Type !== 'input', message: this.$t('common:ruleMessage:select')}
|
||||||
]"
|
]"
|
||||||
>
|
>
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
@@ -270,21 +285,22 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 选项 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.TableQuestionType === 0 || form.Type === 'class'"
|
v-if="form.TableQuestionType === 0 || form.Type === 'class'"
|
||||||
label="选项"
|
:label="$t('trials:qcCfg:table:typeValue')"
|
||||||
prop="TypeValue"
|
prop="TypeValue"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.TypeValue"
|
v-model="form.TypeValue"
|
||||||
placeholder="选项请用‘|’分割多个选项"
|
:placeholder="$t('trials:qcCfg:message:typeValue')"
|
||||||
@change="typeValueChange"
|
@change="typeValueChange"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 关联问题 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.TableQuestionType === 2"
|
v-if="form.TableQuestionType === 2"
|
||||||
label="关联问题"
|
:label="$t('dictionary:template:criterionConfig:table:dependParentId')"
|
||||||
prop="DependParentId"
|
prop="DependParentId"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -298,9 +314,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 关联字段 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.TableQuestionType === 1 || !!form.DependParentId"
|
v-if="form.TableQuestionType === 1 || !!form.DependParentId"
|
||||||
label="关联字段"
|
:label="$t('dictionary:template:criterionConfig:table:dataTableColumn')"
|
||||||
prop="DataTableColumn"
|
prop="DataTableColumn"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.DataTableColumn">
|
<el-select v-model="form.DataTableColumn">
|
||||||
@@ -312,9 +329,10 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 关联字典 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.TableQuestionType === 3 || form.TableQuestionType === 2"
|
v-if="form.TableQuestionType === 3 || form.TableQuestionType === 2"
|
||||||
label="关联字典"
|
:label="$t('dictionary:template:criterionConfig:table:relatedDictionaryCode')"
|
||||||
prop="DictionaryCode"
|
prop="DictionaryCode"
|
||||||
:rules="[{ required: form.TableQuestionType === 3, message: '请选择', trigger: 'blur' }]"
|
:rules="[{ required: form.TableQuestionType === 3, message: '请选择', trigger: 'blur' }]"
|
||||||
>
|
>
|
||||||
@@ -327,7 +345,36 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.Type === 'select' || form.Type === 'radio'" label="高亮标记值" prop="HighlightAnswerList">
|
<!-- 默认值 -->
|
||||||
|
<el-form-item v-if="form.TableQuestionType === 3" :label="$t('trials:readingUnit:qsList:title:defaultValue')">
|
||||||
|
<el-select v-model="form.DefaultValue" clearable>
|
||||||
|
<!-- <el-option
|
||||||
|
v-for="item of form.DictionaryCode ? $d[form.DictionaryCode] : []"
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value.toString()"
|
||||||
|
/> -->
|
||||||
|
<el-option
|
||||||
|
v-for="item of highlightAnswers"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="$i18n.locale === 'zh' ? item.ValueCN : item.Value"
|
||||||
|
:value="item.Code"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 默认值 -->
|
||||||
|
<el-form-item v-if="form.TableQuestionType === 0" :label="$t('trials:readingUnit:qsList:title:defaultValue')">
|
||||||
|
<el-select v-model="form.DefaultValue" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="item of form.TypeValue ? form.TypeValue.split('|') : []"
|
||||||
|
:key="item"
|
||||||
|
:label="item"
|
||||||
|
:value="item"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- 高亮标记值 -->
|
||||||
|
<el-form-item v-if="form.Type === 'select' || form.Type === 'radio'" :label="$t('trials:readingUnit:qsList:title:highlightAnswers')" prop="HighlightAnswerList">
|
||||||
<el-select v-model="form.HighlightAnswerList" clearable multiple>
|
<el-select v-model="form.HighlightAnswerList" clearable multiple>
|
||||||
<template v-if="form.TypeValue">
|
<template v-if="form.TypeValue">
|
||||||
<el-option
|
<el-option
|
||||||
@@ -338,18 +385,25 @@
|
|||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="form.DictionaryCode">
|
<template v-else-if="form.DictionaryCode">
|
||||||
<el-option
|
<!-- <el-option
|
||||||
v-for="item of $d[form.DictionaryCode]"
|
v-for="item of $d[form.DictionaryCode]"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.value.toString()"
|
:value="item.value.toString()"
|
||||||
|
/> -->
|
||||||
|
<el-option
|
||||||
|
v-for="item of highlightAnswers"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="$i18n.locale === 'zh' ? item.ValueCN : item.Value"
|
||||||
|
:value="item.Code"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 最大长度 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'input' || form.Type === 'textarea'"
|
v-if="form.Type === 'input' || form.Type === 'textarea'"
|
||||||
label="最大长度"
|
:label="$t('trials:readingUnit:qsList:title:MaxAnswerLength')"
|
||||||
prop="MaxAnswerLength"
|
prop="MaxAnswerLength"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' }
|
||||||
@@ -373,10 +427,10 @@
|
|||||||
<!-- 数值类型 -->
|
<!-- 数值类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
||||||
label="数值类型"
|
:label="$t('trials:readingUnit:qsList:title:valueType')"
|
||||||
prop="ValueType"
|
prop="ValueType"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: '请选择'}
|
{ required: true, message: this.$t('common:ruleMessage:select') }
|
||||||
]"
|
]"
|
||||||
>
|
>
|
||||||
<el-radio-group
|
<el-radio-group
|
||||||
@@ -392,10 +446,10 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<!-- 数值单位 -->
|
<!-- 单位 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
v-if="form.Type === 'number' || form.Type === 'calculation'"
|
||||||
label="单位"
|
:label="$t('trials:readingUnit:qsList:title:unit')"
|
||||||
prop="Unit"
|
prop="Unit"
|
||||||
:rules="[
|
:rules="[
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
@@ -413,9 +467,10 @@
|
|||||||
</el-radio>
|
</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 最大上传个数 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'upload'"
|
v-if="form.Type === 'upload'"
|
||||||
label="最大上传个数"
|
:label="$t('trials:readingUnit:qsList:title:imageCount')"
|
||||||
prop="ImageCount"
|
prop="ImageCount"
|
||||||
>
|
>
|
||||||
<el-input-number
|
<el-input-number
|
||||||
@@ -428,7 +483,7 @@
|
|||||||
<!-- 文件类型 -->
|
<!-- 文件类型 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'upload'"
|
v-if="form.Type === 'upload'"
|
||||||
label="文件类型"
|
:label="$t('trials:readingUnit:qsList:title:FileType')"
|
||||||
prop="FileType"
|
prop="FileType"
|
||||||
:rules="[{ type: 'array', required: true, message: this.$t('common:ruleMessage:specify'), trigger: [ 'change'] }]"
|
:rules="[{ type: 'array', required: true, message: this.$t('common:ruleMessage:specify'), trigger: [ 'change'] }]"
|
||||||
>
|
>
|
||||||
@@ -452,9 +507,10 @@
|
|||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 分类 -->
|
<!-- 分类 -->
|
||||||
|
<!-- 分类数据来源 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'class'"
|
v-if="form.Type === 'class'"
|
||||||
label="分类数据来源"
|
:label="$t('dictionary:template:criterionConfig:table:classifyQuestion')"
|
||||||
prop="ClassifyTableQuestionId"
|
prop="ClassifyTableQuestionId"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.ClassifyTableQuestionId" clearable>
|
<el-select v-model="form.ClassifyTableQuestionId" clearable>
|
||||||
@@ -462,9 +518,10 @@
|
|||||||
:value="item.Id"/>
|
:value="item.Id"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<!-- 分类算法 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-if="form.Type === 'class'"
|
v-if="form.Type === 'class'"
|
||||||
label="分类算法"
|
:label="$t('dictionary:template:criterionConfig:table:classifyAlgorithms')"
|
||||||
prop="ClassifyAlgorithms"
|
prop="ClassifyAlgorithms"
|
||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
@@ -563,7 +620,7 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
var arr = value.split('|')
|
var arr = value.split('|')
|
||||||
if (new Set(arr).size !== arr.length) {
|
if (new Set(arr).size !== arr.length) {
|
||||||
callback(new Error('选项不允许存在相同值'))
|
callback(new Error(this.$t('trials:readingUnit:qsList:message:msg0')))
|
||||||
} else {
|
} else {
|
||||||
callback()
|
callback()
|
||||||
}
|
}
|
||||||
@@ -607,38 +664,39 @@ export default {
|
|||||||
ImageCount: 0,
|
ImageCount: 0,
|
||||||
ClassifyTableQuestionId: null,
|
ClassifyTableQuestionId: null,
|
||||||
ClassifyAlgorithms: null,
|
ClassifyAlgorithms: null,
|
||||||
ExportIdentification: 0,
|
// ExportIdentification: 0,
|
||||||
ExportResult: []
|
ExportResult: [],
|
||||||
|
DefaultValue:null
|
||||||
// IsEnable: true
|
// IsEnable: true
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
Type: [
|
Type: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
],
|
],
|
||||||
// QuestionName: [{ required: true, message: '请注明', trigger: 'blur' },
|
// QuestionName: [{ required: true, message: '请注明', trigger: 'blur' },
|
||||||
// { max: 300, message: '最大长度为 300' }],
|
// { max: 300, message: '最大长度为 300' }],
|
||||||
|
|
||||||
TypeValue: [{ required: true, message: '请注明', trigger: 'blur' },
|
TypeValue: [{ required: true, message: this.$t('common:ruleMessage:specify'), trigger: 'blur' },
|
||||||
{ validator: validateTypeVal, trigger: 'blur' },
|
{ validator: validateTypeVal, trigger: 'blur' },
|
||||||
{ max: 200, message: '最大长度为 200' }],
|
{ max: 200, message: `${this.$t('common:ruleMessage:maxLength')} 200` }],
|
||||||
ShowQuestion: [{ required: true, message: '请选择', trigger: 'blur' }],
|
ShowQuestion: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
IsRequired: [{ required: true, message: '请选择', trigger: 'blur' }],
|
IsRequired: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
ParentId: [{ required: true, message: '请选择', trigger: 'blur' }],
|
ParentId: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
ParentTriggerValueList: [
|
ParentTriggerValueList: [
|
||||||
{ required: true, message: '请选择', trigger: 'blur' }
|
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }
|
||||||
],
|
],
|
||||||
RelevanceId: [{ required: true, message: '请选择', trigger: 'blur' }],
|
RelevanceId: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
RelevanceValueList: [{ required: true, message: '请选择', trigger: 'blur' }],
|
RelevanceValueList: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
DataTableName: [{ required: true, message: '请选择', trigger: 'blur' }],
|
DataTableName: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
DataTableColumn: [{ required: true, message: '请选择', trigger: 'blur' }],
|
DataTableColumn: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
// DictionaryCode: [{ required: true, message: '请选择', trigger: 'blur' }],
|
// DictionaryCode: [{ required: true, message: '请选择', trigger: 'blur' }],
|
||||||
DependParentId: [{ required: true, message: '请选择', trigger: 'blur' }],
|
DependParentId: [{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' }],
|
||||||
ExportIdentification: [
|
// ExportIdentification: [
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
// { required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
||||||
],
|
// ],
|
||||||
ExportResult: [
|
// ExportResult: [
|
||||||
{ required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
// { required: true, message: this.$t('common:ruleMessage:select'), trigger: 'blur' },
|
||||||
]
|
// ]
|
||||||
},
|
},
|
||||||
loading: false,
|
loading: false,
|
||||||
parentOptions: [],
|
parentOptions: [],
|
||||||
@@ -648,9 +706,31 @@ export default {
|
|||||||
colOptions: [],
|
colOptions: [],
|
||||||
dicList: [],
|
dicList: [],
|
||||||
CriterionDictionaryList: [],
|
CriterionDictionaryList: [],
|
||||||
Questions: []
|
Questions: [],
|
||||||
|
highlightAnswers: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
'form.DictionaryCode': {
|
||||||
|
deep: true,
|
||||||
|
immediate: true,
|
||||||
|
async handler(v, oldv) {
|
||||||
|
try {
|
||||||
|
if (!v) {
|
||||||
|
this.highlightAnswers = []
|
||||||
|
return
|
||||||
|
}
|
||||||
|
let res = await getCriterionDictionary({
|
||||||
|
ReadingCriterionId: this.criterionId,
|
||||||
|
DictionaryCode: this.form.DictionaryCode,
|
||||||
|
})
|
||||||
|
this.highlightAnswers = res.Result[this.form.DictionaryCode]
|
||||||
|
} catch (e) {
|
||||||
|
console.log(e)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.initForm()
|
this.initForm()
|
||||||
this.getCriterionDictionary()
|
this.getCriterionDictionary()
|
||||||
@@ -710,7 +790,13 @@ export default {
|
|||||||
})
|
})
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
this.parentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
// this.parentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.criterionId, DictionaryCode: dicCode})
|
||||||
|
|
||||||
|
this.parentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
||||||
@@ -726,8 +812,12 @@ export default {
|
|||||||
})
|
})
|
||||||
if (i !== -1) {
|
if (i !== -1) {
|
||||||
if (this.parentOptions[i].QuestionGenre === 3) {
|
if (this.parentOptions[i].QuestionGenre === 3) {
|
||||||
console.log(this.$d[this.parentOptions[i].DictionaryCode])
|
// this.reParentTriggerValOptions = this.$d[this.parentOptions[i].DictionaryCode]
|
||||||
this.reParentTriggerValOptions = this.$d[this.parentOptions[i].DictionaryCode]
|
let dicCode = this.parentOptions[i].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.criterionId, DictionaryCode: dicCode})
|
||||||
|
this.reParentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[i].TypeValue.split('|').forEach((item, index) => {
|
this.parentOptions[i].TypeValue.split('|').forEach((item, index) => {
|
||||||
@@ -805,14 +895,20 @@ export default {
|
|||||||
form.RelevanceValue = ''
|
form.RelevanceValue = ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
parentQuestionChange(val, form) {
|
async parentQuestionChange(val, form) {
|
||||||
if (val) {
|
if (val) {
|
||||||
var index = this.parentOptions.findIndex(item => {
|
var index = this.parentOptions.findIndex(item => {
|
||||||
return item.QuestionId === val
|
return item.QuestionId === val
|
||||||
})
|
})
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
this.parentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
// this.parentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.criterionId, DictionaryCode: dicCode})
|
||||||
|
|
||||||
|
this.parentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
||||||
@@ -824,16 +920,20 @@ export default {
|
|||||||
}
|
}
|
||||||
form.ParentTriggerValue = ''
|
form.ParentTriggerValue = ''
|
||||||
},
|
},
|
||||||
relevanceQuestionChange(val, form) {
|
async relevanceQuestionChange(val, form) {
|
||||||
if (val) {
|
if (val) {
|
||||||
var index = this.parentOptions.findIndex(item => {
|
var index = this.parentOptions.findIndex(item => {
|
||||||
return item.QuestionId === val
|
return item.QuestionId === val
|
||||||
})
|
})
|
||||||
console.log(this.$d[this.parentOptions[index].DictionaryCode], this.parentOptions[index].QuestionGenre)
|
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
if (this.parentOptions[index].QuestionGenre === 3) {
|
if (this.parentOptions[index].QuestionGenre === 3) {
|
||||||
console.log(this.$d[this.parentOptions[index].DictionaryCode])
|
// this.reParentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
||||||
this.reParentTriggerValOptions = this.$d[this.parentOptions[index].DictionaryCode]
|
let dicCode = this.parentOptions[index].DictionaryCode
|
||||||
|
let res = await getCriterionDictionary({ReadingCriterionId: this.criterionId, DictionaryCode: dicCode})
|
||||||
|
|
||||||
|
this.reParentTriggerValOptions = res.Result[dicCode].map(i=>{
|
||||||
|
return {id: i.Id, label: this.$i18n.locale === 'zh' ? i.ValueCN : i.Value, value: i.Code}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
const options = []
|
const options = []
|
||||||
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
this.parentOptions[index].TypeValue.split('|').forEach((item, index) => {
|
||||||
@@ -890,8 +990,9 @@ export default {
|
|||||||
form.ImageCount = null
|
form.ImageCount = null
|
||||||
form.ClassifyTableQuestionId = null
|
form.ClassifyTableQuestionId = null
|
||||||
form.ClassifyAlgorithms = null
|
form.ClassifyAlgorithms = null
|
||||||
form.ExportIdentification = 0
|
// form.ExportIdentification = 0
|
||||||
form.ExportResult = []
|
form.ExportResult = []
|
||||||
|
form.DefaultValue = null
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
this.$emit('close')
|
this.$emit('close')
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>
|
>
|
||||||
新增
|
{{$t('common:button:new')}}
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@@ -20,24 +20,28 @@
|
|||||||
size="small"
|
size="small"
|
||||||
height="500"
|
height="500"
|
||||||
>
|
>
|
||||||
|
<!-- 序号 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowOrder"
|
prop="ShowOrder"
|
||||||
label="序号"
|
:label="$t('trials:qcCfg:table:order')"
|
||||||
min-width="70"
|
min-width="70"
|
||||||
/>
|
/>
|
||||||
|
<!-- 问题名称 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionName"
|
prop="QuestionName"
|
||||||
label="问题名称"
|
:label="$t('trials:readingUnit:qsList:title:qsName')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 问题名称(EN) -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionEnName"
|
prop="QuestionEnName"
|
||||||
label="问题名称(EN)"
|
:label="$t('trials:readingUnit:qsList:title:qsNameEn')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
|
<!-- 类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="Type"
|
prop="Type"
|
||||||
label="类型"
|
:label="$t('trials:readingUnit:qsList:title:type')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -61,9 +65,10 @@
|
|||||||
min-width="110"
|
min-width="110"
|
||||||
/>
|
/>
|
||||||
-->
|
-->
|
||||||
|
<!-- 是否显示 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ShowQuestion"
|
prop="ShowQuestion"
|
||||||
label="是否显示"
|
:label="$t('trials:readingUnit:qsList:title:isShow')"
|
||||||
min-width="90"
|
min-width="90"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -71,9 +76,10 @@
|
|||||||
{{ $fd('ShowQuestion',scope.row.ShowQuestion) }}
|
{{ $fd('ShowQuestion',scope.row.ShowQuestion) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<!-- 是否必填 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="IsRequired"
|
prop="IsRequired"
|
||||||
label="是否必填"
|
:label="$t('trials:readingUnit:qsList:title:isRequired')"
|
||||||
min-width="90"
|
min-width="90"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -125,7 +131,7 @@
|
|||||||
<!-- 问题标识 -->
|
<!-- 问题标识 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="QuestionMark"
|
prop="QuestionMark"
|
||||||
label="问题标识"
|
:label="$t('dictionary:template:criterionConfig:table:questionMark')"
|
||||||
width="140"
|
width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -178,9 +184,10 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
-->
|
-->
|
||||||
|
<!-- 最大行数 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="MaxRowCount"
|
prop="MaxRowCount"
|
||||||
label="最大行数"
|
:label="$t('trials:readingUnit:qsList:title:MaxRowCount')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -190,7 +197,7 @@
|
|||||||
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop=""
|
prop=""
|
||||||
label="操作"
|
:label="$t('common:action:action')"
|
||||||
width="150"
|
width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
>
|
>
|
||||||
@@ -201,7 +208,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleLook(scope.row)"
|
@click="handleLook(scope.row)"
|
||||||
>
|
>
|
||||||
查看
|
{{ $t('trials:readingPeriod:button:view') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="!isCompleteConfig"
|
v-if="!isCompleteConfig"
|
||||||
@@ -209,7 +216,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
>
|
>
|
||||||
编辑
|
{{ $t('common:button:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="!isCompleteConfig"
|
v-if="!isCompleteConfig"
|
||||||
@@ -217,7 +224,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
>
|
>
|
||||||
删除
|
{{ $t('common:button:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -295,7 +302,7 @@ export default {
|
|||||||
handleLook(row) {
|
handleLook(row) {
|
||||||
this.type = 'look'
|
this.type = 'look'
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.addOrEdit.title = '编辑'
|
this.addOrEdit.title = this.$t('common:button:edit')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
@@ -308,13 +315,13 @@ export default {
|
|||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.type = 'add'
|
this.type = 'add'
|
||||||
this.rowData = {}
|
this.rowData = {}
|
||||||
this.addOrEdit.title = '添加'
|
this.addOrEdit.title = this.$t('common:button:new')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.type = 'edit'
|
this.type = 'edit'
|
||||||
this.rowData = { ...row }
|
this.rowData = { ...row }
|
||||||
this.addOrEdit.title = '编辑'
|
this.addOrEdit.title = this.$t('common:button:edit')
|
||||||
this.addOrEdit.visible = true
|
this.addOrEdit.visible = true
|
||||||
},
|
},
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
@@ -329,7 +336,7 @@ export default {
|
|||||||
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'))
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
}).catch(() => { this.loading = false })
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -246,9 +246,9 @@
|
|||||||
:autosize="{ minRows: 8, maxRows: 8 }"
|
:autosize="{ minRows: 8, maxRows: 8 }"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
:disabled="!form.EmailHtmlContentCN"
|
:disabled="!form.EmailHtmlContentCN && form.EmailHtmlContent"
|
||||||
type="text"
|
type="text"
|
||||||
@click="PreviewHTML(form.EmailHtmlContentCN)"
|
@click="PreviewHTML(form.EmailHtmlContentCN, form.EmailHtmlContent)"
|
||||||
style="position: absolute; left: -50px; top: 30px"
|
style="position: absolute; left: -50px; top: 30px"
|
||||||
>
|
>
|
||||||
{{ $t('common:button:preview') }}
|
{{ $t('common:button:preview') }}
|
||||||
@@ -265,9 +265,9 @@
|
|||||||
:autosize="{ minRows: 8, maxRows: 8 }"
|
:autosize="{ minRows: 8, maxRows: 8 }"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
:disabled="!form.EmailHtmlContent"
|
:disabled="!form.EmailHtmlContentCN && form.EmailHtmlContent"
|
||||||
type="text"
|
type="text"
|
||||||
@click="PreviewHTML(form.EmailHtmlContent)"
|
@click="PreviewHTML(form.EmailHtmlContentCN, form.EmailHtmlContent)"
|
||||||
style="position: absolute; left: -50px; top: 30px"
|
style="position: absolute; left: -50px; top: 30px"
|
||||||
>
|
>
|
||||||
{{ $t('common:button:preview') }}
|
{{ $t('common:button:preview') }}
|
||||||
@@ -519,8 +519,8 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 预览模板
|
// 预览模板
|
||||||
PreviewHTML(html) {
|
PreviewHTML(html, htmlEn) {
|
||||||
this.$emit('PreviewHTML', html)
|
this.$emit('PreviewHTML', html, htmlEn)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -123,8 +123,16 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleSearch">查询</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleReset">重置</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left: auto">
|
<span style="margin-left: auto">
|
||||||
@@ -370,6 +378,13 @@
|
|||||||
<el-button type="text" @click="handleDelete(scope.row)"
|
<el-button type="text" @click="handleDelete(scope.row)"
|
||||||
>删除</el-button
|
>删除</el-button
|
||||||
>
|
>
|
||||||
|
<el-button
|
||||||
|
type="text"
|
||||||
|
@click="
|
||||||
|
preview(scope.row.EmailHtmlContentCN, scope.row.EmailHtmlContent)
|
||||||
|
"
|
||||||
|
>{{ $t('common:button:preview') }}</el-button
|
||||||
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
@@ -427,7 +442,23 @@
|
|||||||
fullscreen
|
fullscreen
|
||||||
custom-class="base-dialog-wrapper"
|
custom-class="base-dialog-wrapper"
|
||||||
>
|
>
|
||||||
<div v-html="previewHTML"></div>
|
<div
|
||||||
|
style="
|
||||||
|
display: flex;
|
||||||
|
align-items: flex-start;
|
||||||
|
justify-content: space-around;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<div style="min-width: 50%">
|
||||||
|
<h3>邮件内容模版(CN)</h3>
|
||||||
|
<div v-html="previewHTML"></div>
|
||||||
|
</div>
|
||||||
|
<div style="min-width: 50%">
|
||||||
|
<h3>邮件内容模版(EN)</h3>
|
||||||
|
<div v-html="previewHTMLEN"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</box-content>
|
</box-content>
|
||||||
</template>
|
</template>
|
||||||
@@ -487,6 +518,7 @@ export default {
|
|||||||
attachmentVisible: false,
|
attachmentVisible: false,
|
||||||
previewVisible: false,
|
previewVisible: false,
|
||||||
previewHTML: null,
|
previewHTML: null,
|
||||||
|
previewHTMLEN: null,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -574,8 +606,9 @@ export default {
|
|||||||
closeDialog() {
|
closeDialog() {
|
||||||
this.editVisible = false
|
this.editVisible = false
|
||||||
},
|
},
|
||||||
preview(html) {
|
preview(html, htmlEN) {
|
||||||
this.previewHTML = html
|
this.previewHTML = html
|
||||||
|
this.previewHTMLEN = htmlEN
|
||||||
this.previewVisible = true
|
this.previewVisible = true
|
||||||
},
|
},
|
||||||
// 导出
|
// 导出
|
||||||
|
|||||||
@@ -1,31 +1,40 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="question-wrapper">
|
<div class="question-wrapper">
|
||||||
<el-tabs v-model="activeTab" @tab-click="clickTab">
|
<el-tabs v-model="activeTab" @tab-click="clickTab">
|
||||||
<el-tab-pane label="QC问题配置" name="qc">
|
<!-- QC问题配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:qcConfig')" name="qc">
|
||||||
<qc-questions v-if="activeTab == 'qc'" />
|
<qc-questions v-if="activeTab == 'qc'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="阅片标准配置" name="criterions">
|
<!-- 阅片标准配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:criterionsConfig')" name="criterions">
|
||||||
<criterions-tmp v-if="activeTab == 'criterions'" />
|
<criterions-tmp v-if="activeTab == 'criterions'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="临床数据配置" name="clinicalData">
|
<!-- 临床数据配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:clinicalDataConfig')" name="clinicalData">
|
||||||
<clinical-data v-if="activeTab == 'clinicalData'" />
|
<clinical-data v-if="activeTab == 'clinicalData'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="医学审核问题配置" name="medicalAudit">
|
<!-- 医学审核问题配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:medicalConfig')" name="medicalAudit">
|
||||||
<medical-audit v-if="activeTab == 'medicalAudit'" />
|
<medical-audit v-if="activeTab == 'medicalAudit'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="DICOM字段匿名化配置" name="anonymization">
|
<!-- DICOM字段匿名化配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:dicomTagConfig')" name="anonymization">
|
||||||
<Anonymization v-if="activeTab == 'anonymization'" />
|
<Anonymization v-if="activeTab == 'anonymization'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="DICOM字段新增配置" name="increasefields">
|
<!-- DICOM字段新增配置 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:dicomTagAddConfig')" name="increasefields">
|
||||||
<IncreaseFields v-if="activeTab == 'increasefields'" />
|
<IncreaseFields v-if="activeTab == 'increasefields'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="邮件管理" name="email">
|
<!-- 邮件管理 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:emailConfig')" name="email">
|
||||||
<Email v-if="activeTab == 'email'" />
|
<Email v-if="activeTab == 'email'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="签名管理" name="sign">
|
<!-- 签名管理 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:signConfig')" name="sign">
|
||||||
<Sign v-if="activeTab == 'sign'" />
|
<Sign v-if="activeTab == 'sign'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="浏览器推荐" name="browser">
|
<!-- 浏览器推荐 -->
|
||||||
|
<el-tab-pane :label="$t('dictionary:template:tab:browserConfig')" name="browser">
|
||||||
<Browser v-if="activeTab == 'browser'" />
|
<Browser v-if="activeTab == 'browser'" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
|
|||||||
@@ -3,15 +3,23 @@
|
|||||||
<!-- 搜索框 -->
|
<!-- 搜索框 -->
|
||||||
<div class="search">
|
<div class="search">
|
||||||
<el-form :inline="true" size="mini" class="base-search-form">
|
<el-form :inline="true" size="mini" class="base-search-form">
|
||||||
<el-form-item label="编号:">
|
<el-form-item label="Code:">
|
||||||
<el-input v-model="searchData.Code" style="width:100px;" />
|
<el-input v-model="searchData.Code" style="width:100px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="模板:">
|
<el-form-item label="模板:">
|
||||||
<el-input v-model="searchData.Name" style="width:100px;" />
|
<el-input v-model="searchData.Name" style="width:100px;" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleReset">Reset</el-button>
|
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||||
<el-button type="primary" @click="handleSearch">Search</el-button>
|
{{ $t('common:button:search') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:reset') }}
|
||||||
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto;">
|
<span style="margin-left:auto;">
|
||||||
|
|||||||
@@ -29,15 +29,16 @@
|
|||||||
<el-input v-model="password.Email" disabled />
|
<el-input v-model="password.Email" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 用户名 -->
|
<!-- 用户名 -->
|
||||||
<el-form-item :label="$t('recompose:form:role')" prop="UserType">
|
<!-- <el-form-item :label="$t('recompose:form:role')" prop="UserType">
|
||||||
<el-input v-model="password.UserType" disabled />
|
<el-input v-model="password.UserType" disabled />
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<!-- 用户名 -->
|
<!-- 用户名 -->
|
||||||
<el-form-item :label="$t('recompose:form:userName')" prop="NewUserName">
|
<el-form-item :label="$t('recompose:form:userName')" prop="NewUserName">
|
||||||
<el-input v-model="password.NewUserName" />
|
<el-input v-model="password.NewUserName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 新密码 -->
|
<!-- 新密码 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
class="my_new_pwd"
|
||||||
:label="$t('recompose:form:newPassword')"
|
:label="$t('recompose:form:newPassword')"
|
||||||
prop="NewPassWord"
|
prop="NewPassWord"
|
||||||
>
|
>
|
||||||
@@ -84,6 +85,11 @@ export default {
|
|||||||
password: {
|
password: {
|
||||||
NewUserName: null,
|
NewUserName: null,
|
||||||
UserId: null,
|
UserId: null,
|
||||||
|
ConfirmPassWord: null,
|
||||||
|
NewPassWord: null,
|
||||||
|
Email: null,
|
||||||
|
UserType: null,
|
||||||
|
access_token: null,
|
||||||
},
|
},
|
||||||
passwordFormRules: {
|
passwordFormRules: {
|
||||||
NewUserName: [
|
NewUserName: [
|
||||||
@@ -95,7 +101,6 @@ export default {
|
|||||||
: 'zh'
|
: 'zh'
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
var reg1 = /^[a-zA-Z0-9_]{4,16}$/ //密码必须是8位以上、必须含有字母、数字、特殊符号
|
var reg1 = /^[a-zA-Z0-9_]{4,16}$/ //密码必须是8位以上、必须含有字母、数字、特殊符号
|
||||||
console.log(!reg1.test(value))
|
|
||||||
if (!reg1.test(value)) {
|
if (!reg1.test(value)) {
|
||||||
callback(
|
callback(
|
||||||
lang === 'zh'
|
lang === 'zh'
|
||||||
@@ -176,9 +181,9 @@ export default {
|
|||||||
this.$i18n.locale = this.$route.query.lang
|
this.$i18n.locale = this.$route.query.lang
|
||||||
this.setLanguage(this.$route.query.lang)
|
this.setLanguage(this.$route.query.lang)
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
if (!this.password.NewUserName) {
|
// if (!this.password.NewUserName) {
|
||||||
this.$alert(this.$t('recompose:message:warning'))
|
// this.$alert(this.$t('recompose:message:warning'))
|
||||||
}
|
// }
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
||||||
@@ -190,8 +195,10 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
}
|
}
|
||||||
this.$i18n.locale = 'zh'
|
if (!this.$i18n.locale) {
|
||||||
this.setLanguage('zh')
|
//this.$i18n.locale = 'zh'
|
||||||
|
//this.setLanguage('zh')
|
||||||
|
}
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
save() {
|
save() {
|
||||||
@@ -229,7 +236,10 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
this.$refs['passwordForm'].resetFields()
|
// this.$refs['passwordForm'].resetFields()
|
||||||
|
this.password.NewPassWord = null
|
||||||
|
this.password.NewUserName = null
|
||||||
|
this.password.ConfirmPassWord = null
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -263,7 +273,7 @@ input {
|
|||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
caret-color: #fff;
|
caret-color: #fff;
|
||||||
}
|
}
|
||||||
.el-form-item {
|
::v-deep .is-error.my_new_pwd {
|
||||||
margin-bottom: 30px;
|
margin-bottom: 45px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
+5
-2
@@ -2,7 +2,8 @@
|
|||||||
<div class="wscn-http404-container">
|
<div class="wscn-http404-container">
|
||||||
<div class="wscn-http404" style="display: flex;align-items: center">
|
<div class="wscn-http404" style="display: flex;align-items: center">
|
||||||
<div class="pic-404">
|
<div class="pic-404">
|
||||||
<img class="pic-404__parent" src="@/assets/login-bg.png" alt="404">
|
<!-- <img class="pic-404__parent" src="@/assets/login-bg.png" alt="404"> -->
|
||||||
|
<svg-icon icon-class="login-bg" style="width: 100%; height: 100%" />
|
||||||
<img class="pic-404__child left" src="@/assets/404_images/404_cloud.png" alt="404">
|
<img class="pic-404__child left" src="@/assets/404_images/404_cloud.png" alt="404">
|
||||||
<img class="pic-404__child mid" src="@/assets/404_images/404_cloud.png" alt="404">
|
<img class="pic-404__child mid" src="@/assets/404_images/404_cloud.png" alt="404">
|
||||||
<img class="pic-404__child right" src="@/assets/404_images/404_cloud.png" alt="404">
|
<img class="pic-404__child right" src="@/assets/404_images/404_cloud.png" alt="404">
|
||||||
@@ -56,8 +57,10 @@ export default {
|
|||||||
.pic-404 {
|
.pic-404 {
|
||||||
position: relative;
|
position: relative;
|
||||||
float: left;
|
float: left;
|
||||||
width: 400px;
|
width: 500px;
|
||||||
|
height: 300px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
margin-right: 10px;
|
||||||
&__parent {
|
&__parent {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -76,7 +76,8 @@
|
|||||||
>
|
>
|
||||||
<!-- 用户名 -->
|
<!-- 用户名 -->
|
||||||
<el-form-item :label="$t('passwordReset:form:userName')" prop="UserId">
|
<el-form-item :label="$t('passwordReset:form:userName')" prop="UserId">
|
||||||
<el-select
|
<el-input v-model="form.UserName" disabled />
|
||||||
|
<!-- <el-select
|
||||||
v-model="form.UserId"
|
v-model="form.UserId"
|
||||||
clearable
|
clearable
|
||||||
filterable
|
filterable
|
||||||
@@ -94,15 +95,15 @@
|
|||||||
item.UserType
|
item.UserType
|
||||||
}}</span>
|
}}</span>
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select> -->
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 用户类型 -->
|
<!-- 用户类型 -->
|
||||||
<el-form-item
|
<!-- <el-form-item
|
||||||
v-if="form.UserId"
|
v-if="form.UserId"
|
||||||
:label="$t('passwordReset:form:userType')"
|
:label="$t('passwordReset:form:userType')"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.UserType" disabled />
|
<el-input v-model="form.UserType" disabled />
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<!-- 新密码 -->
|
<!-- 新密码 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
class="my_new_pwd"
|
class="my_new_pwd"
|
||||||
@@ -338,11 +339,13 @@ export default {
|
|||||||
)
|
)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.formLoading = false
|
this.formLoading = false
|
||||||
this.users = res.Result
|
this.form.UserId = res.Result.Id
|
||||||
if (this.users.length === 1) {
|
this.form.UserName = res.Result.UserName
|
||||||
this.form.UserId = this.users[0].UserId
|
// this.users = res.Result
|
||||||
this.form.UserType = this.users[0].UserType
|
// if (this.users.length === 1) {
|
||||||
}
|
// this.form.UserId = this.users[0].UserId
|
||||||
|
// this.form.UserType = this.users[0].UserType
|
||||||
|
// }
|
||||||
// 验证成功
|
// 验证成功
|
||||||
this.$message.success(
|
this.$message.success(
|
||||||
this.$t('passwordReset:message:verifiedSuccessfully')
|
this.$t('passwordReset:message:verifiedSuccessfully')
|
||||||
@@ -420,7 +423,7 @@ export default {
|
|||||||
/* margin-bottom: 40px;*/
|
/* margin-bottom: 40px;*/
|
||||||
/*}*/
|
/*}*/
|
||||||
.is-error.my_new_pwd {
|
.is-error.my_new_pwd {
|
||||||
margin-bottom: 40px;
|
margin-bottom: 45px;
|
||||||
}
|
}
|
||||||
.flexBox {
|
.flexBox {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
+132
-48
@@ -83,7 +83,7 @@
|
|||||||
<svg-icon icon-class="password" />
|
<svg-icon icon-class="password" />
|
||||||
</span>
|
</span>
|
||||||
<!-- password -->
|
<!-- password -->
|
||||||
<!-- <el-input
|
<el-input
|
||||||
:key="passwordType"
|
:key="passwordType"
|
||||||
ref="password"
|
ref="password"
|
||||||
v-model="loginForm.password"
|
v-model="loginForm.password"
|
||||||
@@ -100,8 +100,8 @@
|
|||||||
<svg-icon
|
<svg-icon
|
||||||
:icon-class="passwordType === 'password' ? 'eye' : 'eye-open'"
|
:icon-class="passwordType === 'password' ? 'eye' : 'eye-open'"
|
||||||
/>
|
/>
|
||||||
</span> -->
|
</span>
|
||||||
<el-input
|
<!-- <el-input
|
||||||
:key="passwordType"
|
:key="passwordType"
|
||||||
ref="password"
|
ref="password"
|
||||||
v-model="pwdCover"
|
v-model="pwdCover"
|
||||||
@@ -115,7 +115,7 @@
|
|||||||
/>
|
/>
|
||||||
<span class="show-pwd" @click="hidePassword">
|
<span class="show-pwd" @click="hidePassword">
|
||||||
<svg-icon :icon-class="!isShowPassword ? 'eye' : 'eye-open'" />
|
<svg-icon :icon-class="!isShowPassword ? 'eye' : 'eye-open'" />
|
||||||
</span>
|
</span> -->
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- Login -->
|
<!-- Login -->
|
||||||
<el-button
|
<el-button
|
||||||
@@ -205,17 +205,21 @@
|
|||||||
"
|
"
|
||||||
>
|
>
|
||||||
<h1
|
<h1
|
||||||
style="text-align: center; margin-bottom: 20px"
|
style="text-align: center; margin-bottom: 30px"
|
||||||
v-if="NODE_ENV === 'usa'"
|
v-if="NODE_ENV === 'usa'"
|
||||||
>
|
>
|
||||||
About
|
About
|
||||||
</h1>
|
</h1>
|
||||||
<h1 style="text-align: center; margin-bottom: 20px" v-else>关于</h1>
|
<h1 style="text-align: center; margin-bottom: 30px" v-else>关于</h1>
|
||||||
<p style="margin-bottom: 20px" v-if="NODE_ENV === 'usa'">
|
<p style="margin-bottom: 0px" v-if="NODE_ENV === 'usa'">
|
||||||
{{ $t('login:title:system_title_about') }}
|
<!-- {{ $t('login:title:system_title_about') }} -->
|
||||||
|
<svg-icon
|
||||||
|
icon-class="login-logo"
|
||||||
|
style="width: 250px; height: 71px"
|
||||||
|
/>
|
||||||
</p>
|
</p>
|
||||||
<p style="margin-bottom: 20px" v-else>{{ $t('login:title:system') }}</p>
|
<p style="margin-bottom: 0px" v-else>{{ $t('login:title:system') }}</p>
|
||||||
<p style="margin-bottom: 20px">
|
<p style="margin-bottom: 20px; margin-top: 0">
|
||||||
V{{ $version.IsEnv_US ? $version.Version_US : $version.Version }}
|
V{{ $version.IsEnv_US ? $version.Version_US : $version.Version }}
|
||||||
</p>
|
</p>
|
||||||
<p style="margin-bottom: 20px" v-if="language === 'zh'">
|
<p style="margin-bottom: 20px" v-if="language === 'zh'">
|
||||||
@@ -243,6 +247,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
<browserTip ref="browserTip" />
|
<browserTip ref="browserTip" />
|
||||||
|
<toggleRole
|
||||||
|
v-if="toggleRoleVisible"
|
||||||
|
:visible.sync="toggleRoleVisible"
|
||||||
|
:loading="toggleRoleLoading"
|
||||||
|
@save="loginByRole"
|
||||||
|
@cancel="cancel"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -253,9 +264,10 @@ import TopLang from './topLang'
|
|||||||
import Vcode from 'vue-puzzle-vcode'
|
import Vcode from 'vue-puzzle-vcode'
|
||||||
import browserTip from '@/views/dictionary/template/browser/tip.vue'
|
import browserTip from '@/views/dictionary/template/browser/tip.vue'
|
||||||
import Img1 from '@/assets/pic-2.png'
|
import Img1 from '@/assets/pic-2.png'
|
||||||
|
import toggleRole from '@/components/toggleRole'
|
||||||
export default {
|
export default {
|
||||||
name: 'Login',
|
name: 'Login',
|
||||||
components: { TopLang, Vcode, browserTip },
|
components: { TopLang, Vcode, browserTip, toggleRole },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
NODE_ENV: process.env.NODE_ENV, // process.env.NODE_ENV
|
NODE_ENV: process.env.NODE_ENV, // process.env.NODE_ENV
|
||||||
@@ -298,12 +310,15 @@ export default {
|
|||||||
isShow: false,
|
isShow: false,
|
||||||
showCode: false,
|
showCode: false,
|
||||||
Img1,
|
Img1,
|
||||||
|
toggleRoleVisible: false,
|
||||||
|
toggleRoleLoading: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters(['asyncRoutes', 'routes', 'language']),
|
...mapGetters(['asyncRoutes', 'routes', 'language']),
|
||||||
host() {
|
host() {
|
||||||
return window.location.host
|
// return window.location.host
|
||||||
|
return 'elevateimaging.ai '
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
@@ -318,6 +333,8 @@ export default {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
let lang = zzSessionStorage.getItem('lang') || 'zh'
|
||||||
|
// zzSessionStorage.clear()
|
||||||
this.loginType = this.$route.query.loginType
|
this.loginType = this.$route.query.loginType
|
||||||
this.location = this.$route.query.location
|
this.location = this.$route.query.location
|
||||||
zzSessionStorage.setItem('loginType', this.loginType)
|
zzSessionStorage.setItem('loginType', this.loginType)
|
||||||
@@ -332,9 +349,9 @@ export default {
|
|||||||
this.setLanguage('en')
|
this.setLanguage('en')
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
} else {
|
} else {
|
||||||
// this.$i18n.locale = 'zh'
|
this.$i18n.locale = lang
|
||||||
// this.setLanguage('zh')
|
this.setLanguage(lang)
|
||||||
// this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.$refs.browserTip.open()
|
this.$refs.browserTip.open()
|
||||||
@@ -376,6 +393,9 @@ export default {
|
|||||||
this.$store
|
this.$store
|
||||||
.dispatch('user/login', this.loginForm)
|
.dispatch('user/login', this.loginForm)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
|
if (res.BasicInfo.LoginState === 2) {
|
||||||
|
this.$message.warning(this.$t('login:message:login4'))
|
||||||
|
}
|
||||||
if (res.BasicInfo.IsFirstAdd) {
|
if (res.BasicInfo.IsFirstAdd) {
|
||||||
// 当前用户为首次登录,请先修改密码之后再次登录
|
// 当前用户为首次登录,请先修改密码之后再次登录
|
||||||
this.$message.success(this.$t('login:message:login1'))
|
this.$message.success(this.$t('login:message:login1'))
|
||||||
@@ -385,7 +405,7 @@ export default {
|
|||||||
})
|
})
|
||||||
}, 500)
|
}, 500)
|
||||||
return
|
return
|
||||||
} else if (res.BasicInfo.LoginState === 1) {
|
} else if (res.BasicInfo.NeedChangePassWord) {
|
||||||
// 请先修改密码后再登录!
|
// 请先修改密码后再登录!
|
||||||
this.$alert(
|
this.$alert(
|
||||||
this.$t('login:message:login3'),
|
this.$t('login:message:login3'),
|
||||||
@@ -401,52 +421,117 @@ export default {
|
|||||||
)
|
)
|
||||||
return
|
return
|
||||||
} else if (res.IsMFA) {
|
} else if (res.IsMFA) {
|
||||||
|
zzSessionStorage.removeItem('userId')
|
||||||
|
zzSessionStorage.removeItem('identityUserId')
|
||||||
this.$MFA({
|
this.$MFA({
|
||||||
UserId: res.BasicInfo.Id,
|
UserId: res.BasicInfo.IdentityUserId,
|
||||||
EMail: res.BasicInfo.EMail,
|
EMail: res.BasicInfo.EMail,
|
||||||
username: this.loginForm.username,
|
username: this.loginForm.username,
|
||||||
callBack: this.loginIn,
|
callBack: this.changeRoleLogin,
|
||||||
cancelBack: () => {
|
cancelBack: () => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
} else if (res.BasicInfo.LoginState === 2) {
|
|
||||||
// 本次登录的IP或设备与上次不一致,请确认'
|
|
||||||
// this.$alert(this.$t('login:message:login4'), this.$t('common:title:warning'))
|
|
||||||
this.$message.warning(this.$t('login:message:login4'))
|
|
||||||
}
|
}
|
||||||
this.$store.dispatch('permission/generateRoutes').then((res) => {
|
// else if (res.BasicInfo.LoginState === 2) {
|
||||||
this.loading = false
|
// // 本次登录的IP或设备与上次不一致,请确认'
|
||||||
if (res && res.length > 0) {
|
// // this.$alert(this.$t('login:message:login4'), this.$t('common:title:warning'))
|
||||||
this.$store.dispatch('global/getNoticeList')
|
// this.$message.warning(this.$t('login:message:login4'))
|
||||||
this.$router.addRoutes(res)
|
// }
|
||||||
if (this.loginType === 'DevOps') {
|
zzSessionStorage.removeItem('userId')
|
||||||
this.$router.replace({ path: res[0].path })
|
zzSessionStorage.removeItem('identityUserId')
|
||||||
return
|
this.changeRoleLogin()
|
||||||
}
|
|
||||||
if (this.hasPermi(['role:radmin'])) {
|
|
||||||
this.$router.replace({ path: res[0].path })
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (
|
|
||||||
this.hasPermi(['role:air', 'role:rpm', 'role:rcrc', 'role:rir'])
|
|
||||||
) {
|
|
||||||
this.$router.replace({ path: '/trials/trials-list' })
|
|
||||||
} else {
|
|
||||||
this.$router.replace({ path: '/trials' })
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// 此账户暂未配置菜单权限,请联系管理员处理后再登录。
|
|
||||||
this.$message.warning(this.$t('login:message:login2'))
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.showCode = true
|
this.showCode = true
|
||||||
this.loading = false
|
this.loading = false
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
loginByRole(userRoleId) {
|
||||||
|
this.toggleRoleLoading = true
|
||||||
|
this.$store
|
||||||
|
.dispatch('user/loginByRole', { userRoleId })
|
||||||
|
.then((res) => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
if (res) {
|
||||||
|
this.$store
|
||||||
|
.dispatch('permission/generateRoutes')
|
||||||
|
.then((res) => {
|
||||||
|
this.loading = false
|
||||||
|
if (res && res.length > 0) {
|
||||||
|
this.$store.dispatch('global/getNoticeList')
|
||||||
|
this.$router.addRoutes(res)
|
||||||
|
// if (this.LoginState === 2) {
|
||||||
|
// this.$message.warning(this.$t('login:message:login4'))
|
||||||
|
// }
|
||||||
|
if (this.loginType === 'DevOps') {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.hasPermi(['role:radmin'])) {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (
|
||||||
|
this.hasPermi([
|
||||||
|
'role:air',
|
||||||
|
'role:rpm',
|
||||||
|
'role:rcrc',
|
||||||
|
'role:rir',
|
||||||
|
])
|
||||||
|
) {
|
||||||
|
this.$router.replace({ path: '/trials/trials-list' })
|
||||||
|
} else {
|
||||||
|
this.$router.replace({ path: '/trials' })
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
// 此账户暂未配置菜单权限,请联系管理员处理后再登录。
|
||||||
|
this.$message.warning(this.$t('login:message:login2'))
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((err) => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.showCode = true
|
||||||
|
this.loading = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
changeRoleLogin() {
|
||||||
|
if (
|
||||||
|
Array.isArray(this.$store.state.user.roles) &&
|
||||||
|
this.$store.state.user.roles.length === 1
|
||||||
|
) {
|
||||||
|
this.loginByRole(this.$store.state.user.roles[0].Id)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (
|
||||||
|
Array.isArray(this.$store.state.user.roles) &&
|
||||||
|
this.$store.state.user.roles.filter((item) => item.IsUserRoleDisabled)
|
||||||
|
.length ===
|
||||||
|
this.$store.state.user.roles.length - 1
|
||||||
|
) {
|
||||||
|
let role = this.$store.state.user.roles.find(
|
||||||
|
(item) => !item.IsUserRoleDisabled
|
||||||
|
)
|
||||||
|
this.loginByRole(role.Id)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
return (this.toggleRoleVisible = true)
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
this.showCode = true
|
||||||
|
this.loading = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
// this.toggleRoleVisible = false
|
||||||
|
},
|
||||||
onSuccess() {
|
onSuccess() {
|
||||||
this.isShow = false
|
this.isShow = false
|
||||||
this.loginIn()
|
this.loginIn()
|
||||||
@@ -456,7 +541,6 @@ export default {
|
|||||||
},
|
},
|
||||||
// 输入框输入事件
|
// 输入框输入事件
|
||||||
setPassword(val) {
|
setPassword(val) {
|
||||||
console.log(val)
|
|
||||||
if (this.isShowPassword) {
|
if (this.isShowPassword) {
|
||||||
this.loginForm.password = val
|
this.loginForm.password = val
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -42,6 +42,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 新密码 -->
|
<!-- 新密码 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
|
class="my_new_pwd"
|
||||||
:label="$t('recompose:form:newPassword')"
|
:label="$t('recompose:form:newPassword')"
|
||||||
prop="NewPassWord"
|
prop="NewPassWord"
|
||||||
>
|
>
|
||||||
@@ -138,14 +139,16 @@ export default {
|
|||||||
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
||||||
async logout() {
|
async logout() {
|
||||||
var loginType = zzSessionStorage.getItem('loginType')
|
var loginType = zzSessionStorage.getItem('loginType')
|
||||||
await this.$store.dispatch('user/logout')
|
await this.$store.dispatch('user/resetData')
|
||||||
if (loginType) {
|
if (loginType) {
|
||||||
this.$router.push(`/login?loginType=${loginType}`)
|
this.$router.push(`/login?loginType=${loginType}`)
|
||||||
} else {
|
} else {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
}
|
}
|
||||||
this.$i18n.locale = 'zh'
|
if (!this.$i18n.locale) {
|
||||||
this.setLanguage('zh')
|
//this.$i18n.locale = 'zh'
|
||||||
|
//this.setLanguage('zh')
|
||||||
|
}
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
save() {
|
save() {
|
||||||
@@ -219,4 +222,7 @@ input {
|
|||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
caret-color: #fff;
|
caret-color: #fff;
|
||||||
}
|
}
|
||||||
|
::v-deep .is-error.my_new_pwd {
|
||||||
|
margin-bottom: 45px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -117,7 +117,7 @@
|
|||||||
:title="$t('trials:researchForm:dialogTitle:reject')"
|
:title="$t('trials:researchForm:dialogTitle:reject')"
|
||||||
width="600px"
|
width="600px"
|
||||||
custom-class="base-dialog-wrapper"
|
custom-class="base-dialog-wrapper"
|
||||||
:append-to-body="userTypeEnumInt !== 0"
|
append-to-body
|
||||||
>
|
>
|
||||||
<el-form ref="rejectForm" :model="rejectForm" label-width="100px">
|
<el-form ref="rejectForm" :model="rejectForm" label-width="100px">
|
||||||
<div class="base-dialog-body">
|
<div class="base-dialog-body">
|
||||||
|
|||||||
@@ -437,7 +437,7 @@ export default {
|
|||||||
},
|
},
|
||||||
handlePreview3(row) {
|
handlePreview3(row) {
|
||||||
return this.$preview({
|
return this.$preview({
|
||||||
path: row.FilePath,
|
path: row.Path || row.FilePath,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
title: row.FileName,
|
title: row.FileName,
|
||||||
})
|
})
|
||||||
@@ -447,7 +447,7 @@ export default {
|
|||||||
},
|
},
|
||||||
handlePreview2(row, r2) {
|
handlePreview2(row, r2) {
|
||||||
return this.$preview({
|
return this.$preview({
|
||||||
path: row.fullPath,
|
path: row.Path || row.fullPath,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
title: row.FileName,
|
title: row.FileName,
|
||||||
})
|
})
|
||||||
@@ -537,7 +537,7 @@ export default {
|
|||||||
handlePreview(row) {
|
handlePreview(row) {
|
||||||
console.log(row)
|
console.log(row)
|
||||||
return this.$preview({
|
return this.$preview({
|
||||||
path: row.FullPath,
|
path: row.Path || row.FullPath,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
title: row.FileName,
|
title: row.FileName,
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -569,22 +569,30 @@
|
|||||||
:label="$t('system:EducationTraining:table:Hospital')"
|
:label="$t('system:EducationTraining:table:Hospital')"
|
||||||
prop="Hospital"
|
prop="Hospital"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-row type="flex" justify="space-between">
|
||||||
v-model="postgraduateForm.HospitalId"
|
<el-col :span="11">
|
||||||
filterable
|
<el-autocomplete
|
||||||
placeholder=""
|
clearable
|
||||||
>
|
class="inline-input"
|
||||||
<el-option
|
style="width: 100%"
|
||||||
v-for="(item, index) in hospitalList"
|
v-model="postgraduateForm.Hospital"
|
||||||
:key="index"
|
:fetch-suggestions="querySearch"
|
||||||
:label="isEN ? item.HospitalName : item.HospitalNameCN"
|
@select="handleSelect"
|
||||||
:value="item.Id"
|
placeholder="Please specify in English"
|
||||||
>
|
></el-autocomplete>
|
||||||
<span>
|
</el-col>
|
||||||
{{ isEN ? item.HospitalName : item.HospitalNameCN }}
|
<el-col :span="11">
|
||||||
</span>
|
<el-autocomplete
|
||||||
</el-option>
|
clearable
|
||||||
</el-select>
|
class="inline-input"
|
||||||
|
style="width: 100%"
|
||||||
|
v-model="postgraduateForm.HospitalCN"
|
||||||
|
:fetch-suggestions="querySearchCN"
|
||||||
|
@select="handleSelect"
|
||||||
|
placeholder="请用中文注明"
|
||||||
|
></el-autocomplete>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('system:EducationTraining:table:University')"
|
:label="$t('system:EducationTraining:table:University')"
|
||||||
@@ -1043,6 +1051,8 @@ export default {
|
|||||||
},
|
},
|
||||||
isDisabled: false,
|
isDisabled: false,
|
||||||
loading: false,
|
loading: false,
|
||||||
|
hospitalSelectList: [],
|
||||||
|
hospitalSelectListCN: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -1051,11 +1061,71 @@ export default {
|
|||||||
return this.$i18n.locale !== 'zh'
|
return this.$i18n.locale !== 'zh'
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
hospitalList: {
|
||||||
|
handler() {
|
||||||
|
if (!Array.isArray(this.hospitalList) || this.hospitalList.length <= 0)
|
||||||
|
return false
|
||||||
|
this.hospitalSelectList = []
|
||||||
|
this.hospitalList.forEach((item) => {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalName,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
this.hospitalSelectListCN.push({
|
||||||
|
value: item.HospitalNameCN,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.initPage()
|
this.initPage()
|
||||||
store.dispatch('global/getHospital')
|
store.dispatch('global/getHospital')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleSelect(value) {
|
||||||
|
const item = value
|
||||||
|
if (item) {
|
||||||
|
this.postgraduateForm.Hospital = item.HospitalName
|
||||||
|
this.postgraduateForm.HospitalCN = item.HospitalNameCN
|
||||||
|
}
|
||||||
|
},
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectList
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
querySearchCN(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectListCN
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString, false))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
createFilter(queryString, isEN = true) {
|
||||||
|
return (hospitalList) => {
|
||||||
|
if (isEN) {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalName.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalNameCN.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
initPage() {
|
initPage() {
|
||||||
const id = this.$route.query.Id || this.reviewerId
|
const id = this.$route.query.Id || this.reviewerId
|
||||||
if (id) {
|
if (id) {
|
||||||
|
|||||||
@@ -14,27 +14,32 @@
|
|||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('system:reviewer:label:Hospital')"
|
:label="$t('system:reviewer:label:Hospital')"
|
||||||
prop="HospitalId"
|
prop="HospitalName"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-autocomplete
|
||||||
v-model="employmentForm.HospitalId"
|
clearable
|
||||||
placeholder="select"
|
class="inline-input"
|
||||||
:disabled="$route.query.ReviewStatus === '1'"
|
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
size="small"
|
v-model="employmentForm.HospitalName"
|
||||||
@change="handleHospitalChange"
|
:fetch-suggestions="querySearch"
|
||||||
>
|
@select="handleSelect"
|
||||||
<el-option
|
placeholder="Please specify in English"
|
||||||
v-for="(item, index) in hospitalList"
|
@change="handleChange"
|
||||||
:key="index"
|
></el-autocomplete>
|
||||||
:label="isEN ? item.HospitalName : item.HospitalNameCN"
|
</el-form-item>
|
||||||
:value="item.Id"
|
</el-col>
|
||||||
>
|
<el-col :span="14">
|
||||||
<span>
|
<el-form-item prop="HospitalNameCN">
|
||||||
{{ isEN ? item.HospitalName : item.HospitalNameCN }}
|
<el-autocomplete
|
||||||
</span>
|
clearable
|
||||||
</el-option>
|
class="inline-input"
|
||||||
</el-select>
|
style="width: 100%"
|
||||||
|
v-model="employmentForm.HospitalNameCN"
|
||||||
|
:fetch-suggestions="querySearchCN"
|
||||||
|
@select="handleSelect"
|
||||||
|
placeholder="请用中文注明"
|
||||||
|
@change="handleChange"
|
||||||
|
></el-autocomplete>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -43,12 +48,25 @@
|
|||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('system:reviewer:label:AffiliatedUniversity')"
|
:label="$t('system:reviewer:label:AffiliatedUniversity')"
|
||||||
|
prop="UniversityAffiliated"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
disabled
|
v-model="employmentForm.UniversityAffiliated"
|
||||||
v-model="UniversityAffiliated"
|
|
||||||
type="textarea"
|
type="textarea"
|
||||||
autosize
|
autosize
|
||||||
|
placeholder="Please specify in English"
|
||||||
|
size="small"
|
||||||
|
:maxlength="4000"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-form-item prop="UniversityAffiliated">
|
||||||
|
<el-input
|
||||||
|
v-model="employmentForm.UniversityAffiliatedCN"
|
||||||
|
type="textarea"
|
||||||
|
autosize
|
||||||
|
placeholder="请用中文注明"
|
||||||
size="small"
|
size="small"
|
||||||
:maxlength="4000"
|
:maxlength="4000"
|
||||||
/>
|
/>
|
||||||
@@ -59,15 +77,23 @@
|
|||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
<el-form-item :label="$t('system:reviewer:label:City')">
|
<el-form-item :label="$t('system:reviewer:label:City')">
|
||||||
<el-input
|
<el-input
|
||||||
disabled
|
v-model="employmentForm.City"
|
||||||
v-model="City"
|
|
||||||
size="small"
|
size="small"
|
||||||
:maxlength="400"
|
placeholder="Please specify in English"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="14">
|
||||||
|
<el-form-item>
|
||||||
|
<el-input
|
||||||
|
v-model="employmentForm.CityCN"
|
||||||
|
size="small"
|
||||||
|
placeholder="请用中文注明"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<!-- <el-row>
|
||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
<el-form-item :label="$t('system:reviewer:label:State/Province')">
|
<el-form-item :label="$t('system:reviewer:label:State/Province')">
|
||||||
<el-input
|
<el-input
|
||||||
@@ -90,7 +116,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row> -->
|
||||||
|
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
@@ -321,14 +347,34 @@ export default {
|
|||||||
Physician: '',
|
Physician: '',
|
||||||
PhysicianCN: '',
|
PhysicianCN: '',
|
||||||
PhysicianOriginal: null,
|
PhysicianOriginal: null,
|
||||||
|
HospitalName: '',
|
||||||
|
HospitalNameCN: '',
|
||||||
WorkPartTime: null,
|
WorkPartTime: null,
|
||||||
WorkPartTimeEn: null,
|
WorkPartTimeEn: null,
|
||||||
|
UniversityAffiliated: null,
|
||||||
|
UniversityAffiliatedCN: null,
|
||||||
|
City: null,
|
||||||
|
CityCN: null,
|
||||||
},
|
},
|
||||||
UniversityAffiliated: '',
|
UniversityAffiliated: '',
|
||||||
City: '',
|
City: '',
|
||||||
Province: '',
|
Province: '',
|
||||||
Country: '',
|
Country: '',
|
||||||
employmentRules: {
|
employmentRules: {
|
||||||
|
HospitalName: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:specify'),
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
HospitalNameCN: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:specify'),
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
|
],
|
||||||
DepartmentId: [
|
DepartmentId: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
@@ -435,6 +481,8 @@ export default {
|
|||||||
otherId: 'ef84e9cb-f1a6-49d7-b6da-34be2c12abd5',
|
otherId: 'ef84e9cb-f1a6-49d7-b6da-34be2c12abd5',
|
||||||
loading: false,
|
loading: false,
|
||||||
dictionaryList: {},
|
dictionaryList: {},
|
||||||
|
hospitalSelectList: [],
|
||||||
|
hospitalSelectListCN: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -446,7 +494,83 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
this.initEmployment()
|
this.initEmployment()
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
hospitalList: {
|
||||||
|
handler() {
|
||||||
|
if (!Array.isArray(this.hospitalList) || this.hospitalList.length <= 0)
|
||||||
|
return false
|
||||||
|
this.hospitalSelectList = []
|
||||||
|
this.hospitalList.forEach((item) => {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalName,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
this.hospitalSelectListCN.push({
|
||||||
|
value: item.HospitalNameCN,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleSelect(value) {
|
||||||
|
const item = value
|
||||||
|
if (item) {
|
||||||
|
this.employmentForm.HospitalName = item.HospitalName
|
||||||
|
this.employmentForm.HospitalNameCN = item.HospitalNameCN
|
||||||
|
this.employmentForm.UniversityAffiliated = item.UniversityAffiliated
|
||||||
|
this.employmentForm.City = item.City
|
||||||
|
this.employmentForm.UniversityAffiliatedCN = item.UniversityAffiliatedCN
|
||||||
|
this.employmentForm.CityCN = item.CityCN
|
||||||
|
} else {
|
||||||
|
this.employmentForm.UniversityAffiliated = null
|
||||||
|
this.employmentForm.City = null
|
||||||
|
this.employmentForm.UniversityAffiliatedCN = null
|
||||||
|
this.employmentForm.CityCN = null
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handleChange(v) {
|
||||||
|
if (v) return
|
||||||
|
this.employmentForm.UniversityAffiliated = null
|
||||||
|
this.employmentForm.City = null
|
||||||
|
this.employmentForm.UniversityAffiliatedCN = null
|
||||||
|
this.employmentForm.CityCN = null
|
||||||
|
},
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectList
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
querySearchCN(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectListCN
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString, false))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
createFilter(queryString, isEN = true) {
|
||||||
|
return (hospitalList) => {
|
||||||
|
if (isEN) {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalName.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalNameCN.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
RankChange(val) {
|
RankChange(val) {
|
||||||
var o = this.$d.Rank.find((v) => {
|
var o = this.$d.Rank.find((v) => {
|
||||||
return v.id === val
|
return v.id === val
|
||||||
@@ -515,6 +639,14 @@ export default {
|
|||||||
: ''
|
: ''
|
||||||
param.HospitalId = this.employmentForm.HospitalId
|
param.HospitalId = this.employmentForm.HospitalId
|
||||||
|
|
||||||
|
param.HospitalName = this.employmentForm.HospitalName
|
||||||
|
param.HospitalNameCN = this.employmentForm.HospitalNameCN
|
||||||
|
param.UniversityAffiliated = this.employmentForm.UniversityAffiliated
|
||||||
|
param.UniversityAffiliatedCN =
|
||||||
|
this.employmentForm.UniversityAffiliatedCN
|
||||||
|
param.City = this.employmentForm.City
|
||||||
|
param.CityCN = this.employmentForm.CityCN
|
||||||
|
|
||||||
updateEmploymentInfo(param)
|
updateEmploymentInfo(param)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.isDisabled = false
|
this.isDisabled = false
|
||||||
@@ -551,9 +683,22 @@ export default {
|
|||||||
PositionOther,
|
PositionOther,
|
||||||
PositionOtherCN,
|
PositionOtherCN,
|
||||||
HospitalId,
|
HospitalId,
|
||||||
|
HospitalName,
|
||||||
|
HospitalNameCN,
|
||||||
WorkPartTime,
|
WorkPartTime,
|
||||||
WorkPartTimeEn,
|
WorkPartTimeEn,
|
||||||
|
UniversityAffiliated,
|
||||||
|
UniversityAffiliatedCN,
|
||||||
|
City,
|
||||||
|
CityCN,
|
||||||
} = res.Result
|
} = res.Result
|
||||||
|
this.employmentForm.HospitalName = HospitalName
|
||||||
|
this.employmentForm.HospitalNameCN = HospitalNameCN
|
||||||
|
this.employmentForm.UniversityAffiliated = UniversityAffiliated
|
||||||
|
this.employmentForm.UniversityAffiliatedCN = UniversityAffiliatedCN
|
||||||
|
this.employmentForm.City = City
|
||||||
|
this.employmentForm.CityCN = CityCN
|
||||||
|
|
||||||
this.employmentForm.WorkPartTime = WorkPartTime
|
this.employmentForm.WorkPartTime = WorkPartTime
|
||||||
this.employmentForm.WorkPartTimeEn = WorkPartTimeEn
|
this.employmentForm.WorkPartTimeEn = WorkPartTimeEn
|
||||||
this.employmentForm.Id = id
|
this.employmentForm.Id = id
|
||||||
|
|||||||
@@ -333,7 +333,7 @@ export default {
|
|||||||
},
|
},
|
||||||
preview(row) {
|
preview(row) {
|
||||||
this.$preview({
|
this.$preview({
|
||||||
path: row.FullPath,
|
path: row.Path || row.FullPath,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
title: row.FileName,
|
title: row.FileName,
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -292,7 +292,7 @@ export default {
|
|||||||
},
|
},
|
||||||
preview(row) {
|
preview(row) {
|
||||||
this.$preview({
|
this.$preview({
|
||||||
path: row.FullPath,
|
path: row.Path || row.FullPath,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
title: row.FileName,
|
title: row.FileName,
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -150,20 +150,31 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('curriculumVitae:continuingTraining:form:hospital')"
|
:label="$t('curriculumVitae:continuingTraining:form:hospital')"
|
||||||
prop="HospitalId"
|
prop="Hospital"
|
||||||
|
v-if="isEN"
|
||||||
>
|
>
|
||||||
<el-select v-model="form.HospitalId" filterable placeholder="">
|
<el-autocomplete
|
||||||
<el-option
|
clearable
|
||||||
v-for="(item, index) in hospitalList"
|
class="inline-input"
|
||||||
:key="index"
|
style="width: 100%"
|
||||||
:label="isEN ? item.HospitalName : item.HospitalNameCN"
|
v-model="form.Hospital"
|
||||||
:value="item.Id"
|
:fetch-suggestions="querySearch"
|
||||||
>
|
placeholder=""
|
||||||
<span>
|
></el-autocomplete>
|
||||||
{{ isEN ? item.HospitalName : item.HospitalNameCN }}
|
</el-form-item>
|
||||||
</span>
|
<el-form-item
|
||||||
</el-option>
|
:label="$t('curriculumVitae:continuingTraining:form:hospital')"
|
||||||
</el-select>
|
prop="Hospital"
|
||||||
|
v-else
|
||||||
|
>
|
||||||
|
<el-autocomplete
|
||||||
|
clearable
|
||||||
|
class="inline-input"
|
||||||
|
style="width: 100%"
|
||||||
|
v-model="form.HospitalCN"
|
||||||
|
:fetch-suggestions="querySearch"
|
||||||
|
placeholder=""
|
||||||
|
></el-autocomplete>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('curriculumVitae:continuingTraining:form:school')"
|
:label="$t('curriculumVitae:continuingTraining:form:school')"
|
||||||
@@ -283,6 +294,8 @@ const defaultForm = () => {
|
|||||||
Major: '',
|
Major: '',
|
||||||
MajorCN: '',
|
MajorCN: '',
|
||||||
HospitalId: null,
|
HospitalId: null,
|
||||||
|
HospitalCN: null,
|
||||||
|
Hospital: null,
|
||||||
School: '',
|
School: '',
|
||||||
SchoolCN: '',
|
SchoolCN: '',
|
||||||
City: '',
|
City: '',
|
||||||
@@ -418,6 +431,7 @@ export default {
|
|||||||
},
|
},
|
||||||
loading: false,
|
loading: false,
|
||||||
daterange: [],
|
daterange: [],
|
||||||
|
hospitalSelectList: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -426,7 +440,55 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
store.dispatch('global/getHospital')
|
store.dispatch('global/getHospital')
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
hospitalList: {
|
||||||
|
handler() {
|
||||||
|
if (!Array.isArray(this.hospitalList) || this.hospitalList.length <= 0)
|
||||||
|
return false
|
||||||
|
this.hospitalSelectList = []
|
||||||
|
this.hospitalList.forEach((item) => {
|
||||||
|
if (this.isEN) {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalName,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalNameCN,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectList
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
createFilter(queryString) {
|
||||||
|
return (hospitalList) => {
|
||||||
|
if (this.isEN) {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalName.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalNameCN.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
openEdit(row) {
|
openEdit(row) {
|
||||||
this.form = defaultForm()
|
this.form = defaultForm()
|
||||||
this.daterange = []
|
this.daterange = []
|
||||||
@@ -458,6 +520,11 @@ export default {
|
|||||||
if (this.reviewerId) {
|
if (this.reviewerId) {
|
||||||
this.form.DoctorId = this.reviewerId
|
this.form.DoctorId = this.reviewerId
|
||||||
}
|
}
|
||||||
|
let data = Object.assign({}, this.form)
|
||||||
|
if (!this.hospitalList.find((item) => item.Id === data.HospitalId)) {
|
||||||
|
data.Hospital = data.HospitalId
|
||||||
|
data.HospitalId = null
|
||||||
|
}
|
||||||
this.loading = true
|
this.loading = true
|
||||||
let res = await addOrUpdatePostgraduateInfo(this.form)
|
let res = await addOrUpdatePostgraduateInfo(this.form)
|
||||||
this.loading = false
|
this.loading = false
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
<template v-if="DATA.FirstName && DATA.LastName">
|
<template v-if="DATA.FirstName && DATA.LastName">
|
||||||
<div class="userInfo">
|
<div class="userInfo">
|
||||||
<span>{{
|
<span>{{
|
||||||
isEN ? DATA.FirstName + DATA.LastName : DATA.ChineseName
|
isEN ? DATA.LastName + ' / ' + DATA.FirstName : DATA.ChineseName
|
||||||
}}</span>
|
}}</span>
|
||||||
<span>{{ $fd('Sex', DATA.Sex) }}</span>
|
<span>{{ $fd('Sex', DATA.Sex) }}</span>
|
||||||
<span v-if="isEN">
|
<span v-if="isEN">
|
||||||
@@ -171,7 +171,11 @@
|
|||||||
:label="$t('curriculumVitae:info:form:email')"
|
:label="$t('curriculumVitae:info:form:email')"
|
||||||
prop="EMail"
|
prop="EMail"
|
||||||
>
|
>
|
||||||
<el-input v-model="form.EMail" clearable disabled></el-input>
|
<el-input
|
||||||
|
v-model="form.EMail"
|
||||||
|
clearable
|
||||||
|
:disabled="DATA.IsHaveAccount"
|
||||||
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
@@ -209,25 +213,35 @@
|
|||||||
</div>
|
</div>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('curriculumVitae:info:form:hospital')"
|
:label="$t('curriculumVitae:info:form:hospital')"
|
||||||
prop="HospitalId"
|
prop="HospitalName"
|
||||||
|
v-if="isEN"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-autocomplete
|
||||||
v-model="form.HospitalId"
|
clearable
|
||||||
filterable
|
class="inline-input"
|
||||||
|
style="width: 100%"
|
||||||
|
v-model="form.HospitalName"
|
||||||
|
:fetch-suggestions="querySearch"
|
||||||
|
@select="handleSelect"
|
||||||
placeholder=""
|
placeholder=""
|
||||||
@change="handleHospitalChange"
|
@change="handleChange"
|
||||||
>
|
></el-autocomplete>
|
||||||
<el-option
|
</el-form-item>
|
||||||
v-for="(item, index) in hospitalList"
|
<el-form-item
|
||||||
:key="index"
|
:label="$t('curriculumVitae:info:form:hospital')"
|
||||||
:label="isEN ? item.HospitalName : item.HospitalNameCN"
|
prop="HospitalNameCN"
|
||||||
:value="item.Id"
|
v-else
|
||||||
>
|
>
|
||||||
<span>
|
<el-autocomplete
|
||||||
{{ isEN ? item.HospitalName : item.HospitalNameCN }}
|
clearable
|
||||||
</span>
|
class="inline-input"
|
||||||
</el-option>
|
style="width: 100%"
|
||||||
</el-select>
|
v-model="form.HospitalNameCN"
|
||||||
|
:fetch-suggestions="querySearch"
|
||||||
|
@select="handleSelect"
|
||||||
|
placeholder=""
|
||||||
|
@change="handleChange"
|
||||||
|
></el-autocomplete>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('curriculumVitae:info:form:AffiliatedUniversity')"
|
:label="$t('curriculumVitae:info:form:AffiliatedUniversity')"
|
||||||
@@ -235,7 +249,6 @@
|
|||||||
v-if="isEN"
|
v-if="isEN"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
disabled
|
|
||||||
v-model="form.UniversityAffiliated"
|
v-model="form.UniversityAffiliated"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
autosize
|
autosize
|
||||||
@@ -249,7 +262,6 @@
|
|||||||
v-else
|
v-else
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
disabled
|
|
||||||
v-model="form.UniversityAffiliatedCN"
|
v-model="form.UniversityAffiliatedCN"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
autosize
|
autosize
|
||||||
@@ -261,10 +273,10 @@
|
|||||||
:label="$t('curriculumVitae:info:form:City')"
|
:label="$t('curriculumVitae:info:form:City')"
|
||||||
v-if="isEN"
|
v-if="isEN"
|
||||||
>
|
>
|
||||||
<el-input disabled v-model="form.City" size="small" />
|
<el-input v-model="form.City" size="small" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('curriculumVitae:info:form:City')" v-else>
|
<el-form-item :label="$t('curriculumVitae:info:form:City')" v-else>
|
||||||
<el-input disabled v-model="form.CityCN" size="small" />
|
<el-input v-model="form.CityCN" size="small" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('curriculumVitae:info:form:department')"
|
:label="$t('curriculumVitae:info:form:department')"
|
||||||
@@ -433,6 +445,8 @@ const defaultForm = () => {
|
|||||||
RankOther: '',
|
RankOther: '',
|
||||||
RankOtherCN: '',
|
RankOtherCN: '',
|
||||||
HospitalId: '',
|
HospitalId: '',
|
||||||
|
HospitalName: null,
|
||||||
|
HospitalNameCN: null,
|
||||||
WorkPartTime: null,
|
WorkPartTime: null,
|
||||||
WorkPartTimeEn: null,
|
WorkPartTimeEn: null,
|
||||||
UniversityAffiliated: null,
|
UniversityAffiliated: null,
|
||||||
@@ -616,11 +630,18 @@ export default {
|
|||||||
trigger: 'blur',
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
HospitalId: [
|
HospitalName: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
message: this.$t('common:ruleMessage:select'),
|
message: this.$t('common:ruleMessage:specify'),
|
||||||
trigger: 'blur',
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
HospitalNameCN: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('common:ruleMessage:specify'),
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
UniversityAffiliated: [
|
UniversityAffiliated: [
|
||||||
@@ -648,16 +669,72 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
dictionaryList: {},
|
dictionaryList: {},
|
||||||
otherId: 'ef84e9cb-f1a6-49d7-b6da-34be2c12abd5',
|
otherId: 'ef84e9cb-f1a6-49d7-b6da-34be2c12abd5',
|
||||||
|
hospitalSelectList: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters(['hospitalList']),
|
...mapGetters(['hospitalList']),
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
hospitalList: {
|
||||||
|
handler() {
|
||||||
|
if (!Array.isArray(this.hospitalList) || this.hospitalList.length <= 0)
|
||||||
|
return false
|
||||||
|
this.hospitalSelectList = []
|
||||||
|
this.hospitalList.forEach((item) => {
|
||||||
|
if (this.isEN) {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalName,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.hospitalSelectList.push({
|
||||||
|
value: item.HospitalNameCN,
|
||||||
|
...item,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getDicData()
|
this.getDicData()
|
||||||
store.dispatch('global/getHospital')
|
store.dispatch('global/getHospital')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleChange(v) {
|
||||||
|
if (v) return
|
||||||
|
this.form.UniversityAffiliated = null
|
||||||
|
this.form.City = null
|
||||||
|
this.form.UniversityAffiliatedCN = null
|
||||||
|
this.form.CityCN = null
|
||||||
|
},
|
||||||
|
querySearch(queryString, cb) {
|
||||||
|
var hospitalList = this.hospitalSelectList
|
||||||
|
var results = queryString
|
||||||
|
? hospitalList.filter(this.createFilter(queryString))
|
||||||
|
: hospitalList
|
||||||
|
// 调用 callback 返回建议列表的数据
|
||||||
|
cb(results)
|
||||||
|
},
|
||||||
|
createFilter(queryString) {
|
||||||
|
return (hospitalList) => {
|
||||||
|
if (this.isEN) {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalName.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
hospitalList.HospitalNameCN.toLowerCase().indexOf(
|
||||||
|
queryString.toLowerCase()
|
||||||
|
) >= 0
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
openEdit() {
|
openEdit() {
|
||||||
this.form = defaultForm()
|
this.form = defaultForm()
|
||||||
Object.keys(this.form).forEach((key) => {
|
Object.keys(this.form).forEach((key) => {
|
||||||
@@ -666,8 +743,6 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.model_cfg.visible = true
|
this.model_cfg.visible = true
|
||||||
console.log(this.form)
|
|
||||||
console.log(this.DATA)
|
|
||||||
},
|
},
|
||||||
handleCancle() {
|
handleCancle() {
|
||||||
this.form = defaultForm()
|
this.form = defaultForm()
|
||||||
@@ -680,8 +755,14 @@ export default {
|
|||||||
if (this.reviewerId) {
|
if (this.reviewerId) {
|
||||||
this.form.Id = this.reviewerId
|
this.form.Id = this.reviewerId
|
||||||
}
|
}
|
||||||
|
// console.log(this.form)
|
||||||
|
let data = Object.assign({}, this.form)
|
||||||
|
// if (!this.hospitalList.find((item) => item.Id === data.HospitalId)) {
|
||||||
|
// data.HospitalName = data.HospitalId
|
||||||
|
// data.HospitalId = null
|
||||||
|
// }
|
||||||
this.loading = true
|
this.loading = true
|
||||||
let res = await addOrUpdateDoctorBasicInfoAndEmployment(this.form)
|
let res = await addOrUpdateDoctorBasicInfoAndEmployment(data)
|
||||||
this.loading = false
|
this.loading = false
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
this.$emit('update:reviewerId', res.Result.Id)
|
this.$emit('update:reviewerId', res.Result.Id)
|
||||||
@@ -701,13 +782,18 @@ export default {
|
|||||||
})
|
})
|
||||||
.catch(() => {})
|
.catch(() => {})
|
||||||
},
|
},
|
||||||
handleHospitalChange(value) {
|
handleSelect(value) {
|
||||||
const item = this.hospitalList.filter((item) => item.Id === value)
|
const item = value
|
||||||
if (item.length) {
|
if (item) {
|
||||||
this.form.UniversityAffiliated = item[0].UniversityAffiliated
|
this.form.UniversityAffiliated = item.UniversityAffiliated
|
||||||
this.form.City = item[0].City
|
this.form.City = item.City
|
||||||
this.form.UniversityAffiliatedCN = item[0].UniversityAffiliatedCN
|
this.form.UniversityAffiliatedCN = item.UniversityAffiliatedCN
|
||||||
this.form.CityCN = item[0].CityCN
|
this.form.CityCN = item.CityCN
|
||||||
|
} else {
|
||||||
|
this.form.UniversityAffiliated = null
|
||||||
|
this.form.City = null
|
||||||
|
this.form.UniversityAffiliatedCN = null
|
||||||
|
this.form.CityCN = null
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -7,8 +7,9 @@
|
|||||||
<span v-if="isAll">
|
<span v-if="isAll">
|
||||||
{{
|
{{
|
||||||
isEN
|
isEN
|
||||||
? reviewerData.BasicInfoView.FirstName +
|
? reviewerData.BasicInfoView.LastName +
|
||||||
reviewerData.BasicInfoView.LastName
|
' / ' +
|
||||||
|
reviewerData.BasicInfoView.FirstName
|
||||||
: reviewerData.BasicInfoView.ChineseName
|
: reviewerData.BasicInfoView.ChineseName
|
||||||
}}
|
}}
|
||||||
</span>
|
</span>
|
||||||
@@ -1014,7 +1015,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
preview(row) {
|
preview(row) {
|
||||||
let path = row.FullPath || row.FilePath
|
let path = row.Path || row.FullPath || row.FilePath
|
||||||
this.$preview({
|
this.$preview({
|
||||||
path: path,
|
path: path,
|
||||||
type: 'pdf',
|
type: 'pdf',
|
||||||
|
|||||||
@@ -8,7 +8,10 @@
|
|||||||
size="small"
|
size="small"
|
||||||
:rules="rules"
|
:rules="rules"
|
||||||
>
|
>
|
||||||
<el-form-item label="国际化类型" prop="InternationalizationType">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:InternationalizationType')"
|
||||||
|
prop="InternationalizationType"
|
||||||
|
>
|
||||||
<el-radio-group v-model="form.InternationalizationType">
|
<el-radio-group v-model="form.InternationalizationType">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.InternationalizationType"
|
v-for="item of $d.InternationalizationType"
|
||||||
@@ -18,7 +21,7 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="状态" prop="State">
|
<el-form-item :label="$t('system:l18n:search:State')" prop="State">
|
||||||
<el-radio-group v-model="form.State">
|
<el-radio-group v-model="form.State">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.InternationalizationKeyState"
|
v-for="item of $d.InternationalizationKeyState"
|
||||||
@@ -28,7 +31,10 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="迭代" prop="PublishLogId">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:PublishVersion')"
|
||||||
|
prop="PublishLogId"
|
||||||
|
>
|
||||||
<el-select v-model="form.PublishLogId" clearable filterable>
|
<el-select v-model="form.PublishLogId" clearable filterable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in PublishVersionList"
|
v-for="item in PublishVersionList"
|
||||||
@@ -39,7 +45,7 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-table :data="form.AddList" style="width: 100%" height="300">
|
<el-table :data="form.AddList" style="width: 100%" height="300">
|
||||||
<el-table-column prop="" label="功能模块/服务名">
|
<el-table-column prop="" :label="$t('system:l18n:search:Module')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label=""
|
label=""
|
||||||
@@ -61,7 +67,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="" label="标识">
|
<el-table-column prop="" :label="$t('system:l18n:search:Code')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label=""
|
label=""
|
||||||
@@ -87,7 +93,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="" label="中文值">
|
<el-table-column prop="" :label="$t('system:l18n:search:ValueCN')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label=""
|
label=""
|
||||||
@@ -113,7 +119,7 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="" label="英文值">
|
<el-table-column prop="" :label="$t('system:l18n:search:Value')">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label=""
|
label=""
|
||||||
@@ -139,7 +145,10 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="" label="说明">
|
<el-table-column
|
||||||
|
prop=""
|
||||||
|
:label="$t('system:l18n:search:Description')"
|
||||||
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label=""
|
label=""
|
||||||
@@ -169,7 +178,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>{{ $t("common:button:new") }}</el-button
|
>{{ $t('common:button:new') }}</el-button
|
||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -179,7 +188,7 @@
|
|||||||
type="text"
|
type="text"
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
@click="handleDelete(scope.$index)"
|
@click="handleDelete(scope.$index)"
|
||||||
>{{ $t("common:button:delete") }}</el-button
|
>{{ $t('common:button:delete') }}</el-button
|
||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -187,28 +196,28 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<template slot="dialog-footer">
|
<template slot="dialog-footer">
|
||||||
<el-button size="small" type="primary" @click="handleCancle"
|
<el-button size="small" type="primary" @click="handleCancle">{{
|
||||||
>取消</el-button
|
$t('common:button:cancel')
|
||||||
>
|
}}</el-button>
|
||||||
<el-button size="small" type="primary" @click="handleSave"
|
<el-button size="small" type="primary" @click="handleSave">{{
|
||||||
>保存</el-button
|
$t('common:button:save')
|
||||||
>
|
}}</el-button>
|
||||||
</template>
|
</template>
|
||||||
</base-model>
|
</base-model>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { batchAddInternationalization } from "@/api/admin";
|
import { batchAddInternationalization } from '@/api/admin'
|
||||||
import BaseModel from "@/components/BaseModel";
|
import BaseModel from '@/components/BaseModel'
|
||||||
const formDataDefault = () => {
|
const formDataDefault = () => {
|
||||||
return {
|
return {
|
||||||
State: 0,
|
State: 0,
|
||||||
InternationalizationType: 1,
|
InternationalizationType: 1,
|
||||||
PublishLogId: null,
|
PublishLogId: null,
|
||||||
AddList: [],
|
AddList: [],
|
||||||
};
|
}
|
||||||
};
|
}
|
||||||
export default {
|
export default {
|
||||||
name: "BatcnAddForm",
|
name: 'BatcnAddForm',
|
||||||
components: { BaseModel },
|
components: { BaseModel },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -217,59 +226,65 @@ export default {
|
|||||||
model_cfg: {
|
model_cfg: {
|
||||||
visible: false,
|
visible: false,
|
||||||
showClose: true,
|
showClose: true,
|
||||||
width: "800px",
|
width: '800px',
|
||||||
title: "",
|
title: '',
|
||||||
appendToBody: true,
|
appendToBody: true,
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
PublishLogId: [{ required: true, message: "请选择", trigger: "blur" }],
|
PublishLogId: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:selectPublishLogId'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
PublishVersionList: [],
|
PublishVersionList: [],
|
||||||
};
|
}
|
||||||
},
|
},
|
||||||
mounted() {},
|
mounted() {},
|
||||||
methods: {
|
methods: {
|
||||||
openDialog(title, data, options = []) {
|
openDialog(title, data, options = []) {
|
||||||
this.PublishVersionList = options;
|
this.PublishVersionList = options
|
||||||
this.model_cfg.visible = true;
|
this.model_cfg.visible = true
|
||||||
this.model_cfg.title = title;
|
this.model_cfg.title = title
|
||||||
this.form = formDataDefault();
|
this.form = formDataDefault()
|
||||||
},
|
},
|
||||||
handleSave() {
|
handleSave() {
|
||||||
this.$refs.batcnAddForm.validate((valid) => {
|
this.$refs.batcnAddForm.validate((valid) => {
|
||||||
if (!valid) return;
|
if (!valid) return
|
||||||
this.loading = true;
|
this.loading = true
|
||||||
batchAddInternationalization(this.form)
|
batchAddInternationalization(this.form)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
this.$message.success(this.$t("common:message:savedSuccessfully"));
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
this.model_cfg.visible = false;
|
this.model_cfg.visible = false
|
||||||
this.$emit("getList");
|
this.$emit('getList')
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
});
|
})
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
handleCancle() {
|
handleCancle() {
|
||||||
this.model_cfg.visible = false;
|
this.model_cfg.visible = false
|
||||||
},
|
},
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.form.AddList.push({
|
this.form.AddList.push({
|
||||||
Description: "",
|
Description: '',
|
||||||
Code: "",
|
Code: '',
|
||||||
ValueCN: "",
|
ValueCN: '',
|
||||||
Value: "",
|
Value: '',
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
handleDelete(index) {
|
handleDelete(index) {
|
||||||
this.$confirm("是否确认删除?", {
|
this.$confirm(this.$t('system:l18n:confirm:delete'), {
|
||||||
type: "warning",
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true,
|
distinguishCancelAndClose: true,
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
this.form.AddList.splice(index, 1);
|
this.form.AddList.splice(index, 1)
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="国际化类型"
|
:label="$t('system:l18n:search:InternationalizationType')"
|
||||||
prop="InternationalizationType"
|
prop="InternationalizationType"
|
||||||
v-if="status !== 'batch'"
|
v-if="status !== 'batch'"
|
||||||
>
|
>
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="功能模块/服务名"
|
:label="$t('system:l18n:search:Module')"
|
||||||
prop="Module"
|
prop="Module"
|
||||||
v-if="status !== 'batch'"
|
v-if="status !== 'batch'"
|
||||||
>
|
>
|
||||||
@@ -35,7 +35,11 @@
|
|||||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="标识" prop="Code" v-if="status !== 'batch'">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:Code')"
|
||||||
|
prop="Code"
|
||||||
|
v-if="status !== 'batch'"
|
||||||
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.Code"
|
v-model="form.Code"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
@@ -43,7 +47,11 @@
|
|||||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="中文值" prop="ValueCN" v-if="status !== 'batch'">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:ValueCN')"
|
||||||
|
prop="ValueCN"
|
||||||
|
v-if="status !== 'batch'"
|
||||||
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.ValueCN"
|
v-model="form.ValueCN"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
@@ -51,7 +59,11 @@
|
|||||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="英文值" prop="Value" v-if="status !== 'batch'">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:Value')"
|
||||||
|
prop="Value"
|
||||||
|
v-if="status !== 'batch'"
|
||||||
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.Value"
|
v-model="form.Value"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
@@ -59,7 +71,7 @@
|
|||||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="状态" prop="State">
|
<el-form-item :label="$t('system:l18n:search:State')" prop="State">
|
||||||
<el-radio-group v-model="form.State">
|
<el-radio-group v-model="form.State">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="item of $d.InternationalizationKeyState"
|
v-for="item of $d.InternationalizationKeyState"
|
||||||
@@ -69,7 +81,11 @@
|
|||||||
>
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="说明" prop="Description" v-if="status !== 'batch'">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:Description')"
|
||||||
|
prop="Description"
|
||||||
|
v-if="status !== 'batch'"
|
||||||
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.Description"
|
v-model="form.Description"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
@@ -77,7 +93,10 @@
|
|||||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="迭代" prop="PublishLogId">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:PublishVersion')"
|
||||||
|
prop="PublishLogId"
|
||||||
|
>
|
||||||
<el-select v-model="form.PublishLogId" clearable filterable>
|
<el-select v-model="form.PublishLogId" clearable filterable>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in PublishVersionList"
|
v-for="item in PublishVersionList"
|
||||||
@@ -90,18 +109,18 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<template slot="dialog-footer">
|
<template slot="dialog-footer">
|
||||||
<el-button size="small" type="primary" @click="handleCancle"
|
<el-button size="small" type="primary" @click="handleCancle">{{
|
||||||
>取消</el-button
|
$t('common:button:cancel')
|
||||||
>
|
}}</el-button>
|
||||||
<el-button size="small" type="primary" @click="handleSave"
|
<el-button size="small" type="primary" @click="handleSave">{{
|
||||||
>保存</el-button
|
$t('common:button:save')
|
||||||
>
|
}}</el-button>
|
||||||
</template>
|
</template>
|
||||||
</base-model>
|
</base-model>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { addOrUpdateInternationalization } from "@/api/admin";
|
import { addOrUpdateInternationalization } from '@/api/admin'
|
||||||
import BaseModel from "@/components/BaseModel";
|
import BaseModel from '@/components/BaseModel'
|
||||||
const formDataDefault = () => {
|
const formDataDefault = () => {
|
||||||
return {
|
return {
|
||||||
Id: null,
|
Id: null,
|
||||||
@@ -113,109 +132,138 @@ const formDataDefault = () => {
|
|||||||
ValueCN: null,
|
ValueCN: null,
|
||||||
InternationalizationType: 1,
|
InternationalizationType: 1,
|
||||||
PublishLogId: null,
|
PublishLogId: null,
|
||||||
};
|
}
|
||||||
};
|
}
|
||||||
export default {
|
export default {
|
||||||
name: "I18nForm",
|
name: 'I18nForm',
|
||||||
components: { BaseModel },
|
components: { BaseModel },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
status: "add", // add update batch
|
status: 'add', // add update batch
|
||||||
loading: false,
|
loading: false,
|
||||||
form: formDataDefault(),
|
form: formDataDefault(),
|
||||||
rules: {
|
rules: {
|
||||||
State: [{ required: true, message: "请选择", trigger: "blur" }],
|
State: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:selectState'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
|
],
|
||||||
Module: [
|
Module: [
|
||||||
{
|
{
|
||||||
max: 200,
|
max: 200,
|
||||||
message: `${this.$t("common:ruleMessage:maxLength")} 200`,
|
message: `${this.$t('common:ruleMessage:maxLength')} 200`,
|
||||||
trigger: "blur",
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
Description: [
|
Description: [
|
||||||
{
|
{
|
||||||
max: 200,
|
max: 200,
|
||||||
message: `${this.$t("common:ruleMessage:maxLength")} 200`,
|
message: `${this.$t('common:ruleMessage:maxLength')} 200`,
|
||||||
trigger: "blur",
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
Code: [
|
Code: [
|
||||||
{ required: true, message: "请注明", trigger: "blur" },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:inputCode'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
max: 200,
|
max: 200,
|
||||||
message: `${this.$t("common:ruleMessage:maxLength")} 200`,
|
message: `${this.$t('common:ruleMessage:maxLength')} 200`,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
Value: [
|
Value: [
|
||||||
{ required: true, message: "请注明", trigger: "blur" },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:inputValue'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
max: 1000,
|
max: 1000,
|
||||||
message: `${this.$t("common:ruleMessage:maxLength")} 1000`,
|
message: `${this.$t('common:ruleMessage:maxLength')} 1000`,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
ValueCN: [
|
ValueCN: [
|
||||||
{ required: true, message: "请注明", trigger: "blur" },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:inputValueCN'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
max: 1000,
|
max: 1000,
|
||||||
message: `${this.$t("common:ruleMessage:maxLength")} 1000`,
|
message: `${this.$t('common:ruleMessage:maxLength')} 1000`,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
InternationalizationType: [
|
InternationalizationType: [
|
||||||
{ required: true, message: "请选择", trigger: "blur" },
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:selectInternationalizationType'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
PublishLogId: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: this.$t('system:l18n:rule:selectPublishLogId'),
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
],
|
],
|
||||||
PublishLogId: [{ required: true, message: "请选择", trigger: "blur" }],
|
|
||||||
},
|
},
|
||||||
model_cfg: {
|
model_cfg: {
|
||||||
visible: false,
|
visible: false,
|
||||||
showClose: true,
|
showClose: true,
|
||||||
width: "600px",
|
width: '600px',
|
||||||
title: "",
|
title: '',
|
||||||
appendToBody: true,
|
appendToBody: true,
|
||||||
},
|
},
|
||||||
PublishVersionList: [],
|
PublishVersionList: [],
|
||||||
};
|
}
|
||||||
},
|
},
|
||||||
mounted() {},
|
mounted() {},
|
||||||
methods: {
|
methods: {
|
||||||
openDialog(title, data, options = [], status) {
|
openDialog(title, data, options = [], status) {
|
||||||
this.PublishVersionList = options;
|
this.PublishVersionList = options
|
||||||
this.status = status;
|
this.loading = false
|
||||||
this.model_cfg.visible = true;
|
this.status = status
|
||||||
this.model_cfg.title = title;
|
this.model_cfg.visible = true
|
||||||
|
this.model_cfg.title = title
|
||||||
if (Object.keys(data).length > 0) {
|
if (Object.keys(data).length > 0) {
|
||||||
for (const k in this.form) {
|
for (const k in this.form) {
|
||||||
if (data.hasOwnProperty(k)) {
|
if (data.hasOwnProperty(k)) {
|
||||||
this.form[k] = data[k];
|
this.form[k] = data[k]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.form = formDataDefault();
|
this.form = formDataDefault()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleSave() {
|
handleSave() {
|
||||||
this.$refs.i18nForm.validate((valid) => {
|
this.$refs.i18nForm.validate((valid) => {
|
||||||
if (!valid) return;
|
if (!valid) return
|
||||||
this.loading = true;
|
this.loading = true
|
||||||
if (this.status === "batch") {
|
if (this.status === 'batch') {
|
||||||
return this.$emit("batch", this.form);
|
return this.$emit('batch', this.form)
|
||||||
}
|
}
|
||||||
addOrUpdateInternationalization(this.form)
|
addOrUpdateInternationalization(this.form)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
this.$message.success(this.$t("common:message:savedSuccessfully"));
|
this.$message.success(this.$t('common:message:savedSuccessfully'))
|
||||||
this.model_cfg.visible = false;
|
this.model_cfg.visible = false
|
||||||
this.$emit("getList");
|
this.$emit('getList')
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
});
|
})
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
handleCancle() {
|
handleCancle() {
|
||||||
this.model_cfg.visible = false;
|
this.model_cfg.visible = false
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
::v-deep .el-select {
|
::v-deep .el-select {
|
||||||
|
|||||||
@@ -2,7 +2,9 @@
|
|||||||
<div class="log">
|
<div class="log">
|
||||||
<div ref="leftContainer" class="left">
|
<div ref="leftContainer" class="left">
|
||||||
<el-form :inline="true">
|
<el-form :inline="true">
|
||||||
<el-form-item label="国际化类型">
|
<el-form-item
|
||||||
|
:label="$t('system:l18n:search:InternationalizationType')"
|
||||||
|
>
|
||||||
<el-select
|
<el-select
|
||||||
v-model="searchData.InternationalizationType"
|
v-model="searchData.InternationalizationType"
|
||||||
clearable
|
clearable
|
||||||
@@ -17,7 +19,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="功能模块/服务名">
|
<el-form-item :label="$t('system:l18n:search:Module')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.Module"
|
v-model="searchData.Module"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -25,7 +27,7 @@
|
|||||||
style="width: 130px"
|
style="width: 130px"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="标识">
|
<el-form-item :label="$t('system:l18n:search:Code')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.Code"
|
v-model="searchData.Code"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -33,7 +35,7 @@
|
|||||||
style="width: 130px"
|
style="width: 130px"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="中文值">
|
<el-form-item :label="$t('system:l18n:search:ValueCN')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.ValueCN"
|
v-model="searchData.ValueCN"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -41,7 +43,7 @@
|
|||||||
style="width: 130px"
|
style="width: 130px"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="英文值">
|
<el-form-item :label="$t('system:l18n:search:Value')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.Value"
|
v-model="searchData.Value"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -49,7 +51,7 @@
|
|||||||
clearable
|
clearable
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="状态">
|
<el-form-item :label="$t('system:l18n:search:State')">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="searchData.State"
|
v-model="searchData.State"
|
||||||
clearable
|
clearable
|
||||||
@@ -64,7 +66,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="说明">
|
<el-form-item :label="$t('system:l18n:search:Description')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.Description"
|
v-model="searchData.Description"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -72,7 +74,7 @@
|
|||||||
style="width: 130px"
|
style="width: 130px"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="迭代">
|
<el-form-item :label="$t('system:l18n:search:PublishVersion')">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="searchData.PublishLogId"
|
v-model="searchData.PublishLogId"
|
||||||
clearable
|
clearable
|
||||||
@@ -118,7 +120,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="getList"
|
@click="getList"
|
||||||
>
|
>
|
||||||
查询
|
{{ $t('common:button:search') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- 重置 -->
|
<!-- 重置 -->
|
||||||
<el-button
|
<el-button
|
||||||
@@ -135,7 +137,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>
|
>
|
||||||
新增
|
{{ $t('common:button:new') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -143,7 +145,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleBatchAdd"
|
@click="handleBatchAdd"
|
||||||
>
|
>
|
||||||
批量新增
|
{{ $t('system:l18n:button:batchAdd') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -152,7 +154,16 @@
|
|||||||
:disabled="selectTableList.length <= 0"
|
:disabled="selectTableList.length <= 0"
|
||||||
@click="handleBatchUpdate"
|
@click="handleBatchUpdate"
|
||||||
>
|
>
|
||||||
批量更新
|
{{ $t('system:l18n:button:batchUpdate') }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-edit-outline"
|
||||||
|
size="mini"
|
||||||
|
:disabled="selectTableList.length <= 0"
|
||||||
|
@click="handleBatchUpdateToChange"
|
||||||
|
>
|
||||||
|
{{ $t('system:l18n:button:batchEdit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
@@ -175,7 +186,7 @@
|
|||||||
><el-table-column type="selection" width="50" />
|
><el-table-column type="selection" width="50" />
|
||||||
<el-table-column type="index" width="50" />
|
<el-table-column type="index" width="50" />
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="国际化类型"
|
:label="$t('system:l18n:search:InternationalizationType')"
|
||||||
prop="InternationalizationType"
|
prop="InternationalizationType"
|
||||||
width="120"
|
width="120"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
@@ -215,35 +226,35 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="功能模块/服务名"
|
:label="$t('system:l18n:search:Module')"
|
||||||
prop="Module"
|
prop="Module"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="标识"
|
:label="$t('system:l18n:search:Code')"
|
||||||
prop="Code"
|
prop="Code"
|
||||||
min-width="150"
|
min-width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="中文值"
|
:label="$t('system:l18n:search:ValueCN')"
|
||||||
prop="ValueCN"
|
prop="ValueCN"
|
||||||
min-width="150"
|
min-width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="英文值"
|
:label="$t('system:l18n:search:Value')"
|
||||||
prop="Value"
|
prop="Value"
|
||||||
min-width="150"
|
min-width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="状态"
|
:label="$t('system:l18n:search:State')"
|
||||||
prop="State"
|
prop="State"
|
||||||
width="100"
|
width="100"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
@@ -262,35 +273,35 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="说明"
|
:label="$t('system:l18n:search:Description')"
|
||||||
prop="Description"
|
prop="Description"
|
||||||
min-width="100"
|
min-width="100"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="迭代"
|
:label="$t('system:l18n:search:PublishVersion')"
|
||||||
prop="Version"
|
prop="Version"
|
||||||
min-width="100"
|
min-width="100"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="更新时间"
|
:label="$t('system:l18n:form:uploadTime')"
|
||||||
prop="UpdateTime"
|
prop="UpdateTime"
|
||||||
width="150"
|
width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="创建时间"
|
:label="$t('system:l18n:form:createTime')"
|
||||||
prop="CreateTime"
|
prop="CreateTime"
|
||||||
width="150"
|
width="150"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="操作"
|
:label="$t('common:action:action')"
|
||||||
fixed="right"
|
fixed="right"
|
||||||
prop=""
|
prop=""
|
||||||
min-width="120"
|
min-width="120"
|
||||||
@@ -303,7 +314,7 @@
|
|||||||
icon="el-icon-edit-outline"
|
icon="el-icon-edit-outline"
|
||||||
@click="handleEdit(scope.row)"
|
@click="handleEdit(scope.row)"
|
||||||
>
|
>
|
||||||
编辑
|
{{ $t('common:button:edit') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
:disabled="scope.row.State === 1"
|
:disabled="scope.row.State === 1"
|
||||||
@@ -312,7 +323,7 @@
|
|||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
>
|
>
|
||||||
删除
|
{{ $t('common:button:delete') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -380,6 +391,9 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getPublishVersionSelect()
|
this.getPublishVersionSelect()
|
||||||
|
this.$EventBus.$on('il8nUpdate', (data) => {
|
||||||
|
this.getList()
|
||||||
|
})
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 获取迭代
|
// 获取迭代
|
||||||
@@ -409,13 +423,17 @@ export default {
|
|||||||
handleBatchUpdate() {
|
handleBatchUpdate() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs['i18nForm'].openDialog(
|
this.$refs['i18nForm'].openDialog(
|
||||||
'批量更新',
|
this.$t('system:l18n:button:batchUpdate'),
|
||||||
{},
|
{},
|
||||||
this.PublishVersionList,
|
this.PublishVersionList,
|
||||||
'batch'
|
'batch'
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
// 批量编辑国际化内容
|
||||||
|
handleBatchUpdateToChange() {
|
||||||
|
this.$openI18n(this.selectTableList)
|
||||||
|
},
|
||||||
async batch(row) {
|
async batch(row) {
|
||||||
let { PublishLogId, State } = row
|
let { PublishLogId, State } = row
|
||||||
let data = {
|
let data = {
|
||||||
@@ -439,7 +457,7 @@ export default {
|
|||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs['i18nForm'].openDialog(
|
this.$refs['i18nForm'].openDialog(
|
||||||
'新增',
|
this.$t("system:l18n:button:add"),
|
||||||
{},
|
{},
|
||||||
this.PublishVersionList,
|
this.PublishVersionList,
|
||||||
'add'
|
'add'
|
||||||
@@ -449,7 +467,7 @@ export default {
|
|||||||
handleBatchAdd() {
|
handleBatchAdd() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs['batcnAddForm'].openDialog(
|
this.$refs['batcnAddForm'].openDialog(
|
||||||
'批量新增',
|
this.$t("system:l18n:button:batchAdd"),
|
||||||
{},
|
{},
|
||||||
this.PublishVersionList
|
this.PublishVersionList
|
||||||
)
|
)
|
||||||
@@ -458,7 +476,7 @@ export default {
|
|||||||
handleEdit(row) {
|
handleEdit(row) {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs['i18nForm'].openDialog(
|
this.$refs['i18nForm'].openDialog(
|
||||||
'编辑',
|
this.$t("system:l18n:button:edit"),
|
||||||
row,
|
row,
|
||||||
this.PublishVersionList,
|
this.PublishVersionList,
|
||||||
'update'
|
'update'
|
||||||
@@ -474,7 +492,7 @@ export default {
|
|||||||
},
|
},
|
||||||
// 删除
|
// 删除
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
this.$confirm('是否确认删除?', {
|
this.$confirm(this.$t("system:l18n:confirm:delete"), {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true,
|
distinguishCancelAndClose: true,
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
<el-form-item :label="$t('system:log:form:version')" prop="Version">
|
<el-form-item :label="$t('system:log:form:version')" prop="Version">
|
||||||
<el-input v-model="form.Version" />
|
<el-input v-model="form.Version" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:log:form:versionUS')" prop="Version">
|
<el-form-item :label="$t('system:log:form:versionUS')" prop="Version_US">
|
||||||
<el-input v-model="form.Version_US" />
|
<el-input v-model="form.Version_US" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
@@ -100,6 +100,9 @@ export default {
|
|||||||
},
|
},
|
||||||
{ max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50` },
|
{ max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50` },
|
||||||
],
|
],
|
||||||
|
Version_US:[
|
||||||
|
{ max: 50, message: `${this.$t('common:ruleMessage:maxLength')} 50` }
|
||||||
|
],
|
||||||
// PublishTime: [
|
// PublishTime: [
|
||||||
// { required: true, message: '请注明', trigger: 'blur' }
|
// { required: true, message: '请注明', trigger: 'blur' }
|
||||||
// ],
|
// ],
|
||||||
|
|||||||
@@ -8,7 +8,10 @@
|
|||||||
<el-form-item :label="$t('system:log:table:versionUS')" prop="Version">
|
<el-form-item :label="$t('system:log:table:versionUS')" prop="Version">
|
||||||
<el-input v-model="searchData.Version_US" size="small" clearable />
|
<el-input v-model="searchData.Version_US" size="small" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="更新功能" prop="UpdateContent">
|
<el-form-item
|
||||||
|
:label="$t('system:log:table:UpdateContent')"
|
||||||
|
prop="UpdateContent"
|
||||||
|
>
|
||||||
<el-input v-model="searchData.UpdateContent" size="small" clearable />
|
<el-input v-model="searchData.UpdateContent" size="small" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
@@ -18,7 +21,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="getList"
|
@click="getList"
|
||||||
>
|
>
|
||||||
查询
|
{{ $t('common:button:search') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -26,7 +29,7 @@
|
|||||||
size="mini"
|
size="mini"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
>
|
>
|
||||||
新增
|
{{ $t('common:button:new') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
|||||||
@@ -0,0 +1,111 @@
|
|||||||
|
<template>
|
||||||
|
<base-model v-if="config.visible" :config="config">
|
||||||
|
<template slot="dialog-body">
|
||||||
|
<el-table :data="curData" border style="width: 100%" size="small">
|
||||||
|
<el-table-column
|
||||||
|
prop="key"
|
||||||
|
:label="$t('system:loginLog:table:cfgItem')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="value"
|
||||||
|
:label="$t('system:loginLog:table:cfgVal')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span v-if="scope.row.prop !== 'UserRoleList'">{{
|
||||||
|
scope.row.value
|
||||||
|
}}</span>
|
||||||
|
<template v-else>
|
||||||
|
<div
|
||||||
|
v-for="item in scope.row.value"
|
||||||
|
:key="item.UserTypeEnum"
|
||||||
|
style="margin: 0"
|
||||||
|
>
|
||||||
|
{{ item.UserTypeShortName
|
||||||
|
}}{{ $t('system:loginLog:form:symbol')
|
||||||
|
}}{{ $fd('IsEnable', !item.IsUserRoleDisabled) }}
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</template>
|
||||||
|
<template slot="dialog-footer">
|
||||||
|
<el-button type="primary" @click="config.visible = false">
|
||||||
|
{{ $t('common:button:confirm') }}
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
</base-model>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import BaseModel from '@/components/BaseModel'
|
||||||
|
export default {
|
||||||
|
components: { BaseModel },
|
||||||
|
props: {
|
||||||
|
JsonObj: {
|
||||||
|
type: String,
|
||||||
|
default: '',
|
||||||
|
},
|
||||||
|
config: {
|
||||||
|
type: Object,
|
||||||
|
default: () => {
|
||||||
|
return {
|
||||||
|
visible: false,
|
||||||
|
title: this.$t('system:loginLog:dialog:title'),
|
||||||
|
width: '500px',
|
||||||
|
top: '10vh',
|
||||||
|
appendToBody: true,
|
||||||
|
bodyStyle: `min-height: 100px; max-height: 650px;overflow-y: auto;padding: 10px;border: 1px solid #e0e0e0;`,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
curKeys: [
|
||||||
|
'UserName',
|
||||||
|
'FirstName',
|
||||||
|
'LastName',
|
||||||
|
'EMail',
|
||||||
|
'Phone',
|
||||||
|
'Status',
|
||||||
|
'OrganizationName',
|
||||||
|
'PositionName',
|
||||||
|
'DepartmentName',
|
||||||
|
'UserRoleList',
|
||||||
|
],
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
curDataArr() {
|
||||||
|
if (!this.curData) return []
|
||||||
|
return Object.keys(this.curData)
|
||||||
|
},
|
||||||
|
curData() {
|
||||||
|
if (!this.JsonObj) return []
|
||||||
|
let obj = JSON.parse(this.JsonObj)
|
||||||
|
let curData = []
|
||||||
|
Object.keys(obj).forEach((key) => {
|
||||||
|
if (this.curKeys.includes(key)) {
|
||||||
|
let o = {
|
||||||
|
key: this.$t(`system:loginLog:form:${key}`),
|
||||||
|
value: obj[key],
|
||||||
|
prop: key,
|
||||||
|
}
|
||||||
|
if (key === 'Status') {
|
||||||
|
o.value = this.$fd('IsUserEnable', obj[key])
|
||||||
|
}
|
||||||
|
curData.push(o)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return curData
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
::v-deep .el-form-item__label {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -50,7 +50,7 @@
|
|||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label=" $t('system:loginLog:table:LoginUserType')"
|
:label="$t('system:loginLog:table:LoginUserType')"
|
||||||
prop="LoginUserTypeEnum"
|
prop="LoginUserTypeEnum"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
@@ -77,19 +77,15 @@
|
|||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button
|
<el-button type="primary" icon="el-icon-search" @click="getList">
|
||||||
type="primary"
|
{{ $t('common:button:search') }}
|
||||||
icon="el-icon-search"
|
|
||||||
@click="getList"
|
|
||||||
>
|
|
||||||
{{ $t("common:button:search") }}
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
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>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
@@ -101,7 +97,32 @@
|
|||||||
class="table"
|
class="table"
|
||||||
@sort-change="handleSortByColumn"
|
@sort-change="handleSortByColumn"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50" />
|
<el-table-column type="index" width="50">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span
|
||||||
|
style="
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: flex-end;
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<el-tooltip
|
||||||
|
class="item"
|
||||||
|
effect="dark"
|
||||||
|
:content="$t('system:loginLog:label:IsLoginUncommonly')"
|
||||||
|
placement="top"
|
||||||
|
style="margin-right: 3px"
|
||||||
|
v-if="scope.row.IsLoginUncommonly"
|
||||||
|
>
|
||||||
|
<i
|
||||||
|
v-if="scope.row.IsLoginUncommonly"
|
||||||
|
class="el-icon-warning icon-i"
|
||||||
|
></i>
|
||||||
|
</el-tooltip>
|
||||||
|
<span>{{ scope.$index + 1 }}</span>
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
:label="$t('system:loginLog:table:OptType')"
|
:label="$t('system:loginLog:table:OptType')"
|
||||||
prop="OptType"
|
prop="OptType"
|
||||||
@@ -110,7 +131,7 @@
|
|||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd("UserOptType", scope.row.OptType) }}
|
{{ $fd('UserOptType', scope.row.OptType) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -127,21 +148,28 @@
|
|||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<!-- <el-table-column
|
||||||
:label="$t('system:loginLog:table:LoginFaildName')"
|
:label="$t('system:loginLog:table:LoginFaildName')"
|
||||||
prop="LoginFaildName"
|
prop="LoginFaildName"
|
||||||
min-width="180"
|
min-width="180"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/> -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
:label="$t('system:loginLog:table:LoginUserName')"
|
:label="$t('system:loginLog:table:LoginUserName')"
|
||||||
prop="LoginUserName"
|
prop="ActionUserName"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
|
:label="$t('system:loginLog:table:Aetionlserlype')"
|
||||||
|
prop="ActionUserType"
|
||||||
|
min-width="100"
|
||||||
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
|
/>
|
||||||
|
<!-- <el-table-column
|
||||||
:label="$t('system:loginLog:table:LoginUserType')"
|
:label="$t('system:loginLog:table:LoginUserType')"
|
||||||
prop="LoginUserTypeEnum"
|
prop="LoginUserTypeEnum"
|
||||||
min-width="120"
|
min-width="120"
|
||||||
@@ -151,15 +179,15 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd("UserType", scope.row.LoginUserTypeEnum) }}
|
{{ $fd("UserType", scope.row.LoginUserTypeEnum) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column> -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
:label="$t('system:loginLog:table:OptUserName')"
|
:label="$t('system:loginLog:table:OptUserName')"
|
||||||
prop="OptUserName"
|
prop="TargetIdentityUserName"
|
||||||
min-width="200"
|
min-width="200"
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
<!-- <el-table-column
|
||||||
:label="$t('system:loginLog:table:OptUserType')"
|
:label="$t('system:loginLog:table:OptUserType')"
|
||||||
prop="OptUserTypeEnum"
|
prop="OptUserTypeEnum"
|
||||||
min-width="200"
|
min-width="200"
|
||||||
@@ -169,6 +197,21 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ $fd("UserType", scope.row.OptUserTypeEnum) }}
|
{{ $fd("UserType", scope.row.OptUserTypeEnum) }}
|
||||||
</template>
|
</template>
|
||||||
|
</el-table-column> -->
|
||||||
|
<el-table-column
|
||||||
|
:label="$t('system:loginLog:table:detail')"
|
||||||
|
min-width="120"
|
||||||
|
show-overflow-tooltip
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
v-if="scope.row.JsonObj"
|
||||||
|
type="text"
|
||||||
|
@click="handleOpenDialog(scope.row)"
|
||||||
|
>
|
||||||
|
<span>{{ $t('system:loginLog:message:detail') }}</span>
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
:label="$t('system:loginLog:table:CreateTime')"
|
:label="$t('system:loginLog:table:CreateTime')"
|
||||||
@@ -187,29 +230,31 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<detail :config="config" :JsonObj="JsonObj" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getUserLogList } from "@/api/user";
|
import { getUserLogList } from '@/api/user'
|
||||||
import Pagination from "@/components/Pagination";
|
import Pagination from '@/components/Pagination'
|
||||||
import moment from "moment";
|
import detail from './detail.vue'
|
||||||
|
import moment from 'moment'
|
||||||
const searchDataDefault = () => {
|
const searchDataDefault = () => {
|
||||||
return {
|
return {
|
||||||
OptType: null,
|
OptType: null,
|
||||||
Ip: "",
|
Ip: '',
|
||||||
LoginFaildName: "",
|
LoginFaildName: '',
|
||||||
LoginUserName: '',
|
LoginUserName: '',
|
||||||
LoginUserTypeEnum: null,
|
LoginUserTypeEnum: null,
|
||||||
BeginDate: "",
|
BeginDate: '',
|
||||||
EndDate: "",
|
EndDate: '',
|
||||||
Asc: false,
|
Asc: false,
|
||||||
SortField: "CreateTime",
|
SortField: 'CreateTime',
|
||||||
PageIndex: 1,
|
PageIndex: 1,
|
||||||
PageSize: 20,
|
PageSize: 20,
|
||||||
};
|
}
|
||||||
};
|
}
|
||||||
export default {
|
export default {
|
||||||
components: { Pagination },
|
components: { Pagination, detail },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
moment,
|
moment,
|
||||||
@@ -218,52 +263,69 @@ export default {
|
|||||||
total: 0,
|
total: 0,
|
||||||
loading: false,
|
loading: false,
|
||||||
datetimerange: [],
|
datetimerange: [],
|
||||||
};
|
config: {
|
||||||
|
visible: false,
|
||||||
|
title: this.$t('system:loginLog:dialog:title'),
|
||||||
|
width: '500px',
|
||||||
|
top: '10vh',
|
||||||
|
},
|
||||||
|
JsonObj: null,
|
||||||
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleOpenDialog(row) {
|
||||||
|
if (!row.JsonObj)
|
||||||
|
return this.$message.warning(this.$t('system:loginLog:message:noJSON'))
|
||||||
|
this.config.title = this.$t('system:loginLog:dialog:title').replace(
|
||||||
|
'xxx',
|
||||||
|
this.$fd('UserOptType', row.OptType)
|
||||||
|
)
|
||||||
|
this.JsonObj = row.JsonObj
|
||||||
|
this.config.visible = true
|
||||||
|
},
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true
|
||||||
getUserLogList(this.searchData)
|
getUserLogList(this.searchData)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
this.list = res.Result.CurrentPageData;
|
this.list = res.Result.CurrentPageData
|
||||||
this.total = res.Result.TotalCount;
|
this.total = res.Result.TotalCount
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
handleDatetimeChange(val) {
|
handleDatetimeChange(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
this.searchData.BeginDate = val[0];
|
this.searchData.BeginDate = val[0]
|
||||||
this.searchData.EndDate = val[1];
|
this.searchData.EndDate = val[1]
|
||||||
} else {
|
} else {
|
||||||
this.searchData.BeginDate = "";
|
this.searchData.BeginDate = ''
|
||||||
this.searchData.EndDate = "";
|
this.searchData.EndDate = ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 重置列表查询
|
// 重置列表查询
|
||||||
handleReset() {
|
handleReset() {
|
||||||
this.datetimerange = []
|
this.datetimerange = []
|
||||||
this.searchData = searchDataDefault();
|
this.searchData = searchDataDefault()
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
// 排序
|
// 排序
|
||||||
handleSortByColumn(column) {
|
handleSortByColumn(column) {
|
||||||
if (column.order === "ascending") {
|
if (column.order === 'ascending') {
|
||||||
this.searchData.Asc = true;
|
this.searchData.Asc = true
|
||||||
} else {
|
} else {
|
||||||
this.searchData.Asc = false;
|
this.searchData.Asc = false
|
||||||
}
|
}
|
||||||
this.searchData.SortField = column.prop;
|
this.searchData.SortField = column.prop
|
||||||
this.searchData.PageIndex = 1;
|
this.searchData.PageIndex = 1
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.log {
|
.log {
|
||||||
@@ -291,5 +353,9 @@ export default {
|
|||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.icon-i {
|
||||||
|
color: #f56c6c;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -5,24 +5,38 @@
|
|||||||
:model="user"
|
:model="user"
|
||||||
:rules="userFormRules"
|
:rules="userFormRules"
|
||||||
label-width="150px"
|
label-width="150px"
|
||||||
style="width:800px;"
|
style="width: 800px"
|
||||||
>
|
>
|
||||||
<el-card class="Basic" shadow="never" size="small">
|
<el-card class="Basic" shadow="never" size="small">
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>{{ $t('system:userlist:title:Information') }}</span>
|
<span>{{ $t('system:userlist:title:Information') }}</span>
|
||||||
</div>
|
</div>
|
||||||
<el-form-item v-if="user.UserCode" :label="$t('system:userlist:table:S/N')" prop="UserCode">
|
<el-form-item
|
||||||
|
v-if="user.UserCode"
|
||||||
|
:label="$t('system:userlist:table:S/N')"
|
||||||
|
prop="UserCode"
|
||||||
|
>
|
||||||
<el-input v-model="user.UserCode" disabled />
|
<el-input v-model="user.UserCode" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item :label="$t('system:userlist:table:UserName')" class="my_new_pwd" prop="UserName">
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:UserName')"
|
||||||
|
class="my_new_pwd"
|
||||||
|
prop="UserName"
|
||||||
|
>
|
||||||
<el-input v-model="user.UserName" />
|
<el-input v-model="user.UserName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item :label="$t('system:userlist:table:LastName')" prop="LastName">
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:LastName')"
|
||||||
|
prop="LastName"
|
||||||
|
>
|
||||||
<el-input v-model="user.LastName" />
|
<el-input v-model="user.LastName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:FirstName')" prop="FirstName">
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:FirstName')"
|
||||||
|
prop="FirstName"
|
||||||
|
>
|
||||||
<el-input v-model="user.FirstName" />
|
<el-input v-model="user.FirstName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- <el-form-item :label="$t('system:userlist:table:Gender')" prop="Sex" style="margin-right:40px;">
|
<!-- <el-form-item :label="$t('system:userlist:table:Gender')" prop="Sex" style="margin-right:40px;">
|
||||||
@@ -32,49 +46,134 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item> -->
|
</el-form-item> -->
|
||||||
<el-form-item :label="$t('system:userlist:table:Email')" prop="EMail">
|
<el-form-item :label="$t('system:userlist:table:Email')" prop="EMail">
|
||||||
<el-input v-model="user.EMail" />
|
<el-input v-model="user.EMail" :disabled="!!user.UserCode" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:Phone')" prop="Phone">
|
<el-form-item :label="$t('system:userlist:table:Phone')" prop="Phone">
|
||||||
<el-input v-model="user.Phone" />
|
<el-input v-model="user.Phone" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="type==1" :label="$t('system:userlist:table:Disable')">
|
<el-form-item
|
||||||
<el-switch v-model="user.Status" :active-value="1" :inactive-value="0" />
|
v-if="type == 1"
|
||||||
|
:label="$t('system:userlist:table:Disable')"
|
||||||
|
>
|
||||||
|
<el-switch
|
||||||
|
v-model="user.Status"
|
||||||
|
:active-value="1"
|
||||||
|
:inactive-value="0"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:IsTestUser')">
|
<el-form-item :label="$t('system:userlist:table:IsTestUser')">
|
||||||
<el-radio-group v-model="user.IsTestUser">
|
<el-radio-group v-model="user.IsTestUser">
|
||||||
<el-radio v-for="item of $d.YesOrNo" :label="item.value">{{ item.label }}</el-radio>
|
<el-radio
|
||||||
|
v-for="item of $d.YesOrNo"
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.value"
|
||||||
|
>{{ item.label }}</el-radio
|
||||||
|
>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:UserType')" prop="UserTypeId">
|
<el-form-item
|
||||||
<el-select ref="userType" v-model="user.UserTypeId" size="small" placeholder="Please select" style="width:100%;" :disabled="user.CanEditUserType === false">
|
:label="$t('system:userlist:table:UserType')"
|
||||||
<el-option
|
prop="Roles"
|
||||||
v-for="(userType,key) of userTypeOptions"
|
v-if="type === 0"
|
||||||
v-if="userType.UserTypeEnum !== 20"
|
>
|
||||||
:key="key"
|
<div style="display: flex; align-items: center">
|
||||||
:label="userType.UserType"
|
<el-select
|
||||||
:value="userType.Id"
|
ref="userType"
|
||||||
/>
|
v-model="user.Roles"
|
||||||
</el-select>
|
size="small"
|
||||||
|
placeholder="Please select"
|
||||||
|
multiple
|
||||||
|
style="width: 100%"
|
||||||
|
:disabled="user.CanEditUserType === false || type === 1"
|
||||||
|
@change="handleChange"
|
||||||
|
>
|
||||||
|
<template v-for="userType of userTypeOptions">
|
||||||
|
<el-option
|
||||||
|
v-if="![4, 6, 20].includes(userType.UserTypeEnum)"
|
||||||
|
:key="userType.Id"
|
||||||
|
:label="userType.UserType"
|
||||||
|
:value="userType.Id"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:UserType')"
|
||||||
|
prop="userTypeId"
|
||||||
|
v-else
|
||||||
|
>
|
||||||
|
<div style="display: flex; align-items: center">
|
||||||
|
<el-select
|
||||||
|
ref="userType"
|
||||||
|
v-model="Roles"
|
||||||
|
size="small"
|
||||||
|
placeholder="Please select"
|
||||||
|
multiple
|
||||||
|
style="width: 100%"
|
||||||
|
:disabled="user.CanEditUserType === false || type === 1"
|
||||||
|
@change="handleChange"
|
||||||
|
>
|
||||||
|
<template v-for="userType of userTypeOptions">
|
||||||
|
<el-option
|
||||||
|
v-if="![4, 6, 20].includes(userType.UserTypeEnum)"
|
||||||
|
:key="userType.Id"
|
||||||
|
:label="userType.UserType"
|
||||||
|
:value="userType.Id"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-select>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
size="small"
|
||||||
|
style="margin-left: 5px"
|
||||||
|
v-if="type === 1"
|
||||||
|
@click.stop="openRoleList"
|
||||||
|
>
|
||||||
|
{{ $t('system:userlist:button:roles') }}
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<el-card class="Affiliation" shadow="never" style="margin-top:10px;" size="small">
|
<el-card
|
||||||
|
class="Affiliation"
|
||||||
|
shadow="never"
|
||||||
|
style="margin-top: 10px"
|
||||||
|
size="small"
|
||||||
|
>
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>{{ $t('system:userlist:title:Affiliation') }}</span>
|
<span>{{ $t('system:userlist:title:Affiliation') }}</span>
|
||||||
</div>
|
</div>
|
||||||
<el-form-item prop="IsZhiZhun">
|
<el-form-item prop="IsZhiZhun">
|
||||||
<el-radio-group v-model="user.IsZhiZhun" @change="OrgnizationTypeChanged">
|
<el-radio-group
|
||||||
<el-radio :label="true">{{ $t('system:userlist:title:Internal') }}</el-radio>
|
v-model="user.IsZhiZhun"
|
||||||
<el-radio :label="false">{{ $t('system:userlist:title:External') }}</el-radio>
|
@change="OrgnizationTypeChanged"
|
||||||
|
>
|
||||||
|
<el-radio :label="true">{{
|
||||||
|
$t('system:userlist:title:Internal')
|
||||||
|
}}</el-radio>
|
||||||
|
<el-radio :label="false">{{
|
||||||
|
$t('system:userlist:title:External')
|
||||||
|
}}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-show="user.IsZhiZhun === false" :label="$t('system:userlist:table:OrganizationName')">
|
<el-form-item
|
||||||
|
v-show="user.IsZhiZhun === false"
|
||||||
|
:label="$t('system:userlist:table:OrganizationName')"
|
||||||
|
>
|
||||||
<el-input v-model="user.OrganizationName" />
|
<el-input v-model="user.OrganizationName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:Department')" prop="DepartmentName">
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:Department')"
|
||||||
|
prop="DepartmentName"
|
||||||
|
>
|
||||||
<el-input v-model="user.DepartmentName" />
|
<el-input v-model="user.DepartmentName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('system:userlist:table:Position')" prop="PositionName">
|
<el-form-item
|
||||||
|
:label="$t('system:userlist:table:Position')"
|
||||||
|
prop="PositionName"
|
||||||
|
>
|
||||||
<el-input v-model="user.PositionName" />
|
<el-input v-model="user.PositionName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-card>
|
</el-card>
|
||||||
@@ -83,20 +182,35 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
:disabled="isDisabled"
|
:disabled="isDisabled"
|
||||||
style="margin:10px 15px"
|
style="margin: 10px 15px"
|
||||||
@click="handleSave"
|
@click="handleSave"
|
||||||
>Save</el-button>
|
>Save</el-button
|
||||||
|
>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<roleList
|
||||||
|
v-if="visible"
|
||||||
|
:visible.sync="visible"
|
||||||
|
:userId="userId"
|
||||||
|
:list="userRoleList"
|
||||||
|
:userTypeOptions="userTypeOptions"
|
||||||
|
@getRoleList="getRoleList"
|
||||||
|
/>
|
||||||
</el-form>
|
</el-form>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getUser, addUser, updateUser, getUserTypeListByUserType } from '@/api/admin.js'
|
import {
|
||||||
|
getUser,
|
||||||
|
addUser,
|
||||||
|
updateUser,
|
||||||
|
getUserTypeListByUserType,
|
||||||
|
} from '@/api/admin.js'
|
||||||
|
import roleList from './roleList.vue'
|
||||||
export default {
|
export default {
|
||||||
name: 'UserInfo',
|
name: 'UserInfo',
|
||||||
props: {
|
props: {
|
||||||
userId: { type: String, default: '' }
|
userId: { type: String, default: '' },
|
||||||
},
|
},
|
||||||
|
components: { roleList },
|
||||||
created() {
|
created() {
|
||||||
this.getUserTypeList()
|
this.getUserTypeList()
|
||||||
if (this.userId !== '') {
|
if (this.userId !== '') {
|
||||||
@@ -107,26 +221,46 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
updateQueryParam(param, newValue,wurl) {
|
openRoleList() {
|
||||||
|
this.userRoleList = []
|
||||||
|
this.user.UserRoleList.forEach((item) => {
|
||||||
|
this.userRoleList.push(Object.assign({}, item))
|
||||||
|
})
|
||||||
|
this.visible = true
|
||||||
|
},
|
||||||
|
handleChange(val) {
|
||||||
|
this.user.UserRoleList = []
|
||||||
|
val.forEach((item) => {
|
||||||
|
let data = this.userTypeOptions.find((d) => d.Id === item)
|
||||||
|
this.user.UserRoleList.push({
|
||||||
|
UserTypeEnum: data.UserTypeEnum,
|
||||||
|
UserTypeId: data.Id,
|
||||||
|
IsUserRoleDisabled: false,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
updateQueryParam(param, newValue, wurl) {
|
||||||
// 获取当前URL
|
// 获取当前URL
|
||||||
let url = wurl || window.location.href;
|
let url = wurl || window.location.href
|
||||||
|
|
||||||
// 正则表达式匹配参数
|
// 正则表达式匹配参数
|
||||||
let regex = new RegExp('([?&])' + param + '=.*?(&|$)');
|
let regex = new RegExp('([?&])' + param + '=.*?(&|$)')
|
||||||
let separator = url.indexOf('?') !== -1 ? '&' : '?';
|
let separator = url.indexOf('?') !== -1 ? '&' : '?'
|
||||||
|
|
||||||
// 如果参数存在,替换它,如果不存在,添加它
|
// 如果参数存在,替换它,如果不存在,添加它
|
||||||
if (regex.test(url)) {
|
if (regex.test(url)) {
|
||||||
return url.replace(regex, '$1' + param + '=' + newValue + '$2');
|
return url.replace(regex, '$1' + param + '=' + newValue + '$2')
|
||||||
} else {
|
} else {
|
||||||
return url + separator + param + '=' + newValue;
|
return url + separator + param + '=' + newValue
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleSave() {
|
handleSave() {
|
||||||
this.$refs.userForm.validate(valid => {
|
this.$refs.userForm.validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.isDisabled = true
|
this.isDisabled = true
|
||||||
const selectedUserType = this.userTypeOptions.filter(item => item.Id === this.user.UserTypeId)
|
const selectedUserType = this.userTypeOptions.filter(
|
||||||
|
(item) => item.Id === this.user.UserTypeId
|
||||||
|
)
|
||||||
let newUrl = this.updateQueryParam('userName', this.user.UserName)
|
let newUrl = this.updateQueryParam('userName', this.user.UserName)
|
||||||
newUrl = this.updateQueryParam('email', this.user.EMail, newUrl)
|
newUrl = this.updateQueryParam('email', this.user.EMail, newUrl)
|
||||||
window.history.pushState({ path: newUrl }, '', newUrl)
|
window.history.pushState({ path: newUrl }, '', newUrl)
|
||||||
@@ -136,53 +270,117 @@ export default {
|
|||||||
this.user.BaseUrl = `${location.protocol}//${location.host}/login`
|
this.user.BaseUrl = `${location.protocol}//${location.host}/login`
|
||||||
this.user.RouteUrl = `${location.protocol}//${location.host}/email-recompose`
|
this.user.RouteUrl = `${location.protocol}//${location.host}/email-recompose`
|
||||||
if (this.user.Id) {
|
if (this.user.Id) {
|
||||||
updateUser(this.user).then(res => {
|
updateUser(this.user)
|
||||||
this.isDisabled = false
|
.then((res) => {
|
||||||
this.$message.success('Updated successfully')
|
this.isDisabled = false
|
||||||
}).catch(() => { this.isDisabled = false })
|
this.$message.success('Updated successfully')
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.isDisabled = false
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
addUser(this.user).then(res => {
|
addUser(this.user)
|
||||||
this.isDisabled = false
|
.then((res) => {
|
||||||
this.user.Id = res.Result.Id
|
this.isDisabled = false
|
||||||
this.user.UserCode = res.Result.UserCode
|
this.user.Id = res.Result.Id
|
||||||
this.$emit('getUserId', res.Result.Id)
|
this.user.UserCode = res.Result.UserCode
|
||||||
this.$message.success('Added successfully')
|
this.$emit('getUserId', res.Result.Id)
|
||||||
this.$router.push({ path: '/system/user/list' })
|
this.$message.success('Added successfully')
|
||||||
}).catch(() => { this.isDisabled = false })
|
this.$router.push({ path: '/system/user/list' })
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.isDisabled = false
|
||||||
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getUserTypeList() {
|
getUserTypeList() {
|
||||||
getUserTypeListByUserType(0).then(res => {
|
getUserTypeListByUserType(0).then((res) => {
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
this.userTypeOptions = res.Result
|
this.userTypeOptions = []
|
||||||
|
res.Result.forEach((item) => {
|
||||||
|
if (item.UserTypeEnum !== 21) {
|
||||||
|
this.userTypeOptions.push(item)
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getUserInfo() {
|
getUserInfo() {
|
||||||
getUser(this.userId).then(res => {
|
getUser({
|
||||||
|
IdentityUserId: this.userId,
|
||||||
|
}).then((res) => {
|
||||||
this.user = res.Result
|
this.user = res.Result
|
||||||
|
this.Roles = []
|
||||||
|
this.user.Roles = []
|
||||||
|
this.user.UserRoleList = []
|
||||||
|
res.Result.AccountList.forEach((item) => {
|
||||||
|
if (!item.IsUserRoleDisabled) {
|
||||||
|
this.Roles.push(item.UserTypeId)
|
||||||
|
this.user.Roles.push(item.UserTypeId)
|
||||||
|
}
|
||||||
|
this.user.UserRoleList.push({
|
||||||
|
UserTypeEnum: item.UserTypeEnum,
|
||||||
|
UserTypeId: item.UserTypeId,
|
||||||
|
IsUserRoleDisabled: item.IsUserRoleDisabled,
|
||||||
|
UserTypeShortName: item.UserTypeShortName,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
getRoleList() {
|
||||||
|
getUser({
|
||||||
|
IdentityUserId: this.userId,
|
||||||
|
}).then((res) => {
|
||||||
|
this.Roles = []
|
||||||
|
this.user.Roles = []
|
||||||
|
this.user.UserRoleList = []
|
||||||
|
res.Result.AccountList.forEach((item) => {
|
||||||
|
if (!item.IsUserRoleDisabled) {
|
||||||
|
this.Roles.push(item.UserTypeId)
|
||||||
|
this.user.Roles.push(item.UserTypeId)
|
||||||
|
}
|
||||||
|
this.user.UserRoleList.push({
|
||||||
|
UserTypeEnum: item.UserTypeEnum,
|
||||||
|
UserTypeId: item.UserTypeId,
|
||||||
|
IsUserRoleDisabled: item.IsUserRoleDisabled,
|
||||||
|
UserTypeShortName: item.UserTypeShortName,
|
||||||
|
})
|
||||||
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
OrgnizationTypeChanged(val) {
|
OrgnizationTypeChanged(val) {
|
||||||
this.user.OrganizationName = ''
|
this.user.OrganizationName = ''
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
var validatePassword = (rule, value, callback) => {
|
var validatePassword = (rule, value, callback) => {
|
||||||
var lang = zzSessionStorage.getItem('lang')?zzSessionStorage.getItem('lang'):'zh'
|
var lang = zzSessionStorage.getItem('lang')
|
||||||
|
? zzSessionStorage.getItem('lang')
|
||||||
|
: 'zh'
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
var reg1 = /^[a-zA-Z0-9_]{4,16}$/; //密码必须是8位以上、必须含有字母、数字、特殊符号
|
var reg1 = /^[a-zA-Z0-9_]{4,16}$/ //密码必须是8位以上、必须含有字母、数字、特殊符号
|
||||||
console.log(!reg1.test(value))
|
|
||||||
if (!reg1.test(value)) {
|
if (!reg1.test(value)) {
|
||||||
callback(lang==='zh' ? new Error("1)新建账号,用户名字符长度最小为4个字符,最大为16个字符,只可使用字母、数字、下划线;") : new Error('For a new account, the username must have:1) At least 4 characters;2) At most 16 characters;3)Only letters, numbers, and underscores are allowed.'))
|
callback(
|
||||||
|
lang === 'zh'
|
||||||
|
? new Error(
|
||||||
|
'1)新建账号,用户名字符长度最小为4个字符,最大为16个字符,只可使用字母、数字、下划线;'
|
||||||
|
)
|
||||||
|
: new Error(
|
||||||
|
'For a new account, the username must have:1) At least 4 characters;2) At most 16 characters;3)Only letters, numbers, and underscores are allowed.'
|
||||||
|
)
|
||||||
|
)
|
||||||
} else {
|
} else {
|
||||||
callback();
|
callback()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return {
|
return {
|
||||||
|
userRoleList: [],
|
||||||
|
Roles: [],
|
||||||
user: {
|
user: {
|
||||||
|
Roles: [],
|
||||||
|
UserRoleList: [],
|
||||||
UserName: '',
|
UserName: '',
|
||||||
LastName: '',
|
LastName: '',
|
||||||
FirstName: '',
|
FirstName: '',
|
||||||
@@ -194,65 +392,75 @@ export default {
|
|||||||
OrganizationName: '',
|
OrganizationName: '',
|
||||||
DepartmentName: '',
|
DepartmentName: '',
|
||||||
PositionName: '',
|
PositionName: '',
|
||||||
IsTestUser: false
|
IsTestUser: false,
|
||||||
},
|
},
|
||||||
|
visible: false,
|
||||||
userFormRules: {
|
userFormRules: {
|
||||||
UserName: [
|
UserName: [
|
||||||
{ required: true, validator: validatePassword, trigger: 'blur' }
|
{ required: true, validator: validatePassword, trigger: 'blur' },
|
||||||
],
|
],
|
||||||
UserTypeId: [
|
Roles: [
|
||||||
{ required: true, message: 'Please Select', trigger: ['blur', 'change'] }
|
{
|
||||||
|
required: true,
|
||||||
|
message: 'Please Select',
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
IsZhiZhun: [
|
IsZhiZhun: [
|
||||||
{ required: true, message: 'Please Select', trigger: ['blur', 'change'] }
|
{
|
||||||
|
required: true,
|
||||||
|
message: 'Please Select',
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
OrganizationName: [
|
OrganizationName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
],
|
],
|
||||||
LastName: [
|
LastName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' },
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
],
|
||||||
FirstName: [
|
FirstName: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' },
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
],
|
||||||
Phone: [
|
Phone: [
|
||||||
{ max: 20, min: 7, message: 'The length is 7 to 20', trigger: ['blur'] }
|
{
|
||||||
|
max: 20,
|
||||||
|
min: 7,
|
||||||
|
message: 'The length is 7 to 20',
|
||||||
|
trigger: ['blur'],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
EMail: [
|
EMail: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
message: 'Please input the email address',
|
message: 'Please input the email address',
|
||||||
trigger: 'blur'
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
type: 'email',
|
type: 'email',
|
||||||
message: 'Please input the correct email address',
|
message: 'Please input the correct email address',
|
||||||
trigger: ['blur']
|
trigger: ['blur'],
|
||||||
},
|
},
|
||||||
{ max: 50, message: 'The maximum length is 50' }
|
{ max: 50, message: 'The maximum length is 50' },
|
||||||
],
|
|
||||||
Sex: [
|
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
|
||||||
],
|
],
|
||||||
|
Sex: [{ required: true, message: 'Please specify', trigger: 'blur' }],
|
||||||
Status: [
|
Status: [
|
||||||
{ required: true, message: 'Please specify', trigger: 'blur' }
|
{ required: true, message: 'Please specify', trigger: 'blur' },
|
||||||
],
|
],
|
||||||
DepartmentName: [
|
DepartmentName: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
{ max: 50, message: 'The maximum length is 50' }],
|
PositionName: [{ max: 50, message: 'The maximum length is 50' }],
|
||||||
PositionName: [{ max: 50, message: 'The maximum length is 50' }
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
userTypeOptions: [],
|
userTypeOptions: [],
|
||||||
isDisabled: false,
|
isDisabled: false,
|
||||||
type: 0 // 1为编辑,0为新增
|
type: 0, // 1为编辑,0为新增
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
/deep/ .is-error.my_new_pwd{
|
::v-deep .is-error.my_new_pwd {
|
||||||
margin-bottom: 40px;
|
margin-bottom: 40px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -0,0 +1,212 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog
|
||||||
|
v-if="visible"
|
||||||
|
:visible.sync="visible"
|
||||||
|
v-dialogDrag
|
||||||
|
width="540px"
|
||||||
|
:close-on-click-modal="false"
|
||||||
|
:close-on-press-escape="false"
|
||||||
|
append-to-body
|
||||||
|
:title="$t('system:userlist:roleList:title')"
|
||||||
|
:before-close="cancel"
|
||||||
|
>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="primary"
|
||||||
|
@click.stop="openAdd"
|
||||||
|
style="float: right"
|
||||||
|
>
|
||||||
|
{{ $t('common:button:new') }}
|
||||||
|
</el-button>
|
||||||
|
<el-table
|
||||||
|
:data="list"
|
||||||
|
style="width: 100%"
|
||||||
|
max-height="300px"
|
||||||
|
v-loading="loading"
|
||||||
|
>
|
||||||
|
<el-table-column type="index" width="40" />
|
||||||
|
<el-table-column
|
||||||
|
prop="UserTypeShortName"
|
||||||
|
:label="$t('system:userlist:roleList:table:UserTypeShortName')"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
prop="IsUserRoleDisabled"
|
||||||
|
:label="$t('system:userlist:roleList:table:IsUserRoleDisabled')"
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span> {{ $fd('IsEnable', !scope.row.IsUserRoleDisabled) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column :label="$t('common:action:action')" min-width="120px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
:disabled="scope.row.IsUserRoleDisabled"
|
||||||
|
@click.stop="scope.row.IsUserRoleDisabled = true"
|
||||||
|
>
|
||||||
|
{{ $fd('IsEnable', false) }}
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
:disabled="!scope.row.IsUserRoleDisabled"
|
||||||
|
@click.stop="scope.row.IsUserRoleDisabled = false"
|
||||||
|
>
|
||||||
|
{{ $fd('IsEnable', true) }}
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div slot="footer">
|
||||||
|
<!-- 保存 -->
|
||||||
|
<el-button type="primary" :loading="loading" size="small" @click="save">
|
||||||
|
{{ $t('common:button:confirm') }}
|
||||||
|
</el-button>
|
||||||
|
<!-- 取消 -->
|
||||||
|
<el-button size="small" @click="cancel">
|
||||||
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
<el-dialog
|
||||||
|
v-if="addVisible"
|
||||||
|
:visible.sync="addVisible"
|
||||||
|
v-dialogDrag
|
||||||
|
:close-on-click-modal="false"
|
||||||
|
:close-on-press-escape="false"
|
||||||
|
append-to-body
|
||||||
|
width="540px"
|
||||||
|
:title="$t('system:userlist:roleList:addTitle')"
|
||||||
|
>
|
||||||
|
<el-form ref="addForm" :model="form" :rules="rule" label-width="80px">
|
||||||
|
<el-form-item :label="$t('system:userlist:table:UserType')">
|
||||||
|
<el-select
|
||||||
|
v-model="form.roles"
|
||||||
|
size="small"
|
||||||
|
placeholder=""
|
||||||
|
multiple
|
||||||
|
style="width: 100%"
|
||||||
|
>
|
||||||
|
<template v-for="item of roleList">
|
||||||
|
<el-option
|
||||||
|
:key="item.Id"
|
||||||
|
:label="item.UserType"
|
||||||
|
:value="item.Id"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer">
|
||||||
|
<!-- 保存 -->
|
||||||
|
<el-button type="primary" size="small" @click="saveAdd">
|
||||||
|
{{ $t('common:button:confirm') }}
|
||||||
|
</el-button>
|
||||||
|
<!-- 取消 -->
|
||||||
|
<el-button size="small" @click="addVisible = false">
|
||||||
|
{{ $t('common:button:cancel') }}
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { updateUserRoleInfo } from '@/api/admin.js'
|
||||||
|
export default {
|
||||||
|
name: 'roleList',
|
||||||
|
props: {
|
||||||
|
userId: { type: String, default: '' },
|
||||||
|
visible: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
list: {
|
||||||
|
type: Array,
|
||||||
|
default: () => {
|
||||||
|
return []
|
||||||
|
},
|
||||||
|
},
|
||||||
|
userTypeOptions: {
|
||||||
|
type: Array,
|
||||||
|
default: () => {
|
||||||
|
return []
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
addVisible: false,
|
||||||
|
loading: false,
|
||||||
|
form: {
|
||||||
|
roles: [],
|
||||||
|
},
|
||||||
|
rule: {
|
||||||
|
roles: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: 'Please Select',
|
||||||
|
trigger: ['blur', 'change'],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
roleList() {
|
||||||
|
let arr = this.list.map((item) => item.UserTypeId)
|
||||||
|
return this.userTypeOptions.filter(
|
||||||
|
(item) =>
|
||||||
|
!arr.includes(item.Id) && ![4, 6, 20].includes(item.UserTypeEnum)
|
||||||
|
)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
cancel() {
|
||||||
|
this.$emit('update:visible', false)
|
||||||
|
},
|
||||||
|
openAdd() {
|
||||||
|
this.form.roles = []
|
||||||
|
this.addVisible = true
|
||||||
|
},
|
||||||
|
async save() {
|
||||||
|
try {
|
||||||
|
let data = {
|
||||||
|
Id: this.userId,
|
||||||
|
UserRoleList: this.list,
|
||||||
|
}
|
||||||
|
this.loading = true
|
||||||
|
let res = await updateUserRoleInfo(data)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
this.$message.success(this.$t('common:message:updatedSuccessfully'))
|
||||||
|
this.$emit('update:visible', false)
|
||||||
|
this.$emit('getRoleList')
|
||||||
|
}
|
||||||
|
} catch (err) {
|
||||||
|
this.loading = false
|
||||||
|
console.log(err)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async saveAdd() {
|
||||||
|
try {
|
||||||
|
let validate = await this.$refs.addForm.validate()
|
||||||
|
if (!validate) return
|
||||||
|
let arr = this.userTypeOptions.filter((item) =>
|
||||||
|
this.form.roles.includes(item.Id)
|
||||||
|
)
|
||||||
|
arr.forEach((item) => {
|
||||||
|
this.list.push({
|
||||||
|
UserTypeEnum: item.UserTypeEnum,
|
||||||
|
UserTypeId: item.Id,
|
||||||
|
IsUserRoleDisabled: false,
|
||||||
|
UserTypeShortName: item.UserTypeShortName,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
this.addVisible = false
|
||||||
|
} catch (err) {
|
||||||
|
console.log(err)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
@@ -20,23 +20,49 @@
|
|||||||
:total="total"
|
:total="total"
|
||||||
@getList="getList"
|
@getList="getList"
|
||||||
@editCb="handleEditUser"
|
@editCb="handleEditUser"
|
||||||
|
@sendCb="addNewUserSendEmail"
|
||||||
@deleteCb="handleDeleteUser"
|
@deleteCb="handleDeleteUser"
|
||||||
@sortByColumn="sortByColumn"
|
@sortByColumn="sortByColumn"
|
||||||
>
|
>
|
||||||
<!-- 选择自定义slot -->
|
<!-- 选择自定义slot -->
|
||||||
<template slot="tip-slot" slot-scope="{ scope }">
|
<template slot="tip-slot" slot-scope="{ scope }">
|
||||||
<i
|
<i
|
||||||
v-if="diffTime(scope.row.LastLoginTime) >= 90"
|
v-if="
|
||||||
|
diffTime(scope.row.LastLoginTime) >= 90 &&
|
||||||
|
diffTime(scope.row.LastChangePassWordTime) >= 90
|
||||||
|
"
|
||||||
|
class="el-icon-warning"
|
||||||
|
style="color: #f56c6c"
|
||||||
|
:title="$t('system:userlist:tip:overTimeAndoverTimePassWord')"
|
||||||
|
/>
|
||||||
|
<i
|
||||||
|
v-else-if="diffTime(scope.row.LastLoginTime) >= 90"
|
||||||
class="el-icon-warning"
|
class="el-icon-warning"
|
||||||
style="color: #f56c6c"
|
style="color: #f56c6c"
|
||||||
:title="$t('system:userlist:tip:overTime')"
|
:title="$t('system:userlist:tip:overTime')"
|
||||||
/>
|
/>
|
||||||
|
<i
|
||||||
|
v-else-if="diffTime(scope.row.LastChangePassWordTime) >= 90"
|
||||||
|
class="el-icon-warning"
|
||||||
|
style="color: #f56c6c"
|
||||||
|
:title="$t('system:userlist:tip:overTimePassWord')"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template slot="genderSlot" slot-scope="{ scope }">
|
<template slot="genderSlot" slot-scope="{ scope }">
|
||||||
{{ scope.row.Sex ? 'Male' : 'Female' }}
|
{{ scope.row.Sex ? 'Male' : 'Female' }}
|
||||||
</template>
|
</template>
|
||||||
|
<template slot="UserTypeSlot" slot-scope="{ scope }">
|
||||||
|
{{
|
||||||
|
Array.isArray(scope.row.UserRoleList) &&
|
||||||
|
scope.row.UserRoleList.length > 0
|
||||||
|
? scope.row.UserRoleList.map((item) => item.UserTypeShortName).join(
|
||||||
|
', '
|
||||||
|
)
|
||||||
|
: ''
|
||||||
|
}}
|
||||||
|
</template>
|
||||||
<template slot="roleSlot" slot-scope="{ scope }">
|
<template slot="roleSlot" slot-scope="{ scope }">
|
||||||
{{ scope.row.RoleNameList.map((role) => role.RoleName).join(',') }}
|
{{ scope.row.RoleNameList.map((role) => role.RoleName).join(', ') }}
|
||||||
</template>
|
</template>
|
||||||
<template slot="isZhiZhunSlot" slot-scope="{ scope }">
|
<template slot="isZhiZhunSlot" slot-scope="{ scope }">
|
||||||
{{
|
{{
|
||||||
@@ -63,7 +89,12 @@
|
|||||||
</box-content>
|
</box-content>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getUserList, getUserTypeList, deleteSysUser } from '@/api/admin'
|
import {
|
||||||
|
getUserList,
|
||||||
|
getUserTypeList,
|
||||||
|
deleteSysUser,
|
||||||
|
addNewUserSendEmail,
|
||||||
|
} from '@/api/admin'
|
||||||
// import { searchForm, searchHandle, columns } from './list'
|
// import { searchForm, searchHandle, columns } from './list'
|
||||||
import BoxContent from '@/components/BoxContent'
|
import BoxContent from '@/components/BoxContent'
|
||||||
import SearchForm from '@/components/BaseForm/search-form'
|
import SearchForm from '@/components/BaseForm/search-form'
|
||||||
@@ -85,8 +116,12 @@ const searchDataDefault = () => {
|
|||||||
RealName: '',
|
RealName: '',
|
||||||
BeginCreateTime: '',
|
BeginCreateTime: '',
|
||||||
EndCreateTime: '',
|
EndCreateTime: '',
|
||||||
|
EndLastLoginTime: null,
|
||||||
|
EndLastChangePassWordTime: null,
|
||||||
|
BeginLastChangePassWordTime: null,
|
||||||
CreateTimeArr: [],
|
CreateTimeArr: [],
|
||||||
LastLoginTimeArr: [],
|
LastLoginTimeArr: [],
|
||||||
|
LastChangePassWordTimeArr: [],
|
||||||
SortField: 'CreateTime',
|
SortField: 'CreateTime',
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -115,7 +150,7 @@ export default {
|
|||||||
showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'RealName',
|
prop: 'FullName',
|
||||||
label: this.$t('system:userlist:table:RealName'),
|
label: this.$t('system:userlist:table:RealName'),
|
||||||
minWidth: 120,
|
minWidth: 120,
|
||||||
sortable: 'custom',
|
sortable: 'custom',
|
||||||
@@ -154,6 +189,7 @@ export default {
|
|||||||
prop: 'UserType',
|
prop: 'UserType',
|
||||||
label: this.$t('system:userlist:table:UserType'),
|
label: this.$t('system:userlist:table:UserType'),
|
||||||
minWidth: 100,
|
minWidth: 100,
|
||||||
|
slot: 'UserTypeSlot',
|
||||||
sortable: 'custom',
|
sortable: 'custom',
|
||||||
showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
},
|
},
|
||||||
@@ -191,6 +227,13 @@ export default {
|
|||||||
sortable: 'custom',
|
sortable: 'custom',
|
||||||
showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
prop: 'LastChangePassWordTime',
|
||||||
|
label: this.$t('system:userlist:table:LastChangePassWordTime'),
|
||||||
|
minWidth: 250,
|
||||||
|
sortable: 'custom',
|
||||||
|
showOverflowTooltip: true,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
prop: 'CreateTime',
|
prop: 'CreateTime',
|
||||||
label: this.$t('system:userlist:table:createTime'),
|
label: this.$t('system:userlist:table:createTime'),
|
||||||
@@ -202,12 +245,19 @@ export default {
|
|||||||
type: 'operate',
|
type: 'operate',
|
||||||
label: this.$t('common:action:action'),
|
label: this.$t('common:action:action'),
|
||||||
minWidth: 200,
|
minWidth: 200,
|
||||||
|
fixed: 'right',
|
||||||
operates: [
|
operates: [
|
||||||
{
|
{
|
||||||
name: this.$t('common:button:edit'),
|
name: this.$t('common:button:edit'),
|
||||||
type: 'primary',
|
type: 'primary',
|
||||||
emitKey: 'editCb',
|
emitKey: 'editCb',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: this.$t('common:button:email'),
|
||||||
|
type: 'primary',
|
||||||
|
emitKey: 'sendCb',
|
||||||
|
show: 'IsFirstAdd',
|
||||||
|
},
|
||||||
// {
|
// {
|
||||||
// name: this.$t('common:button:delete'),
|
// name: this.$t('common:button:delete'),
|
||||||
// type: 'danger',
|
// type: 'danger',
|
||||||
@@ -326,6 +376,13 @@ export default {
|
|||||||
width: '400px',
|
width: '400px',
|
||||||
placeholder: '',
|
placeholder: '',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
type: 'Daterange',
|
||||||
|
label: this.$t('system:userlist:label:LastChangePassWordTime'),
|
||||||
|
prop: 'LastChangePassWordTimeArr',
|
||||||
|
width: '400px',
|
||||||
|
placeholder: '',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
type: 'Daterange',
|
type: 'Daterange',
|
||||||
label: this.$t('system:userlist:label:CreateTime'),
|
label: this.$t('system:userlist:label:CreateTime'),
|
||||||
@@ -335,15 +392,17 @@ export default {
|
|||||||
},
|
},
|
||||||
],
|
],
|
||||||
searchHandle: [
|
searchHandle: [
|
||||||
{
|
|
||||||
label: this.$t('common:button:reset'),
|
|
||||||
type: 'primary',
|
|
||||||
emitKey: 'reset',
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
label: this.$t('common:button:search'),
|
label: this.$t('common:button:search'),
|
||||||
type: 'primary',
|
type: 'primary',
|
||||||
emitKey: 'search',
|
emitKey: 'search',
|
||||||
|
icon: 'el-icon-search'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: this.$t('common:button:reset'),
|
||||||
|
type: 'primary',
|
||||||
|
emitKey: 'reset',
|
||||||
|
icon: 'el-icon-refresh-left'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: this.$t('common:button:new'),
|
label: this.$t('common:button:new'),
|
||||||
@@ -365,6 +424,31 @@ export default {
|
|||||||
diffTime(time) {
|
diffTime(time) {
|
||||||
return moment(new Date()).diff(time, 'days')
|
return moment(new Date()).diff(time, 'days')
|
||||||
},
|
},
|
||||||
|
async addNewUserSendEmail(row) {
|
||||||
|
try {
|
||||||
|
let confirm = await this.$confirm(
|
||||||
|
this.$t('system:userlist:confirm:sendEmail')
|
||||||
|
)
|
||||||
|
if (!confirm) return false
|
||||||
|
let data = {
|
||||||
|
IdentityUserId: row.Id,
|
||||||
|
BaseUrl: `${location.protocol}//${location.host}/login`,
|
||||||
|
RouteUrl: `${location.protocol}//${location.host}/email-recompose`,
|
||||||
|
}
|
||||||
|
this.loading = true
|
||||||
|
let res = await addNewUserSendEmail(data)
|
||||||
|
this.loading = false
|
||||||
|
if (res.IsSuccess) {
|
||||||
|
this.$message.success(
|
||||||
|
this.$t('system:userlist:message:sendEmailSuccess')
|
||||||
|
)
|
||||||
|
this.getList()
|
||||||
|
}
|
||||||
|
} catch (err) {
|
||||||
|
this.loading = false
|
||||||
|
console.log(err)
|
||||||
|
}
|
||||||
|
},
|
||||||
// 获取用户信息
|
// 获取用户信息
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
@@ -430,6 +514,12 @@ export default {
|
|||||||
this.searchData.BeginLastLoginTime = this.searchData.LastLoginTimeArr[0]
|
this.searchData.BeginLastLoginTime = this.searchData.LastLoginTimeArr[0]
|
||||||
this.searchData.EndLastLoginTime = this.searchData.LastLoginTimeArr[1]
|
this.searchData.EndLastLoginTime = this.searchData.LastLoginTimeArr[1]
|
||||||
}
|
}
|
||||||
|
if (this.searchData.LastChangePassWordTimeArr.length > 0) {
|
||||||
|
this.searchData.BeginLastChangePassWordTime =
|
||||||
|
this.searchData.LastChangePassWordTimeArr[0]
|
||||||
|
this.searchData.EndLastChangePassWordTime =
|
||||||
|
this.searchData.LastChangePassWordTimeArr[1]
|
||||||
|
}
|
||||||
this.getList()
|
this.getList()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -71,6 +71,8 @@ export default {
|
|||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.notice-marquee_wrapper{
|
.notice-marquee_wrapper{
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
/deep/ .el-dialog__header{
|
/deep/ .el-dialog__header{
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ export default {
|
|||||||
this.$i18n.locale = lang
|
this.$i18n.locale = lang
|
||||||
this.setLanguage(lang)
|
this.setLanguage(lang)
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
console.log(Vue)
|
|
||||||
this.$upload()
|
this.$upload()
|
||||||
window.location.reload()
|
window.location.reload()
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
<img v-else src="@/assets/zzlogo4.png" alt="" />
|
<img v-else src="@/assets/zzlogo4.png" alt="" />
|
||||||
<span style="white-space: nowrap" v-if="NODE_ENV !== 'usa'">
|
<span style="white-space: nowrap" v-if="NODE_ENV !== 'usa'">
|
||||||
<!-- 中心影像系统(EICS) -->
|
<!-- 中心影像系统(EICS) -->
|
||||||
{{ $t("trials:trials:title:eics") }}
|
{{ $t('trials:trials:title:eics') }}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="center-menu">
|
<div class="center-menu">
|
||||||
@@ -39,13 +39,17 @@
|
|||||||
>
|
>
|
||||||
<i class="el-icon-odometer" />
|
<i class="el-icon-odometer" />
|
||||||
<!-- 工作台 -->
|
<!-- 工作台 -->
|
||||||
<span slot="title">{{ $t("trials:menuTitle:workbench") }}</span>
|
<span slot="title">{{ $t('trials:menuTitle:workbench') }}</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item v-if="!hasPermi(['role:zys','role:zyss','role:zybs'])" index="2" :disabled="TotalNeedSignSystemDocCount !== 0">
|
<el-menu-item
|
||||||
|
v-if="!hasPermi(['role:zys', 'role:zyss', 'role:zybs'])"
|
||||||
|
index="2"
|
||||||
|
:disabled="TotalNeedSignSystemDocCount !== 0"
|
||||||
|
>
|
||||||
<i class="el-icon-box" />
|
<i class="el-icon-box" />
|
||||||
<!-- 我的项目 -->
|
<!-- 我的项目 -->
|
||||||
<span slot="title">
|
<span slot="title">
|
||||||
{{ $t("trials:tab:trials") }}
|
{{ $t('trials:tab:trials') }}
|
||||||
</span>
|
</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item
|
<el-menu-item
|
||||||
@@ -63,7 +67,7 @@
|
|||||||
>
|
>
|
||||||
<i class="el-icon-chat-dot-square" />
|
<i class="el-icon-chat-dot-square" />
|
||||||
<!-- 通知消息 -->
|
<!-- 通知消息 -->
|
||||||
<span slot="title">{{ $t("trials:tab:notice") }}</span>
|
<span slot="title">{{ $t('trials:tab:notice') }}</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
|
|
||||||
<el-submenu index="4" class="my_info">
|
<el-submenu index="4" class="my_info">
|
||||||
@@ -75,128 +79,230 @@
|
|||||||
</span>
|
</span>
|
||||||
<!-- 账户信息 -->
|
<!-- 账户信息 -->
|
||||||
<el-menu-item v-if="!hasPermi(['role:air'])" index="4-2">{{
|
<el-menu-item v-if="!hasPermi(['role:air'])" index="4-2">{{
|
||||||
$t("trials:trials-myinfo:title:accountInfo")
|
$t('trials:trials-myinfo:title:accountInfo')
|
||||||
}}</el-menu-item>
|
}}</el-menu-item>
|
||||||
<!-- 管理后台 -->
|
<!-- 管理后台 -->
|
||||||
<el-menu-item
|
<el-menu-item
|
||||||
v-if="hasPermi(['role:dev', 'role:oa', 'role:admin'])"
|
v-if="hasPermi(['role:dev', 'role:oa', 'role:admin'])"
|
||||||
index="4-4"
|
index="4-4"
|
||||||
>{{ $t("trials:trials-myinfo:title:system") }}</el-menu-item
|
>{{ $t('trials:trials-myinfo:title:system') }}</el-menu-item
|
||||||
>
|
>
|
||||||
|
<!-- 切换角色 -->
|
||||||
|
<el-menu-item index="4-5" v-if="hasRole">{{
|
||||||
|
$t('trials:trials-myinfo:title:toggleRole')
|
||||||
|
}}</el-menu-item>
|
||||||
<!-- 退出 -->
|
<!-- 退出 -->
|
||||||
<el-menu-item index="4-3">{{
|
<el-menu-item index="4-3">{{
|
||||||
$t("trials:trials-myinfo:button:loginout")
|
$t('trials:trials-myinfo:button:loginout')
|
||||||
}}</el-menu-item>
|
}}</el-menu-item>
|
||||||
</el-submenu>
|
</el-submenu>
|
||||||
</el-menu>
|
</el-menu>
|
||||||
<TopLang v-if="VUE_APP_OSS_CONFIG_REGION !== 'oss-us-west-1'&& NODE_ENV !== 'usa'" />
|
<TopLang
|
||||||
|
v-if="
|
||||||
|
VUE_APP_OSS_CONFIG_REGION !== 'oss-us-west-1' && NODE_ENV !== 'usa'
|
||||||
|
"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
<toggleRole
|
||||||
|
v-if="toggleRoleVisible"
|
||||||
|
:visible.sync="toggleRoleVisible"
|
||||||
|
:loading="toggleRoleLoading"
|
||||||
|
@save="loginByRole"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters, mapMutations } from "vuex";
|
import { mapGetters, mapMutations } from 'vuex'
|
||||||
import TopLang from "./topLang";
|
import TopLang from './topLang'
|
||||||
import NoticeMarquee from "./noticeMarquee";
|
import NoticeMarquee from './noticeMarquee'
|
||||||
|
import { resetRouter } from '@/router'
|
||||||
|
import toggleRole from '@/components/toggleRole'
|
||||||
export default {
|
export default {
|
||||||
components: { TopLang, NoticeMarquee },
|
components: { TopLang, NoticeMarquee, toggleRole },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
activeIndex: "2",
|
activeIndex: '2',
|
||||||
isReviewer: false,
|
isReviewer: false,
|
||||||
userTypeShortName: zzSessionStorage.getItem("userTypeShortName"),
|
// userTypeShortName: zzSessionStorage.getItem('userTypeShortName'),
|
||||||
notice: "",
|
notice: '',
|
||||||
VUE_APP_OSS_CONFIG_REGION: process.env.VUE_APP_OSS_CONFIG_REGION,
|
VUE_APP_OSS_CONFIG_REGION: process.env.VUE_APP_OSS_CONFIG_REGION,
|
||||||
NODE_ENV: process.env.NODE_ENV,
|
NODE_ENV: process.env.NODE_ENV,
|
||||||
};
|
toggleRoleVisible: false,
|
||||||
|
toggleRoleLoading: false,
|
||||||
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters([
|
...mapGetters([
|
||||||
"sidebar",
|
'sidebar',
|
||||||
"name",
|
'name',
|
||||||
"userName",
|
'userName',
|
||||||
"device",
|
'device',
|
||||||
"TotalNeedSignSystemDocCount",
|
'TotalNeedSignSystemDocCount',
|
||||||
"language",
|
'language',
|
||||||
|
'userTypeShortName',
|
||||||
]),
|
]),
|
||||||
|
roles() {
|
||||||
|
return this.$store.state.user.roles
|
||||||
|
},
|
||||||
|
hasRole() {
|
||||||
|
return (
|
||||||
|
this.roles &&
|
||||||
|
this.roles.length > 1 &&
|
||||||
|
this.roles.filter((item) => !item.IsUserRoleDisabled).length > 1
|
||||||
|
)
|
||||||
|
},
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
$route(v) {
|
$route(v) {
|
||||||
this.changeRoute(v);
|
this.changeRoute(v)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
console.log(!this.hasPermi(["role:air"]));
|
// this.isReviewer = JSON.parse(zzSessionStorage.getItem('IsReviewer'))
|
||||||
this.isReviewer = JSON.parse(zzSessionStorage.getItem("IsReviewer"));
|
this.changeRoute(this.$route)
|
||||||
this.changeRoute(this.$route);
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
...mapMutations({ setLanguage: "lang/setLanguage" }),
|
...mapMutations({ setLanguage: 'lang/setLanguage' }),
|
||||||
changeRoute(v) {
|
changeRoute(v) {
|
||||||
if (v.path === "/trials/trials-workbench") {
|
if (v.path === '/trials/trials-workbench') {
|
||||||
this.activeIndex = "1";
|
this.activeIndex = '1'
|
||||||
}
|
}
|
||||||
if (
|
if (
|
||||||
v.path === "/trials/trials-list" ||
|
v.path === '/trials/trials-list' ||
|
||||||
~v.path.indexOf("/trials/trials-panel")
|
~v.path.indexOf('/trials/trials-panel')
|
||||||
) {
|
) {
|
||||||
this.activeIndex = "2";
|
this.activeIndex = '2'
|
||||||
}
|
}
|
||||||
if (v.path === "/trials/trials-notice") {
|
if (v.path === '/trials/trials-notice') {
|
||||||
this.activeIndex = "3";
|
this.activeIndex = '3'
|
||||||
}
|
}
|
||||||
if (v.path === "/trials/trials-myinfo") {
|
if (v.path === '/trials/trials-myinfo') {
|
||||||
this.activeIndex = "4-2";
|
this.activeIndex = '4-2'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleSelect(key, keyPath) {
|
handleSelect(key, keyPath) {
|
||||||
switch (key) {
|
switch (key) {
|
||||||
case "4-2":
|
case '4-2':
|
||||||
this.go("/trials/trials-myinfo");
|
this.go('/trials/trials-myinfo')
|
||||||
break;
|
break
|
||||||
case "4-3":
|
case '4-3':
|
||||||
this.logout();
|
this.logout()
|
||||||
break;
|
break
|
||||||
case "4-4":
|
case '4-4':
|
||||||
this.go("/dashboard/list");
|
this.go('/dashboard/list')
|
||||||
break;
|
break
|
||||||
case "1":
|
case '4-5':
|
||||||
this.go("/trials/trials-workbench");
|
// this.go('/dashboard/list')
|
||||||
break;
|
// console.log('切换角色')
|
||||||
case "2":
|
this.$store.dispatch('user/getUserInfo').then((res) => {
|
||||||
if (~this.$route.path.indexOf("/trials/trials-panel")) {
|
this.toggleRoleVisible = true
|
||||||
return;
|
})
|
||||||
|
|
||||||
|
break
|
||||||
|
case '1':
|
||||||
|
this.go('/trials/trials-workbench')
|
||||||
|
break
|
||||||
|
case '2':
|
||||||
|
if (~this.$route.path.indexOf('/trials/trials-panel')) {
|
||||||
|
return
|
||||||
}
|
}
|
||||||
var lastWorkbench = zzSessionStorage.getItem("lastWorkbench");
|
var lastWorkbench = zzSessionStorage.getItem('lastWorkbench')
|
||||||
if (lastWorkbench) {
|
if (lastWorkbench) {
|
||||||
this.go(lastWorkbench);
|
this.go(lastWorkbench)
|
||||||
} else {
|
} else {
|
||||||
this.go("/trials/trials-list");
|
this.go('/trials/trials-list')
|
||||||
}
|
}
|
||||||
break;
|
break
|
||||||
case "3":
|
case '3':
|
||||||
this.go("/trials/trials-notice");
|
this.go('/trials/trials-notice')
|
||||||
break;
|
break
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
toggleSideBar() {
|
toggleSideBar() {
|
||||||
this.$store.dispatch("app/toggleSideBar");
|
this.$store.dispatch('app/toggleSideBar')
|
||||||
},
|
},
|
||||||
async logout() {
|
async logout() {
|
||||||
await this.$store.dispatch("user/logout");
|
await this.$store.dispatch('user/logout')
|
||||||
this.$router.push(`/login`);
|
this.$router.push(`/login`)
|
||||||
this.$i18n.locale = "zh";
|
//this.$i18n.locale = 'zh'
|
||||||
this.setLanguage("zh");
|
//this.setLanguage('zh')
|
||||||
this.$updateDictionary();
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
go(value) {
|
go(value) {
|
||||||
this.$router.push({ path: value });
|
this.$router.push({ path: value })
|
||||||
},
|
},
|
||||||
account() {
|
account() {
|
||||||
this.$router.push({ name: "Account" });
|
this.$router.push({ name: 'Account' })
|
||||||
|
},
|
||||||
|
loginByRole(userRoleId) {
|
||||||
|
if (this.$store.state.user.userId === userRoleId) {
|
||||||
|
this.toggleRoleVisible = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
this.toggleRoleLoading = true
|
||||||
|
this.$store
|
||||||
|
.dispatch('user/loginByRole', { userRoleId })
|
||||||
|
.then((res) => {
|
||||||
|
if (res) {
|
||||||
|
this.$store
|
||||||
|
.dispatch('permission/generateRoutes')
|
||||||
|
.then(async (res) => {
|
||||||
|
if (res && res.length > 0) {
|
||||||
|
resetRouter()
|
||||||
|
await this.$store.dispatch('global/getNoticeList')
|
||||||
|
this.$router.addRoutes(res)
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
if (this.loginType === 'DevOps') {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.hasPermi(['role:radmin'])) {
|
||||||
|
this.$router.replace({ path: res[0].path })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (
|
||||||
|
this.hasPermi([
|
||||||
|
'role:air',
|
||||||
|
'role:rpm',
|
||||||
|
'role:rcrc',
|
||||||
|
'role:rir',
|
||||||
|
])
|
||||||
|
) {
|
||||||
|
history.replaceState(null, null, '/trials/trials-list')
|
||||||
|
history.go(0)
|
||||||
|
// this.$router.replace({ path: '/trials/trials-list' })
|
||||||
|
} else {
|
||||||
|
history.replaceState(null, null, '/trials/trials-workbench')
|
||||||
|
history.go(0)
|
||||||
|
// this.$router.replace({ path: '/trials/trials-workbench' })
|
||||||
|
}
|
||||||
|
this.toggleRoleVisible = false
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
this.$EventBus.$emit('reload')
|
||||||
|
// this.$nextTick(() => {
|
||||||
|
// window.location.reload()
|
||||||
|
// })
|
||||||
|
} else {
|
||||||
|
// 此账户暂未配置菜单权限,请联系管理员处理后再登录。
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
this.$message.warning(this.$t('login:message:login2'))
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch((err) => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
@@ -277,6 +383,11 @@ export default {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.right-menu {
|
||||||
|
.el-menu-item.is-active {
|
||||||
|
font-weight: bolder;
|
||||||
|
}
|
||||||
|
}
|
||||||
.center-menu {
|
.center-menu {
|
||||||
width: calc(100% - 1200px);
|
width: calc(100% - 1200px);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -788,6 +788,11 @@ export default {
|
|||||||
created() {
|
created() {
|
||||||
this.initPage()
|
this.initPage()
|
||||||
},
|
},
|
||||||
|
mounted(){
|
||||||
|
this.$EventBus.$on("reload", (data) => {
|
||||||
|
window.location.reload()
|
||||||
|
});
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
initPage() {
|
initPage() {
|
||||||
this.getList()
|
this.getList()
|
||||||
|
|||||||
@@ -108,6 +108,35 @@
|
|||||||
{{ $t('trials:trials-myinfo:button:update') }}
|
{{ $t('trials:trials-myinfo:button:update') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item
|
||||||
|
:label="$t('trials:trials-myinfo:form:toggleRole')"
|
||||||
|
style="position: relative"
|
||||||
|
prop="VerificationCode"
|
||||||
|
v-if="hasRole"
|
||||||
|
>
|
||||||
|
<el-radio-group v-model="userRoleId" class="roles" v-if="hasRole">
|
||||||
|
<el-radio
|
||||||
|
v-for="item in roles"
|
||||||
|
:key="item.Id"
|
||||||
|
:label="item.Id"
|
||||||
|
:disabled="item.IsUserRoleDisabled"
|
||||||
|
style="margin-bottom: 10px"
|
||||||
|
>
|
||||||
|
{{ item.UserTypeShortName }}
|
||||||
|
</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
<!-- 修改 -->
|
||||||
|
<el-button
|
||||||
|
:disabled="!userRoleId || saveDisabled"
|
||||||
|
class="saveBtn"
|
||||||
|
:loading="toggleRoleLoading"
|
||||||
|
type="primary"
|
||||||
|
size="small"
|
||||||
|
@click="toggleRole"
|
||||||
|
>
|
||||||
|
{{ $t('trials:trials-myinfo:button:toggleRole') }}
|
||||||
|
</el-button>
|
||||||
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<password />
|
<password />
|
||||||
@@ -142,6 +171,8 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
userForm: {},
|
userForm: {},
|
||||||
|
userRoleId: null,
|
||||||
|
toggleRoleLoading: false,
|
||||||
sendDisabled: true,
|
sendDisabled: true,
|
||||||
sendTitle: this.$t('trials:trials-myinfo:button:getVCode'),
|
sendTitle: this.$t('trials:trials-myinfo:button:getVCode'),
|
||||||
rule: {
|
rule: {
|
||||||
@@ -174,7 +205,39 @@ export default {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
this.userRoleId = zzSessionStorage.getItem('userId')
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
roles() {
|
||||||
|
return this.$store.state.user.roles
|
||||||
|
},
|
||||||
|
hasRole() {
|
||||||
|
return this.roles && this.roles.length > 1
|
||||||
|
},
|
||||||
|
saveDisabled() {
|
||||||
|
return this.userRoleId === zzSessionStorage.getItem('userId')
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 切换角色
|
||||||
|
toggleRole() {
|
||||||
|
if (
|
||||||
|
this.userRoleId === zzSessionStorage.getItem('userId') ||
|
||||||
|
this.toggleRoleLoading
|
||||||
|
)
|
||||||
|
return false
|
||||||
|
this.toggleRoleLoading = true
|
||||||
|
this.$store
|
||||||
|
.dispatch('user/loginByRole', { userRoleId: this.userRoleId })
|
||||||
|
.then((res) => {
|
||||||
|
zzSessionStorage.removeItem('lastWorkbench')
|
||||||
|
window.location.reload()
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.toggleRoleLoading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
setNewEmail() {
|
setNewEmail() {
|
||||||
setNewEmail(this.userForm.EMail, this.userForm.VerificationCode).then(
|
setNewEmail(this.userForm.EMail, this.userForm.VerificationCode).then(
|
||||||
() => {
|
() => {
|
||||||
@@ -271,10 +334,18 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
}
|
}
|
||||||
this.$i18n.locale = 'zh'
|
//this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
//this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.el-radio-group {
|
||||||
|
margin-top: 12px;
|
||||||
|
}
|
||||||
|
.el-radio {
|
||||||
|
width: 60px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -37,7 +37,7 @@
|
|||||||
:IsCanConnectInternet="IsCanConnectInternet"
|
:IsCanConnectInternet="IsCanConnectInternet"
|
||||||
v-if="activeIndex === '2'"
|
v-if="activeIndex === '2'"
|
||||||
/>
|
/>
|
||||||
<login-log v-if="activeIndex === '3'" :id="userId" :isMine="true" />
|
<login-log v-if="activeIndex === '3'" :id="identityUserId" :isMine="true" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -64,7 +64,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
...mapGetters(['userId', 'userName']),
|
...mapGetters(['identityUserId', 'userName']),
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getUserInfo()
|
this.getUserInfo()
|
||||||
@@ -107,11 +107,11 @@ export default {
|
|||||||
spinner: 'el-icon-loading',
|
spinner: 'el-icon-loading',
|
||||||
background: 'rgba(0, 0, 0, 0.07)',
|
background: 'rgba(0, 0, 0, 0.07)',
|
||||||
})
|
})
|
||||||
getUser(this.userId)
|
getUser()
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
this.user = res.Result
|
this.user = res.Result
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
zzSessionStorage.setItem('realName', this.user.RealName)
|
zzSessionStorage.setItem('Name', this.user.FullName)
|
||||||
await store.dispatch('user/updateInfo')
|
await store.dispatch('user/updateInfo')
|
||||||
loading.close()
|
loading.close()
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -82,7 +82,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { updateUser } from "@/api/admin.js";
|
import { updateUserBasicInfo } from "@/api/admin.js";
|
||||||
export default {
|
export default {
|
||||||
name: "mine",
|
name: "mine",
|
||||||
props: {
|
props: {
|
||||||
@@ -179,7 +179,7 @@ export default {
|
|||||||
// this.user.OrganizationName = 'ZhiZhun'
|
// this.user.OrganizationName = 'ZhiZhun'
|
||||||
// }
|
// }
|
||||||
if (this.user.Id) {
|
if (this.user.Id) {
|
||||||
updateUser(this.user)
|
updateUserBasicInfo(this.user)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.isDisabled = false;
|
this.isDisabled = false;
|
||||||
this.$message.success(
|
this.$message.success(
|
||||||
|
|||||||
@@ -27,6 +27,7 @@
|
|||||||
<!-- 新密码 -->
|
<!-- 新密码 -->
|
||||||
<el-form-item
|
<el-form-item
|
||||||
:label="$t('recompose:form:newPassword')"
|
:label="$t('recompose:form:newPassword')"
|
||||||
|
class="my_new_pwd"
|
||||||
prop="NewPassWord"
|
prop="NewPassWord"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
@@ -151,15 +152,15 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.$router.push(`/login`)
|
this.$router.push(`/login`)
|
||||||
}
|
}
|
||||||
this.$i18n.locale = 'zh'
|
//this.$i18n.locale = 'zh'
|
||||||
this.setLanguage('zh')
|
//this.setLanguage('zh')
|
||||||
this.$updateDictionary()
|
this.$updateDictionary()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.el-form-item {
|
::v-deep .is-error.my_new_pwd {
|
||||||
margin-bottom: 30px;
|
margin-bottom: 45px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
<el-form-item :label="$t('trials:notice:table:notificationContent')">
|
<el-form-item :label="$t('trials:notice:table:notificationContent')">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="searchData.NoticeContent"
|
v-model="searchData.NoticeContent"
|
||||||
style="width:100px;"
|
style="width: 100px"
|
||||||
clearable
|
clearable
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -36,7 +36,11 @@
|
|||||||
<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>
|
||||||
<el-button type="primary" icon="el-icon-refresh-left" @click="handleReset">
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-refresh-left"
|
||||||
|
@click="handleReset"
|
||||||
|
>
|
||||||
{{ $t('common:button:reset') }}
|
{{ $t('common:button:reset') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -44,7 +48,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<template slot="main-container">
|
<template slot="main-container">
|
||||||
<el-table
|
<el-table
|
||||||
v-adaptive="{bottomOffset:60}"
|
v-adaptive="{ bottomOffset: 60 }"
|
||||||
v-loading="loading"
|
v-loading="loading"
|
||||||
:data="list"
|
:data="list"
|
||||||
stripe
|
stripe
|
||||||
@@ -79,7 +83,15 @@
|
|||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag :type="scope.row.ActualNoticeStateEnum === 0 ? 'info' : scope.row.ActualNoticeStateEnum === 1 ? 'success' : 'error'">
|
<el-tag
|
||||||
|
:type="
|
||||||
|
scope.row.ActualNoticeStateEnum === 0
|
||||||
|
? 'info'
|
||||||
|
: scope.row.ActualNoticeStateEnum === 1
|
||||||
|
? 'success'
|
||||||
|
: 'error'
|
||||||
|
"
|
||||||
|
>
|
||||||
{{ $fd('NoticeState', scope.row.ActualNoticeStateEnum) }}
|
{{ $fd('NoticeState', scope.row.ActualNoticeStateEnum) }}
|
||||||
</el-tag>
|
</el-tag>
|
||||||
</template>
|
</template>
|
||||||
@@ -113,7 +125,12 @@
|
|||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<a :href="OSSclientConfig.basePath + scope.row.Path" target="_blank" style="color:#428bca">{{ scope.row.FileName }}</a>
|
<a
|
||||||
|
:href="OSSclientConfig.basePath + scope.row.Path"
|
||||||
|
target="_blank"
|
||||||
|
style="color: #428bca"
|
||||||
|
>{{ scope.row.FileName }}</a
|
||||||
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -124,11 +141,19 @@
|
|||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="scope.row.IsRead">{{ $fd('YesOrNo', scope.row.IsRead) }}</el-tag>
|
<el-tag v-if="scope.row.IsRead">{{
|
||||||
<el-tag v-else type="danger">{{ $fd('YesOrNo', scope.row.IsRead) }}</el-tag>
|
$fd('YesOrNo', scope.row.IsRead)
|
||||||
|
}}</el-tag>
|
||||||
|
<el-tag v-else type="danger">{{
|
||||||
|
$fd('YesOrNo', scope.row.IsRead)
|
||||||
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column :label="$t('common:action:action')" min-width="100" fixed="right">
|
<el-table-column
|
||||||
|
:label="$t('common:action:action')"
|
||||||
|
min-width="100"
|
||||||
|
fixed="right"
|
||||||
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
circle
|
circle
|
||||||
@@ -136,12 +161,17 @@
|
|||||||
icon="el-icon-info"
|
icon="el-icon-info"
|
||||||
@click="showDetail(scope.row)"
|
@click="showDetail(scope.row)"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<!-- 分页组件 -->
|
<!-- 分页组件 -->
|
||||||
<pagination class="page" :total="total" :page.sync="searchData.PageIndex" :limit.sync="searchData.PageSize" @pagination="getList" />
|
<pagination
|
||||||
|
class="page"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="searchData.PageIndex"
|
||||||
|
:limit.sync="searchData.PageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
</BaseContainer>
|
</BaseContainer>
|
||||||
</template>
|
</template>
|
||||||
@@ -157,9 +187,10 @@ const searchDataDefault = () => {
|
|||||||
ApplicableProjectEnum: null,
|
ApplicableProjectEnum: null,
|
||||||
NoticeModeEnum: null,
|
NoticeModeEnum: null,
|
||||||
NoticeStateEnum: null,
|
NoticeStateEnum: null,
|
||||||
Asc: true,
|
Asc: false,
|
||||||
|
SortField: 'PublishedTime',
|
||||||
PageIndex: 1,
|
PageIndex: 1,
|
||||||
PageSize: 20
|
PageSize: 20,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
export default {
|
export default {
|
||||||
@@ -171,7 +202,7 @@ export default {
|
|||||||
searchData: searchDataDefault(),
|
searchData: searchDataDefault(),
|
||||||
list: [],
|
list: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
loading: false
|
loading: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -180,17 +211,21 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
getUserSystemNoticeList(this.searchData).then(res => {
|
getUserSystemNoticeList(this.searchData)
|
||||||
this.loading = false
|
.then((res) => {
|
||||||
this.list = res.Result.CurrentPageData
|
this.loading = false
|
||||||
this.total = res.Result.TotalCount
|
this.list = res.Result.CurrentPageData
|
||||||
}).catch(() => { this.loading = false })
|
this.total = res.Result.TotalCount
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
},
|
},
|
||||||
showDetail(row) {
|
showDetail(row) {
|
||||||
var currentNoticeType = this.$fd('NoteType', row.NoticeTypeEnum)
|
var currentNoticeType = this.$fd('NoteType', row.NoticeTypeEnum)
|
||||||
if (row.IsRead || row.ActualNoticeStateEnum !== 1) {
|
if (row.IsRead || row.ActualNoticeStateEnum !== 1) {
|
||||||
this.$alert(row.NoticeContent, currentNoticeType, {
|
this.$alert(row.NoticeContent, currentNoticeType, {
|
||||||
showConfirmButton: false
|
showConfirmButton: false,
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
const h = this.$createElement
|
const h = this.$createElement
|
||||||
@@ -200,18 +235,22 @@ export default {
|
|||||||
beforeClose: (action, instance, done) => {
|
beforeClose: (action, instance, done) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
instance.confirmButtonLoading = true
|
instance.confirmButtonLoading = true
|
||||||
setSystemNoticeHaveRead(row.Id).then(async res => {
|
setSystemNoticeHaveRead(row.Id)
|
||||||
if (res.IsSuccess) {
|
.then(async (res) => {
|
||||||
await this.$store.dispatch('global/getNoticeList')
|
if (res.IsSuccess) {
|
||||||
this.getList()
|
await this.$store.dispatch('global/getNoticeList')
|
||||||
}
|
this.getList()
|
||||||
instance.confirmButtonLoading = false
|
}
|
||||||
done()
|
instance.confirmButtonLoading = false
|
||||||
}).catch(() => { instance.confirmButtonLoading = false })
|
done()
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
instance.confirmButtonLoading = false
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
done()
|
done()
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -237,10 +276,9 @@ export default {
|
|||||||
this.searchData.SortField = column.prop
|
this.searchData.SortField = column.prop
|
||||||
this.searchData.PageIndex = 1
|
this.searchData.PageIndex = 1
|
||||||
this.getList()
|
this.getList()
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -5,7 +5,11 @@
|
|||||||
<el-form :inline="true">
|
<el-form :inline="true">
|
||||||
<!-- 文件类型 -->
|
<!-- 文件类型 -->
|
||||||
<el-form-item :label="$t('trials:signRecords:table:fileType')">
|
<el-form-item :label="$t('trials:signRecords:table:fileType')">
|
||||||
<el-select v-model="searchData.FileTypeId" clearable style="width: 150px">
|
<el-select
|
||||||
|
v-model="searchData.FileTypeId"
|
||||||
|
clearable
|
||||||
|
style="width: 150px"
|
||||||
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of typeOptions"
|
v-for="item of typeOptions"
|
||||||
:key="item.FileTypeId"
|
:key="item.FileTypeId"
|
||||||
@@ -72,7 +76,7 @@
|
|||||||
style="width: 120px"
|
style="width: 120px"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="i of $d.YesOrNo"
|
v-for="i of $d.TrainingStatusEnum"
|
||||||
:key="'IsConfirmed' + i.label"
|
:key="'IsConfirmed' + i.label"
|
||||||
:value="i.value"
|
:value="i.value"
|
||||||
:label="i.label"
|
:label="i.label"
|
||||||
@@ -86,7 +90,7 @@
|
|||||||
style="width: 120px"
|
style="width: 120px"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="i of $d.YesOrNo"
|
v-for="i of $d.TrainingStatus"
|
||||||
:key="'IsDeleted' + i.label"
|
:key="'IsDeleted' + i.label"
|
||||||
:value="i.value"
|
:value="i.value"
|
||||||
:label="i.label"
|
:label="i.label"
|
||||||
@@ -96,7 +100,7 @@
|
|||||||
<el-form-item>
|
<el-form-item>
|
||||||
<!-- 查询 -->
|
<!-- 查询 -->
|
||||||
<el-button icon="el-icon-search" type="primary" @click="handleSearch">
|
<el-button icon="el-icon-search" type="primary" @click="handleSearch">
|
||||||
{{ $t("common:button:search") }}
|
{{ $t('common:button:search') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- 重置 -->
|
<!-- 重置 -->
|
||||||
<el-button
|
<el-button
|
||||||
@@ -104,7 +108,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
@click="handleReset"
|
@click="handleReset"
|
||||||
>
|
>
|
||||||
{{ $t("common:button:reset") }}
|
{{ $t('common:button:reset') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- 导出 -->
|
<!-- 导出 -->
|
||||||
<el-button
|
<el-button
|
||||||
@@ -113,7 +117,7 @@
|
|||||||
:loading="exportLoading"
|
:loading="exportLoading"
|
||||||
@click="handleExport"
|
@click="handleExport"
|
||||||
>
|
>
|
||||||
{{ $t("common:button:export") }}
|
{{ $t('common:button:export') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
@@ -156,10 +160,10 @@
|
|||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="scope.row.IsSystemDoc" type="primary">{{
|
<el-tag v-if="scope.row.IsSystemDoc" type="primary">{{
|
||||||
$fd("IsSystemDoc", scope.row.IsSystemDoc)
|
$fd('IsSystemDoc', scope.row.IsSystemDoc)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
<el-tag v-else type="warning">{{
|
<el-tag v-else type="warning">{{
|
||||||
$fd("IsSystemDoc", scope.row.IsSystemDoc)
|
$fd('IsSystemDoc', scope.row.IsSystemDoc)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -172,10 +176,10 @@
|
|||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
||||||
$fd("YesOrNo", scope.row.IsDeleted)
|
$fd('TrainingStatus', scope.row.IsDeleted)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
<el-tag v-else type="primary">{{
|
<el-tag v-else type="primary">{{
|
||||||
$fd("YesOrNo", scope.row.IsDeleted)
|
$fd('TrainingStatus', scope.row.IsDeleted)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -195,11 +199,11 @@
|
|||||||
sortable="custom"
|
sortable="custom"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="!scope.row.IsConfirmed" type="primary">{{
|
<el-tag v-if="scope.row.IsConfirmed" type="primary">{{
|
||||||
$fd("YesOrNo", scope.row.IsConfirmed)
|
$fd('TrainingStatusEnum', scope.row.IsConfirmed)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
<el-tag v-else type="danger">{{
|
<el-tag v-else type="danger">{{
|
||||||
$fd("YesOrNo", scope.row.IsConfirmed)
|
$fd('TrainingStatusEnum', scope.row.IsConfirmed)
|
||||||
}}</el-tag>
|
}}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -219,11 +223,19 @@
|
|||||||
/>
|
/>
|
||||||
<!-- 用户类型 -->
|
<!-- 用户类型 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UserTypeShortName"
|
prop="UserConfirmedUserTypeList"
|
||||||
:label="$t('trials:signRecords:table:userType')"
|
:label="$t('trials:signRecords:table:userType')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
>
|
||||||
/>
|
<template slot-scope="scope">
|
||||||
|
<span>{{
|
||||||
|
Array.isArray(scope.row.UserConfirmedUserTypeList) &&
|
||||||
|
scope.row.UserConfirmedUserTypeList.length > 0
|
||||||
|
? scope.row.UserConfirmedUserTypeList.join(', ')
|
||||||
|
: ''
|
||||||
|
}}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<!-- 签署时间 -->
|
<!-- 签署时间 -->
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="ConfirmTime"
|
prop="ConfirmTime"
|
||||||
@@ -283,25 +295,25 @@ import {
|
|||||||
getTrialUserSelect,
|
getTrialUserSelect,
|
||||||
getTrialUserTypeList,
|
getTrialUserTypeList,
|
||||||
getTrialDocAndSystemDocType,
|
getTrialDocAndSystemDocType,
|
||||||
} from "@/api/trials";
|
} from '@/api/trials'
|
||||||
import { pMTrainingRecordList_Export } from "@/api/export";
|
import { pMTrainingRecordList_Export } from '@/api/export'
|
||||||
import BaseContainer from "@/components/BaseContainer";
|
import BaseContainer from '@/components/BaseContainer'
|
||||||
import Pagination from "@/components/Pagination";
|
import Pagination from '@/components/Pagination'
|
||||||
import PreviewFile from "@/components/PreviewFile/index";
|
import PreviewFile from '@/components/PreviewFile/index'
|
||||||
const searchDataDefault = () => {
|
const searchDataDefault = () => {
|
||||||
return {
|
return {
|
||||||
FileTypeId: "",
|
FileTypeId: '',
|
||||||
Name: "",
|
Name: '',
|
||||||
UserId: "",
|
UserId: '',
|
||||||
UserTypeId: "",
|
UserTypeId: '',
|
||||||
PageIndex: 1,
|
PageIndex: 1,
|
||||||
PageSize: 20,
|
PageSize: 20,
|
||||||
IsConfirmed: null,
|
IsConfirmed: null,
|
||||||
IsDeleted: null,
|
IsDeleted: null,
|
||||||
};
|
}
|
||||||
};
|
}
|
||||||
export default {
|
export default {
|
||||||
name: "AttachmentsManagement",
|
name: 'AttachmentsManagement',
|
||||||
components: { BaseContainer, Pagination, PreviewFile },
|
components: { BaseContainer, Pagination, PreviewFile },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -310,99 +322,99 @@ export default {
|
|||||||
list: [],
|
list: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
currentRow: {},
|
currentRow: {},
|
||||||
currentPath: "",
|
currentPath: '',
|
||||||
currentType: "",
|
currentType: '',
|
||||||
previewVisible: false,
|
previewVisible: false,
|
||||||
userOptions: [],
|
userOptions: [],
|
||||||
userTypeOptions: [],
|
userTypeOptions: [],
|
||||||
currentUser: zzSessionStorage.getItem("userName"),
|
currentUser: zzSessionStorage.getItem('userName'),
|
||||||
typeOptions: [],
|
typeOptions: [],
|
||||||
trialId: this.$route.query.trialId,
|
trialId: this.$route.query.trialId,
|
||||||
exportLoading: false,
|
exportLoading: false,
|
||||||
};
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getTypeOptions();
|
this.getTypeOptions()
|
||||||
this.getUserSelect();
|
this.getUserSelect()
|
||||||
this.getUserType();
|
this.getUserType()
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleExport() {
|
handleExport() {
|
||||||
this.exportLoading = true;
|
this.exportLoading = true
|
||||||
pMTrainingRecordList_Export(this.searchData)
|
pMTrainingRecordList_Export(this.searchData)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
this.exportLoading = false;
|
this.exportLoading = false
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
this.exportLoading = false;
|
this.exportLoading = false
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 获取系统文件数据
|
// 获取系统文件数据
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true
|
||||||
this.searchData.TrialId = this.trialId;
|
this.searchData.TrialId = this.trialId
|
||||||
getDocumentConfirmList(this.searchData)
|
getDocumentConfirmList(this.searchData)
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
this.list = res.Result.CurrentPageData;
|
this.list = res.Result.CurrentPageData
|
||||||
this.total = res.Result.TotalCount;
|
this.total = res.Result.TotalCount
|
||||||
console.log(this.total);
|
console.log(this.total)
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
this.loading = false;
|
this.loading = false
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 获取文件类型下拉数据
|
// 获取文件类型下拉数据
|
||||||
getTypeOptions() {
|
getTypeOptions() {
|
||||||
getTrialDocAndSystemDocType(this.trialId).then((res) => {
|
getTrialDocAndSystemDocType(this.trialId).then((res) => {
|
||||||
this.typeOptions = res.Result;
|
this.typeOptions = res.Result
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 获取当前项目下参与者信息
|
// 获取当前项目下参与者信息
|
||||||
getUserSelect() {
|
getUserSelect() {
|
||||||
getTrialUserSelect(this.trialId).then((res) => {
|
getTrialUserSelect(this.trialId).then((res) => {
|
||||||
this.userOptions = res.Result;
|
this.userOptions = res.Result
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 获取用户类型下拉数据
|
// 获取用户类型下拉数据
|
||||||
getUserType() {
|
getUserType() {
|
||||||
getTrialUserTypeList().then((res) => {
|
getTrialUserTypeList().then((res) => {
|
||||||
this.userTypeOptions = res.Result;
|
this.userTypeOptions = res.Result
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 预览
|
// 预览
|
||||||
handlePreview(row) {
|
handlePreview(row) {
|
||||||
this.currentRow = { ...row };
|
this.currentRow = { ...row }
|
||||||
const { Name, FullFilePath } = row;
|
const { Name, FullFilePath } = row
|
||||||
this.currentPath = FullFilePath;
|
this.currentPath = FullFilePath
|
||||||
this.currentType = row.Name
|
this.currentType = row.Name
|
||||||
? Name.substring(Name.lastIndexOf(".") + 1).toLocaleLowerCase()
|
? Name.substring(Name.lastIndexOf('.') + 1).toLocaleLowerCase()
|
||||||
: "";
|
: ''
|
||||||
this.previewVisible = true;
|
this.previewVisible = true
|
||||||
},
|
},
|
||||||
// 重置
|
// 重置
|
||||||
handleReset() {
|
handleReset() {
|
||||||
this.searchData = searchDataDefault();
|
this.searchData = searchDataDefault()
|
||||||
this.getList();
|
this.getList()
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.AttachmentsManagement.clearSort();
|
this.$refs.AttachmentsManagement.clearSort()
|
||||||
});
|
})
|
||||||
},
|
},
|
||||||
// 查询
|
// 查询
|
||||||
handleSearch() {
|
handleSearch() {
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
// 排序
|
// 排序
|
||||||
handleSortByColumn(column) {
|
handleSortByColumn(column) {
|
||||||
if (column.order === "ascending") {
|
if (column.order === 'ascending') {
|
||||||
this.searchData.Asc = true;
|
this.searchData.Asc = true
|
||||||
} else {
|
} else {
|
||||||
this.searchData.Asc = false;
|
this.searchData.Asc = false
|
||||||
}
|
}
|
||||||
this.searchData.SortField = column.prop;
|
this.searchData.SortField = column.prop
|
||||||
this.getList();
|
this.getList()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user