commit
a8ae365ff7
@ -39,6 +39,10 @@
|
|||||||
and question_type = #{questionType}
|
and question_type = #{questionType}
|
||||||
</if>
|
</if>
|
||||||
<if test="name != null and name != ''"> and (name like concat('%', #{name}, '%') or phone like concat('%',#{name},'%'))</if>
|
<if test="name != null and name != ''"> and (name like concat('%', #{name}, '%') or phone like concat('%',#{name},'%'))</if>
|
||||||
|
<if test="beginTime != null and endTime != null">
|
||||||
|
and date_format(create_time,'%Y-%m-%d') >= #{beginTime} and #{endTime} >= date_format(create_time,'%Y-%m-%d')
|
||||||
|
</if>
|
||||||
|
order by create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectSysPreSaleSurveyById" parameterType="Long" resultMap="SysPreSaleSurveyResult">
|
<select id="selectSysPreSaleSurveyById" parameterType="Long" resultMap="SysPreSaleSurveyResult">
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
<div class="report_title">{{reportData.name ? reportData.name : '您的'}}身体评估报告</div>
|
<div class="report_title">{{reportData.name ? reportData.name : '您的'}}身体评估报告</div>
|
||||||
<div class="report_weight">
|
<div class="report_weight">
|
||||||
<div style="text-align:center">
|
<div style="text-align:center">
|
||||||
<span><span class="weight_name">{{reportData.overWeight > 0 ? '超重' : '增重'}}</span>{{Math.abs(reportData.overWeight).toFixed(2)}} 斤</span> <span style="margin-left:30px"><span class="weight_name">标准体重</span>{{reportData.standardWeight.toFixed(2)}} 斤</span>
|
<span><span class="weight_name">{{reportData.overWeight > 0 ? '超重' : '增重'}}</span>{{Math.abs(reportData.overWeight).toFixed(2)}} 斤</span> <span style="margin-left:8px"><span class="weight_name">标准体重</span>{{reportData.standardWeight.toFixed(2)}} 斤</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@ -23,10 +23,16 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="blood_moisture">
|
<div class="blood_moisture">
|
||||||
<div style="float: left;">
|
<div style="float: left;">
|
||||||
<div class="blood_moisture_title">湿气指数</div><div :class="getBloodMoistureIndexClass(reportData.moistureIndex)"></div>
|
<div class="blood_moisture_title">湿气指数</div>
|
||||||
|
<div :class="getBloodMoistureIndexClass(reportData.moistureIndex)">
|
||||||
|
<span class="blood_moisture_index_span" :style="'margin-left:'+getBloodMoistureIndexClass(reportData.moistureIndex, 2)+'%;'">{{getBloodMoistureIndexClass(reportData.moistureIndex, 1)}}</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="float: left;margin-top:20px">
|
<div style="float: left;margin-top:20px">
|
||||||
<div class="blood_moisture_title">气血指数</div><div :class="getBloodMoistureIndexClass(reportData.bloodIndex)"></div>
|
<div class="blood_moisture_title">气血指数</div>
|
||||||
|
<div :class="getBloodMoistureIndexClass(reportData.bloodIndex)">
|
||||||
|
<span class="blood_moisture_index_span" :style="'margin-left:'+getBloodMoistureIndexClass(reportData.bloodIndex, 2)+'%;'">{{getBloodMoistureIndexClass(reportData.bloodIndex, 1)}}</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="clear"></div>
|
<div class="clear"></div>
|
||||||
@ -63,7 +69,10 @@ export default {
|
|||||||
signTypeArray: [],
|
signTypeArray: [],
|
||||||
moistureIndex: 0,
|
moistureIndex: 0,
|
||||||
bloodIndex: 0
|
bloodIndex: 0
|
||||||
}
|
},
|
||||||
|
//
|
||||||
|
//分别代表轻度、中度、重度的界限,如:1-3之间为轻度
|
||||||
|
indexRange: [1,4,7]
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
@ -99,16 +108,26 @@ export default {
|
|||||||
let signObj = this.physicalSignsList.find((obj) => obj.dictValue === value);
|
let signObj = this.physicalSignsList.find((obj) => obj.dictValue === value);
|
||||||
return signObj != null ? signObj.dictLabel : null;
|
return signObj != null ? signObj.dictLabel : null;
|
||||||
},
|
},
|
||||||
getBloodMoistureIndexClass(num){
|
getBloodMoistureIndexClass(num, type){
|
||||||
let className = "blood_moisture_value";
|
let className = "blood_moisture_value";
|
||||||
if(num <= 3){
|
let spanValue = "";
|
||||||
|
let marginLeft = 0;
|
||||||
|
if(num < this.indexRange[0]){
|
||||||
|
className += " none";
|
||||||
|
}else if(num < this.indexRange[1]){
|
||||||
|
spanValue = "低";
|
||||||
|
marginLeft = 21;
|
||||||
className += " light";
|
className += " light";
|
||||||
}else if(num <= 6){
|
}else if(num < this.indexRange[2]){
|
||||||
|
spanValue = "中";
|
||||||
|
marginLeft = 55;
|
||||||
className += " moderate";
|
className += " moderate";
|
||||||
}else{
|
}else{
|
||||||
|
spanValue = "高";
|
||||||
|
marginLeft = 86;
|
||||||
className += " severe";
|
className += " severe";
|
||||||
}
|
}
|
||||||
return className;
|
return (type != undefined && type > 0) ? (type == 1 ? spanValue : marginLeft) : className;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
@ -149,7 +168,7 @@ export default {
|
|||||||
margin-top: 25px;
|
margin-top: 25px;
|
||||||
border-top:2px solid #F1F1F1;
|
border-top:2px solid #F1F1F1;
|
||||||
border-bottom:2px solid #F1F1F1;
|
border-bottom:2px solid #F1F1F1;
|
||||||
padding: 0px 10px;
|
padding: 0px 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.weight_name{
|
.weight_name{
|
||||||
@ -158,7 +177,7 @@ export default {
|
|||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: #4B8AFF;
|
color: #4B8AFF;
|
||||||
line-height: 50px;
|
line-height: 50px;
|
||||||
margin-right:5px;
|
margin-right:2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.weight_value{
|
.weight_value{
|
||||||
@ -194,7 +213,7 @@ export default {
|
|||||||
|
|
||||||
.sign_type_div{
|
.sign_type_div{
|
||||||
height: 30px;
|
height: 30px;
|
||||||
background: #F1F1F1;
|
background: #e16664;
|
||||||
border-radius: 24px;
|
border-radius: 24px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin:10px 5px;
|
margin:10px 5px;
|
||||||
@ -208,7 +227,7 @@ export default {
|
|||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-family: Source Han Sans CN;
|
font-family: Source Han Sans CN;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
color: #333333;
|
color: #ffffff;
|
||||||
line-height: 30px;
|
line-height: 30px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -228,23 +247,27 @@ export default {
|
|||||||
.blood_moisture_value{
|
.blood_moisture_value{
|
||||||
margin-left:10px;
|
margin-left:10px;
|
||||||
float: left;
|
float: left;
|
||||||
width: 220px;
|
width: 180px;
|
||||||
height:30px;
|
height:30px;
|
||||||
border-radius: 20px;
|
border-radius: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.clear{ clear:both}
|
.clear{ clear:both}
|
||||||
|
|
||||||
|
.none{
|
||||||
|
background: #CCCCCC
|
||||||
|
}
|
||||||
|
|
||||||
.light{
|
.light{
|
||||||
background: #20d866;
|
background: linear-gradient(to right,#37bc02,#e6b46a 33%,#CCCCCC 35%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.moderate{
|
.moderate{
|
||||||
background: #f0a70b;
|
background: linear-gradient(to right,#37bc02,#f5b95e 33%, #fa9500 67%,#CCCCCC 67%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.severe{
|
.severe{
|
||||||
background: #e94545;
|
background: linear-gradient(to right,#37bc02,#fa9500,#da302a);
|
||||||
}
|
}
|
||||||
|
|
||||||
.bottom_content{
|
.bottom_content{
|
||||||
@ -257,5 +280,11 @@ export default {
|
|||||||
margin-top:20px;
|
margin-top:20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.blood_moisture_index_span{
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: Source Han Sans CN;
|
||||||
|
font-weight: 500;
|
||||||
|
color: #FEFEFF;
|
||||||
|
line-height: 30px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -9,6 +9,20 @@
|
|||||||
size="small"
|
size="small"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="日期范围" prop="time">
|
||||||
|
|
||||||
|
<el-date-picker
|
||||||
|
v-model="timeScope"
|
||||||
|
type="daterange"
|
||||||
|
range-separator="至"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
format="yyyy-MM-dd"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
:picker-options="timePickerOptions"
|
||||||
|
>
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
<el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
@ -237,6 +251,7 @@ import Clipboard from "clipboard";
|
|||||||
import AutoHideInfo from "@/components/AutoHideInfo";
|
import AutoHideInfo from "@/components/AutoHideInfo";
|
||||||
import AutoHideMessage from "@/components/AutoHideMessage"
|
import AutoHideMessage from "@/components/AutoHideMessage"
|
||||||
import VueQr from "vue-qr";
|
import VueQr from "vue-qr";
|
||||||
|
import dayjs from "dayjs";
|
||||||
const logo = require("@/assets/logo/logo_b.png");
|
const logo = require("@/assets/logo/logo_b.png");
|
||||||
export default {
|
export default {
|
||||||
name: "PreSaleSurvey",
|
name: "PreSaleSurvey",
|
||||||
@ -276,7 +291,13 @@ export default {
|
|||||||
simpleSignTypeOption: [],
|
simpleSignTypeOption: [],
|
||||||
moistureDataExtendedOption:[],
|
moistureDataExtendedOption:[],
|
||||||
bloodDataExtendedOption:[],
|
bloodDataExtendedOption:[],
|
||||||
copyValue: ""
|
copyValue: "",
|
||||||
|
timeScope: null,
|
||||||
|
timePickerOptions: {
|
||||||
|
disabledDate(time) {
|
||||||
|
return time.getTime() > dayjs()
|
||||||
|
},
|
||||||
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
@ -300,6 +321,8 @@ export default {
|
|||||||
/** 查询简易问卷调查列表 */
|
/** 查询简易问卷调查列表 */
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
|
this.queryParams.beginTime = this.timeScope && this.timeScope.length > 0 ? this.timeScope[0] : null;
|
||||||
|
this.queryParams.endTime = this.timeScope && this.timeScope.length > 0 ? this.timeScope[1] : null;
|
||||||
listPreSaleSurvey(this.queryParams).then(response => {
|
listPreSaleSurvey(this.queryParams).then(response => {
|
||||||
response.rows.forEach(item => {
|
response.rows.forEach(item => {
|
||||||
item.physicalSignsIdArray = item.physicalSignsId.split(",");
|
item.physicalSignsIdArray = item.physicalSignsId.split(",");
|
||||||
@ -406,6 +429,7 @@ export default {
|
|||||||
/** 重置按钮操作 */
|
/** 重置按钮操作 */
|
||||||
resetQuery() {
|
resetQuery() {
|
||||||
this.resetForm("queryForm");
|
this.resetForm("queryForm");
|
||||||
|
this.timeScope = null;
|
||||||
this.handleQuery();
|
this.handleQuery();
|
||||||
},
|
},
|
||||||
// 多选框选中数据
|
// 多选框选中数据
|
||||||
@ -457,7 +481,13 @@ export default {
|
|||||||
/** 删除按钮操作 */
|
/** 删除按钮操作 */
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
const ids = row.id || this.ids;
|
const ids = row.id || this.ids;
|
||||||
this.$confirm('是否确认删除简易问卷调查编号为"' + ids + '"的数据项?', "警告", {
|
let confirmTitle = "";
|
||||||
|
if(row != undefined && row.id != undefined){
|
||||||
|
confirmTitle = '是否确认删除名字为 '+row.name+' 的简易问卷信息?';
|
||||||
|
}else{
|
||||||
|
confirmTitle = '是否确认删除所勾选的 '+ids.length+' 条的简易问卷信息?';
|
||||||
|
}
|
||||||
|
this.$confirm(confirmTitle, "警告", {
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: "确定",
|
||||||
cancelButtonText: "取消",
|
cancelButtonText: "取消",
|
||||||
type: "warning"
|
type: "warning"
|
||||||
|
@ -40,14 +40,25 @@
|
|||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="8、病史体征(可多选)" prop="physicalSignsIdArray" >
|
<el-form-item label="8、病史体征(可多选)" prop="physicalSignsIdArray" >
|
||||||
<el-select v-model="form.physicalSignsIdArray" multiple placeholder="请选择">
|
<el-select v-model="form.physicalSignsIdArray" multiple filterable clearable placeholder="请选择病史体征">
|
||||||
<el-option
|
<!--<el-option
|
||||||
v-for="physicalSign in physicalSignsList"
|
v-for="physicalSign in physicalSignsList"
|
||||||
:key="physicalSign.dictValue"
|
:key="physicalSign.dictValue"
|
||||||
:label="physicalSign.dictLabel"
|
:label="physicalSign.dictLabel"
|
||||||
:value="physicalSign.dictValue"
|
:value="physicalSign.dictValue"
|
||||||
>
|
>
|
||||||
|
</el-option>-->
|
||||||
|
<el-option-group
|
||||||
|
v-for="(group,index) in physicalSignsGroupList"
|
||||||
|
:key="index"
|
||||||
|
:label="group.label">
|
||||||
|
<el-option
|
||||||
|
v-for="(item, j) in group.options"
|
||||||
|
:key="index+'_'+j"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value">
|
||||||
</el-option>
|
</el-option>
|
||||||
|
</el-option-group>
|
||||||
</el-select>
|
</el-select>
|
||||||
<div><span class="text-span">其他病史体征</span>
|
<div><span class="text-span">其他病史体征</span>
|
||||||
<el-input type="textarea"
|
<el-input type="textarea"
|
||||||
@ -122,6 +133,7 @@ export default {
|
|||||||
moistureDataList:[],
|
moistureDataList:[],
|
||||||
bloodDataList:[],
|
bloodDataList:[],
|
||||||
physicalSignsList:[],
|
physicalSignsList:[],
|
||||||
|
physicalSignsGroupList:[],
|
||||||
form:{
|
form:{
|
||||||
customerKey: null,
|
customerKey: null,
|
||||||
name: "",
|
name: "",
|
||||||
@ -244,7 +256,29 @@ export default {
|
|||||||
getPhysicalSignsList() {
|
getPhysicalSignsList() {
|
||||||
getDictData("simple_sign_type").then((response) => {
|
getDictData("simple_sign_type").then((response) => {
|
||||||
this.physicalSignsList = response.data;
|
this.physicalSignsList = response.data;
|
||||||
|
this.physicalSignsGroupList = this.dealSignList(response.data);
|
||||||
});
|
});
|
||||||
|
},
|
||||||
|
dealSignList(signList){
|
||||||
|
let result = [];
|
||||||
|
if(signList == null || signList.length == 0){
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
let groupObj = {};
|
||||||
|
let groupLabelArray = [];
|
||||||
|
signList.forEach(item => {
|
||||||
|
if(item.remark != null && item.remark != ""){
|
||||||
|
if(groupLabelArray.indexOf(item.remark) == -1){
|
||||||
|
groupLabelArray.push(item.remark);
|
||||||
|
}
|
||||||
|
groupObj[item.remark] = groupObj[item.remark] == undefined ? [] : groupObj[item.remark];
|
||||||
|
groupObj[item.remark].push({'value': item.dictValue, 'label': item.dictLabel});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
groupLabelArray.forEach(item => {
|
||||||
|
result.push({'label': item, 'options': groupObj[item]});
|
||||||
|
})
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user