Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
T
tanpu-community
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
探普后端
tanpu-community
Commits
3bbbcdb0
Commit
3bbbcdb0
authored
Aug 18, 2021
by
刘基明
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
图片审核注释
parent
35d2e2a4
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
6 deletions
+25
-6
CallBackController.java
...va/com/tanpu/community/controller/CallBackController.java
+3
-5
FileManager.java
...rc/main/java/com/tanpu/community/manager/FileManager.java
+3
-1
v2.sql
docs/v2.sql
+19
-0
No files found.
community-service/src/main/java/com/tanpu/community/controller/CallBackController.java
View file @
3bbbcdb0
...
@@ -14,7 +14,6 @@ import org.springframework.web.bind.annotation.RequestMapping;
...
@@ -14,7 +14,6 @@ import org.springframework.web.bind.annotation.RequestMapping;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -32,6 +31,9 @@ public class CallBackController {
...
@@ -32,6 +31,9 @@ public class CallBackController {
* 回调时间:6秒以内
* 回调时间:6秒以内
* 文档地址:https://help.aliyun.com/document_detail/129946.html?spm=a2c4g.11186623.6.562.19a05f3aNkd2Oo#table-s9e-grd-408
* 文档地址:https://help.aliyun.com/document_detail/129946.html?spm=a2c4g.11186623.6.562.19a05f3aNkd2Oo#table-s9e-grd-408
* https://help.aliyun.com/document_detail/70292.htm?spm=a2c4g.11186623.2.12.26573ac7EEunMN#reference-fzy-ztm-v2b
* https://help.aliyun.com/document_detail/70292.htm?spm=a2c4g.11186623.2.12.26573ac7EEunMN#reference-fzy-ztm-v2b
* 屏蔽内容:
* 图片智能鉴黄(porn)结果分类:normal:正常 sexy:性感 porn:色情
* 图片不良场景(live)结果分类:normal:正常 meaningless:图片中无内容(例如,黑屏、白屏) PIP:画中画 smoking:吸烟 drivelive:车内直播
* @param checksum
* @param checksum
* @param content
* @param content
* @return
* @return
...
@@ -75,9 +77,5 @@ public class CallBackController {
...
@@ -75,9 +77,5 @@ public class CallBackController {
}
}
}
}
public
static
void
main
(
String
[]
args
)
{
System
.
out
.
println
(
new
Date
());
}
}
}
community-service/src/main/java/com/tanpu/community/manager/FileManager.java
View file @
3bbbcdb0
...
@@ -88,7 +88,9 @@ public class FileManager {
...
@@ -88,7 +88,9 @@ public class FileManager {
// 同步查询,使用taskId,且1/24小时内才能查询
// 同步查询,使用taskId,且1/24小时内才能查询
public
JSONArray
queryTask
(
String
taskId
)
throws
Exception
{
public
JSONArray
queryTask
(
String
taskId
)
throws
Exception
{
IClientProfile
profile
=
DefaultProfile
.
getProfile
(
"cn-shanghai"
,
"LTAIAKEzVydP0Q9P"
,
"59V9ke9txaIFzWxHFKTb1eoOOpmKpJ"
);
// 帐号没有权限,会导致查询结果为空
IClientProfile
profile
=
DefaultProfile
.
getProfile
(
"cn-shanghai"
,
ossFileService
.
accessId
,
ossFileService
.
accessSK
);
DefaultProfile
.
addEndpoint
(
"cn-shanghai"
,
"cn-shanghai"
,
"Green"
,
"green.cn-shanghai.aliyuncs.com"
);
DefaultProfile
.
addEndpoint
(
"cn-shanghai"
,
"cn-shanghai"
,
"Green"
,
"green.cn-shanghai.aliyuncs.com"
);
IAcsClient
client
=
new
DefaultAcsClient
(
profile
);
IAcsClient
client
=
new
DefaultAcsClient
(
profile
);
...
...
docs/v2.sql
0 → 100644
View file @
3bbbcdb0
use
tamp_community
;
ALTER
TABLE
tamp_community
.
file_record
ADD
`check_status`
int
(
3
)
NOT
NULL
DEFAULT
'0'
COMMENT
'审核状态 0:初试化 1:通过 2:不通过 3:需要人工再审'
;
ALTER
TABLE
tamp_community
.
file_record
ADD
`check_result_log`
varchar
(
500
)
NOT
NULL
DEFAULT
''
COMMENT
'审核结果记录'
;
CREATE
TABLE
`notification`
(
`id`
bigint
(
32
)
NOT
NULL
COMMENT
'id'
,
`notification_id`
varchar
(
64
)
NOT
NULL
DEFAULT
''
COMMENT
'通知主键Id'
,
`notified_user_id`
varchar
(
64
)
NOT
NULL
DEFAULT
''
COMMENT
'被通知的用户id'
,
`message_type`
varchar
(
64
)
NOT
NULL
DEFAULT
''
COMMENT
'1:转发 2:点赞 3:评论 4:关注'
,
`target_id`
varchar
(
64
)
NOT
NULL
DEFAULT
''
COMMENT
'目标id,类型是转发、点赞、评论时为themeId,关注则为user_id'
,
`content`
varchar
(
600
)
NOT
NULL
DEFAULT
''
COMMENT
'评论:评论内容 转发:topicId+内容 点赞:人数+最近3个用户'
,
`operator_id`
varchar
(
64
)
NOT
NULL
DEFAULT
''
COMMENT
'操作者id'
,
`create_time`
datetime
NOT
NULL
DEFAULT
CURRENT_TIMESTAMP
,
`update_time`
datetime
NOT
NULL
DEFAULT
CURRENT_TIMESTAMP
,
`delete_tag`
int
(
3
)
NOT
NULL
DEFAULT
'0'
,
PRIMARY
KEY
(
`id`
),
KEY
`idx_user_type_time`
(
`notified_user_id`
,
`update_time`
,
`message_type`
)
USING
BTREE
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COMMENT
=
'消息通知记录'
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment