Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
_milo
Great Teamwork
提交
e84fe253
Great Teamwork
项目概览
_milo
/
Great Teamwork
通知
13
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Great Teamwork
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
e84fe253
编写于
5月 30, 2023
作者:
M
MicroMilo
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'backend' of
https://gitcode.net/qq_50679803/great-teamwork
into backend
上级
c8186330
087ea00d
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
145 addition
and
55 deletion
+145
-55
alpha/admin/js_sdk/validator/mustgo-post-comment.js
alpha/admin/js_sdk/validator/mustgo-post-comment.js
+7
-2
alpha/admin/js_sdk/validator/mustgo-post.js
alpha/admin/js_sdk/validator/mustgo-post.js
+6
-1
alpha/admin/js_sdk/validator/mustgo-school-activity.js
alpha/admin/js_sdk/validator/mustgo-school-activity.js
+38
-14
alpha/admin/js_sdk/validator/mustgo-team-activity.js
alpha/admin/js_sdk/validator/mustgo-team-activity.js
+25
-6
alpha/admin/js_sdk/validator/mustgo-team.js
alpha/admin/js_sdk/validator/mustgo-team.js
+15
-5
alpha/admin/js_sdk/validator/mustgo-user.js
alpha/admin/js_sdk/validator/mustgo-user.js
+22
-6
alpha/admin/uniCloud-aliyun/cloudfunctions/fe-team-activityDetail/index.js
...oud-aliyun/cloudfunctions/fe-team-activityDetail/index.js
+32
-21
未找到文件。
alpha/admin/js_sdk/validator/mustgo-post-comment.js
浏览文件 @
e84fe253
...
...
@@ -23,7 +23,7 @@ const validator = {
"
likes
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
int
"
format
:
"
Number
"
}
],
"
title
"
:
"
点赞数
"
,
...
...
@@ -49,8 +49,13 @@ const validator = {
},
"
content
"
:
{
"
rules
"
:
[
{
required
:
true
,
errorMessage
:
"
请输入内容
"
,
},
{
"
format
"
:
"
string
"
format
:
"
string
"
,
errorMessage
:
"
请输入正确的内容格式
"
,
}
],
"
title
"
:
"
评论内容
"
,
...
...
alpha/admin/js_sdk/validator/mustgo-post.js
浏览文件 @
e84fe253
...
...
@@ -5,7 +5,12 @@ const validator = {
"
content
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入内容
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的内容格式
"
,
}
],
"
title
"
:
"
内容
"
,
...
...
alpha/admin/js_sdk/validator/mustgo-school-activity.js
浏览文件 @
e84fe253
...
...
@@ -5,8 +5,13 @@ const validator = {
"
title
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
}
required
:
true
,
errorMessage
:
"
请输入标题
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的标题格式
"
,
}
],
"
title
"
:
"
标题
"
,
"
label
"
:
"
标题
"
...
...
@@ -14,8 +19,13 @@ const validator = {
"
content
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
}
required
:
true
,
errorMessage
:
"
请输入内容
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的内容格式
"
,
}
],
"
title
"
:
"
内容
"
,
"
label
"
:
"
内容
"
...
...
@@ -23,7 +33,7 @@ const validator = {
"
start_date
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
datetime
"
format
:
"
datetime
"
}
],
"
title
"
:
"
开始时间
"
,
...
...
@@ -32,7 +42,7 @@ const validator = {
"
end_date
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
datetime
"
}
],
"
title
"
:
"
结束时间
"
,
...
...
@@ -41,7 +51,7 @@ const validator = {
"
owner_id
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
format
:
"
string
"
}
],
"
title
"
:
"
发布者id
"
,
...
...
@@ -50,7 +60,7 @@ const validator = {
"
background_picture
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
format
:
"
string
"
}
],
"
title
"
:
"
背景图片
"
,
...
...
@@ -59,7 +69,12 @@ const validator = {
"
place
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入地点
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的地点格式
"
,
}
],
"
title
"
:
"
地点
"
,
...
...
@@ -68,7 +83,7 @@ const validator = {
"
status
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
int
"
format
:
"
number
"
}
],
"
title
"
:
"
活动状态
"
,
...
...
@@ -77,17 +92,26 @@ const validator = {
"
contact
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
^1[0-9]{10}$
"
,
// "pattern": "^1[0-9]{10}$",
}
required
:
true
,
errorMessage
:
"
请输入联系方式
"
,
},
{
pattern
:
/^
(
13
[
0-9
]
|14
[
01456879
]
|15
[
0-35-9
]
|16
[
2567
]
|17
[
0-8
]
|18
[
0-9
]
|19
[
0-35-9
])\d{8}
$/
,
errorMessage
:
"
请输入正确的联系方式
"
,
}
],
"
title
"
:
"
联系方式
"
,
"
label
"
:
"
联系方式
"
},
"
invitee
"
:
{
"
rules
"
:
[
{
required
:
true
,
errorMessage
:
"
请输入面向对象
"
,
},
{
"
format
"
:
"
string
"
format
:
"
string
"
,
errorMessage
:
"
请输入正确的面向对象格式
"
,
}
],
"
title
"
:
"
面向对象
"
,
...
...
alpha/admin/js_sdk/validator/mustgo-team-activity.js
浏览文件 @
e84fe253
...
...
@@ -5,7 +5,12 @@ const validator = {
"
title
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入标题
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的标题格式
"
,
}
],
"
title
"
:
"
标题
"
,
...
...
@@ -14,7 +19,12 @@ const validator = {
"
content
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入内容
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的内容格式
"
,
}
],
"
title
"
:
"
内容
"
,
...
...
@@ -59,7 +69,12 @@ const validator = {
"
place
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入地点
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的地点格式
"
,
}
],
"
title
"
:
"
地点
"
,
...
...
@@ -77,7 +92,7 @@ const validator = {
"
participants
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
int
"
"
format
"
:
"
Number
"
}
],
"
title
"
:
"
参与人数
"
,
...
...
@@ -86,8 +101,12 @@ const validator = {
"
contact
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
,
"
pattern
"
:
"
/^1[0-9]{10}$/
"
,
required
:
true
,
errorMessage
:
"
请输入联系方式
"
,
},
{
pattern
:
/^
(
13
[
0-9
]
|14
[
01456879
]
|15
[
0-35-9
]
|16
[
2567
]
|17
[
0-8
]
|18
[
0-9
]
|19
[
0-35-9
])\d{8}
$/
,
errorMessage
:
"
请输入正确的联系方式
"
,
}
],
"
title
"
:
"
联系方式
"
,
...
...
alpha/admin/js_sdk/validator/mustgo-team.js
浏览文件 @
e84fe253
...
...
@@ -5,7 +5,7 @@ const validator = {
"
icon
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
format
:
"
string
"
}
],
"
title
"
:
"
队标
"
,
...
...
@@ -13,9 +13,14 @@ const validator = {
},
"
name
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
}
{
required
:
true
,
errorMessage
:
"
请输入队名
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的队名格式
"
,
}
],
"
title
"
:
"
队名
"
,
"
label
"
:
"
队名
"
...
...
@@ -32,7 +37,12 @@ const validator = {
"
description
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入描述
"
,
},
{
format
:
"
string
"
,
errorMessage
:
"
请输入正确的格式
"
,
}
],
"
title
"
:
"
描述
"
,
...
...
alpha/admin/js_sdk/validator/mustgo-user.js
浏览文件 @
e84fe253
...
...
@@ -4,8 +4,13 @@
const
validator
=
{
"
name
"
:
{
"
rules
"
:
[
{
required
:
true
,
errorMessage
:
"
请输入用户名
"
,
},
{
"
format
"
:
"
string
"
maxLength
:
15
,
errorMessage
:
"
用户名过长
"
,
}
],
"
title
"
:
"
姓名
"
,
...
...
@@ -14,7 +19,7 @@ const validator = {
"
icon
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
format
:
"
string
"
}
],
"
title
"
:
"
头像
"
,
...
...
@@ -24,7 +29,7 @@ const validator = {
"
gender
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
format
:
"
string
"
}
],
"
title
"
:
"
性别
"
,
...
...
@@ -33,8 +38,14 @@ const validator = {
"
password
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
}
required
:
true
,
errorMessage
:
"
请输入密码
"
,
},
{
minLengt
:
8
,
maxLength
:
20
,
errorMessage
:
"
密码长度在8到20位
"
,
}
],
"
title
"
:
"
密码
"
,
"
label
"
:
"
密码
"
...
...
@@ -42,7 +53,12 @@ const validator = {
"
phone_num
"
:
{
"
rules
"
:
[
{
"
format
"
:
"
string
"
required
:
true
,
errorMessage
:
"
请输入联系方式
"
,
},
{
pattern
:
/^
(
13
[
0-9
]
|14
[
01456879
]
|15
[
0-35-9
]
|16
[
2567
]
|17
[
0-8
]
|18
[
0-9
]
|19
[
0-35-9
])\d{8}
$/
,
errorMessage
:
"
请输入正确的联系方式
"
,
}
],
"
title
"
:
"
手机号码
"
,
...
...
alpha/admin/uniCloud-aliyun/cloudfunctions/fe-team-activityDetail/index.js
浏览文件 @
e84fe253
...
...
@@ -24,26 +24,10 @@ exports.main = async (event, context) => {
owner_id
:
event
.
userId
}).
get
()
var
time
=
getSystemTime
()
var
date
=
new
Date
();
var
month
=
date
.
getMonth
()
+
1
;
if
(
month
<
10
)
month
=
"
0
"
+
month
;
var
day
=
date
.
getDate
();
if
(
day
<
10
)
day
=
"
0
"
+
day
;
var
hours
=
date
.
getHours
();
if
(
hours
<
10
)
hours
=
"
0
"
+
hours
;
var
minutes
=
date
.
getMinutes
();
if
(
minutes
<
10
)
minutes
=
"
0
"
+
minutes
;
var
time
=
date
.
getFullYear
()
+
"
-
"
+
month
+
"
-
"
+
day
+
"
"
+
hours
+
"
:
"
+
minutes
;
// return time
if
(
time
>
res
.
data
[
0
][
"
start_date
"
]
)
{
if
(
time
>
res
.
data
[
0
][
"
start_date
"
])
{
return
{
code
:
200
,
message
:
"
成功返回活动详情
"
,
...
...
@@ -85,7 +69,7 @@ exports.main = async (event, context) => {
return
{
code
:
200
,
message
:
"
成功返回活动详情
"
,
qualification
:
"
报名停止
"
,
qualification
:
"
活动人数已满
"
,
data
:
{
"
username
"
:
username
,
"
icon
"
:
icon
,
...
...
@@ -123,4 +107,31 @@ exports.main = async (event, context) => {
"
message
"
:
"
返回小队活动详情失败
"
,
"
data
"
:
{}
}
};
\ No newline at end of file
};
function
getSystemTime
()
{
// 实例化日期类
var
time
=
new
Date
();
// 获取完整的年份(4位)
var
year
=
time
.
getFullYear
();
// 获取月份(0-11,0代表1月)
var
month
=
time
.
getMonth
()
+
1
;
if
(
month
<
10
)
month
=
"
0
"
+
month
// 获取日期(1-31)
var
date
=
time
.
getDate
();
if
(
date
<
10
)
date
=
"
0
"
+
date
// 获取小时
var
h
=
time
.
getHours
()
+
8
;
h
=
h
<
10
?
'
0
'
+
h
:
h
;
// 获取分钟
var
m
=
time
.
getMinutes
();
m
=
m
<
10
?
'
0
'
+
m
:
m
;
// 获取秒钟
var
s
=
time
.
getSeconds
();
s
=
s
<
10
?
'
0
'
+
s
:
s
;
// 合并返回
return
(
year
+
"
-
"
+
month
+
"
-
"
+
date
+
"
"
+
h
+
"
:
"
+
m
)
;
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录