Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
swx_weapp
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
hookehuyr
2022-11-03 16:35:17 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1a932ef69c78b36c9c67c4bd103f3e030dc23821
1a932ef6
1 parent
649d9721
✨ feat: 测试调整文档
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
58 additions
and
40 deletions
src/components/activity-bar.vue
src/components/activity-card.vue
src/pages/activityDetail/index.vue
src/pages/auth/index.vue
src/pages/createActivity/index.vue
src/pages/editInfo/index.vue
src/pages/my/index.vue
src/pages/myFollowUser/index.vue
src/pages/userAdd/index.config.js
src/pages/userAdd/index.vue
src/pages/userManage/index.vue
src/pages/userSearch/index.vue
src/components/activity-bar.vue
View file @
1a932ef
<!--
* @Date: 2022-09-26 16:10:35
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
2 17:00:30
* @LastEditTime: 2022-11-0
3 16:19:26
* @FilePath: /swx/src/components/activity-bar.vue
* @Description: 活动详情页底部导航栏
-->
...
...
@@ -75,15 +75,15 @@ const props = defineProps({
volunteerStatus : String,
})
const emit = defineEmits(['on-handle']);
const goTo = (type) => {
if (type === 'home') { // 返回首页
Taro.redirectTo({
url: '../index/index'
})
} else if (type === 'join') { // 活动报名
Taro.navigateTo({
url: '../joinActivity/index?id=' + getCurrentPageParam().id
})
emit('on-handle', { type: 'join' });
} else if (type === 'volunteer') { // 义工报名
if (props.volunteerStatus) {
Taro.navigateTo({
...
...
src/components/activity-card.vue
View file @
1a932ef
<!--
* @Date: 2022-09-20 15:39:37
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
1 14:21:37
* @LastEditTime: 2022-11-0
3 16:17:22
* @FilePath: /swx/src/components/activity-card.vue
* @Description: 活动卡片组件
-->
...
...
src/pages/activityDetail/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-26 14:36:57
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-03 1
1:46:08
* @LastEditTime: 2022-11-03 1
6:27:17
* @FilePath: /swx/src/pages/activityDetail/index.vue
* @Description: 活动详情页
-->
...
...
@@ -106,7 +106,7 @@
</view>
</view>
<view style="height: 6rem;"></view>
<activity-bar :user-type="userType" :reg-id="reg_id" :member-role="member_role" :reg-role="reg_role" :is-end="is_end" :activity-status="activity_status" :volunteer-status="volunteer_status" />
<activity-bar
@on-handle="onHandle"
:user-type="userType" :reg-id="reg_id" :member-role="member_role" :reg-role="reg_role" :is-end="is_end" :activity-status="activity_status" :volunteer-status="volunteer_status" />
<!-- <van-action-sheet
:z-index="10"
...
...
@@ -155,6 +155,7 @@ import { infoUserAPI } from '@/api/User/index';
import { qrCodeActivityAPI } from '@/api/Activity/index';
import icon_share from '@/images/icon/share.png'
import image_line from '@/images/line@2x-2.png'
import Toast from '../../components/vant-weapp/toast/toast';
const nickname = ref('');
const avatar = ref('');
...
...
@@ -618,6 +619,21 @@ export default {
// }
// 返回shareObj
return shareObj;
},
methods: {
onHandle ({ type }) { // 活动报名操作回调
if (this.activity.reg_max && (this.activity.reg_count === this.activity.reg_max)) {
Toast('活动人员已满');
return false;
} else if (+new Date(this.server_time) > +new Date(this.activity.reg_end_time)) {
Toast('报名已结束');
return false;
} else if (type === 'join') {
Taro.navigateTo({
url: '../joinActivity/index?id=' + getCurrentPageParam().id
})
}
}
}
};
</script>
...
...
src/pages/auth/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
1 15:47:30
* @LastEditTime: 2022-11-0
3 16:30:02
* @FilePath: /swx/src/pages/auth/index.vue
* @Description: 文件描述
-->
...
...
src/pages/createActivity/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-21 16:04:10
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-03 1
3:19:04
* @LastEditTime: 2022-11-03 1
5:47:28
* @FilePath: /swx/src/pages/createActivity/index.vue
* @Description: 创建活动页面
-->
...
...
@@ -141,14 +141,14 @@
<view class="form-item inner-sub">
<view class="inner-sub-border">
<view class="form-item-title fix">
允许
内部人员
报名活动
允许
义工
报名活动
<van-icon :name="icon_vip" size="1rem" color="" class="vip-icon" />
</view>
<van-switch style="float: right; padding-top: 0.5rem;" :checked="is_inner" @change="onInnerChange"
size="1.5rem" active-color="#199A74" inactive-color="#FFFFFF" />
</view>
</view>
<view class="form-item blacklist-sub">
<
!-- <
view class="form-item blacklist-sub">
<view class="blacklist-sub-border">
<view class="form-item-title fix">
屏蔽黑名单用户
...
...
@@ -157,12 +157,12 @@
<van-switch style="float: right; padding-top: 0.5rem;" :checked="is_black" @change="onBlackChange"
size="1.5rem" active-color="#199A74" inactive-color="#FFFFFF" />
</view>
</view>
</view>
-->
<view class="form-item server-sub">
<van-row>
<van-col span="10" offset="0">
<view class="form-item-title fix">
服务
岗位报名
义工
岗位报名
<van-icon :name="icon_vip" size="1rem" color="" class="vip-icon" />
</view>
</van-col>
...
...
@@ -182,7 +182,7 @@
<view class="confirm-publish-wrapper">
<view class="box">
<view @tap="create_show=true" class="button">确定
发布
</view>
<view @tap="create_show=true" class="button">确定</view>
</view>
</view>
...
...
src/pages/editInfo/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-30 09:53:14
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-03 1
4:31:02
* @LastEditTime: 2022-11-03 1
6:33:28
* @FilePath: /swx/src/pages/editInfo/index.vue
* @Description: 文件描述
-->
...
...
@@ -49,8 +49,9 @@
<view class="at-input" style="margin-right: 1rem;">
<view class="at-input__container">
<label class="h5-label at-input__title at-input__title">状态</label>
<input @tap="show_status_popup=true" class="h5-input at-input__input" placeholder-class="placeholder" :value="user_status" placeholder="请选择用户状态" :disabled="true"/>
<view style="margin-right: 0; margin-top: 0.5rem;"><van-icon @tap="show_status_popup=true" :name="icon_sel" color="" /></view>
<!-- <input @tap="show_status_popup=true" class="h5-input at-input__input" placeholder-class="placeholder" :value="user_status" placeholder="请选择用户状态" :disabled="true"/> -->
<input class="h5-input at-input__input" placeholder-class="placeholder" :value="user_status" placeholder="" :disabled="true"/>
<!-- <view style="margin-right: 0; margin-top: 0.5rem;"><van-icon @tap="show_status_popup=true" :name="icon_sel" color="" /></view> -->
</view>
</view>
<view class="at-input" style="margin-right: 1rem;">
...
...
@@ -62,8 +63,8 @@
</view>
<view v-if="role === 'player'" class="at-input" style="margin-right: 1rem;">
<view class="at-input__container">
<label class="h5-label at-input__title at-input__title">
陪伴者
</label>
<input @tap="show_partner_popup=true" class="h5-input at-input__input" placeholder-class="placeholder" :value="user_partner.text" placeholder="请选择
跟踪
人" :disabled="true"/>
<label class="h5-label at-input__title at-input__title">
记录人
</label>
<input @tap="show_partner_popup=true" class="h5-input at-input__input" placeholder-class="placeholder" :value="user_partner.text" placeholder="请选择
记录
人" :disabled="true"/>
<view style="margin-right: 0; margin-top: 0.5rem;"><van-icon @tap="show_partner_popup=true" :name="icon_sel" color="" /></view>
</view>
</view>
...
...
src/pages/my/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-21 14:51:44
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
2 17:05:11
* @LastEditTime: 2022-11-0
3 16:13:18
* @FilePath: /swx/src/pages/my/index.vue
* @Description: 我的页面
-->
...
...
@@ -43,8 +43,9 @@
</view>
</view>
<view @tap="followUser" style="flex: 1; line-height: 60rpx;">
<view>
<view
style="position: relative;"
>
<van-icon :name="icon_user" size="3rem" color="" style="vertical-align: sub;" />
<view style="width: 0.5rem; height: 0.5rem; background-color: red; border-radius: 50%; position: absolute; top: 0; right: 25%;"></view>
</view>
<view>
<text style="font-size: 1rem; color: #222;">陪伴的用户</text>
...
...
src/pages/myFollowUser/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
1 16:06:39
* @LastEditTime: 2022-11-0
3 15:43:21
* @FilePath: /swx/src/pages/myFollowUser/index.vue
* @Description: 陪伴的用户页面
-->
...
...
@@ -61,7 +61,7 @@
<view class="list-wrapper" style="margin: 1rem;">
<view id="navbar-page" style="background-color: white; border-radius: 0.65rem; padding: 1rem;overflow: auto; margin-bottom: 1px;">
<view style="display: inline-block; margin-right: 1rem; line-height: 60rpx;">
<view @tap="toggleColum('activity')" :class="[activated === 1 ? 'bg-gradient' : 'inactivate']" style="font-size: 1rem;">全部
用户
</view>
<view @tap="toggleColum('activity')" :class="[activated === 1 ? 'bg-gradient' : 'inactivate']" style="font-size: 1rem;">全部
义工
</view>
</view>
<view style="display: inline-block; line-height: 60rpx; position: relative;">
<view @tap="toggleColum('join')" :class="[activated === 2 ? 'bg-gradient' : 'inactivate']">待陪伴</view>
...
...
@@ -279,7 +279,7 @@ export default {
this.show_host_popup = false;
},
toggleColum (type) {
if (type === 'activity') { // 全部
用户
if (type === 'activity') { // 全部
义工
this.activated = 1;
} else { // 待陪伴
this.activated = 2;
...
...
src/pages/userAdd/index.config.js
View file @
1a932ef
export
default
{
navigationBarTitleText
:
'
添加成员
'
,
navigationBarTitleText
:
'
成为义工
'
,
usingComponents
:
{
},
}
...
...
src/pages/userAdd/index.vue
View file @
1a932ef
...
...
@@ -51,7 +51,7 @@
<view style="position: absolute; right: 0; bottom: 0.75rem;">
<view @tap="addUser(item)"
style="color: #FFFFFF; background-color: #199A74; border-bottom-left-radius: 0.85rem; border-top-left-radius: 0.85rem; padding: 0.25rem 0.5rem 0.25rem 1rem; font-size: 0.9rem;">
添加成员
</view>
成为义工
</view>
</view>
</view>
</view>
...
...
@@ -143,11 +143,11 @@ export default {
addUser ({ id }) {
Dialog.confirm({
title: '温馨提示',
message: '是否确认
添加成员
?',
message: '是否确认
成为义工
?',
confirmButtonColor: '#199A74'
})
.then(async () => {
//
添加成员
//
成为义工
const { code } = await setRoleMemberAPI({ i: id, role: 'volunteer' });
if (code) {
this.member_list.splice(this.member_list.findIndex(item => item.id === id), 1);
...
...
src/pages/userManage/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-0
1 15:13:53
* @LastEditTime: 2022-11-0
3 15:55:01
* @FilePath: /swx/src/pages/userManage/index.vue
* @Description: 单个主办方管理页面
-->
...
...
@@ -27,7 +27,7 @@
<!-- <view style="display: flex; text-align: center;">
<view @tap="goToAddUser" style="flex: 1;">
<van-icon :name="icon_add" size="3.5rem" color="" style="vertical-align: middle;" />
<text style="font-size: 1.1rem; color: #222; vertical-align: middle;">
添加成员
</text>
<text style="font-size: 1.1rem; color: #222; vertical-align: middle;">
成为义工
</text>
</view>
<view @tap="goToSearchUser" style="flex: 1; border-left: 1px solid #F5F5F5;">
<van-icon :name="icon_user" size="3.5rem" color="" style="vertical-align: middle;" />
...
...
@@ -38,7 +38,7 @@
<van-row>
<van-col span="20">
<view style="padding: 0.7rem 1rem 0rem 1.5rem;">
<input :value="search" class="weui-input" @blur="bindKeyBlur" @input="bindKeyInput" placeholder="请输入
用户名
姓名/手机号查找" style="width: 100%;" />
<input :value="search" class="weui-input" @blur="bindKeyBlur" @input="bindKeyInput" placeholder="请输入姓名/手机号查找" style="width: 100%;" />
</view>
</van-col>
<van-col span="4">
...
...
@@ -84,8 +84,8 @@
</van-col>
</van-row>
<view class="handle-box">
<view v-if="item.role === 'player'" @tap="addUser(item)" class="add-user">
添加成员
</view>
<view v-if="item.role === 'volunteer'" @tap="delUser(item)" class="del-user">
删除成员
</view>
<view v-if="item.role === 'player'" @tap="addUser(item)" class="add-user">
成为义工
</view>
<view v-if="item.role === 'volunteer'" @tap="delUser(item)" class="del-user">
转成用户
</view>
</view>
</view>
</view>
...
...
@@ -246,11 +246,11 @@ export default {
addUser ({ id }) {
Dialog.confirm({
title: '温馨提示',
message: '是否确认
添加成员
?',
message: '是否确认
成为义工
?',
confirmButtonColor: '#199A74'
})
.then(async () => {
//
添加成员
//
成为义工
const { code } = await setRoleMemberAPI({ i: id, role: 'volunteer' });
if (code) {
this.member_list.splice(this.member_list.findIndex(item => item.id === id), 1);
...
...
@@ -264,11 +264,11 @@ export default {
delUser ({ id }) {
Dialog.confirm({
title: '温馨提示',
message: '是否确认
删除成员
?',
message: '是否确认
转成用户
?',
confirmButtonColor: '#199A74'
})
.then(async () => {
//
删除成员
//
转成用户
const { code } = await setRoleMemberAPI({ i: id, role: 'player' });
if (code) {
this.member_list.splice(this.member_list.findIndex(item => item.id === id), 1);
...
...
src/pages/userSearch/index.vue
View file @
1a932ef
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-11-03 1
1:17:49
* @LastEditTime: 2022-11-03 1
5:53:45
* @FilePath: /swx/src/pages/userSearch/index.vue
* @Description: 文件描述
-->
...
...
@@ -47,7 +47,7 @@
</van-col>
</van-row>
<view style="position: absolute; right: 0; bottom: 0.75rem;">
<view @tap="addUser" style="color: #FFFFFF; background-color: #199A74; border-bottom-left-radius: 0.85rem; border-top-left-radius: 0.85rem; padding: 0.25rem 0.5rem 0.25rem 1rem; font-size: 0.9rem;">
添加成员
</view>
<view @tap="addUser" style="color: #FFFFFF; background-color: #199A74; border-bottom-left-radius: 0.85rem; border-top-left-radius: 0.85rem; padding: 0.25rem 0.5rem 0.25rem 1rem; font-size: 0.9rem;">
成为义工
</view>
</view>
</view>
</view>
...
...
@@ -118,7 +118,7 @@ const onPhoneClick = (number) => {
const addUser = () => {
Dialog.confirm({
title: '温馨提示',
message: '是否确认
添加成员
?',
message: '是否确认
成为义工
?',
// confirmButtonColor: '#199A74'
})
.then(() => {
...
...
Please
register
or
login
to post a comment