import {request} from "../../request/index";
Page({
data: {
user: {
account: "",
password: ""
}
},
changeValue(e) {
let property = "user." + e.target.dataset.label
let value = e.detail.value
this.setData({
[property]: value
})
},
userLogin() {
wx.showLoading({
title: "正在努力加载中",
mask: false
})
request("/user/login", this.data.user).then(res => {
console.log(res)
wx.hideLoading()
let icon = "error"
if (res.data.code === 200) {
icon = "success"
}
wx.showToast({
title: res.data.message,
icon
})
}).catch(res => {
console.error(res)
wx.hideLoading()
})
}
})

亣柒
- 粉丝: 140
最新资源
- 微软正在研发谷歌Chromecast电视棒的设备.doc
- 国际化网络会计毕业设计【精品发布】.doc
- 华东理工基因工程专家讲座.pptx
- 机房管理系统数据库课程设计.doc
- 图书馆计算机培训工作总结.docx
- 信息系统安全考题.doc
- 学校网络安全事件应急预案.doc
- 优化算法模拟退火粒子群遗传算法专家讲座.pptx
- 通信公司运营支撑系统BOSS技术规范.doc
- 2023年安徽省计算机一级考试试题.doc
- 长安奔奔MINI-网络营销推广策划案.doc
- 汽车网络营销.pptx
- 计算机基础实训总结.docx
- 京信移动通信基站天线基础知识交流.pptx
- 专升本操作系统复习试题及答案.doc
- (源码)基于Django框架的二手车交易系统.zip
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



评论5