<!doctype html>
|
<html>
|
<head>
|
<meta charset="utf-8" />
|
<title>选择疾病类型</title>
|
<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
|
<!-- js引用 -->
|
<script src="../../js/config.js"></script>
|
<script src="../../js/h5toapp.js"></script>
|
<script src="../../js/h5to.js"></script>
|
|
<!-- 组件js引用 -->
|
<script src="../../js/mui.min.js"></script>
|
<!-- 组件标准css引用 -->
|
<link rel="stylesheet" href="../../css/mui.min.css">
|
<!-- css引用 -->
|
<link href="../../css/currency.css" rel="stylesheet">
|
<link href="../../css/spinkit.css" rel="stylesheet">
|
<link href="../../css/icon/iconfont.css" rel="stylesheet">
|
<!-- 界面本身css引用 -->
|
<link href="./xzjblx.css" rel="stylesheet">
|
|
<style type="text/css">
|
.mui-input-row .mui-input-clear~.mui-icon-clear {
|
line-height: 27px;
|
width: 30px;
|
height: 17px;
|
top: 16px;
|
background: url(../../img/Delete%20Keyword.png) no-repeat;
|
}
|
|
.mui-icon-clear:before {
|
content: '';
|
/* background: url(../../img/Delete%20Keyword.png) no-repeat; */
|
}
|
</style>
|
</head>
|
|
<body class="app_page">
|
<div style="background-color: #F9FAFC; height: 100vh; width: 100%; margin: 0; overflow: auto;">
|
<div id="loading" class="example">
|
<div class="sk-plane loading_location"></div>
|
</div>
|
|
<div class="mui-content">
|
|
<div style="margin: 16px; box-sizing: border-box;">
|
<div class="mui-card" style="border-radius: 24px;">
|
<div class="z_menu_btn_row mui-input-row" style="height: 48px;line-height: 48px;padding: 0;padding-left: 16px;" >
|
<img src="../../img/ic_search_normal.png" class="search_icon" />
|
<input id="val" type="text" class="mui-input-clear search_frame" />
|
</div>
|
</div>
|
</div>
|
<div style="margin: 16px; box-sizing: border-box;">
|
<div id="show_area" class="mui-card" style="height: 100%;display: none;">
|
<div class="z_menu_btn_row " onclick="click_add_label(this)" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">
|
<span class="z_menu_btn_txt_1">填写说明:</span>
|
</div>
|
<div class="z_menu_btn_row " onclick="" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">
|
<span class="z_menu_btn_txt_1">填写说明:</span>
|
</div>
|
<div class="z_menu_btn_row " onclick="" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">
|
<span class="z_menu_btn_txt_1">填写说明:</span>
|
</div>
|
<div class="z_menu_btn_row " onclick="" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">
|
<span class="z_menu_btn_txt_1">填写说明:</span>
|
</div>
|
<div class="z_menu_btn_row " onclick="" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">
|
<span class="z_menu_btn_txt_1">填写说明:</span>
|
</div>
|
</div>
|
</div>
|
<div style="margin: 16px; box-sizing: border-box;">
|
<div id="label_list" class="mui-card" style="height: 131px;">
|
<div class="label_style">
|
<img src="../../img/Fill(1).png" class="label_close" />
|
<span class="label_txt">房颤</span>
|
</div>
|
<div class="label_style">
|
<img src="../../img/Fill(1).png" class="label_close" />
|
<span class="label_txt">房颤</span>
|
</div>
|
<div class="label_style">
|
<img src="../../img/Fill(1).png" class="label_close" />
|
<span class="label_txt">房颤</span>
|
</div>
|
<div class="label_style">
|
<img src="../../img/Fill(1).png" class="label_close" />
|
<span class="label_txt">房颤</span>
|
</div>
|
</div>
|
</div>
|
<div style="width: 100%;">
|
<button class="confirm_button" style="margin: 80px 110px;">保存</button>
|
</div>
|
</div>
|
</div>
|
|
|
<script type="text/javascript">
|
var bt_txt ="血压记录(晨起)";
|
var zxjz_num = 11;
|
var jsjz_num = 22;
|
var srys_num = 33;
|
var zxgh_num = 44;
|
|
var info = [];
|
|
var menurows = [
|
{id: "1", name: "选择疾病类型", path: "./myzs",_id: 10},
|
{id: "2", name: "详细信息", path: "./ysxx"},
|
{id: "3", name: "门诊排班", path: "./mzpb"},
|
{id: "4", name: "共享的随访量表", path: "./sflb"},
|
];
|
|
mui.init({
|
swipeBack:true //启用右滑关闭功能
|
});
|
|
// window.onload=function(){
|
// loadinfo();
|
// }
|
|
|
// 停止loading
|
var int=self.setInterval("infosetuser()",100);
|
function infosetuser() {
|
if (login_data.userId != "123456") {
|
alert(login_data.userId);
|
window.clearInterval(int);
|
// muiInfo();
|
loadinfo();
|
}
|
}
|
|
function loadinfo() {
|
|
var label = document.getElementById('label_list');
|
label.addEventListener('tap',function(){
|
// label.removeChild(element);
|
if(event.target.className != 'label_close') return;
|
let img_element = event.target.closest('.label_style');
|
img_element.remove();
|
})
|
|
|
mui.ajax('http://api.medeasy123.com/content/api/query/doctor/id/1299297572180185090',{
|
data:{
|
"doctorId": 1299297572180185090,
|
},
|
// headers:{'':'application/json'},
|
dataType:'json',//服务器返回json格式数据
|
type:'GET',//HTTP请求类型
|
timeout:10000,//超时时间设置为10秒;
|
success:function(data){
|
|
console.info("success");
|
console.info(data);
|
// console.info("data:"+JSON.stringify(data));
|
// console.info(data.data[0].contentTitle);
|
info = [];
|
for (var i = 0; i < data.data.length; i++) {
|
var flag = {
|
id: data.data[i].id,
|
diseaseName: data.data[i].contentTitle
|
}
|
info.push(flag);
|
|
// info[i] = data.data[i];
|
}
|
},
|
error:function(xhr,type,errorThrown){
|
console.info("error:"+type);
|
|
}
|
});
|
|
clickEventList();
|
hideloading("loading");
|
}
|
|
let input = document.getElementById('val');
|
let show = document.getElementById('show_area');
|
|
// let arr = ['web1','web2','web3','html1','html2']
|
let arr = [
|
{id: 1,name: "web1"},
|
{id: 2,name: "web2"},
|
{id: 3,name: "web3"},
|
{id: 4,name: "html1"},
|
{id: 5,name: "html2"},
|
|
];
|
|
input.onkeyup = function(){
|
show.style.display = 'block';
|
|
let str = '';
|
info.forEach((item)=>{
|
let res = item.diseaseName.indexOf(input.value);
|
if(res != -1){
|
str +=
|
'<div id="'+item.id+'" class="z_menu_btn_row " onclick="click_add_label(this)" style="height: 36px;line-height: 36px;padding: 0;padding-left: 16px;">'+
|
'<span class="z_menu_btn_txt_1">'+item.diseaseName+'</span>'+
|
'</div>'
|
}
|
})
|
// console.info(str);
|
if(!input.value||!arr){
|
show.innerHTML = '';
|
}else {
|
show.innerHTML = str;
|
}
|
}
|
|
// input.onblur = function(){
|
// show.style.display = 'none';
|
|
// }
|
|
|
function click_row(row) {
|
var pam = {
|
_id:row._id,
|
params:{
|
userId: login_data.userId
|
}
|
};
|
window.webBridge.callAppRouter("route", pam, function(err, resultObj) {
|
err(err, resultObj);
|
});
|
|
// mui.openWindow({
|
// url: row.path + '.html'
|
// });
|
}
|
|
function docallback(err, resultObj){
|
alert("123");
|
}
|
function err(err, resultObj){
|
alert("err");
|
}
|
|
function click_add_label(e) {
|
|
var label = document.getElementById('label_list');
|
var element = document.createElement('div');
|
element.className = "label_style";
|
var img_element = document.createElement('img');
|
img_element.className = "label_close";
|
img_element.src = "../../img/Fill(1).png";
|
var span_element = document.createElement('span');
|
span_element.className = "label_txt";
|
span_element.innerText = document.getElementById(e.id).getElementsByTagName('span')[0].innerText;
|
element.appendChild(img_element);
|
element.appendChild(span_element);
|
label.appendChild(element);
|
|
show.style.display = 'none';
|
input.value = '';
|
}
|
|
// function click_row(row) {
|
// mui.openWindow({
|
// url: row.path + '.html'
|
// });
|
// }
|
|
function clickEventList() {
|
mui('body').on('tap', '.mui-popover-action li>a', function(event) {
|
//event.cancelBubble = true;//阻止当前事件的冒泡
|
var a = this, parent;
|
//根据点击按钮,反推当前是哪个actionsheet
|
for (parent = a.parentNode; parent != document.body; parent = parent.parentNode) {
|
if (parent.classList.contains('mui-popover-action')) {
|
break;
|
}
|
}
|
|
//关闭actionsheet
|
mui('#' + parent.id).popover('toggle');
|
if (parent.id == "myzsSelect") {
|
document.getElementById('myzs_name').innerHTML = a.innerHTML;
|
}
|
});
|
}
|
|
</script>
|
</body>
|
|
</html>
|