提交 816853b3 编写于 作者: 杨广俊's avatar 杨广俊

代码整理

上级 28bd11b4
...@@ -120,37 +120,9 @@ export default { ...@@ -120,37 +120,9 @@ export default {
created() { created() {
let _this = this; let _this = this;
_this.initAll(); _this.initAll();
_this.getUserInfo();
// window.__refresh = function(params){
// }
window.__getStatusBarHeight = function(parm) {
// alert(JSON.stringify(parm))
_this.statusBarHeight = parm.statusBarHeight;
};
// alert("token之前");
window.__getUserInfo = function(parm) {
// _this.systemType = parm.systemType;
// _this.appVersion = parm.appVersion;
// _this.token = parm.userToken;
// _this.userToken = parm.userToken;
// _this.userMobile = parm.userMobile;
// _this.initByToken(parm.userToken);
};
// _this.getStatusHight()
// _this.initByToken('593F679F62964076AF1C7489DA3343ED');
// arraySort([1, 1, 1, 2, 2, 1, 1, 3, 4, 2, 5])
}, },
beforeMount() { beforeMount() {},
// let appBody = document.getElementById('appBody')
// appBody.style.overflow = 'hidden'
// appBody.style.height = '0'
},
mounted() { mounted() {
window.addEventListener("scroll", this.scrollFun); window.addEventListener("scroll", this.scrollFun);
}, },
...@@ -161,21 +133,20 @@ export default { ...@@ -161,21 +133,20 @@ export default {
watch: {}, watch: {},
methods: { methods: {
// 排序 // 排序
orderAction(orderName, isSortUp) { orderAction(orderName, isSortUp) {
let orderType = isSortUp ? -1 : 1; let orderType = isSortUp ? -1 : 1;
let orderData = this.oldParmDataDoctList.slice(); let orderData = this.oldParmDataDoctList.slice();
if(orderName === "doctorFirstNameChar") { if (orderName === "doctorFirstNameChar") {
orderData = arraySort(orderData, isSortUp, orderName, (fieldValue) => { orderData = arraySort(orderData, isSortUp, orderName, fieldValue => {
return fieldValue.charCodeAt(0) return fieldValue.charCodeAt(0);
}) });
} else if(orderName === "newTime") { } else if (orderName === "newTime") {
orderData = arraySort(orderData, isSortUp, orderName, (fieldValue) => { orderData = arraySort(orderData, isSortUp, orderName, fieldValue => {
return new Date(fieldValue.replace(/-/g, "/")).getTime() / 1000 return new Date(fieldValue.replace(/-/g, "/")).getTime() / 1000;
}) });
} else { } else {
orderData = arraySort(orderData, isSortUp, orderName) orderData = arraySort(orderData, isSortUp, orderName);
} }
this.parmDataDoctList = orderData; this.parmDataDoctList = orderData;
}, },
...@@ -195,32 +166,20 @@ export default { ...@@ -195,32 +166,20 @@ export default {
this.selectedLevelName = selectedLevelName; this.selectedLevelName = selectedLevelName;
this.selectedDepartName = selectedDepartName; this.selectedDepartName = selectedDepartName;
}, },
// 选择标题组件 // 选择标题组件
selectedTypeFromTitle(index) { selectedTypeFromTitle(index) {
this.selectedTypeIndex = index; this.selectedTypeIndex = index;
this.$refs.lecturerSelContRef.selectedType(index); this.$refs.lecturerSelContRef.selectedType(index);
this.$refs.lecturerSelContRef.show(); this.$refs.lecturerSelContRef.show();
}, },
// 请求数据 // 请求数据
initAll() { initAll() {
this.getSwiper(); this.getSwiper();
this.getYqDoctorDataByCD(); this.getYqDoctorDataByCD();
}, },
//获取状态栏高度
getStatusHight() {
rocNative.getStatusBarHeight({
__funcName: "__getStatusBarHeight"
});
},
//获取用户信息及版本号等()
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfo"
});
},
//轮播图跳转 //轮播图跳转
goLinkByswiper(itemData) { goLinkByswiper(itemData) {
this.pageBurialPoin({ this.pageBurialPoin({
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册