Commit 5c0f6e5d authored by 刘予佳's avatar 刘予佳

详情随访接口 表格样式

parent 1fb9382e
...@@ -30,10 +30,15 @@ export function getFollowUncheck(params = {}) { ...@@ -30,10 +30,15 @@ export function getFollowUncheck(params = {}) {
}); });
} }
//随访病例待审核(详情数据) //随访病例待审核(详情数据)
export function getFollowUnCheckDetail(params = {}) { export function getFollowUnCheckDetail(id) {
return request({ return request({
url: "/disease-data/dataCheck/follow/unCheck/detail/", url: `/disease-data/dataCheck/follow/unCheck/detail/${id}`,
method: "get", method: "get",
params,
}); });
} }
\ No newline at end of file // export function getHproleDetail(id) {
// return request({
// url: `/cloud-upms//sys/role/${id}`,
// method: "get",
// })
// }
\ No newline at end of file
...@@ -34,16 +34,9 @@ ...@@ -34,16 +34,9 @@
</template> </template>
<!-- 表内容插槽 --> <!-- 表内容插槽 -->
<template slot-scope="scope"> <template slot-scope="scope">
<!-- 转化文字 --> <span :style="{ fontSize: fontSize + 'px' }">
<span <span>{{scope.row[column.value]|| "--"}}</span>
:style="{ fontSize: fontSize + 'px' }" </span>
v-if="column.transList"
>{{column.transList[scope.row[String(column.value)]]|| "--"}}</span>
<!-- 一般情况 -->
<span
:style="{ fontSize: fontSize + 'px' }"
v-else
>{{ String(scope.row[column.value]|| "--") }}</span>
</template> </template>
</el-table-column> </el-table-column>
</template> </template>
......
This diff is collapsed.
<template> <template>
<span v-if="themeBar"> <span v-if="themeBar">
<vab-icon <vab-icon title="主题配置" :icon="['fas', 'palette']" @click="handleChangeTheme" />
title="主题配置"
:icon="['fas', 'palette']"
@click="handleChangeTheme"
/>
<div class="theme-bar-setting"> <div class="theme-bar-setting">
<div @click="handleChangeTheme"> <div @click="handleChangeTheme">
<vab-icon :icon="['fas', 'palette']" /> <vab-icon :icon="['fas', 'palette']" />
...@@ -86,11 +82,7 @@ ...@@ -86,11 +82,7 @@
></el-color-picker> ></el-color-picker>
</el-form-item> </el-form-item>
<el-form-item label="菜单文字色"> <el-form-item label="菜单文字色">
<el-color-picker <el-color-picker v-model="theme.menuColor" :predefine="['#000', '#fff']" show-alpha></el-color-picker>
v-model="theme.menuColor"
:predefine="['#000', '#fff']"
show-alpha
></el-color-picker>
</el-form-item> </el-form-item>
<el-form-item label="标签主题色"> <el-form-item label="标签主题色">
<el-color-picker <el-color-picker
...@@ -115,13 +107,11 @@ ...@@ -115,13 +107,11 @@
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button @click="handleSetDfaultTheme">恢复默认</el-button> <el-button @click="handleSetDfaultTheme">恢复默认</el-button>
<el-button type="primary" @click="handleSaveTheme" <el-button type="primary" @click="handleSaveTheme">保存</el-button>
>保存</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div></el-scrollbar </div>
> </el-scrollbar>
</el-drawer> </el-drawer>
</span> </span>
</template> </template>
......
...@@ -32,6 +32,7 @@ const actions = { ...@@ -32,6 +32,7 @@ const actions = {
newDictSet.push(v.type) newDictSet.push(v.type)
} }
}) })
console.log('执行getDictData', commit, state)
commit("setDictSet", latestDict) commit("setDictSet", latestDict)
newDictSet = Object.keys(dictMap).length === 0 ? latestDictSet : newDictSet newDictSet = Object.keys(dictMap).length === 0 ? latestDictSet : newDictSet
// 存在新增加的字典 // 存在新增加的字典
...@@ -56,10 +57,12 @@ const actions = { ...@@ -56,10 +57,12 @@ const actions = {
}, },
// 更新字典分类 // 更新字典分类
async updateDictType({ commit, state }, data) { async updateDictType({ commit, state }, data) {
console.log('执行updateDictType')
commit("setDictSet", data) commit("setDictSet", data)
}, },
// 更新字典详情 // 更新字典详情
async updateDictDetail({ commit, state }, { type, data }) { async updateDictDetail({ commit, state }, { type, data }) {
console.log('执行updateDictDetail')
const dictMap = state.dictMap const dictMap = state.dictMap
if (type) { if (type) {
const list = data.map((item) => { const list = data.map((item) => {
......
...@@ -213,7 +213,19 @@ html { ...@@ -213,7 +213,19 @@ html {
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
} }
.is-background{
button,.el-pager li{
border-radius: 6px !important;
}
button,.el-pager li:not(.active){
border: 1px solid #D9D9D9;
background: transparent !important;
}
.el-input__inner{
border-radius: 6px !important;
}
}
/* 分页结束 */ /* 分页结束 */
/* 菜单开始 */ /* 菜单开始 */
......
...@@ -153,7 +153,7 @@ export function getInfoByIdCard(idCard, type = "birthDate") { ...@@ -153,7 +153,7 @@ export function getInfoByIdCard(idCard, type = "birthDate") {
d.getFullYear() - d.getFullYear() -
birthdays.getFullYear() - birthdays.getFullYear() -
(d.getMonth() < birthdays.getMonth() || (d.getMonth() < birthdays.getMonth() ||
(d.getMonth() == birthdays.getMonth() && d.getDate() < birthdays.getDate()) (d.getMonth() == birthdays.getMonth() && d.getDate() < birthdays.getDate())
? 1 ? 1
: 0) : 0)
...@@ -182,12 +182,12 @@ export function paramObj(url) { ...@@ -182,12 +182,12 @@ export function paramObj(url) {
} }
return JSON.parse( return JSON.parse(
'{"' + '{"' +
decodeURIComponent(search) decodeURIComponent(search)
.replace(/"/g, '\\"') .replace(/"/g, '\\"')
.replace(/&/g, '","') .replace(/&/g, '","')
.replace(/=/g, '":"') .replace(/=/g, '":"')
.replace(/\+/g, " ") + .replace(/\+/g, " ") +
'"}' '"}'
) )
} }
...@@ -471,7 +471,7 @@ export function formatDicList(list, value, connector = ",") { ...@@ -471,7 +471,7 @@ export function formatDicList(list, value, connector = ",") {
if (!list) return "" if (!list) return ""
if (list.constructor !== Array) return "" if (list.constructor !== Array) return ""
// if (!value && value != 0) return "" // if (!value && value != 0) return ""
let result = "" let result = "--"
let multiple = Array.isArray(value) ? true : false let multiple = Array.isArray(value) ? true : false
if (multiple) { if (multiple) {
const resultList = [] const resultList = []
...@@ -489,6 +489,7 @@ export function formatDicList(list, value, connector = ",") { ...@@ -489,6 +489,7 @@ export function formatDicList(list, value, connector = ",") {
} }
}) })
} }
console.log('字典', list, value, result)
return result return result
} }
/** /**
...@@ -522,7 +523,7 @@ export function changeTime(time) { ...@@ -522,7 +523,7 @@ export function changeTime(time) {
let seconds = Math.floor(time % 60) //秒 let seconds = Math.floor(time % 60) //秒
return `${day ? day + "" : ""} ${hours ? hours + "小时" : ""}${ return `${day ? day + "" : ""} ${hours ? hours + "小时" : ""}${
minutes ? minutes + "" : "" minutes ? minutes + "" : ""
}${seconds}秒` }${seconds}秒`
} }
export default { formatDicList, excelExport } export default { formatDicList, excelExport }
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
<script> <script>
import publicDialog from "./components/publicDialog.vue" import publicDialog from "./components/publicDialog.vue"
import screenReview from "./components/screenReview.vue" import screenReview from "./components/screenReview.vue"
import { getFollowUnCheckDetail } from "@/api/followup"
export default { export default {
components: { publicDialog, screenReview }, components: { publicDialog, screenReview },
data() { data() {
...@@ -128,13 +128,8 @@ export default { ...@@ -128,13 +128,8 @@ export default {
} }
}, },
watch: {}, watch: {},
computed:{
unionId(){
return this.$route.query.id
}
},
mounted() { mounted() {
this.getDetail()
}, },
methods: { methods: {
showDialog(val) { showDialog(val) {
...@@ -200,20 +195,7 @@ export default { ...@@ -200,20 +195,7 @@ export default {
nextExample() { nextExample() {
this.onCancel() this.onCancel()
}, },
async getDetail(){
this.loading = true
let params={
unionId:this.unionId,
}
let res = await getFollowUnCheckDetail(params)
if(res.code==1){
//分页内容
// const d = res.data
// this.total= d.total
// this.tableData=d['records']
}
this.loading = false
},
}, },
} }
</script> </script>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
</div> </div>
</div> </div>
<div class="bot-table"> <div class="bot-table">
<customs-table <el-table-self
ref="table" ref="table"
:table-data="tableData" :table-data="tableData"
:columns="columns" :columns="columns"
...@@ -70,15 +70,17 @@ export default { ...@@ -70,15 +70,17 @@ export default {
sessionStorage.setItem('audit-status',val) sessionStorage.setItem('audit-status',val)
switch (this.type) { switch (this.type) {
case "1": case "1":
this.getFollowupList() this.handleSearch()
break break
} }
console.log('status',val)
}, },
type(val) { type(val) {
console.log('type',val)
sessionStorage.setItem('audit-type',val) sessionStorage.setItem('audit-type',val)
switch (val) { switch (val) {
case "1": case "1":
this.getFollowupList() this.handleSearch()
break break
} }
}, },
...@@ -180,9 +182,13 @@ export default { ...@@ -180,9 +182,13 @@ export default {
} }
}, },
mounted() { mounted() {
if(sessionStorage.getItem('audit-status') || sessionStorage.getItem('audit-type') ){
this.auditStatus = sessionStorage.getItem('audit-status') || "0" this.auditStatus = sessionStorage.getItem('audit-status') || "0"
this.type = sessionStorage.getItem('audit-type') || "0" this.type = sessionStorage.getItem('audit-type') || "0"
this.getFollowupList() }
else{
this.handleSearch()
}
}, },
methods: { methods: {
handleClick() { handleClick() {
...@@ -197,20 +203,25 @@ export default { ...@@ -197,20 +203,25 @@ export default {
auditHandle(data, i) { auditHandle(data, i) {
console.log(data, i) console.log(data, i)
if (this.type == "1") { if (this.type == "1") {
this.$router.push("/followaudit") this.$router.push({
path: "/followaudit",
query: {
id: data['unionId'],
},
})
} else { } else {
this.$router.push({ this.$router.push({
path: "/auditdetail", path: "/auditdetail",
query: { query: {
id: data['unionId'], id: i,
}, },
}) })
} }
}, },
async getFollowupList() { async handleSearch() {
let params = { let params = {
pageSize: 10, pageSize:this.pageSize,
pageNum: 1, pageNum:this.pageIndex
} }
let res let res
switch (this.auditStatus) { switch (this.auditStatus) {
...@@ -221,8 +232,8 @@ export default { ...@@ -221,8 +232,8 @@ export default {
res = await getFollowCheck(params) //已审核 res = await getFollowCheck(params) //已审核
break; break;
} }
this.tableData = res.records this.tableData = res.data.records
this.total= res.total this.total= res.data.total
}, },
}, },
} }
......
...@@ -95,6 +95,7 @@ ...@@ -95,6 +95,7 @@
<script> <script>
import publicDialog from "./components/publicDialog.vue" import publicDialog from "./components/publicDialog.vue"
import followReview from "./components/followReview.vue" import followReview from "./components/followReview.vue"
import { getFollowUnCheckDetail } from "@/api/followup"
export default { export default {
components: { publicDialog, followReview }, components: { publicDialog, followReview },
data() { data() {
...@@ -127,7 +128,14 @@ export default { ...@@ -127,7 +128,14 @@ export default {
} }
}, },
watch: {}, watch: {},
mounted() {}, mounted() {
this.getDetail()
},
computed:{
unionId(){
return this.$route.query.id
}
},
methods: { methods: {
showDialog(val) { showDialog(val) {
this.curBtn = val this.curBtn = val
...@@ -192,6 +200,17 @@ export default { ...@@ -192,6 +200,17 @@ export default {
nextExample() { nextExample() {
this.onCancel() this.onCancel()
}, },
async getDetail(){
this.loading = true
let res = await getFollowUnCheckDetail(this.unionId)
if(res.code==1){
//分页内容
// const d = res.data
// this.total= d.total
// this.tableData=d['records']
}
this.loading = false
},
}, },
} }
</script> </script>
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<form-components :forms="formList" :formEdit="formEdit" @handleSearch="onSearch"></form-components> <form-components :forms="formList" :formEdit="formEdit" @handleSearch="onSearch"></form-components>
</div> </div>
<div class="bot"> <div class="bot">
<customs-table <el-table-self
ref="table" ref="table"
:table-data="tableData" :table-data="tableData"
:columns="columns" :columns="columns"
...@@ -41,65 +41,82 @@ export default { ...@@ -41,65 +41,82 @@ export default {
columns: [ columns: [
{ {
label: "医联体", label: "医联体",
value: "unionName",
minWidth: 120, minWidth: 120,
value: "unionName",
formatter: (row) => {
return row.unionName ? row.unionName : "--"
},
}, },
{ {
label: "姓名", label: "姓名",
value: "name",
minWidth: 120, minWidth: 120,
formatter: (row) => {
return row.name ? row.name : "--"
},
value: "name",
}, },
{ {
label: "性别", label: "性别",
minWidth: 80,
value: "sex", value: "sex",
minWidth: 120,
formatter: (row) => { formatter: (row) => {
return this.$handle.formatDicList( return this.$handle.formatDicList(this.dictMap["d-sex"], row.sex + "")
this.dictMap["d-sex"],
String(row.sex)
)
}, },
}, },
{ {
label: "身份证", label: "身份证",
value: "idCard",
minWidth: 120, minWidth: 120,
value: "idCard",
formatter: (row) => {
return row.idCard ? row.idCard : "--"
},
}, },
{ {
label: "年龄", label: "年龄",
value:"age",
minWidth: 120, minWidth: 120,
value: "age",
formatter: (row) => {
return row.age ? row.age : "--"
},
}, },
{ {
label: "筛查时间", label: "筛查时间",
minWidth: 180,
value: "screeningTime", value: "screeningTime",
minWidth: 120, formatter: (row) => {
return row.createTime ? row.createTime : "--"
},
}, },
{ {
label: "风险评估结果", label: "风险评估结果",
minWidth: 120,
value: "riskRank", value: "riskRank",
trans:'risk_level', formatter: (row) => {
transList:{ return this.$handle.formatDicList(this.dictMap["risk_level"],String(row.riskRank))
}, },
minWidth: 120,
}, },
{ {
label: "上次随访时间", label: "上次随访时间",
value: "followTime", value: "followTime",
minWidth: 120, minWidth: 120,
formatter: (row) => {
return row.followTime ? row.followTime : "--"
},
}, },
{ {
label: "随访进度", label: "随访进度",
value: "followBatch", value: "followBatch",
trans:'follow_type',
transList:{
},
minWidth: 120, minWidth: 120,
formatter: (row) => {
return this.$handle.formatDicList(this.dictMap["follow_type"],String(row.followBatch))
},
}, },
{ {
label: "计划随访时间", label: "计划随访时间",
value: "nextFollowTime", value: "nextFollowTime",
trans:'next_follow_time', formatter: (row) => {
return this.$handle.formatDicList(this.dictMap["next_follow_time"],String(row.nextFollowTime))
},
minWidth: 120, minWidth: 120,
}, },
{ {
...@@ -143,7 +160,8 @@ export default { ...@@ -143,7 +160,8 @@ export default {
"formRecordId": "", //表单记录id "formRecordId": "", //表单记录id
"linkPhone": "0556-5556666", //联系方式 "linkPhone": "0556-5556666", //联系方式
"isContinueFollow": 1, //是否继续随访 "isContinueFollow": 1, //是否继续随访
"checkStatus": "" //审核状态 "checkStatus": "", //审核状态
"riskRank":"medium"
}, },
{ {
name:'11', name:'11',
...@@ -284,7 +302,7 @@ export default { ...@@ -284,7 +302,7 @@ export default {
} }
}, },
created(){ created(){
this.initColumn() // this.initColumn()
}, },
mounted() { mounted() {
this.formEdit = JSON.parse(sessionStorage.getItem('followResearch-form')) ||{} this.formEdit = JSON.parse(sessionStorage.getItem('followResearch-form')) ||{}
...@@ -333,41 +351,41 @@ export default { ...@@ -333,41 +351,41 @@ export default {
} }
this.listLoading = false this.listLoading = false
}, },
initColumn(){ // initColumn(){
this.columns.forEach((item,index) => { // this.columns.forEach((item,index) => {
if(item.trans){ // if(item.trans){
this.initDict(item.trans,index) // this.initDict(item.trans,index)
} // }
}) // })
}, // },
async initDict(type,index){ // async initDict(type,index){
let params={ // let params={
type:type // type:type
} // }
const res = await getDictDetail(params) // const res = await getDictDetail(params)
let item = this.formList.find(_ => _.trans == type) // let item = this.formList.find(_ => _.trans == type)
res.data.forEach((itemD,inx) => { // res.data.forEach((itemD,inx) => {
// if(!this.columns[index]['transList']){ // // if(!this.columns[index]['transList']){
// this.columns[index]['transList']={} // // this.columns[index]['transList']={}
// } // // }
// else{ // // else{
// this.columns[index]['transList'][itemD.code]=itemD.name // // this.columns[index]['transList'][itemD.code]=itemD.name
// } // // }
if(item){ // if(item){
if(!item['opts']){ // if(!item['opts']){
item['opts']=[] // item['opts']=[]
} // }
else { // else {
item['opts']=res.data.map((_) => { // item['opts']=res.data.map((_) => {
return { // return {
label: _.name, // label: _.name,
value: _.code, // value: _.code,
} // }
}) // })
} // }
} // }
}) // })
} // }
}, },
} }
</script> </script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment