中心列表展示字段变更
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
11b1e92488
commit
4c98f91677
|
@ -5,7 +5,7 @@
|
|||
<el-form-item :label="$t('trials:site:table:siteId')">
|
||||
<el-input
|
||||
v-model="searchData.TrialSiteCode"
|
||||
style="width:130px;"
|
||||
style="width: 130px"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
|
@ -13,7 +13,7 @@
|
|||
<el-form-item :label="$t('trials:site:table:site')">
|
||||
<el-input
|
||||
v-model="searchData.SiteName"
|
||||
style="width:130px;"
|
||||
style="width: 130px"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
|
@ -21,7 +21,7 @@
|
|||
<el-form-item :label="$t('trials:site:table:staff')">
|
||||
<el-input
|
||||
v-model="searchData.UserKeyInfo"
|
||||
style="width:130px;"
|
||||
style="width: 130px"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
|
@ -29,11 +29,15 @@
|
|||
<el-form-item>
|
||||
<!-- 查询 -->
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleSearch">
|
||||
{{ $t('common:button:search') }}
|
||||
{{ $t("common:button:search") }}
|
||||
</el-button>
|
||||
<!-- 重置 -->
|
||||
<el-button type="primary" icon="el-icon-refresh-left" @click="handleReset">
|
||||
{{ $t('common:button:reset') }}
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="el-icon-refresh-left"
|
||||
@click="handleReset"
|
||||
>
|
||||
{{ $t("common:button:reset") }}
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
@ -58,25 +62,17 @@
|
|||
/>
|
||||
<!-- 中心名称 -->
|
||||
<el-table-column
|
||||
prop="TrialSiteAliasName"
|
||||
prop="TrialSiteName"
|
||||
min-width="100"
|
||||
:label="$t('trials:site:table:site')"
|
||||
show-overflow-tooltip
|
||||
sortable="custom"
|
||||
/>
|
||||
<!-- City -->
|
||||
<!-- 中心别名 -->
|
||||
<el-table-column
|
||||
prop="City"
|
||||
prop="TrialSiteAliasName"
|
||||
min-width="100"
|
||||
:label="$t('trials:site:table:city')"
|
||||
show-overflow-tooltip
|
||||
sortable="custom"
|
||||
/>
|
||||
<!-- Country -->
|
||||
<el-table-column
|
||||
prop="Country"
|
||||
min-width="100"
|
||||
:label="$t('trials:site:table:country')"
|
||||
:label="$t('trials:site:table:TrialSiteAliasName')"
|
||||
show-overflow-tooltip
|
||||
sortable="custom"
|
||||
/>
|
||||
|
@ -105,14 +101,28 @@
|
|||
sortable="custom"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button v-if="scope.row.UserCount > 0" type="text" @click="getStaffList(scope.row)">
|
||||
{{ scope.row.UserNameList.length>0 ? scope.row.UserNameList.join(', ') :'' }}
|
||||
<el-button
|
||||
v-if="scope.row.UserCount > 0"
|
||||
type="text"
|
||||
@click="getStaffList(scope.row)"
|
||||
>
|
||||
{{
|
||||
scope.row.UserNameList.length > 0
|
||||
? scope.row.UserNameList.join(", ")
|
||||
: ""
|
||||
}}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</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>
|
||||
<base-model v-if="crc_model.visible" :config="crc_model">
|
||||
<template slot="dialog-body">
|
||||
|
@ -153,8 +163,12 @@
|
|||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.IsDeleted" type="danger">{{ $fd('IsUserExitTrial', scope.row.IsDeleted) }}</el-tag>
|
||||
<el-tag v-else>{{ $fd('IsUserExitTrial', scope.row.IsDeleted) }}</el-tag>
|
||||
<el-tag v-if="scope.row.IsDeleted" type="danger">{{
|
||||
$fd("IsUserExitTrial", scope.row.IsDeleted)
|
||||
}}</el-tag>
|
||||
<el-tag v-else>{{
|
||||
$fd("IsUserExitTrial", scope.row.IsDeleted)
|
||||
}}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 授权时间 -->
|
||||
|
@ -173,30 +187,29 @@
|
|||
sortable
|
||||
min-width="150"
|
||||
/>
|
||||
|
||||
</el-table>
|
||||
</template>
|
||||
</base-model>
|
||||
</BaseContainer>
|
||||
</template>
|
||||
<script>
|
||||
import { getSiteCRCList, getTrialSiteCRCList } from '@/api/trials'
|
||||
import BaseContainer from '@/components/BaseContainer'
|
||||
import BaseModel from '@/components/BaseModel'
|
||||
import Pagination from '@/components/Pagination'
|
||||
import { getSiteCRCList, getTrialSiteCRCList } from "@/api/trials";
|
||||
import BaseContainer from "@/components/BaseContainer";
|
||||
import BaseModel from "@/components/BaseModel";
|
||||
import Pagination from "@/components/Pagination";
|
||||
const searchDataDefault = () => {
|
||||
return {
|
||||
UserRealName: '',
|
||||
SiteName: '',
|
||||
SortField: 'TrialSiteCode',
|
||||
UserRealName: "",
|
||||
SiteName: "",
|
||||
SortField: "TrialSiteCode",
|
||||
Asc: true,
|
||||
PageIndex: 1,
|
||||
PageSize: 20,
|
||||
TrialSiteCode: null
|
||||
}
|
||||
}
|
||||
TrialSiteCode: null,
|
||||
};
|
||||
};
|
||||
export default {
|
||||
name: 'SiteList',
|
||||
name: "SiteList",
|
||||
components: { BaseContainer, BaseModel, Pagination },
|
||||
data() {
|
||||
return {
|
||||
|
@ -204,55 +217,67 @@ export default {
|
|||
list: [],
|
||||
total: 0,
|
||||
loading: false,
|
||||
crc_model: { visible: false, title: this.$t('trials:site:dialogTitle:staff'), width: '60%' },
|
||||
userListLoading: '',
|
||||
crc_model: {
|
||||
visible: false,
|
||||
title: this.$t("trials:site:dialogTitle:staff"),
|
||||
width: "60%",
|
||||
},
|
||||
userListLoading: "",
|
||||
userList: [],
|
||||
trialId: ''
|
||||
}
|
||||
trialId: "",
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.trialId = this.$route.query.trialId
|
||||
this.trialId = this.$route.query.trialId;
|
||||
|
||||
this.getList()
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.loading = true
|
||||
this.searchData.TrialId = this.trialId
|
||||
getSiteCRCList(this.searchData).then(res => {
|
||||
this.loading = false
|
||||
this.list = res.Result.CurrentPageData
|
||||
this.total = res.Result.TotalCount
|
||||
}).catch(() => { this.loading = false })
|
||||
this.loading = true;
|
||||
this.searchData.TrialId = this.trialId;
|
||||
getSiteCRCList(this.searchData)
|
||||
.then((res) => {
|
||||
this.loading = false;
|
||||
this.list = res.Result.CurrentPageData;
|
||||
this.total = res.Result.TotalCount;
|
||||
})
|
||||
.catch(() => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
getStaffList(row) {
|
||||
this.currentRow = { ...row }
|
||||
this.crc_model.visible = true
|
||||
this.userListLoading = true
|
||||
getTrialSiteCRCList(this.trialId, this.currentRow.SiteId).then(res => {
|
||||
this.userListLoading = false
|
||||
this.userList = res.Result
|
||||
}).catch(() => { this.userListLoading = false })
|
||||
this.currentRow = { ...row };
|
||||
this.crc_model.visible = true;
|
||||
this.userListLoading = true;
|
||||
getTrialSiteCRCList(this.trialId, this.currentRow.SiteId)
|
||||
.then((res) => {
|
||||
this.userListLoading = false;
|
||||
this.userList = res.Result;
|
||||
})
|
||||
.catch(() => {
|
||||
this.userListLoading = false;
|
||||
});
|
||||
},
|
||||
handleSearch() {
|
||||
this.searchData.PageIndex = 1
|
||||
this.getList()
|
||||
this.searchData.PageIndex = 1;
|
||||
this.getList();
|
||||
},
|
||||
handleReset() {
|
||||
this.searchData = searchDataDefault()
|
||||
this.getList()
|
||||
this.searchData = searchDataDefault();
|
||||
this.getList();
|
||||
},
|
||||
// 排序
|
||||
handleSortChange(column) {
|
||||
if (column.order === 'ascending') {
|
||||
this.searchData.Asc = true
|
||||
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.searchData.Asc = false;
|
||||
}
|
||||
this.searchData.SortField = column.prop;
|
||||
this.searchData.PageIndex = 1;
|
||||
this.getList();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue