//index.js
//获取应用实例
const app = getApp()
Page({
data: {
motto: 'Hello World',
userInfo: {},
hasUserInfo: false,
canIUse: wx.canIUse('button.open-type.getUserInfo'),
user:{
name:"王振",
phone:"18324729453",
email:"1013089446@qq.com"
}
},
//事件处理函数
bindViewTap: function() {
wx.navigateTo({
url: '../logs/logs'
})
},
call:function(){
let that=this
wx.makePhoneCall({
phoneNumber: that.data.user.phone, //此号码并非真实电话号码,仅用于测试
success: function () {
console.log("拨打电话成功!")
},
fail: function () {
console.log("拨打电话失败!")
}
})
},
onLoad: function () {
let that = this
if (app.globalData.userInfo) {
this.setData({
userInfo: app.globalData.userInfo,
hasUserInfo: true
})
} else if (this.data.canIUse){
// 由于 getUserInfo 是网络请求,可能会在 Page.onLoad 之后才返回
// 所以此处加入 callback 以防止这种情况
app.userInfoReadyCallback = res => {
this.setData({
userInfo: res.userInfo,
hasUserInfo: true
})
}
} else {
// 在没有 open-type=getUserInfo 版本的兼容处理
wx.getUserInfo({
success: res => {
app.globalData.userInfo = res.userInfo
this.setData({
userInfo: res.userInfo,
hasUserInfo: true
})
}
})
}
},
getUserInfo: function(e) {
console.log(e)
app.globalData.userInfo = e.detail.userInfo
this.setData({
userInfo: e.detail.userInfo,
hasUserInfo: true
})
}
})
没有合适的资源?快使用搜索试试~ 我知道了~
微信小程序 个人简历
共43个文件
json:8个
png:8个
js:8个
1星 需积分: 50 110 下载量 94 浏览量
2018-08-31
16:25:47
上传
评论 6
收藏 962KB 7Z 举报
温馨提示
一个简短的简历类型的微信小程序,只是平时没事的时候随便写写,新手可以参观一下。
资源推荐
资源详情
资源评论
收起资源包目录
myself.7z (43个子文件)
myself
app.json 352B
pages
index
index.js 2KB
index.json 48B
index.wxss 1KB
index.wxml 2KB
experience
index.js 219B
index.json 92B
index.wxss 789B
index.wxml 1KB
logs
logs.js 261B
logs.json 52B
logs.wxml 173B
logs.wxss 106B
education
index.js 218B
index.json 92B
index.wxss 417B
index.wxml 1001B
skill
index.js 743B
index.json 92B
index.wxss 653B
index.wxml 948B
project
index.js 761B
index.json 92B
index.wxss 545B
index.wxml 343B
app.wxss 249B
app.js 1KB
project.config.json 564B
utils
images
portfolio-2.jpg 433KB
left1.png 1KB
right.png 527B
portfolio-1.jpg 77KB
bac05.jpg 78KB
left2.png 770B
name.png 50KB
portfolio-3.jpg 22KB
kang.jpg 20KB
it03.png 130KB
timg.jpg 47KB
left.png 753B
experience.png 1KB
it02.png 108KB
util.js 472B
共 43 条
- 1
资源评论
- sunday06122019-09-07只能当做参考,有必要的时候再看看
不帅的猿
- 粉丝: 10
- 资源: 1
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功