Merge branch 'main' of https://gitea.frp.extimaging.com/XCKJ/irc_web into main
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
commit
7e52005dab
|
@ -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"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -104,8 +104,8 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="UpdateTime"
|
prop="CreateTime"
|
||||||
label="更新时间"
|
label="创建时间"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -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"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -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>
|
||||||
|
|
|
@ -456,7 +456,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 {
|
||||||
|
|
|
@ -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
|
||||||
|
|
|
@ -150,20 +150,32 @@
|
||||||
</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"
|
||||||
>
|
@select="handleSelect"
|
||||||
<span>
|
placeholder=""
|
||||||
{{ isEN ? item.HospitalName : item.HospitalNameCN }}
|
></el-autocomplete>
|
||||||
</span>
|
</el-form-item>
|
||||||
</el-option>
|
<el-form-item
|
||||||
</el-select>
|
:label="$t('curriculumVitae:continuingTraining:form:hospital')"
|
||||||
|
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 +295,8 @@ const defaultForm = () => {
|
||||||
Major: '',
|
Major: '',
|
||||||
MajorCN: '',
|
MajorCN: '',
|
||||||
HospitalId: null,
|
HospitalId: null,
|
||||||
|
HospitalCN: null,
|
||||||
|
Hospital: null,
|
||||||
School: '',
|
School: '',
|
||||||
SchoolCN: '',
|
SchoolCN: '',
|
||||||
City: '',
|
City: '',
|
||||||
|
@ -418,6 +432,7 @@ export default {
|
||||||
},
|
},
|
||||||
loading: false,
|
loading: false,
|
||||||
daterange: [],
|
daterange: [],
|
||||||
|
hospitalSelectList: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
@ -426,7 +441,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 +521,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
|
||||||
|
|
|
@ -209,25 +209,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 +245,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 +258,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 +269,16 @@
|
||||||
: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 +447,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 +632,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 +671,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 +745,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 +757,13 @@ export default {
|
||||||
if (this.reviewerId) {
|
if (this.reviewerId) {
|
||||||
this.form.Id = this.reviewerId
|
this.form.Id = this.reviewerId
|
||||||
}
|
}
|
||||||
|
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 +783,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
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<box-content style="height: 100%;background: #fff;">
|
<box-content style="height: 100%; background: #fff">
|
||||||
<!-- 搜索框 -->
|
<!-- 搜索框 -->
|
||||||
<div class="search">
|
<div class="search">
|
||||||
<el-form :inline="true" class="base-search-form">
|
<el-form :inline="true" class="base-search-form">
|
||||||
|
@ -8,7 +8,7 @@
|
||||||
<el-select
|
<el-select
|
||||||
v-model="searchData.FileTypeId"
|
v-model="searchData.FileTypeId"
|
||||||
clearable
|
clearable
|
||||||
style="width:150px;"
|
style="width: 150px"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of $d.Trial_Document"
|
v-for="item of $d.Trial_Document"
|
||||||
|
@ -20,14 +20,14 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 文件名称 -->
|
<!-- 文件名称 -->
|
||||||
<el-form-item :label="$t('trials:attachment:table:fileName')">
|
<el-form-item :label="$t('trials:attachment:table:fileName')">
|
||||||
<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 :label="$t('trials:attachment:table:isDeleted')">
|
<el-form-item :label="$t('trials:attachment:table:isDeleted')">
|
||||||
<el-select
|
<el-select
|
||||||
clearable
|
clearable
|
||||||
v-model="searchData.IsDeleted"
|
v-model="searchData.IsDeleted"
|
||||||
style="width:150px;"
|
style="width: 150px"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of $d.TrainingStatus"
|
v-for="item of $d.TrainingStatus"
|
||||||
|
@ -42,11 +42,18 @@
|
||||||
<el-select
|
<el-select
|
||||||
v-model="searchData.UserTypeId"
|
v-model="searchData.UserTypeId"
|
||||||
clearable
|
clearable
|
||||||
style="width:100%;"
|
style="width: 100%"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item of userTypeOptions"
|
v-for="item of userTypeOptions"
|
||||||
v-show="item.UserTypeEnum !== 1 && item.UserTypeEnum !== 8 && item.UserTypeEnum !== 20 && item.UserTypeEnum !== 26 && item.UserTypeEnum !== 27 && item.UserTypeEnum !== 31"
|
v-show="
|
||||||
|
item.UserTypeEnum !== 1 &&
|
||||||
|
item.UserTypeEnum !== 8 &&
|
||||||
|
item.UserTypeEnum !== 20 &&
|
||||||
|
item.UserTypeEnum !== 26 &&
|
||||||
|
item.UserTypeEnum !== 27 &&
|
||||||
|
item.UserTypeEnum !== 31
|
||||||
|
"
|
||||||
:key="item.Id"
|
:key="item.Id"
|
||||||
:label="item.UserTypeShortName"
|
:label="item.UserTypeShortName"
|
||||||
:value="item.Id"
|
:value="item.Id"
|
||||||
|
@ -56,19 +63,22 @@
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<!-- 查询 -->
|
<!-- 查询 -->
|
||||||
<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>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span style="margin-left:auto;">
|
<span style="margin-left: auto">
|
||||||
<!-- 新增 -->
|
<!-- 新增 -->
|
||||||
<el-button
|
<el-button
|
||||||
v-hasPermi="['trials:trials-panel:setting:attachment:add']"
|
v-hasPermi="['trials:trials-panel:setting:attachment:add']"
|
||||||
|
@ -85,7 +95,7 @@
|
||||||
<el-table
|
<el-table
|
||||||
ref="attachmentList"
|
ref="attachmentList"
|
||||||
v-loading="loading"
|
v-loading="loading"
|
||||||
v-adaptive="{bottomOffset:60}"
|
v-adaptive="{ bottomOffset: 60 }"
|
||||||
:data="list"
|
:data="list"
|
||||||
stripe
|
stripe
|
||||||
height="100"
|
height="100"
|
||||||
|
@ -125,8 +135,12 @@
|
||||||
min-width="100"
|
min-width="100"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="scope.row.IsDeleted" type="danger">{{ $fd('TrainingStatus', !scope.row.IsDeleted) }}</el-tag>
|
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
||||||
<el-tag v-else type="primary">{{ $fd('TrainingStatus', !scope.row.IsDeleted) }}</el-tag>
|
$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>
|
||||||
<!-- 需要签署的用户类型 -->
|
<!-- 需要签署的用户类型 -->
|
||||||
|
@ -137,7 +151,11 @@
|
||||||
min-width="100"
|
min-width="100"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.NeedConfirmedUserTypes?scope.row.NeedConfirmedUserTypes.join(', '):'' }}
|
{{
|
||||||
|
scope.row.NeedConfirmedUserTypes
|
||||||
|
? scope.row.NeedConfirmedUserTypes.join(', ')
|
||||||
|
: ''
|
||||||
|
}}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- 描述 -->
|
<!-- 描述 -->
|
||||||
|
@ -148,14 +166,21 @@
|
||||||
min-width="300"
|
min-width="300"
|
||||||
/> -->
|
/> -->
|
||||||
<!-- 更新时间 -->
|
<!-- 更新时间 -->
|
||||||
<el-table-column
|
<!-- <el-table-column
|
||||||
prop="UpdateTime"
|
prop="UpdateTime"
|
||||||
:label="$t('trials:attachment:table:updateTime')"
|
:label="$t('trials:attachment:table:updateTime')"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
sortable="custom"
|
sortable="custom"
|
||||||
min-width="160"
|
min-width="160"
|
||||||
|
/> -->
|
||||||
|
<!--创建时间-->
|
||||||
|
<el-table-column
|
||||||
|
prop="CreateTime"
|
||||||
|
:label="$t('trials:attachment:table:CreateTime')"
|
||||||
|
show-overflow-tooltip
|
||||||
|
sortable="custom"
|
||||||
|
min-width="160"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
:label="$t('common:action:action')"
|
:label="$t('common:action:action')"
|
||||||
min-width="140"
|
min-width="140"
|
||||||
|
@ -192,7 +217,13 @@
|
||||||
</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"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 新增/编辑 -->
|
<!-- 新增/编辑 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
|
@ -203,7 +234,11 @@
|
||||||
width="800px"
|
width="800px"
|
||||||
custom-class="base-dialog-wrapper"
|
custom-class="base-dialog-wrapper"
|
||||||
>
|
>
|
||||||
<AttachmentForm :data="currentRow" @closeDialog="closeDialog" @getList="getList" />
|
<AttachmentForm
|
||||||
|
:data="currentRow"
|
||||||
|
@closeDialog="closeDialog"
|
||||||
|
@getList="getList"
|
||||||
|
/>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
<!-- 预览文件 -->
|
<!-- 预览文件 -->
|
||||||
|
@ -215,16 +250,25 @@
|
||||||
append-to-body
|
append-to-body
|
||||||
custom-class="base-dialog-wrapper"
|
custom-class="base-dialog-wrapper"
|
||||||
>
|
>
|
||||||
<div class="base-modal-body" style="border:2px solid #ccc;padding: 10px">
|
<div
|
||||||
<PreviewFile v-if="previewVisible" :file-path="currentPath" :file-type="currentType" />
|
class="base-modal-body"
|
||||||
|
style="border: 2px solid #ccc; padding: 10px"
|
||||||
|
>
|
||||||
|
<PreviewFile
|
||||||
|
v-if="previewVisible"
|
||||||
|
:file-path="currentPath"
|
||||||
|
:file-type="currentType"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</box-content>
|
</box-content>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
import {
|
||||||
import { getTrialDocumentList, userAbandonDoc, getTrialUserTypeList } from '@/api/trials'
|
getTrialDocumentList,
|
||||||
|
userAbandonDoc,
|
||||||
|
getTrialUserTypeList,
|
||||||
|
} from '@/api/trials'
|
||||||
import BoxContent from '@/components/BoxContent'
|
import BoxContent from '@/components/BoxContent'
|
||||||
import Pagination from '@/components/Pagination'
|
import Pagination from '@/components/Pagination'
|
||||||
import AttachmentForm from './components/attachmentForm'
|
import AttachmentForm from './components/attachmentForm'
|
||||||
|
@ -238,7 +282,7 @@ const searchDataDefault = () => {
|
||||||
SortField: '',
|
SortField: '',
|
||||||
Asc: false,
|
Asc: false,
|
||||||
IsDeleted: null,
|
IsDeleted: null,
|
||||||
UserTypeId: null
|
UserTypeId: null,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
export default {
|
export default {
|
||||||
|
@ -258,7 +302,7 @@ export default {
|
||||||
currentPath: '',
|
currentPath: '',
|
||||||
currentType: '',
|
currentType: '',
|
||||||
trialId: '',
|
trialId: '',
|
||||||
userTypeOptions: []
|
userTypeOptions: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
@ -271,31 +315,38 @@ export default {
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
this.searchData.TrialId = this.trialId
|
this.searchData.TrialId = this.trialId
|
||||||
getTrialDocumentList(this.searchData).then(res => {
|
getTrialDocumentList(this.searchData)
|
||||||
this.loading = false
|
.then((res) => {
|
||||||
const { CurrentPageData, TotalCount } = res.Result
|
this.loading = false
|
||||||
CurrentPageData.forEach(item => {
|
const { CurrentPageData, TotalCount } = res.Result
|
||||||
item.NeedConfirmedUserTypes = []
|
CurrentPageData.forEach((item) => {
|
||||||
item.NeedConfirmedUserTypeeIds = []
|
item.NeedConfirmedUserTypes = []
|
||||||
item.NeedConfirmedUserTypeList.forEach((i) => {
|
item.NeedConfirmedUserTypeeIds = []
|
||||||
item.NeedConfirmedUserTypes.push(i.UserTypeShortName)
|
item.NeedConfirmedUserTypeList.forEach((i) => {
|
||||||
item.NeedConfirmedUserTypeeIds.push(i.NeedConfirmUserTypeId)
|
item.NeedConfirmedUserTypes.push(i.UserTypeShortName)
|
||||||
|
item.NeedConfirmedUserTypeeIds.push(i.NeedConfirmUserTypeId)
|
||||||
|
})
|
||||||
})
|
})
|
||||||
|
this.list = CurrentPageData
|
||||||
|
this.total = TotalCount
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.loading = false
|
||||||
})
|
})
|
||||||
this.list = CurrentPageData
|
|
||||||
this.total = TotalCount
|
|
||||||
}).catch(() => {
|
|
||||||
this.loading = false
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 获取用户类型下拉数据
|
// 获取用户类型下拉数据
|
||||||
getUserType() {
|
getUserType() {
|
||||||
getTrialUserTypeList().then(res => {
|
getTrialUserTypeList()
|
||||||
this.userTypeOptions = res.Result
|
.then((res) => {
|
||||||
if (this.form.Id) {
|
this.userTypeOptions = res.Result
|
||||||
this.form.NeedConfirmedUserTypeIdList = this.data.NeedConfirmedUserTypeeIds
|
if (this.form.Id) {
|
||||||
}
|
this.form.NeedConfirmedUserTypeIdList =
|
||||||
}).catch(() => { this.loading = false })
|
this.data.NeedConfirmedUserTypeeIds
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
},
|
},
|
||||||
// 新增
|
// 新增
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
|
@ -307,7 +358,9 @@ export default {
|
||||||
handlePreview(row) {
|
handlePreview(row) {
|
||||||
const { Name, FullFilePath } = row
|
const { Name, FullFilePath } = row
|
||||||
this.currentPath = FullFilePath
|
this.currentPath = FullFilePath
|
||||||
this.currentType = row.Name ? Name.substring(Name.lastIndexOf('.') + 1).toLocaleLowerCase() : ''
|
this.currentType = row.Name
|
||||||
|
? Name.substring(Name.lastIndexOf('.') + 1).toLocaleLowerCase()
|
||||||
|
: ''
|
||||||
this.previewVisible = true
|
this.previewVisible = true
|
||||||
},
|
},
|
||||||
// 编辑
|
// 编辑
|
||||||
|
@ -320,19 +373,25 @@ export default {
|
||||||
handleRepeal(row) {
|
handleRepeal(row) {
|
||||||
this.$confirm(this.$t('trials:attachment:message:abolish'), {
|
this.$confirm(this.$t('trials:attachment:message:abolish'), {
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
distinguishCancelAndClose: true
|
distinguishCancelAndClose: true,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
userAbandonDoc(row.Id, false)
|
userAbandonDoc(row.Id, false)
|
||||||
.then(res => {
|
.then((res) => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
if (res.IsSuccess) {
|
if (res.IsSuccess) {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.$message.success(this.$t('trials:trials-list:message:abolitionSuccessfully'))
|
this.$message.success(
|
||||||
|
this.$t('trials:trials-list:message:abolitionSuccessfully')
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}).catch(() => { this.loading = false })
|
})
|
||||||
}).catch(() => {})
|
.catch(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
})
|
||||||
|
.catch(() => {})
|
||||||
},
|
},
|
||||||
// 关闭编辑弹窗
|
// 关闭编辑弹窗
|
||||||
closeDialog() {
|
closeDialog() {
|
||||||
|
@ -361,7 +420,7 @@ 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>
|
||||||
|
|
Loading…
Reference in New Issue