diff --git a/README.md b/README.md index b9c19e8..f7311b6 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,10 @@ # Suimang-wxapp +setStorageSync 键名 +userId --用户id,用于邀请分享功能 +loginAwardCoin --注册奖励金币 +inviteAwardCoin --邀请奖励金币 +plat --根据平台不同来返回的值,用于发送请求 1为微信,2为抖音 wx-"appid": "wx75cf14e3a0d45821", diff --git a/src/App.vue b/src/App.vue index 416bfc9..a64281b 100644 --- a/src/App.vue +++ b/src/App.vue @@ -19,8 +19,10 @@ onLaunch(() => { if (res.uniPlatform == "web") { uniPlatform = 1; } else if (res.uniPlatform == "mp-weixin") { + uni.setStorageSync("plat", 1); uniPlatform = 2; } else if (res.uniPlatform == "mp-toutiao") { + uni.setStorageSync("plat", 2); uniPlatform = 3; } if (res.osName == "windows") { @@ -42,7 +44,7 @@ onLaunch(() => { }, }); - uni.setStorageSync("userId", "114514"); + // uni.setStorageSync("userId", "114514"); const updateManager = uni.getUpdateManager(); diff --git a/src/api/lookPhoto.js b/src/api/lookPhoto.js index df6e4f1..d0dcd02 100644 --- a/src/api/lookPhoto.js +++ b/src/api/lookPhoto.js @@ -52,3 +52,15 @@ export function getUserQrcodeApi(data) { data }) } + +/** +* @description:获取订阅消息模版id +* @param +* @return: data +*/ +export function getTemplateMsgApi() { + return request({ + url: `api/templateMsg/list?projectType=5&plat=${uni.getStorageSync("plat")}&type=1`, + method: 'get', + }) +} diff --git a/src/api/uploadphoto.js b/src/api/uploadphoto.js index 7006a54..2cfd8f2 100644 --- a/src/api/uploadphoto.js +++ b/src/api/uploadphoto.js @@ -27,4 +27,29 @@ export function addImageApi(data) { method: 'post', data }); +} + +/** +* @description:获取登陆,注册送多少金币的接口 +* @param "projectType":5,//智像固定5 "type":1-注册,2-邀请 +* @return: data +*/ +export function getProjectConfigApi(data) { + return request({ + url: `api/glodConfig/getProjectConfig`, + method: 'post', + data + }) +} + +/** +* @description:获取照片生成次数,判断是不是首次生成 +* @param "projectType":5,//智像固定5 "type":1-注册,2-邀请 +* @return: data +*/ +export function getCountApi() { + return request({ + url: `api/digitalAvatarPhoto/getCount`, + method: 'get', + }) } \ No newline at end of file diff --git a/src/pages/closeStyle/closeStyle copy.vue b/src/pages/closeStyle/closeStyle copy.vue new file mode 100644 index 0000000..c8098d3 --- /dev/null +++ b/src/pages/closeStyle/closeStyle copy.vue @@ -0,0 +1,225 @@ + + + + + diff --git a/src/pages/closeStyle/closeStyle.vue b/src/pages/closeStyle/closeStyle.vue index c8098d3..58827a3 100644 --- a/src/pages/closeStyle/closeStyle.vue +++ b/src/pages/closeStyle/closeStyle.vue @@ -1,14 +1,22 @@