diff --git a/miniprogram/apis/card.js b/miniprogram/apis/card.js new file mode 100644 index 0000000..e69de29 diff --git a/miniprogram/apis/card.ts b/miniprogram/apis/card.ts new file mode 100644 index 0000000..1899707 --- /dev/null +++ b/miniprogram/apis/card.ts @@ -0,0 +1,11 @@ + +import { request } from '../utils/request' + +export function businessCard(data) { + return request({ + url: '/consumer/businessCard', + method: 'PUT', + data + }) +} +// /consumer/businessCard \ No newline at end of file diff --git a/miniprogram/app.json b/miniprogram/app.json index f9411c1..4910ff6 100644 --- a/miniprogram/app.json +++ b/miniprogram/app.json @@ -1,6 +1,7 @@ { "pages": [ "pages/index/index", + "pages/card/card", "pages/shareTimeLine/shareTimeLine", "pages/QA/QA", "pages/service/service", @@ -45,12 +46,15 @@ "pages/question/question", "pages/questionDetail/questionDetail", "pages/whiteList/whiteList", + "pages/validComment/validComment", + "pages/commentResult/commentResult", "pages/addAuthName/addAuthName" + ], "window": { "backgroundTextStyle": "light", "navigationBarBackgroundColor": "#fff", - "navigationBarTitleText": "众评", + "navigationBarTitleText": "与评", "navigationBarTextStyle": "black" }, diff --git a/miniprogram/app.ts b/miniprogram/app.ts index 699ad89..3a25233 100644 --- a/miniprogram/app.ts +++ b/miniprogram/app.ts @@ -61,7 +61,10 @@ App({ console.log('appShow', options) const { path, query } = options let { q, source } = query - if (['pages/apply/apply', 'pages/reportPreview/reportPreview', 'pages/scanLogin/scanLogin'].includes(path)) { + console.log('query.source', source); + if (source) this.globalData.smsCode = source + + if (['pages/index/index'].includes(path)) { let pageQueryStr = '' if (q) { q = decodeURIComponent(q) @@ -69,14 +72,15 @@ App({ const queryObj = querystrToObj(decodeURIComponent(querystrToObj(queryStr).query)) pageQueryStr = decodeURIComponent(querystrToObj(queryStr).query) source = queryObj.source + } - const backPage = `/${path}?${pageQueryStr}` - console.log(backPage) - wx.setStorageSync('QSource', source) - wx.setStorageSync('backPage', backPage) + // const backPage = `/${path}?${pageQueryStr}` + // console.log(backPage,this.smsCode) + // wx.setStorageSync('QSource', source) + // wx.setStorageSync('backPage', backPage) } else { - wx.removeStorageSync('QSource') - wx.removeStorageSync('backPage') + // wx.removeStorageSync('QSource') + // wx.removeStorageSync('backPage') } }, // 登录 @@ -95,16 +99,19 @@ App({ this.globalData.unionId = res.d.unionId login({ openId: res.d.openId, + unionId: res.d.unionId, // ...res.d, - loginType: 1 + loginType: 1, + smsCode: this.globalData.smsCode }).then((res: any) => { wx.setStorageSync('Authorization', res.d) // this.getBindPhoneList() - + console.log('QSource', this.globalData.smsCode); + resolve(true) - console.log('resolve'); + // console.log('resolve'); bindPhoneList().then(res => { - console.log('##2##',res); + // console.log('##2##', res); wx.setStorageSync('accountList', res.d) wx.setStorageSync('userInfo', res.d.find(item => item.phone === wx.getStorageSync('userInfo').phone) || res.d[0]) }) @@ -164,7 +171,7 @@ App({ } return val }, - + /** * 会员校验 * @param skip 是否跳转到购买会员页面 diff --git a/miniprogram/assets/images/card/cStar_0.5.png b/miniprogram/assets/images/card/cStar_0.5.png new file mode 100644 index 0000000..d6f4945 Binary files /dev/null and b/miniprogram/assets/images/card/cStar_0.5.png differ diff --git a/miniprogram/assets/images/card/cStar_0.png b/miniprogram/assets/images/card/cStar_0.png new file mode 100644 index 0000000..510da7d Binary files /dev/null and b/miniprogram/assets/images/card/cStar_0.png differ diff --git a/miniprogram/assets/images/card/cStar_1.png b/miniprogram/assets/images/card/cStar_1.png new file mode 100644 index 0000000..6945970 Binary files /dev/null and b/miniprogram/assets/images/card/cStar_1.png differ diff --git a/miniprogram/assets/images/card/icon_edit.png b/miniprogram/assets/images/card/icon_edit.png new file mode 100644 index 0000000..9065a34 Binary files /dev/null and b/miniprogram/assets/images/card/icon_edit.png differ diff --git a/miniprogram/assets/images/card/icon_email.png b/miniprogram/assets/images/card/icon_email.png new file mode 100644 index 0000000..0b71999 Binary files /dev/null and b/miniprogram/assets/images/card/icon_email.png differ diff --git a/miniprogram/assets/images/card/icon_logo.png b/miniprogram/assets/images/card/icon_logo.png new file mode 100644 index 0000000..954ec7f Binary files /dev/null and b/miniprogram/assets/images/card/icon_logo.png differ diff --git a/miniprogram/assets/images/card/icon_phone.png b/miniprogram/assets/images/card/icon_phone.png new file mode 100644 index 0000000..77dd9f6 Binary files /dev/null and b/miniprogram/assets/images/card/icon_phone.png differ diff --git a/miniprogram/assets/images/card/icon_q.png b/miniprogram/assets/images/card/icon_q.png new file mode 100644 index 0000000..344b6e1 Binary files /dev/null and b/miniprogram/assets/images/card/icon_q.png differ diff --git a/miniprogram/assets/images/card/icon_quote.png b/miniprogram/assets/images/card/icon_quote.png new file mode 100644 index 0000000..4a4c3e0 Binary files /dev/null and b/miniprogram/assets/images/card/icon_quote.png differ diff --git a/miniprogram/assets/images/card/icon_slogan.png b/miniprogram/assets/images/card/icon_slogan.png new file mode 100644 index 0000000..51ec632 Binary files /dev/null and b/miniprogram/assets/images/card/icon_slogan.png differ diff --git a/miniprogram/assets/images/comment/fail.png b/miniprogram/assets/images/comment/fail.png new file mode 100644 index 0000000..da1f8ca Binary files /dev/null and b/miniprogram/assets/images/comment/fail.png differ diff --git a/miniprogram/assets/images/comment/icon_checked.png b/miniprogram/assets/images/comment/icon_checked.png new file mode 100644 index 0000000..7557125 Binary files /dev/null and b/miniprogram/assets/images/comment/icon_checked.png differ diff --git a/miniprogram/assets/images/pay/icon_faild.png b/miniprogram/assets/images/comment/icon_faild.png similarity index 100% rename from miniprogram/assets/images/pay/icon_faild.png rename to miniprogram/assets/images/comment/icon_faild.png diff --git a/miniprogram/assets/images/pay/icon_success.png b/miniprogram/assets/images/comment/icon_success.png similarity index 100% rename from miniprogram/assets/images/pay/icon_success.png rename to miniprogram/assets/images/comment/icon_success.png diff --git a/miniprogram/assets/images/index/icon_q.png b/miniprogram/assets/images/index/icon_q.png new file mode 100644 index 0000000..a7f45a2 Binary files /dev/null and b/miniprogram/assets/images/index/icon_q.png differ diff --git a/miniprogram/assets/images/index/name.png b/miniprogram/assets/images/index/name.png index 45c0dc8..e97ba16 100644 Binary files a/miniprogram/assets/images/index/name.png and b/miniprogram/assets/images/index/name.png differ diff --git a/miniprogram/assets/images/index/pic.png b/miniprogram/assets/images/index/pic.png deleted file mode 100644 index 7ef415a..0000000 Binary files a/miniprogram/assets/images/index/pic.png and /dev/null differ diff --git a/miniprogram/assets/images/index/slogan.png b/miniprogram/assets/images/index/slogan.png index 6810a49..4bef3de 100644 Binary files a/miniprogram/assets/images/index/slogan.png and b/miniprogram/assets/images/index/slogan.png differ diff --git a/miniprogram/assets/images/my/icon_clear.png b/miniprogram/assets/images/my/icon_clear.png new file mode 100644 index 0000000..e05702c Binary files /dev/null and b/miniprogram/assets/images/my/icon_clear.png differ diff --git a/miniprogram/components/btn/btn.scss b/miniprogram/components/btn/btn.scss index fc28a49..43da32a 100644 --- a/miniprogram/components/btn/btn.scss +++ b/miniprogram/components/btn/btn.scss @@ -84,4 +84,8 @@ $member: #653E12; border: 1rpx solid #7986FF; background: #FFFFFF; } +} +.default1{ + border: 1px solid #C3C3C3; + box-sizing: border-box; } \ No newline at end of file diff --git a/miniprogram/components/btn/btn.ts b/miniprogram/components/btn/btn.ts index d97e667..b28049b 100644 --- a/miniprogram/components/btn/btn.ts +++ b/miniprogram/components/btn/btn.ts @@ -24,11 +24,19 @@ Component({ type: String, value: '24rpx' }, - bgColor:{ - type:String, + bgColor: { + type: String, }, - padding:{ - type:String, + padding: { + type: String, + }, + fontWeight: { + type: String, + value: 'initial' + }, + fontColor: { + type: String, + value: '' } }, diff --git a/miniprogram/components/btn/btn.wxml b/miniprogram/components/btn/btn.wxml index 2e3c491..2d051d6 100644 --- a/miniprogram/components/btn/btn.wxml +++ b/miniprogram/components/btn/btn.wxml @@ -1,5 +1,4 @@ - + \ No newline at end of file diff --git a/miniprogram/components/dialog/dialog.wxml b/miniprogram/components/dialog/dialog.wxml index 7479a0a..6e3e86a 100644 --- a/miniprogram/components/dialog/dialog.wxml +++ b/miniprogram/components/dialog/dialog.wxml @@ -51,8 +51,8 @@ 5 - 返回众评,选择证书展示 - 完成电子证书授权后,返回众评再次选择想要展示的个人信息报告及对应的授权电子证书即可。 + 返回与评™,选择证书展示 + 完成电子证书授权后,返回与评™再次选择想要展示的个人信息报告及对应的授权电子证书即可。 diff --git a/miniprogram/components/star/star.scss b/miniprogram/components/star/star.scss index 89eb2fa..a4bbbdb 100644 --- a/miniprogram/components/star/star.scss +++ b/miniprogram/components/star/star.scss @@ -43,4 +43,17 @@ height: 30rpx; } } + + .cStars_half { + margin-right: 17rpx; + &:last-child{ + margin-right: 0; + } + image{ + width: 30rpx !important; + height: 30rpx !important; + } + // width: 30rpx; + // height: 30rpx; + } } \ No newline at end of file diff --git a/miniprogram/components/star/star.ts b/miniprogram/components/star/star.ts index 32fdc4e..7904b57 100644 --- a/miniprogram/components/star/star.ts +++ b/miniprogram/components/star/star.ts @@ -151,7 +151,34 @@ Component({ bgImg_all: "/assets/images/searchResult/cStar_active.png" } ], - } + cStars_half: [ + { + bgImg: "/assets/images/card/cStar_0.png", + bgImg_half: "/assets/images/card/cStar_0.5.png", + bgImg_all: "/assets/images/card/cStar_1.png" + }, + { + bgImg: "/assets/images/card/cStar_0.png", + bgImg_half: "/assets/images/card/cStar_0.5.png", + bgImg_all: "/assets/images/card/cStar_1.png" + }, + { + bgImg: "/assets/images/card/cStar_0.png", + bgImg_half: "/assets/images/card/cStar_0.5.png", + bgImg_all: "/assets/images/card/cStar_1.png" + }, + { + bgImg: "/assets/images/card/cStar_0.png", + bgImg_half: "/assets/images/card/cStar_0.5.png", + bgImg_all: "/assets/images/card/cStar_1.png" + }, + { + bgImg: "/assets/images/card/cStar_0.png", + bgImg_half: "/assets/images/card/cStar_0.5.png", + bgImg_all: "/assets/images/card/cStar_1.png" + } + ], + }, }, /** diff --git a/miniprogram/components/userInfo/userInfo.scss b/miniprogram/components/userInfo/userInfo.scss index 2510205..eef8450 100644 --- a/miniprogram/components/userInfo/userInfo.scss +++ b/miniprogram/components/userInfo/userInfo.scss @@ -4,12 +4,13 @@ display: flex; align-items: center; margin-bottom: 50rpx; - position: fixed; + // position: fixed; + position: relative; background: #7B8EFF; width: 100%; left: 0; top: 0rpx; - padding: 30rpx 0 0 30rpx; + // padding: 30rpx 0 0 30rpx; height: 150rpx; align-items: flex-start; @@ -48,6 +49,7 @@ margin: 65rpx; border-radius: 24rpx; width: 100%; + z-index:99; .dialog_title { font-size: 32rpx; diff --git a/miniprogram/pages/QA/QA.ts b/miniprogram/pages/QA/QA.ts index 8cd57f4..71e7c57 100644 --- a/miniprogram/pages/QA/QA.ts +++ b/miniprogram/pages/QA/QA.ts @@ -5,7 +5,7 @@ Page({ * 页面的初始数据 */ data: { - nodes: `

1、什么是众评数据?

众评数据是基于手机号码统计的相关数据,数据包括综合评价、标签、全国人力资源信息数据验证平台个人信息报告。

2、什么是全国人力资源信息数据验证平台个人信息报告?

个人信息报告所有数据均通过全国人力资源信息数据验证平台收录,由报告主体授权后展示在众评数据中,主要用于个人增信展示或提供给他人查验。

3、什么是实名认证用户?

手机号码已完成全国人力资源信息数据验证平台实名认证的用户,通过“实名认证”标签展示,用户需要实名认证可前往“全国人力资源信息数据验证平台”完成实名认证流程。

4、如何绑定多个手机号码?

通过“切换手机号”更换当前登录手机号,如需绑定其他号码,可通过手机号及验证码新增绑定手机号。

5、如何查看评价及标签详情?

本人被评价人数达到3人后,可开通查看评价及标签详情权限,您可邀请好友为您综合评价。

` + nodes: `

1、什么是与评™数据?

与评™数据是基于手机号码统计的相关数据,数据包括综合评价、标签、全国人力资源信息数据验证平台个人信息报告。

2、什么是全国人力资源信息数据验证平台个人信息报告?

个人信息报告所有数据均通过全国人力资源信息数据验证平台收录,由报告主体授权后展示在与评™数据中,主要用于个人增信展示或提供给他人查验。

3、什么是实名认证用户?

手机号码已完成全国人力资源信息数据验证平台实名认证的用户,通过“实名认证”标签展示,用户需要实名认证可前往“全国人力资源信息数据验证平台”完成实名认证流程。

4、如何绑定多个手机号码?

通过“切换手机号”更换当前登录手机号,如需绑定其他号码,可通过手机号及验证码新增绑定手机号。

5、如何查看评价及标签详情?

本人被评价人数达到3人后,可开通查看评价及标签详情权限,您可邀请好友为您综合评价。

` }, /** diff --git a/miniprogram/pages/card/card.json b/miniprogram/pages/card/card.json new file mode 100644 index 0000000..2021359 --- /dev/null +++ b/miniprogram/pages/card/card.json @@ -0,0 +1,8 @@ +{ + "navigationBarTitleText": "口碑名片", + "usingComponents": { + "btn":"/components/btn/btn", + "painter": "/components/painter/painter", + "star":"/components/star/star" + } +} \ No newline at end of file diff --git a/miniprogram/pages/card/card.scss b/miniprogram/pages/card/card.scss new file mode 100644 index 0000000..ac2f523 --- /dev/null +++ b/miniprogram/pages/card/card.scss @@ -0,0 +1,412 @@ +/* pages/card/card.wxss */ +page { + background: #F9F9F9; +} + +.card { + // background: #F9F9F9; + // padding: 30rpx; + display: flex; + align-items: center; + justify-content: center; + flex-direction: column; + padding-top: 20rpx; + + .card-box { + box-sizing: border-box; + width: 719rpx; + height: 382rpx; + background: url('https://chrivc.obs.cn-north-4.myhuaweicloud.com/09f36e4cf9474682b194f3c0694d239d:card_bg.png')no-repeat; + background-size: cover; + + .top { + + margin-bottom: 40rpx; + padding-top: 20rpx; + padding-left: 60rpx; + padding-right: 60rpx; + + .nameAndScore { + display: flex; + justify-content: space-between; + align-items: center; + + + .name { + font-size: 48rpx; + font-family: PingFang SC; + font-weight: 800; + color: #FFFFFF; + } + + .score { + font-size: 64rpx; + font-family: Alibaba PuHuiTi; + font-weight: 800; + color: #FFFFFF; + + + text { + font-size: 26rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + margin-right: 9rpx; + } + } + } + + .positionAndTags { + display: flex; + justify-content: space-between; + + .position { + font-size: 32rpx; + font-family: PingFang SC; + font-weight: bold; + color: #FFFFFF; + width: 350rpx; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + .company { + font-size: 24rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + margin-top: 5rpx; + width: 350rpx; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + .tagsAndStar { + + display: flex; + flex-direction: column; + + .tags { + display: flex; + justify-content: flex-end; + margin-top: 10rpx; + + .tagItem { + position: relative; + background: #2235B6; + border-radius: 22rpx; + width: 124rpx; + height: 43rpx; + display: flex; + align-items: center; + justify-content: center; + font-size: 22rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + margin-bottom: 5rpx; + margin-left: 26rpx; + + .numTag { + font-size: 14rpx; + font-family: Alibaba PuHuiTi; + font-weight: 800; + font-style: italic; + color: #FFFFFF; + background: #FF662A; + border-radius: 9px 8px 8px 4px; + width: 36rpx; + height: 19rpx; + display: flex; + align-items: center; + justify-content: center; + position: absolute; + right: -25rpx; + top: 0; + } + } + + .moreTag { + font-size: 48rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + width: 81rpx; + height: 43rpx; + background: #2235B6; + border-radius: 22rpx; + line-height: 8px; + text-align: center; + margin-left: 27rpx; + // display: flex; + // justify-content: center; + // align-items: center; + } + } + + } + } + } + + .bottom { + padding-left: 60rpx; + + .btn_copy { + margin-left: 20rpx; + text-decoration: underline; + color: rgba(255, 255, 255, .43); + } + + text { + font-size: 24rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + } + + .icon_phone { + width: 21.8rpx; + height: 20rpx; + margin-right: 9rpx; + } + + .icon_email { + width: 22rpx; + height: 19.7rpx; + margin-right: 9rpx; + margin-left: 42rpx; + } + + .introduce { + padding-right: 60rpx; + font-size: 24rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + opacity: 0.43; + margin-top: 20rpx; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + } + + + .card-box-bg { + width: 689rpx; + height: 362rpx; + position: absolute; + left: 0; + top: 0; + z-index: 0; + } + } + + // .zhanwei{ + // background: red; + // height: 200rpx; + // width: 100%; + // position: relative; + // top: -20px; + // } + .card-info-box { + margin: 15rpx; + border-radius: 24rpx; + background: #fff; + padding: 40rpx; + box-sizing: border-box; + margin-top: 20rpx; + + .title { + font-size: 30rpx; + font-family: PingFang SC; + font-weight: bold; + color: #3E3E3E; + display: flex; + justify-content: space-between; + + .btn_edit { + font-size: 30rpx; + font-family: PingFang SC; + font-weight: 500; + color: #6571D9; + display: flex; + align-items: center; + + .icon_edit { + width: 28rpx; + height: 28rpx; + margin-right: 10rpx; + } + } + + + } + + .item { + font-size: 26rpx; + font-family: PingFang SC; + font-weight: 400; + color: #9F9F9F; + margin-top: 40rpx; + display: flex; + align-items: center; + } + + .btnItem { + display: flex; + justify-content: flex-end; + } + + text { + display: inline-block; + width: 140rpx; + font-size: 26rpx; + font-family: PingFang SC; + font-weight: 500; + color: #3E3E3E; + } + } + + .otherLayout { + background: #fff; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + + + .welcome { + margin: 70rpx; + position: relative; + font-size: 30rpx; + font-family: PingFang SC; + font-weight: 500; + color: #AEAEAE; + + .icon_quote { + width: 25rpx; + height: 24rpx; + position: absolute; + top: -40rpx; + left: -36rpx; + } + + .quote_end { + transform: rotate(180deg); + position: absolute; + top: inherit; + left: inherit; + bottom: -49rpx; + right: -34rpx; + } + } + + .icon_logo { + width: 176rpx; + height: 73rpx; + margin-top: 207rpx; + } + + .icon_slogan { + width: 428rpx; + height: 41rpx; + margin-top: 21rpx; + } + + .description { + margin: 36rpx 50rpx; + font-size: 24rpx; + font-family: PingFang SC; + font-weight: 500; + color: #CACACA; + line-height: 38rpx; + + text { + text-decoration: underline; + } + + .icon_q { + width: 19rpx; + height: 19rpx; + } + } + } + + .btns { + display: flex; + justify-content: center; + position: fixed; + bottom: 42rpx; + } +} + +.canvas { + position: fixed; + opacity: 0; + left: 200%; + top: 200%; + z-index: -10; +} + +.shareBtn { + // width="442rpx" height="88rpx" fontSize="30rpx" style="margin-left: 30rpx; + width: 442rpx; + height: 88rpx; + font-size: 30rpx; + margin-left: 30rpx !important; + background: #6571D9; + font-size: 30rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FFFFFF; + border-radius: 44rpx; + display: flex; + justify-content: center; + align-items: center; +} + +.explain-box { + background: rgba(0, 0, 0, .5); + width: 100%; + height: 100%; + position: fixed; + left: 0; + top: 0; + display: flex; + align-items: center; + justify-content: center; + z-index: 99; + + .explain { + background: #fff; + border-radius: 24rpx; + // padding: 24rpx 58rpx 41rpx 58rpx; + margin: 60rpx; + display: flex; + align-items: center; + justify-content: center; + flex-direction: column; + padding-bottom: 42rpx; + + .title { + font-size: 32rpx; + font-family: PingFang SC; + font-weight: bold; + color: #3E3E3E; + margin-bottom: 26rpx; + margin-top: 42rpx; + } + + .content { + font-size: 28rpx; + font-family: PingFang SC; + font-weight: 500; + color: #9F9F9F; + margin-bottom: 33rpx; + padding: 0 58rpx; + } + } +} \ No newline at end of file diff --git a/miniprogram/pages/card/card.ts b/miniprogram/pages/card/card.ts new file mode 100644 index 0000000..46f873a --- /dev/null +++ b/miniprogram/pages/card/card.ts @@ -0,0 +1,326 @@ +// pages/card/card.ts +// import { card } from '../../utils/painter' +import { info } from "../../apis/phone"; +import { businessCard } from "../../apis/card"; +Page({ + + /** + * 页面的初始数据 + */ + data: { + cardPainter: {}, + isEdit: false, + companyName: "", + consumerId: "", + email: "", + introduction: "", + name: "", + office: "", + phone: "", + businessCard: null, + labelOptions: [], + dialogExplain: false, + type: 0, + info: {}, + dialogDetail: false, + detailInfo: '', + detailTitle: '' + }, + // saveImage() { + // let screenWidth = wx.getSystemInfoSync().screenWidth; + // let screenHeight = wx.getSystemInfoSync().screenHeight; + // let canvasContext = wx.createCanvasContext('myCanvas'); + // wx.createSelectorQuery().select('#saveArea').boundingClientRect(function (rect) { + // let top = rect.top; + // let left = rect.left; + // let width = rect.width; + // let height = rect.height; + // console.log(top, left, width, height); + + // canvasContext.drawImage('../../assets/images/card/card_bg.png', 0, 100, screenWidth, screenHeight); + + // // 将第二个绘制操作放在canvasContext.draw()方法中 + // canvasContext.draw(false, () => { + // // 在回调函数中调用wx.canvasToTempFilePath()方法进行保存图片 + // wx.canvasToTempFilePath({ + // canvasId: 'myCanvas', + // x: left, + // y: top, + // width: width, + // height: height, + // destWidth: screenWidth * 2, + // destHeight: screenHeight * 2, + // success: function (res) { + // wx.saveImageToPhotosAlbum({ + // filePath: res.tempFilePath, + // success: function () { + // wx.showToast({ + // title: '保存成功' + // }); + // }, + // fail: function () { + // wx.showToast({ + // title: '保存失败' + // }); + // } + // }); + // } + // }); + // }); + // }).exec(); + // }, + handleEdit() { + console.log('handleEdit'); + const { isEdit } = this.data + this.setData({ + isEdit: !isEdit + }) + // if (isEdit) { + + // const { companyName, email, introduction, office, phone } = this.data + // const payload = { + // companyName, email, introduction, office, phone + // } + // businessCard(payload).then(res => { + // console.log(res); + // this.getInfo(phone) + // }) + // } + // }, + }, + handleCancelEdit() { + console.log('handleCancelEdit'); + + this.setData({ + isEdit: false + }) + }, + handleSearch(){ + wx.navigateTo({ + url:`/pages/searchResult/searchResult?phone=${this.data.phone}` + }) + }, + + handleSave() { + const { companyName, email, introduction, office, phone } = this.data + const payload = { + companyName, email, introduction, office, phone + } + businessCard(payload).then((res: any) => { + console.log(res); + if (res.c === 200) { + wx.showToast({ + icon: 'none', + title: '保存成功' + }) + this.getInfo(phone) + this.setData({ + isEdit: false + }) + } + }) + }, + handleSaveContract() { + const info = this.data.info.businessCard + wx.addPhoneContact({ + firstName: info.name, + email: info.email, + organization: info.companyName, + title: info.office, + mobilePhoneNumber:this.data.phone + }) + + }, + handleDetail() { + const { phone } = this.data + wx.navigateTo({ + url: `/pages/searchResult/searchResult?phone=${phone}` + }) + }, + closeDetail() { + this.setData({ + dialogDetail: false + }) + }, + showExplain() { + this.setData({ + dialogExplain: true + }) + }, + closeExplain() { + this.setData({ + dialogExplain: false + }) + }, + // onImgOK(e: WechatMiniprogram.CustomEvent) { + // const { path } = e.detail + // this.setData({ + // shareImg: path + // }) + // // wx.showShareImageMenu({ //分享给朋友 + // // path, + // // success: (res) => { + // // console.log("分享成功:", res); + // // }, + // // fail: (err) => { + // // console.log("分享失败:", err); + // // wx.showToast({ + // // title: "分享失败", + // // duration: 2000 + // // }) + // // }, + // // }) + // }, + handleDialogDetail(e: WechatMiniprogram.BaseEvent) { + console.log(e); + const { title, info } = e.currentTarget.dataset + if (info) { + this.setData({ + dialogDetail: true, + detailInfo: info, + detailTitle: title + }) + } + }, + getInfo(phone: string) { + const { type } = this.data + info({ phone, type, businessCard: true }).then((res: any) => { + let { labelVoList } = res.d + if (res.d.businessCard) { + const { companyName, email, introduction, office } = res.d.businessCard + if(labelVoList){ + labelVoList = labelVoList.slice(0, 1) + } + + this.setData({ + businessCard: res.d.businessCard, + companyName, + email, + introduction, + office, + labelOptions: labelVoList, + info: res.d + }) + } else { + this.setData({ + info: res.d, + labelOptions: labelVoList, + }) + } + // this.setData({ + // businessCard: res.d.businessCard, + // companyName, + // email, + // introduction, + // office, + // labelOptions: res.d.labelVoList.slice(0, 2), + // info: res.d + // }) + }) + // this.downLoadCard() + + }, + phoneCall() { + wx.makePhoneCall({ + phoneNumber: this.data.phone, + }) + }, + // async downLoadCard() { + // console.log('downLoadCard'); + // const cardPainter = await card() + // this.setData({ + // cardPainter + // }) + // }, + handleCopy(e) { + const { email } = e.currentTarget.dataset + wx.setClipboardData({ + data: email, + success(res) { + wx.showToast({ + title: '复制成功', + icon: 'none' + }) + // wx.getClipboardData({ + // success(res) { + // console.log(res.data) // data + // } + // }) + } + }) + }, + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + console.log(options); + const { type, phone } = options + this.setData({ + type: Number(type), + phone + }) + this.getInfo(phone) + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + const promise = new Promise(resolve => { + setTimeout(() => { + resolve({ + title: '您好,这是我的口碑名片,请收下', + imageUrl: this.data.shareImg, + path: `/pages/card/card?phone=${this.data.phone}&type=1`, + }) + }) + }) + return { + title: '您好,这是我的口碑名片,请收下', + path: '/pages/card/card', + promise + } + } +}) \ No newline at end of file diff --git a/miniprogram/pages/card/card.wxml b/miniprogram/pages/card/card.wxml new file mode 100644 index 0000000..2823e51 --- /dev/null +++ b/miniprogram/pages/card/card.wxml @@ -0,0 +1,103 @@ + + + + + + + {{info.businessCard.name}} + 口碑指数{{tools.toFix(info.totalAverage)}} + + + + {{info.businessCard.office||'暂无职位信息'}} + {{info.businessCard.companyName||'暂无公司信息'}} + + + + + + + + {{labelOptions[0].content}} + x{{labelOptions[0].contentCount}} + + ... + + + + + + {{phone}} + + {{info.businessCard.email||'暂未添加邮箱'}} + 复制 + + {{info.businessCard.introduction||'暂未添加自我介绍'}} + + + + + + 名片信息 + 编辑 + + + 公司: + 职位: + 邮箱: + 自我介绍: + + 退出编辑 + 保存 + + + + + + + + 保存至通讯录 + 查看更多口碑评价 + + + + 与评™是全国人力资源信息数据验证平台 + 授权并监管的一款个人综合社交评价工具,根据国家《中华人民共和国网络安全法》《互联网信息服务管理办法》等条例规定,所有基础数据存储、隐私安全保障、用户行为数据溯源均由全国人力资源信息数据验证平台提供相应接口及支撑,国家监管确保与评不向第三方提供原始数据信息。 + + + + + + + + + + + + 全国人力资源信息数据验证平台 + + 全国人力资源信息数据验证平台”是由中国防伪行业协会“全国产品防伪溯源验证公共平台”建立的国家数据平台。中国防伪行业协会的业务指导部门为国家市场监督管理总局,党建工作机构为中央和国家机关工作委员会。 + + 我已了解 + + + + + + {{detailTitle}} + + {{detailInfo}} + + 关闭 + + + \ No newline at end of file diff --git a/miniprogram/pages/commentResult/commentResult.json b/miniprogram/pages/commentResult/commentResult.json new file mode 100644 index 0000000..f302f22 --- /dev/null +++ b/miniprogram/pages/commentResult/commentResult.json @@ -0,0 +1,5 @@ +{ + "usingComponents": { + "btn":"/components/btn/btn" + } +} \ No newline at end of file diff --git a/miniprogram/pages/commentResult/commentResult.scss b/miniprogram/pages/commentResult/commentResult.scss new file mode 100644 index 0000000..3613c89 --- /dev/null +++ b/miniprogram/pages/commentResult/commentResult.scss @@ -0,0 +1,29 @@ +/* pages/commentResult/commentResult.wxss */ +.box { + display: flex; + justify-content: center; + flex-direction: column; + align-items: center; + margin-top: 156rpx; + + .icon_status { + width: 161rpx; + height: 208rpx; + } + + .title { + font-size: 36rpx; + font-family: PingFang SC; + font-weight: bold; + color: #3E3E3E; + margin-bottom: 23rpx; + } + + .content { + font-size: 28rpx; + font-family: PingFang SC; + font-weight: 500; + color: #A1A1A1; + margin-bottom: 36rpx; + } +} \ No newline at end of file diff --git a/miniprogram/pages/commentResult/commentResult.ts b/miniprogram/pages/commentResult/commentResult.ts new file mode 100644 index 0000000..b78a521 --- /dev/null +++ b/miniprogram/pages/commentResult/commentResult.ts @@ -0,0 +1,80 @@ +// pages/commentResult/commentResult.ts +Page({ + + /** + * 页面的初始数据 + */ + data: { + status: 'faild' + }, + goback(){ + wx.navigateBack({ + delta: 1 + }) + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + this.setData({ + status: options.status + }) + if (options.status === 'success') { + setTimeout(() => { + wx.redirectTo({ + url: `/pages/searchResult/searchResult?phone=${options.phone}` + }) + }, 3000) + } + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/miniprogram/pages/commentResult/commentResult.wxml b/miniprogram/pages/commentResult/commentResult.wxml new file mode 100644 index 0000000..3074e31 --- /dev/null +++ b/miniprogram/pages/commentResult/commentResult.wxml @@ -0,0 +1,7 @@ + + + + 操作{{status==='faild'?'失败':'成功'}}! + {{status==='faild'?'您的实名认证信息有误,请重新填写':'即将跳转至上一页'}} + 返回重新填写 + \ No newline at end of file diff --git a/miniprogram/pages/index/index.json b/miniprogram/pages/index/index.json index 8f42b3c..57f01c8 100644 --- a/miniprogram/pages/index/index.json +++ b/miniprogram/pages/index/index.json @@ -1,6 +1,7 @@ { "navigationStyle": "custom", "usingComponents": { - "btn": "/components/btn/btn" + "btn": "/components/btn/btn", + "message-box": "/components/message/message" } } \ No newline at end of file diff --git a/miniprogram/pages/index/index.scss b/miniprogram/pages/index/index.scss index 97e18dc..541971f 100644 --- a/miniprogram/pages/index/index.scss +++ b/miniprogram/pages/index/index.scss @@ -2,7 +2,7 @@ page { background: #7E8BFF; // height: 100%; - background: url("https://chrivc.obs.cn-north-4.myhuaweicloud.com/1cde69cc683a42219c12e8e7e4f6bed0:生意伙伴人品如何@2x.png"); + background: url("https://chrivc.obs.cn-north-4.myhuaweicloud.com/ee3b42fbe99b4b79bed33816b87a02d2:组 4 拷贝@2x.png"); background-size: 100%; } @@ -21,9 +21,9 @@ page { flex-direction: column; .name { - width: 135rpx; - height: 61rpx; - margin-bottom: 17rpx; + width: 176rpx; + height: 73rpx; + margin-bottom: 20rpx; } .slogan { @@ -38,10 +38,20 @@ page { font-size: 24rpx; font-family: PingFang SC; font-weight: 500; - color: #FFFFFF; + color: #C4CAFF; line-height: 22px; - opacity: 0.58; margin-bottom: 31rpx; + text-align: center; + + text { + color: #fff; + opacity: 1; + } + + .icon_q { + width: 19rpx; + height: 19rpx; + } } .pic { @@ -56,6 +66,8 @@ page { // border-radius: 32rpx; // margin-top: 36rpx; // padding: 64rpx 48rpx; + margin-top: 96rpx; + margin-bottom: 35rpx; .top { display: flex; @@ -89,7 +101,7 @@ page { color: #FFFFFF; display: flex; justify-content: center; - margin-top: 180rpx; + margin-top: 30rpx; } } @@ -112,12 +124,14 @@ page { display: flex; align-items: center; margin-bottom: 25rpx; + justify-content: center; .sourceItem { display: flex; align-items: center; margin-right: 25rpx; + .icon_seemore { width: 26.8rpx; height: 26rpx; @@ -135,8 +149,39 @@ page { height: 25.6rpx; margin-right: 7rpx; } + + text { + color: #C4CAFF; + } } + .sourceLogos { + margin-right: 10px; + + .icon_gh { + width: 34.6rpx; + height: 33.4rpx; + margin-right: 9rpx; + } + + .icon_fw { + width: 34.9rpx; + height: 33.4rpx; + // margin-right: 7rpx; + } + } + + .sourceNames { + .name { + font-size: 20rpx; + font-family: PingFang SC; + font-weight: 500; + color: #C4CAFF; + } + } + + + } @@ -175,4 +220,47 @@ page { margin-right: 8rpx; } } +} + +.explain-box { + background: rgba(0, 0, 0, .5); + width: 100%; + height: 100%; + position: fixed; + left: 0; + top: 0; + display: flex; + align-items: center; + justify-content: center; + z-index: 99; + + .explain { + background: #fff; + border-radius: 24rpx; + // padding: 24rpx 58rpx 41rpx 58rpx; + margin: 60rpx; + display: flex; + align-items: center; + justify-content: center; + flex-direction: column; + padding-bottom: 42rpx; + + .title { + font-size: 32rpx; + font-family: PingFang SC; + font-weight: bold; + color: #3E3E3E; + margin-bottom: 26rpx; + margin-top: 42rpx; + } + + .content { + font-size: 28rpx; + font-family: PingFang SC; + font-weight: 500; + color: #9F9F9F; + margin-bottom: 33rpx; + padding: 0 58rpx; + } + } } \ No newline at end of file diff --git a/miniprogram/pages/index/index.ts b/miniprogram/pages/index/index.ts index 35be354..e024e00 100644 --- a/miniprogram/pages/index/index.ts +++ b/miniprogram/pages/index/index.ts @@ -16,6 +16,7 @@ Page({ canIUseGetUserProfile: false, canIUseOpenData: wx.canIUse('open-data.type.userAvatarUrl') && wx.canIUse('open-data.type.userNickName'), // 如需尝试获取用户信息可改为false // isBind: false + dialogExplain: false }, // 事件处理函数 handleResult() { @@ -41,9 +42,9 @@ Page({ // } // let reg = ''; // console.log((reg.test(phone)) - + // console.log(/^1[3|4|5|7|8][0-9]{9}$/.test(phone)); - + if (!/^1[3|4|5|7|8][0-9]{9}$/.test(phone)) { wx.showToast({ icon: 'none', @@ -78,7 +79,7 @@ Page({ let reg = /^1[3|4|5|7|8][0-9]{9}$/; if (reg.test(temp)) { this.setData({ - phone:temp + phone: temp }) } else { @@ -114,6 +115,17 @@ Page({ } }) }, + showExplain() { + this.setData({ + dialogExplain: true + }) + }, + closeExplain() { + this.setData({ + dialogExplain: false + }) + }, + onLoad() { // @ts-ignore if (wx.getUserProfile) { diff --git a/miniprogram/pages/index/index.wxml b/miniprogram/pages/index/index.wxml index 0e54bc3..7ea2781 100644 --- a/miniprogram/pages/index/index.wxml +++ b/miniprogram/pages/index/index.wxml @@ -4,18 +4,7 @@
- - - - 四川私慕科技有限公司 - - - - - 全国人力资源信息数据验证平台 - - - 众评是四川私慕科技有限公司与全国人力资源信息数据验证平台共同推出的一款个人综合社交评价工具,所有关键数据存储、隐私安全保障、用户行为数据溯源均由全国人力资源信息数据验证平台提供相应接口及支撑。 + @@ -31,16 +20,50 @@ - 查看众评数据 + 查看与评数据 查看我的号码 + + + + + + + + 中 国 防 伪 行 业 协 会 + 全国人力资源信息数据验证平台 + + + + 与评™是全国人力资源信息数据验证平台 + 授权并监管的一款个人综合社交评价工具,根据国家《中华人民共和国网络安全法》《互联网信息服务管理办法》等条例规定,所有基础数据存储、隐私安全保障、用户行为数据溯源均由全国人力资源信息数据验证平台提供相应接口及支撑,国家监管确保与评不向第三方提供原始数据信息。 + 《隐私政策》| 《用户协议》|  Q&A + + + 全国人力资源信息数据验证平台 + + 全国人力资源信息数据验证平台”是由中国防伪行业协会“全国产品防伪溯源验证公共平台”建立的国家数据平台。中国防伪行业协会的业务指导部门为国家市场监督管理总局,党建工作机构为中央和国家机关工作委员会。 + + 我已了解 + + + \ No newline at end of file diff --git a/miniprogram/pages/login/login.scss b/miniprogram/pages/login/login.scss index 684be78..9714c7a 100644 --- a/miniprogram/pages/login/login.scss +++ b/miniprogram/pages/login/login.scss @@ -70,4 +70,32 @@ align-items: center; justify-content: center; margin-top: 46rpx; +} + +.privacy { + display: flex; + align-items: center; + justify-content: center; + font-size: 22rpx; + font-family: PingFang SC; + font-weight: 500; + color: #8D8D8D; + margin-top: 25rpx; + + .checkbox { + width: 28rpx; + height: 28rpx; + background: #FFFFFF; + border: 2rpx solid #D4D4D4; + border-radius: 8rpx; + display: flex; + justify-content: center; + align-items: center; + margin-right: 10rpx; + + image { + width: 17rpx; + height: 13rpx; + } + } } \ No newline at end of file diff --git a/miniprogram/pages/login/login.ts b/miniprogram/pages/login/login.ts index 6770353..23f2946 100644 --- a/miniprogram/pages/login/login.ts +++ b/miniprogram/pages/login/login.ts @@ -19,6 +19,7 @@ Page({ sending: false, sendNum: 60, sendTimer: 0, + isChecked: false }, /** @@ -36,7 +37,13 @@ Page({ send() { console.log('send'); - + if (!this.data.isChecked) { + wx.showToast({ + icon: 'none', + title: '请先阅读并勾选隐私政策和用户协议' + }) + return + } if (this.data.sending) return // const rsa = new RSA() // rsa.setPublicKey(this.data.publicKey) @@ -85,6 +92,27 @@ Page({ defaultLogin() { const { phone, code } = this.data + if (!phone) { + wx.showToast({ + icon: 'none', + title: '手机号不能为空' + }) + return + } + if (!code) { + wx.showToast({ + icon: 'none', + title: '验证码不能为空' + }) + return + } + if (!this.data.isChecked) { + wx.showToast({ + icon: 'none', + title: '请先阅读并勾选隐私政策和用户协议' + }) + return + } bindPhone({ phone, code }).then(res => { if (res.c === 200) { bindPhoneList().then(resp => { @@ -96,11 +124,18 @@ Page({ // wx.redirectTo({ // url: `/pages/my/my?phone=${phone}` // }) - wx.redirectTo({ - url: `/pages/my/my` - }) + let from = wx.getStorageSync('from') + if (from.page === 'comment') { + wx.removeStorageSync('from') + wx.redirectTo({ + url: `/pages/searchResult/searchResult?phone=${from.phone}` + }) + } else { + wx.redirectTo({ + url: `/pages/my/my` + }) + } }) - } }) @@ -122,6 +157,23 @@ Page({ url: "/pages/agreement/agreement" }) }, + handleChecked() { + console.log('handleChecked'); + + this.setData({ + isChecked: !this.data.isChecked + }) + }, + goPrivacy() { + wx.navigateTo({ + url: '/pages/privacy/privacy' + }) + }, + goService() { + wx.navigateTo({ + url: '/pages/service/service' + }) + }, /** * 生命周期函数--监听页面初次渲染完成 diff --git a/miniprogram/pages/login/login.wxml b/miniprogram/pages/login/login.wxml index 2fd3611..ea6d2b6 100644 --- a/miniprogram/pages/login/login.wxml +++ b/miniprogram/pages/login/login.wxml @@ -17,6 +17,7 @@ + 我已同意《隐私政策》《用户协议》 diff --git a/miniprogram/pages/my/my.scss b/miniprogram/pages/my/my.scss index 9b66cb9..eba0eb2 100644 --- a/miniprogram/pages/my/my.scss +++ b/miniprogram/pages/my/my.scss @@ -101,6 +101,23 @@ page { // background: #F9F9F9; // height: 7rpx; // } + .btn_clear { + text-decoration: underline; + font-size: 24rpx; + font-family: PingFang SC; + font-weight: 500; + color: #ACACAC; + display: flex; + align-items: center; + justify-content: center; + margin-top: 30rpx; + + .icon_clear { + width: 27rpx; + height: 27rpx; + margin-right: 6rpx; + } + } .scoreLayout { font-size: 53rpx; diff --git a/miniprogram/pages/my/my.ts b/miniprogram/pages/my/my.ts index 386f918..5b73825 100644 --- a/miniprogram/pages/my/my.ts +++ b/miniprogram/pages/my/my.ts @@ -23,7 +23,8 @@ Page({ dialogClear: false, dialogGoPay: false, form_phone: '', - form_name: '' + form_name: '', + dialogCard: false }, handleTagRecord() { const { checkCondition } = this.data @@ -361,6 +362,26 @@ Page({ dialogGoPay: false }) }, + handleSearchOther(){ + wx.navigateTo({ + url:'/pages/index/index' + }) + }, + handleCard() { + const { realName, phone } = this.data.userInfo + if (realName) { + wx.navigateTo({ + url: `/pages/card/card?phone=${phone}&type=0`, + }) + } else { + // this.dialogCard = true + this.setData({ + dialogCard: true, + visible: true + }) + } + + }, /** * 生命周期函数--监听页面加载 */ @@ -474,13 +495,13 @@ Page({ const promise = new Promise(resolve => { setTimeout(() => { resolve({ - title: '邀请您到【众评】上对我做出印象评价', + title: '邀请您到【与评™】上对我做出印象评价', path: `/pages/searchResult/searchResult?phone=${this.data.userInfo.phone}`, }) }) }) return { - title: '邀请您到【众评】上对我做出印象评价', + title: '邀请您到【与评™】上对我做出印象评价', path: '/pages/login/login', promise } diff --git a/miniprogram/pages/my/my.wxml b/miniprogram/pages/my/my.wxml index efa6a51..a50fa12 100644 --- a/miniprogram/pages/my/my.wxml +++ b/miniprogram/pages/my/my.wxml @@ -23,7 +23,7 @@ 实名认证 - 手机号码已完成全国人力资源信息数据验证平台实名认证的用户,将通过“实名认证”标签展示,用户可前往“全国人力资源信息数据验证平台”小程序完成本人实名认证。 + {{dialogCard?'创建口碑名片需先通过“全国人力资源信息数据验证平台”实名认证。':'手机号码已完成全国人力资源信息数据验证平台实名认证的用户,将通过“实名认证”标签展示,用户可前往“全国人力资源信息数据验证平台”小程序完成本人实名认证。'}} 前往认证 @@ -84,9 +84,13 @@ + + 清空评价数据 + - 清空所有评价数据 - 邀请好友评价 + 查他人号码 + 口碑名片 + 邀请好友评价 @@ -172,10 +176,10 @@ 为确保操作为用户本人,您需要进行一次实名认证,费用¥{{money}}。清空后所有的分数和印象标签将清零。 - + - + 提交认证,确认支付 @@ -185,7 +189,7 @@ - + {{money}} @@ -206,7 +210,7 @@ {{userInfo.phone}} - “邀请您到【众评】上对我做出印象评价,国家平台隐私保护,完全匿名” + “邀请您到【与评™】上对我做出印象评价,国家平台隐私保护,完全匿名” diff --git a/miniprogram/pages/privacy/privacy.json b/miniprogram/pages/privacy/privacy.json index c5ef686..21731c6 100644 --- a/miniprogram/pages/privacy/privacy.json +++ b/miniprogram/pages/privacy/privacy.json @@ -1,4 +1,4 @@ { - "navigationBarTitleText": "众评小程序隐私政策", + "navigationBarTitleText": "与评™小程序隐私政策", "usingComponents": {} } \ No newline at end of file diff --git a/miniprogram/pages/reportDetail/reportDetail.wxml b/miniprogram/pages/reportDetail/reportDetail.wxml index 5d94ed1..ccb7179 100644 --- a/miniprogram/pages/reportDetail/reportDetail.wxml +++ b/miniprogram/pages/reportDetail/reportDetail.wxml @@ -29,7 +29,7 @@ 查看证书> - 添加至众评个人主页 + 添加至与评™个人主页 diff --git a/miniprogram/pages/searchResult/searchResult.ts b/miniprogram/pages/searchResult/searchResult.ts index 24e3c38..d40156c 100644 --- a/miniprogram/pages/searchResult/searchResult.ts +++ b/miniprogram/pages/searchResult/searchResult.ts @@ -311,8 +311,10 @@ Page({ }, submitComment() { console.log('submitComment'); - const { phone, form, tagList, userInfo } = this.data + let { phone, form, tagList, userInfo } = this.data let evaluateLabelIds = tagList.map(m => m.id).toString(); + let evaluateLabelLevels = tagList.map(m => m.evaluateLevel); + if (form.score === 0) { wx.showToast({ icon: 'none', @@ -320,25 +322,59 @@ Page({ }) return } - let paylod = { - evaluateLabelIds, - phone, - score: form.score, - sponsorPhone: userInfo.phone || undefined - } - // console.log(paylod); + form.evaluateLabelIds = evaluateLabelIds + form.phone = phone + wx.removeStorageSync('from') + if (form.score < 3) { - evaluateLaunch(paylod).then(res => { - console.log(res); - wx.showToast({ - icon: 'none', - title: '提交成功' + if (!userInfo.phone) { + wx.navigateTo({ + url: '/pages/login/login' + }) + wx.setStorageSync('from', { page: 'comment', phone }) + return + } + wx.setStorageSync('commentParams', form) + wx.navigateTo({ + url: `/pages/validComment/validComment?phone=${phone}&sponsorPhone=${userInfo.phone}` }) - this.setData({ - dialogComment: false + + } else if (evaluateLabelLevels.indexOf(2) > -1) { + if (!userInfo.phone) { + wx.navigateTo({ + url: '/pages/login/login' + }) + return + } + wx.setStorageSync('commentParams', form) + // wx.navigateTo({ + // url: '/pages/validComment/validComment' + // }) + wx.navigateTo({ + url: `/pages/validComment/validComment?phone=${phone}&sponsorPhone=${userInfo.phone}` }) - this.getInfo() - }) + + } else { + let paylod = { + evaluateLabelIds, + phone, + score: form.score, + sponsorPhone: userInfo.phone || undefined + } + console.log(paylod); + + evaluateLaunch(paylod).then(res => { + console.log(res); + wx.showToast({ + icon: 'none', + title: '提交成功' + }) + this.setData({ + dialogComment: false + }) + this.getInfo() + }) + } }, getTagListOrigin() { console.log('tagListOrigi1n'); diff --git a/miniprogram/pages/searchResult/searchResult.wxml b/miniprogram/pages/searchResult/searchResult.wxml index 2fbe2bd..d9986f8 100644 --- a/miniprogram/pages/searchResult/searchResult.wxml +++ b/miniprogram/pages/searchResult/searchResult.wxml @@ -3,7 +3,7 @@ - + 分数已隐藏 @@ -108,7 +108,7 @@ 评价对方 - 评价对方后,即可查看对方众评数据 + 评价对方后,即可查看对方与评™数据 {{form.score}} @@ -193,44 +193,7 @@ - + diff --git a/miniprogram/pages/service/service.json b/miniprogram/pages/service/service.json index 62b8b24..9ddf916 100644 --- a/miniprogram/pages/service/service.json +++ b/miniprogram/pages/service/service.json @@ -1,4 +1,4 @@ { - "navigationBarTitleText": "众评用户服务协议", + "navigationBarTitleText": "与评™用户服务协议", "usingComponents": {} } \ No newline at end of file diff --git a/miniprogram/pages/service/service.ts b/miniprogram/pages/service/service.ts index 2f81624..eb80f3a 100644 --- a/miniprogram/pages/service/service.ts +++ b/miniprogram/pages/service/service.ts @@ -6,13 +6,13 @@ Page({ */ data: { nodes:`

- 为使用众评微信小程序服务(以下简称“本服务”或“小程序服务”),您应当阅读并遵守《众评小程序用户协议》,请务必审慎阅读、充分理解各条款内容,特别是免除或限制责任的相应条款,以及开通或使用某项服务的单独协议,并选择接受或不接受。 + 为使用与评™微信小程序服务(以下简称“本服务”或“小程序服务”),您应当阅读并遵守《与评™小程序用户协议》,请务必审慎阅读、充分理解各条款内容,特别是免除或限制责任的相应条款,以及开通或使用某项服务的单独协议,并选择接受或不接受。


- 除非您已阅读并接受本条款所有条款,否则您无权使用众评微信小程序服务。您对本服务的登录、查看、发布信息等行为即视为已阅读并同意本条款的约束。 + 除非您已阅读并接受本条款所有条款,否则您无权使用与评™微信小程序服务。您对本服务的登录、查看、发布信息等行为即视为已阅读并同意本条款的约束。


@@ -39,7 +39,7 @@ Page({ 二、用户信息的提供、保护和保证、授权

- 三、众评服务使用规则 + 三、与评™服务使用规则

四、不可抗力及其他免责事由 @@ -69,7 +69,7 @@ Page({ (一)用户资格

- 请确认,在您开始登录程序使用众评服务前,您应当具备中华人民共和国法律规定的与您行为相适应的民事行为能力。若您不具备前述与您行为相适应的民事行为能力,则您及您的监护人应依照法律规定承担因此而导致的后果。 此外,您还需确保您不是任何国家、国际组织或者地域实施的贸易限制、制裁或其他法律、规则限制的对象。 + 请确认,在您开始登录程序使用与评™服务前,您应当具备中华人民共和国法律规定的与您行为相适应的民事行为能力。若您不具备前述与您行为相适应的民事行为能力,则您及您的监护人应依照法律规定承担因此而导致的后果。 此外,您还需确保您不是任何国家、国际组织或者地域实施的贸易限制、制裁或其他法律、规则限制的对象。

(二)账户说明 @@ -78,13 +78,13 @@ Page({ 1、账户获得

- 当您阅读并同意本协议,且按照提示完成全部登录绑定程序后,您可获得众评账户。 如众评系统判断您存在不当注册或不当使用账户的情形,我们可采取封禁账户等措施。 + 当您阅读并同意本协议,且按照提示完成全部登录绑定程序后,您可获得与评™账户。 如与评™系统判断您存在不当注册或不当使用账户的情形,我们可采取封禁账户等措施。

2、账户使用

- 您有权使用您设置或确认的手机号码等(“账户名称”)登录众评。 由于您的账户关联您的个人信息,您的账户仅限您本人使用。您享有您账户的使用权。我们享有账户的所有权。在使用中,您不应以任何方式私自转让该使用权,也不应以任何形式盗用他人账户。账户的行为将被视为账户注册用户的行为。 如您账户的使用可能危及您的账户安全及/或其他用户信息安全的,我们可采取相应安全措施。 + 您有权使用您设置或确认的手机号码等(“账户名称”)登录与评™。 由于您的账户关联您的个人信息,您的账户仅限您本人使用。您享有您账户的使用权。我们享有账户的所有权。在使用中,您不应以任何方式私自转让该使用权,也不应以任何形式盗用他人账户。账户的行为将被视为账户注册用户的行为。 如您账户的使用可能危及您的账户安全及/或其他用户信息安全的,我们可采取相应安全措施。

3、账户安全 @@ -96,7 +96,7 @@ Page({ 4、日常维护

- 如发现任何未经授权使用您账户登录众评或其他可能导致您账户遭窃、遗失的情况,建议您立即通知我们,并授权我们为保护您的账户信息采取相应措施。请理解,我们对您的任何请求采取行动均需要合理时间,且应您请求而采取的行动可能无法避免或阻止侵害后果的形成或扩大。 + 如发现任何未经授权使用您账户登录与评™或其他可能导致您账户遭窃、遗失的情况,建议您立即通知我们,并授权我们为保护您的账户信息采取相应措施。请理解,我们对您的任何请求采取行动均需要合理时间,且应您请求而采取的行动可能无法避免或阻止侵害后果的形成或扩大。


@@ -114,7 +114,7 @@ Page({ 1、用户信息的保护

- 保护用户信息是我们的一项基本原则。我们将按照本协议及《众评隐私政策》的规定收集、使用、储存和分享您的个人信息。本协议对信息保护相关内容未作明确规定的,均以《众评隐私政策》的内容为准。 + 保护用户信息是我们的一项基本原则。我们将按照本协议及《与评™隐私政策》的规定收集、使用、储存和分享您的个人信息。本协议对信息保护相关内容未作明确规定的,均以《与评™隐私政策》的内容为准。

(二)用户信息的保证、授权 @@ -141,58 +141,58 @@ Page({ (5)侮辱、诽谤、恐吓、涉及他人隐私等侵害他人合法权益的;

- (6)存在可能破坏、篡改、删除、影响众评系统正常运行或未经授权秘密获取众评及其他用户的数据、个人资料的病毒、木马、爬虫等恶意软件、程序代码的; + (6)存在可能破坏、篡改、删除、影响与评™系统正常运行或未经授权秘密获取与评™及其他用户的数据、个人资料的病毒、木马、爬虫等恶意软件、程序代码的;

- (7)其他违背社会公共利益或公共道德不适合在众评上发布的。 + (7)其他违背社会公共利益或公共道德不适合在与评™上发布的。

2、用户信息的授权

- 为方便您使用众评的其他相关服务,请您授权我们将您在账户注册和使用众评服务过程中提供、形成的信息传递给其他相关服务提供者,或从其他相关服务提供者获取您在注册、使用相关服务期间提供、形成的信息。 + 为方便您使用与评™的其他相关服务,请您授权我们将您在账户注册和使用与评™服务过程中提供、形成的信息传递给其他相关服务提供者,或从其他相关服务提供者获取您在注册、使用相关服务期间提供、形成的信息。


- 三、众评服务使用规则 + 三、与评™服务使用规则


- (一)在使用众评的产品或服务过程中,您应当遵守如下规则: + (一)在使用与评™的产品或服务过程中,您应当遵守如下规则:

1、遵守中国法律、法规、行政规章及规范性文件;

- 2、遵守与众评服务有关的协议、政策等文件; + 2、遵守与与评™服务有关的协议、政策等文件;

- 3、不应为任何违法、犯罪目的而使用众评服务; + 3、不应为任何违法、犯罪目的而使用与评™服务;

4、不应以任何形式侵犯任何第三方的合法权利;

- 5、不应进行任何可能对互联网正常运转造成不利影响的行为。 对于您上传到众评网站或平台的任何文本、图片、图形、音频和/ 或视频等,或您的其他使用行为,我们将依据法律法规的规定,保留对其内容监督的权利。 + 5、不应进行任何可能对互联网正常运转造成不利影响的行为。 对于您上传到与评™网站或平台的任何文本、图片、图形、音频和/ 或视频等,或您的其他使用行为,我们将依据法律法规的规定,保留对其内容监督的权利。

(二)用户行为违约及处理

- 1、在使用众评的产品或服务时,如您有如下情形之一的,视为违约: + 1、在使用与评™的产品或服务时,如您有如下情形之一的,视为违约:

(1)违反法律法规等相关规定的;

- (2)违反本协议、《众评隐私政策》等约定的; + (2)违反本协议、《与评™隐私政策》等约定的;

- 2、请确认,您对众评产品或服务的使用承担独立且完全的法律责任。如您有违约行为,相关国家机关或机构可能会对您提起诉讼、罚款或采取其他制裁措施,并要求我们给予协助。因此造成损害的(包括但不限于直接经济损失、商誉损失及支出的赔偿金、律师费、诉讼费等间接经济损失),您应承担全部责任。 此外,我们保留对您的使用等行为进行监督的权利。如您被投诉或被发现有违约行为,为及时解决问题,保护各方合法权利,我们可以独立判断并采取相应措施(包括但不限于通过技术手段删除、屏蔽相关内容或断开链接、暂停或中止向您提供服务等)。 + 2、请确认,您对与评™产品或服务的使用承担独立且完全的法律责任。如您有违约行为,相关国家机关或机构可能会对您提起诉讼、罚款或采取其他制裁措施,并要求我们给予协助。因此造成损害的(包括但不限于直接经济损失、商誉损失及支出的赔偿金、律师费、诉讼费等间接经济损失),您应承担全部责任。 此外,我们保留对您的使用等行为进行监督的权利。如您被投诉或被发现有违约行为,为及时解决问题,保护各方合法权利,我们可以独立判断并采取相应措施(包括但不限于通过技术手段删除、屏蔽相关内容或断开链接、暂停或中止向您提供服务等)。

(三)服务的变更、中断、终止 @@ -207,7 +207,7 @@ Page({ (1)根据法律法规规定,您应提交真实信息,而您提供的信息不真实、或与注册时信息不一致又未能提供合理证明。

- (2)您违反相关法律法规的规定、违反《众评隐私政策》或违反本协议的约定。 + (2)您违反相关法律法规的规定、违反《与评™隐私政策》或违反本协议的约定。

(3)按照法律法规规定,司法机关或主管部门的要求。 @@ -225,7 +225,7 @@ Page({ 1、请确认,我们可能自行或由第三方通过短信、电子邮件或电子信息等多种方式向您发送、展示广告或其他信息(包括商业与非商业信息),广告或其他信息的具体发送及展示形式、频次及内容等以实际提供为准。如您不希望收到这些信息,可以按照我们的相关提示,在设备上选择取消订阅。

- 2、我们将依照相关法律法规要求开展广告业务。对众评的产品或服务中出现的广告,您应审慎判断其真实性和可靠性,除法律明确规定外,您应对因该广告而实施的行为负责。 + 2、我们将依照相关法律法规要求开展广告业务。对与评™的产品或服务中出现的广告,您应审慎判断其真实性和可靠性,除法律明确规定外,您应对因该广告而实施的行为负责。

3、我们可能在必要时(例如因系统维护而暂停某一项服务时)向您发出与服务有关的公告。您可能无法取消这些与服务有关、性质不属于推广的公告。 @@ -240,7 +240,7 @@ Page({

- (一)在使用众评的产品或服务的过程中,可能会遇到不可抗力等风险因素,使产品或服务受到影响。不可抗力是指不能预见、不能克服并不能避免且造成重大影响的客观事件,包括但不限于自然灾害如洪水、地震、瘟疫流行和风暴等以及社会事件如战争、动乱、政府行为等。出现上述情况时,我们将努力在第一时间与相关单位配合,争取及时进行处理,但是由此给您造成的损失在法律允许的范围内免责。 + (一)在使用与评™的产品或服务的过程中,可能会遇到不可抗力等风险因素,使产品或服务受到影响。不可抗力是指不能预见、不能克服并不能避免且造成重大影响的客观事件,包括但不限于自然灾害如洪水、地震、瘟疫流行和风暴等以及社会事件如战争、动乱、政府行为等。出现上述情况时,我们将努力在第一时间与相关单位配合,争取及时进行处理,但是由此给您造成的损失在法律允许的范围内免责。

(二)在法律允许的范围内,我们对以下情形导致的服务中断或受阻、损失等后果不承担责任: @@ -261,7 +261,7 @@ Page({ 5、其他我们无法控制或合理预见的情形。

- (三)在使用众评服务的过程中,可能会遇到网络信息或其他用户行为带来的风险,可能会遇到其他用户损害合法权利(包括但不仅限于知识产权)的行为,我们不对任何信息的准确性、真实性、适用性、合法性作承诺保证或承担责任,也不对因用户的侵权行为造成的损害负责。这些风险包括但不限于: + (三)在使用与评™服务的过程中,可能会遇到网络信息或其他用户行为带来的风险,可能会遇到其他用户损害合法权利(包括但不仅限于知识产权)的行为,我们不对任何信息的准确性、真实性、适用性、合法性作承诺保证或承担责任,也不对因用户的侵权行为造成的损害负责。这些风险包括但不限于:

1、来自他人匿名或冒名的含有威胁、诽谤、令人反感或非法内容的信息。 @@ -318,7 +318,7 @@ Page({ 1、未经您明确同意,我们不会限制您按照本协议所应享有的权利。

- 2、对于重大变更(包括但不限于我们的服务模式发生重大变化),我们还会提供更为显著的通知。在该种情况下,若您继续使用我们的服务,即表示同意受经修订的协议约束。若您不接受修改后的最新协议条款,可立即停止使用众评服务,或注销账户。 + 2、对于重大变更(包括但不限于我们的服务模式发生重大变化),我们还会提供更为显著的通知。在该种情况下,若您继续使用我们的服务,即表示同意受经修订的协议约束。若您不接受修改后的最新协议条款,可立即停止使用与评™服务,或注销账户。


@@ -333,7 +333,7 @@ Page({ 1、本协议的成立、生效、履行、解释及因本协议产生的任何争议,均适用中华人民共和国法律(不包括港澳台地区法律)。如法律无相关规定的,参照商业惯例及/或行业惯例。

- 2、您因使用众评产品或服务所产生的与众评服务有关的任何纠纷或争议,首先应友好协商解决;协商不成的,您同意将纠纷或争议提交北京淘友天下科技发展有限公司所在地有管辖权的人民法院管辖。 + 2、您因使用与评™产品或服务所产生的与与评™服务有关的任何纠纷或争议,首先应友好协商解决;协商不成的,您同意将纠纷或争议提交北京淘友天下科技发展有限公司所在地有管辖权的人民法院管辖。

3、本协议所有条款的标题仅为阅读方便,本身并无实际涵义,不能作为本协议涵义解释的依据。 diff --git a/miniprogram/pages/shareTimeLine/shareTimeLine.wxml b/miniprogram/pages/shareTimeLine/shareTimeLine.wxml index 645f3cd..f9e5920 100644 --- a/miniprogram/pages/shareTimeLine/shareTimeLine.wxml +++ b/miniprogram/pages/shareTimeLine/shareTimeLine.wxml @@ -68,7 +68,7 @@ - “邀请您到【众评】上对我做出印象评价,国家平台隐私保护,完全匿名” + “邀请您到【与评™】上对我做出印象评价,国家平台隐私保护,完全匿名” diff --git a/miniprogram/pages/validComment/validComment.json b/miniprogram/pages/validComment/validComment.json new file mode 100644 index 0000000..6ac4404 --- /dev/null +++ b/miniprogram/pages/validComment/validComment.json @@ -0,0 +1,8 @@ +{ + "navigationBarBackgroundColor": "#FFFFFF", + "navigationBarTextStyle": "black", + "navigationBarTitleText": "", + "usingComponents": { + "btn":"/components/btn/btn" + } +} \ No newline at end of file diff --git a/miniprogram/pages/validComment/validComment.scss b/miniprogram/pages/validComment/validComment.scss new file mode 100644 index 0000000..fb3ad02 --- /dev/null +++ b/miniprogram/pages/validComment/validComment.scss @@ -0,0 +1,46 @@ +/* pages/validComment/validComment.wxss */ +page { + background: #F6F6F6; + + .tip { + padding: 24rpx 30rpx; + background: #FFEBEB; + font-size: 22rpx; + font-family: PingFang SC; + font-weight: 500; + color: #FF614C; + margin-bottom: 20rpx; + } + + .form { + .form-box-item { + margin-bottom: 20rpx; + background: #fff; + padding: 36rpx 30rpx 10rpx 30rpx; + + .form-label { + margin-bottom: 24rpx; + } + + .form-item { + border-bottom: 1px solid #EBEBEB; + + + &:last-child { + border-bottom: 0; + } + + input { + height: 88rpx; + } + } + } + } +} +.center{ + display: flex; + justify-content: center; +} +.mt30{ + margin-top: 30rpx; +} \ No newline at end of file diff --git a/miniprogram/pages/validComment/validComment.ts b/miniprogram/pages/validComment/validComment.ts new file mode 100644 index 0000000..8f4ea31 --- /dev/null +++ b/miniprogram/pages/validComment/validComment.ts @@ -0,0 +1,138 @@ +// pages/validComment/validComment.ts +import { evaluateLaunch } from "../../apis/phone"; +Page({ + + /** + * 页面的初始数据 + */ + data: { + // form: { + name: "", + phone: "", + sponsorName: "", + sponsorPhone: "", + // }, + commentParams: {} + }, + submit() { + const { name, phone, sponsorName, sponsorPhone, commentParams } = this.data + if (!name) { + wx.showToast({ + icon: 'none', + title: '请输入对方姓名' + }) + return + } + if (!phone) { + wx.showToast({ + icon: 'none', + title: '请输入对方手机号' + }) + return + } + if (!sponsorName) { + wx.showToast({ + icon: 'none', + title: '请输入您的姓名' + }) + return + } + if (!sponsorPhone) { + wx.showToast({ + icon: 'none', + title: '请输入您的手机号' + }) + return + } + const payload = { + evaluateLabelIds: commentParams.evaluateLabelIds, + score: commentParams.score, + name, + phone, + sponsorName, + sponsorPhone + } + // console.log(payload); + + evaluateLaunch(payload).then(res => { + // console.log(res); + if (res.c === 200) { + wx.navigateTo({ + url: `/pages/commentResult/commentResult?phone=${payload.phone}&status=success` + }) + } else if (res.c === 501007) { + wx.showToast({ + icon: 'none', + // image: '/assets/images/comment/fail.png', + title: res.m, + duration: 2000 + }) + } else { + wx.navigateTo({ + url: `/pages/commentResult/commentResult?status=faild` + }) + } + }) + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + console.log(options, wx.getStorageSync('commentParams')); + this.setData({ + commentParams: wx.getStorageSync('commentParams'), + sponsorPhone: options.sponsorPhone, + phone: options.phone, + }) + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/miniprogram/pages/validComment/validComment.wxml b/miniprogram/pages/validComment/validComment.wxml new file mode 100644 index 0000000..87350d3 --- /dev/null +++ b/miniprogram/pages/validComment/validComment.wxml @@ -0,0 +1,28 @@ + + + 根据《中华人民共和国网络安全法》《互联网信息服务管理办法》法律法规和国家有关规定,为规避恶意评价、随意诋毁他人,现按照“后台实名、前台匿名”原则,要求本平台记录低分评价前,须验证评价人确实认识被评价人,同时要求评价人为实名用户,请放心验证,您和对方的实名信息以及您的评价细节数据受国家平台监管,遵守最高等级隐私信息安全保护,不会对任何第三方透露。 + + + 验证对方信息 + + + + + + + + + + 验证用户本人信息 + + + + + + + + + + 提交认证 + + \ No newline at end of file diff --git a/miniprogram/utils/painter.ts b/miniprogram/utils/painter.ts index e243871..1693b84 100644 --- a/miniprogram/utils/painter.ts +++ b/miniprogram/utils/painter.ts @@ -1,19 +1,90 @@ import { loadImg } from './util' import { parseTime } from './index' -export async function card(QRCode: string) { +export async function card() { const scale = 2; - const bg = await loadImg('https://chrivc.obs.cn-north-4.myhuaweicloud.com/cab0fd6a9335480bbc882968f5a356f4:组 1 拷贝 6.png') + const bg = await loadImg('https://chrivc.obs.cn-north-4.myhuaweicloud.com/09f36e4cf9474682b194f3c0694d239d:card_bg.png') + const tags = [{ + type: 'text', + text: '特别靠谱', + css: { + width: `${124 * scale}rpx`, + height: `${34.86 * scale}rpx`, + display: 'inline-block', + textAlign: 'center', + padding: `${11 * scale}rpx 0 ${11 * scale}rpx 0`, + background: '#2235B6', + borderRadius: `${22 * scale}rpx`, + color: '#ffffff', + fontSize: `${22 * scale}rpx`, + // fontWeight: 'bold', + top: `${150 * scale}rpx`, + left: `${391 * scale}rpx`, + } + }, + { + type: 'text', + text: '才华横溢', + css: { + width: `${124 * scale}rpx`, + height: `${43 * scale}rpx`, + textAlign: 'center', + padding: `${11 * scale}rpx`, + boxSizing: 'border-box', + background: '#2235B6', + borderRadius: `${22 * scale}rpx`, + color: '#ffffff', + fontSize: `${22 * scale}rpx`, + top: `${150 * scale}rpx`, + left: `${559 * scale}rpx`, + } + }] + const tagNums = [{ + type: 'text', + text: 'x50', + css: { + width: `${36 * scale}rpx`, + height: `${19 * scale}rpx`, + textAlign: 'center', + padding: `${4 * scale}rpx ${6 * scale}rpx ${5 * scale}rpx ${3 * scale}rpx`, + fontWeight: 'bold', + fontStyle: 'italic', + background: '#FF662A', + borderRadius: `${9 * scale}rpx ${8 * scale}rpx ${8 * scale}rpx ${4 * scale}rpx`, + color: '#ffffff', + fontSize: `${14 * scale}rpx`, + top: `${145 * scale}rpx`, + left: `${508 * scale}rpx`, + } + }, + { + type: 'text', + text: 'x99', + css: { + textAlign: 'center', + padding: `${4 * scale}rpx ${6 * scale}rpx ${5 * scale}rpx ${3 * scale}rpx`, + fontWeight: 'bold', + fontStyle: 'italic', + background: '#FF662A', + boxSizing: 'border-box', + borderRadius: `${9 * scale}rpx ${8 * scale}rpx ${8 * scale}rpx ${4 * scale}rpx`, + color: '#ffffff', + fontSize: `${14 * scale}rpx`, + top: `${145 * scale}rpx`, + left: `${665 * scale}rpx`, + } + }, + ] return { - width: `${429 * scale}rpx`, - height: `${546 * scale}rpx`, + width: `${719 * scale}rpx`, + height: `${382 * scale}rpx`, views: [ // 背景 { type: 'image', url: bg.path, css: { - width: `${429 * scale}rpx`, - height: `${546 * scale}rpx`, + width: `${719 * scale}rpx`, + height: `${382 * scale}rpx`, left: '0rpx', top: '0rpx' } @@ -29,17 +100,189 @@ export async function card(QRCode: string) { // left: `${82 * scale}rpx`, // } // }, + { + type: 'text', + text: '高叶', + css: { + color: '#ffffff', + fontSize: `${48 * scale}rpx`, + fontWeight: 'bold', + top: `${59 * scale}rpx`, + left: `${60 * scale}rpx`, + } + }, + { + type: 'text', + text: '4.5', + css: { + color: '#ffffff', + fontSize: `${78 * scale}rpx`, + fontWeight: 'bold', + top: `${56 * scale}rpx`, + left: `${509 * scale}rpx`, + } + }, + { + type: 'text', + text: '分', + css: { + color: '#ffffff', + fontSize: `${48 * scale}rpx`, + fontWeight: 'bold', + top: `${78 * scale}rpx`, + left: `${632 * scale}rpx`, + } + }, + ...tags, + ...tagNums, // { // type: 'text', - // text: '溯源优才', + // text: '特别靠谱', // css: { - // color: '#3A61B1', - // fontSize: `${48 * scale}rpx`, - // fontWeight: 'bold', - // top: `${59 * scale}rpx`, - // left: `${142 * scale}rpx`, + // width: `${124 * scale}rpx`, + // height: `${34.86 * scale}rpx`, + // display: 'inline-block', + // textAlign: 'center', + // padding: `${11 * scale}rpx 0 ${11 * scale}rpx 0`, + // background: '#2235B6', + // borderRadius: `${22 * scale}rpx`, + // color: '#ffffff', + // fontSize: `${22 * scale}rpx`, + // // fontWeight: 'bold', + // top: `${150 * scale}rpx`, + // left: `${391 * scale}rpx`, // } // }, + // { + // type: 'text', + // text: 'x50', + // css: { + // width: `${36 * scale}rpx`, + // height: `${19 * scale}rpx`, + // textAlign: 'center', + // padding: `${4 * scale}rpx`, + // fontWeight: 'bold', + // fontStyle: 'italic', + // background: '#FF662A', + // borderRadius: `${9 * scale}rpx ${8 * scale}rpx ${8 * scale}rpx ${4 * scale}rpx`, + // color: '#ffffff', + // fontSize: `${14 * scale}rpx`, + // top: `${145 * scale}rpx`, + // left: `${504 * scale}rpx`, + // } + // }, + // { + // type: 'text', + // text: '才华横溢', + // css: { + // width: `${124 * scale}rpx`, + // height: `${43 * scale}rpx`, + // textAlign: 'center', + // padding: `${11 * scale}rpx`, + // boxSizing: 'border-box', + // background: '#2235B6', + // borderRadius: `${22 * scale}rpx`, + // color: '#ffffff', + // fontSize: `${22 * scale}rpx`, + // top: `${150 * scale}rpx`, + // left: `${559 * scale}rpx`, + // } + // }, + // { + // type: 'text', + // text: 'x99', + // css: { + // textAlign: 'center', + // padding: `${4 * scale}rpx ${6 * scale}rpx ${5 * scale}rpx ${3 * scale}rpx`, + // fontWeight: 'bold', + // fontStyle: 'italic', + // background: '#FF662A', + // boxSizing: 'border-box', + // borderRadius: `${9 * scale}rpx ${8 * scale}rpx ${8 * scale}rpx ${4 * scale}rpx`, + // color: '#ffffff', + // fontSize: `${14 * scale}rpx`, + // top: `${145 * scale}rpx`, + // left: `${665 * scale}rpx`, + // } + // }, + { + type: 'text', + text: '暂无职位信息', + css: { + color: '#ffffff', + fontSize: `${32 * scale}rpx`, + top: `${143 * scale}rpx`, + left: `${60 * scale}rpx`, + } + }, + { + type: 'text', + text: '暂无公司信息', + css: { + color: '#ffffff', + fontSize: `${24 * scale}rpx`, + fontWeight: 'bold', + top: `${184 * scale}rpx`, + left: `${60 * scale}rpx`, + } + }, + { + type: 'image', + url: '/assets/images/card/icon_phone.png', + text: '暂无公司信息', + css: { + color: '#ffffff', + top: `${268 * scale}rpx`, + left: `${61 * scale}rpx`, + } + }, + { + type: 'text', + text: '18702872377', + css: { + color: '#ffffff', + fontSize: `${24 * scale}rpx`, + fontWeight: 'bold', + top: `${258 * scale}rpx`, + left: `${92 * scale}rpx`, + } + }, + { + type: 'image', + url: '/assets/images/card/icon_email.png', + text: '暂无公司信息', + css: { + color: '#ffffff', + // fontSize: `${48 * scale}rpx`, + // fontWeight: 'bold', + top: `${268 * scale}rpx`, + left: `${289 * scale}rpx`, + } + }, + { + type: 'text', + text: '暂未添加邮箱', + css: { + color: '#ffffff', + fontSize: `${24 * scale}rpx`, + fontWeight: 'bold', + top: `${258 * scale}rpx`, + left: `${324 * scale}rpx`, + } + }, + { + type: 'text', + text: '自我介绍 : 暂未添加自我介绍', + css: { + color: 'rgba(255,255,255,.43)', + fontSize: `${24 * scale}rpx`, + // fontWeight: 'bold', + maxLines: "1", + top: `${301 * scale}rpx`, + left: `${63 * scale}rpx`, + } + }, + // { // type: 'text', // text: '全国人力资源信息数据验证平台', @@ -51,28 +294,28 @@ export async function card(QRCode: string) { // left: `${61 * scale}rpx`, // } // }, - { - type: 'rect', - css: { - top: `${187 * scale}rpx`, - left: `${71 * scale}rpx`, - width: `${293 * scale}rpx`, - height: `${293 * scale}rpx`, - borderRadius: `${10 * scale}rpx`, - color: "#FFFFFF" - }, - }, + // { + // type: 'rect', + // css: { + // top: `${187 * scale}rpx`, + // left: `${71 * scale}rpx`, + // width: `${293 * scale}rpx`, + // height: `${293 * scale}rpx`, + // borderRadius: `${10 * scale}rpx`, + // color: "#FFFFFF" + // }, + // }, // 二维码 - { - type: 'image', - url: QRCode, - css: { - width: `${253 * scale}rpx`, - height: `${253 * scale}rpx`, - top: `${207 * scale}rpx`, - left: `${91 * scale}rpx`, - } - } + // { + // type: 'image', + // url: QRCode, + // css: { + // width: `${253 * scale}rpx`, + // height: `${253 * scale}rpx`, + // top: `${207 * scale}rpx`, + // left: `${91 * scale}rpx`, + // } + // } ] } } diff --git a/miniprogram/utils/request.ts b/miniprogram/utils/request.ts index d9b9844..8af356f 100644 --- a/miniprogram/utils/request.ts +++ b/miniprogram/utils/request.ts @@ -1,6 +1,5 @@ -// export const baseUrl = 'https://www.chrivc.com/api'; -// export const baseUrl = 'https://app.pc.seemore.club'; -export const baseUrl = 'http://office.xianci.info:19092'; +export const baseUrl = 'https://app.pc.seemore.club'; +// export const baseUrl = 'http://office.xianci.info:19092'; // export const baseUrl = 'http://192.168.168.189:9090'; // export const baseUrl = 'http://120.77.82.246:18085'; // export const baseUrl = 'http://192.168.168.234:18085'; @@ -24,13 +23,13 @@ export function request(config: WechatMiniprogram.RequestOption) { }) wx.request({ ...config, - url: baseUrl + url, + url: baseUrl + url, header: { ...header, Authorization: wx.getStorageSync('Authorization') }, timeout: 60000, - success: (res:any) => { + success: (res: any) => { const { data } = res if (data.c !== 200) { wx.nextTick(() => { @@ -56,6 +55,17 @@ export function request(config: WechatMiniprogram.RequestOption) { title: msg }) } + if (data.c === 501007 || data.c === 501006) { + resolve(data) + } + // if (data.c === 501006) { + // wx.showToast({ + // duration: 1500, + // icon: 'none', + // image: '/assets/images/comment/fail.png', + // title: msg + // }) + // } reject(data) }) } else { diff --git a/typings/index.d.ts b/typings/index.d.ts index 275c0ea..fc66942 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -13,8 +13,9 @@ interface IAppOption { userInfo?: WechatMiniprogram.UserInfo & UserInfo, openId?: string, unionId?: string, - ready?: Boolean - } + ready?: Boolean, + smsCode?: string, + }, userInfoReadyCallback?: WechatMiniprogram.GetUserInfoSuccessCallback, getUserInfo: Function, reload: Function,