Commit 905d1c7b authored by Mac's avatar Mac

1

parent 93dee415
......@@ -92,6 +92,9 @@
//调用获取code
getCode(obj) {
var that = this;
uni.showLoading({
title: '登录中'
});
uni.getUserInfo({
provider: 'weixin',
success: info => {
......@@ -117,9 +120,7 @@
getLogin(obj) {
var that = this;
that.showLogin =false
uni.showLoading({
title: '登录中'
});
let pid = uni.getStorageSync("pid") ? uni.getStorageSync("pid").pid : 0;
let Up = uni.getStorageSync("Up") ? uni.getStorageSync("Up").Up : 0;
let SmallShopId = uni.getStorageSync("SmallShopId") ? uni.getStorageSync("SmallShopId").SmallShopId : 0;
......
......@@ -572,15 +572,21 @@
</view>
</view>
</u-popup>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'gbAuth'></auth>
</view>
</template>
<script>
import auth from "@/components/auth/index.vue";
export default{
components: {
auth
},
data(){
return{
pageTitle: "活动详情",
mainColor: "",
showAuth:false,
msg:{
pageIndex:1,
pageSize:20,
......@@ -672,10 +678,20 @@
richtext = richtext.replace(regex, `<img width="100%"`); //图片超出的处理
this.details.Content = richtext
this.init()//评论列表
//判断是否登录
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
// this.showAuth = true;
} else{
if(this.details.IsOpenEnroll==1){
this.GetActivityEnrollPageList()//获取招募贴报名列表
}
}
}
);
......@@ -747,6 +763,14 @@
this.showreply = false
},
setSend(type=1){
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
let Id = this.sendMsg.ParentId
uni.showLoading({
title:'发表中~'
......@@ -806,12 +830,25 @@
this.initialize()
}
);
}
},
getimgs(){
//判断是否登录
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
let sendMsg = encodeURIComponent(JSON.stringify(this.sendMsg))
uni.navigateTo({
url: '/pages/blindDate/sendimg?sendMsg=' + sendMsg
})
}
},
Children(){
this.initialize()
......@@ -935,10 +972,20 @@
);
},
gosigUp(){//报名页面
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
let details = encodeURIComponent(JSON.stringify(this.details))
uni.navigateTo({
url: '/pages/blindDate/stickSignUp?details=' + details
})
}
},
gobmlist(){//查看当前活动的报名列表
let type =0
......@@ -950,6 +997,14 @@
})
},
getfollow(x){
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
let ID=0
if(x.IsFocus!=0){
ID = x.MyFollowId
......@@ -979,6 +1034,8 @@
}
);
}
},
keyboardheightchange(e){
console.log(e.detail.height)
......@@ -986,7 +1043,14 @@
that.oneheight=e.detail.height-1;
that.$forceUpdate()
},
reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth=false;
},
//关闭登录窗口
gbAuth(){
this.showAuth = false;
},
}
}
......
......@@ -144,7 +144,7 @@ export default {
nomore: "没有更多了",
},
forumList:[],
showtype:2,
showtype:2,//好像这里没配置了 直接显示的大图模式
};
},
created() {
......@@ -173,10 +173,11 @@ export default {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
// this.showAuth = true;
} else{
this.GetForumList()
}
this.GetForumList()
},
methods: {
......@@ -250,9 +251,19 @@ export default {
}
},
gopublishing(){//发帖
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
uni.navigateTo({
url: '/pages/blindDate/postPublishing'
})
}
},
reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo");
......@@ -261,7 +272,7 @@ export default {
},
//关闭登录窗口
gbAuth(){
uni.navigateBack()
this.showAuth = false;
},
gopostdetails(x){//招募贴的
uni.navigateTo({
......
......@@ -494,16 +494,25 @@
nickName: "未登录",
avatarUrl: ""
};
if(this.IsOpenMiAi ==0){
this.showAuth = true;
}
} else {
this.init();
}
if(this.IsOpenMiAi ==1){
this.init();
}
},
onShow(){
if (!this.u) {
} else {
if(this.IsOpenMiAi ==0){
this.getDMCount();
}
}
},
......@@ -536,8 +545,11 @@
this.status = "nomore";
}
}
if(this.IsOpenMiAi ==0){
this.getDMCount()
}
}
);
},
getDMCount(){
......@@ -603,9 +615,21 @@
},
//关闭登录窗口
gbAuth() {
uni.navigateBack()
this.showAuth = false
},
getdian(x, i) { //点击点点
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else {
if(this.dianindex == i){
this.g[i].dianshow = !this.g[i].dianshow;
this.dianindex = i
......@@ -616,6 +640,8 @@
}
this.$forceUpdate()
}
},
dianzan(x, i) { //点赞
this.choiceId = x.id;
......@@ -728,6 +754,17 @@
);
},
addComment() {
this.u = uni.getStorageSync("mall_UserInfo");
console.log(this.u)
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else {
if (this.commentMsg.Content == '') {
uni.showToast({
title: '请输入评论',
......@@ -750,6 +787,8 @@
}
}
);
}
},
init2(type) { //根据id去查询当前的数据 只更新当前数据
......@@ -821,9 +860,18 @@
}
},
btnclick(item) {//跳入发布
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else {
uni.navigateTo({
url: '/pages/friendcircle/release'
})
}
innerAudioContext.stop();
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment