Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cust-api
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李伟
cust-api
Commits
9484fa03
Commit
9484fa03
authored
Feb 26, 2025
by
liwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了活动、动态和报名
parent
3ce6fb5f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
72 deletions
+19
-72
CmsActivity.java
.../org/rcisoft/business/cmsActivity/entity/CmsActivity.java
+0
-63
CmsActivityServiceImpl.java
...ness/cmsActivity/service/impl/CmsActivityServiceImpl.java
+0
-6
OpmArticleServiceImpl.java
...siness/opmArticle/service/impl/OpmArticleServiceImpl.java
+15
-2
CmsApplicationMapper.xml
...r/business/cmsApplication.mapper/CmsApplicationMapper.xml
+4
-1
No files found.
src/main/java/org/rcisoft/business/cmsActivity/entity/CmsActivity.java
View file @
9484fa03
...
...
@@ -22,70 +22,7 @@ import java.util.Date;
@TableName
(
"cms_activity"
)
public
class
CmsActivity
extends
CyIdIncreEntity
<
CmsActivity
>
{
/**
* @desc 创建人
* @column create_by
* @default
*/
@Excel
(
name
=
"创建人"
)
@TableField
(
"create_by"
)
private
String
createBy
;
/**
* @desc 创建时间
* @column create_date
* @default
*/
@Excel
(
name
=
"创建时间"
)
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
timezone
=
"GMT+8"
)
@TableField
(
"create_date"
)
private
Date
createDate
;
/**
* @desc 更新人
* @column update_by
* @default
*/
@Excel
(
name
=
"更新人"
)
@TableField
(
"update_by"
)
private
String
updateBy
;
/**
* @desc 更新时间
* @column update_date
* @default
*/
@Excel
(
name
=
"更新时间"
)
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
timezone
=
"GMT+8"
)
@TableField
(
"update_date"
)
private
Date
updateDate
;
/**
* @desc 启动状态(0禁用、1启动)
* @column flag
* @default
*/
@Excel
(
name
=
"启动状态(0禁用、1启动)"
)
@TableField
(
"flag"
)
private
String
flag
;
/**
* @desc 删除标志(0删除,1已删除)
* @column del_flag
* @default
*/
@Excel
(
name
=
"删除标志(0删除,1已删除)"
)
@TableField
(
"del_flag"
)
private
String
delFlag
;
/**
* @desc 备注
* @column remarks
* @default
*/
@JsonIgnore
@Excel
(
name
=
"备注"
)
@TableField
(
"remarks"
)
private
String
remarks
;
/**
* @desc 活动标题
* @column title
...
...
src/main/java/org/rcisoft/business/cmsActivity/service/impl/CmsActivityServiceImpl.java
View file @
9484fa03
...
...
@@ -55,12 +55,6 @@ public class CmsActivityServiceImpl extends ServiceImpl<CmsActivityRepository, C
@Transactional
(
propagation
=
Propagation
.
REQUIRED
,
isolation
=
Isolation
.
DEFAULT
)
@Override
public
CyPersistModel
persist
(
CmsActivity
cmsActivity
)
{
//增加操作
cmsActivity
.
setDelFlag
(
"0"
);
//当图片字段没有时增加默认1
/* if (ObjectUtil.isNull(cmsActivity.getPictureId())) {
cmsActivity.setPictureId(global.getDEFAULT_NEWS_LOCATION());
}*/
CmsActivity
check
=
baseMapper
.
checkWeight
(
cmsActivity
.
getWeight
());
if
(
ObjectUtil
.
isNotNull
(
check
))
{
throw
new
CyServiceException
(
500
,
"权重已存在"
);
...
...
src/main/java/org/rcisoft/business/opmArticle/service/impl/OpmArticleServiceImpl.java
View file @
9484fa03
...
...
@@ -9,6 +9,8 @@ import lombok.extern.slf4j.Slf4j;
import
org.apache.commons.lang3.StringUtils
;
import
org.rcisoft.baidu.censor.dto.CensorResult
;
import
org.rcisoft.baidu.censor.service.ContentCensorService
;
import
org.rcisoft.business.memGoldCoinFlow.dao.MemGoldCoinFlowRepository
;
import
org.rcisoft.business.memGoldCoinFlow.entity.MemGoldCoinFlow
;
import
org.rcisoft.business.memInfo.bean.MemberInfoRedisBean
;
import
org.rcisoft.business.memInfo.dao.MemInfoRepository
;
import
org.rcisoft.business.memInfo.entity.MemInfo
;
...
...
@@ -37,6 +39,7 @@ import org.springframework.transaction.annotation.Isolation;
import
org.springframework.transaction.annotation.Propagation
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.math.BigInteger
;
import
java.text.ParseException
;
import
java.text.SimpleDateFormat
;
import
java.time.LocalDate
;
...
...
@@ -70,6 +73,8 @@ public class OpmArticleServiceImpl extends ServiceImpl<OpmArticleRepository, Opm
private
RedissonClient
redissonClient
;
@Autowired
private
StringRedisTemplate
redisTemplate
;
@Autowired
private
MemGoldCoinFlowRepository
memGoldCoinFlowRepository
;
/**
* 保存 opmArticle管理
* @param opmArticle
...
...
@@ -94,8 +99,8 @@ public class OpmArticleServiceImpl extends ServiceImpl<OpmArticleRepository, Opm
String
date
=
month
+
day
;
List
<
DictData
>
articleConfig
=
dictionaryService
.
selectByTypes
(
"article_config"
);
DictData
dictData1
=
articleConfig
.
stream
().
filter
(
item
->
item
.
getDictLabel
().
equals
(
"publish_article_count"
)).
findFirst
().
orElse
(
null
);
DictData
dictData2
=
articleConfig
.
stream
().
filter
(
item
->
item
.
getDictLabel
().
equals
(
"publish_article_count"
)).
findFirst
().
orElse
(
null
);
DictData
dictData3
=
articleConfig
.
stream
().
filter
(
item
->
item
.
getDictLabel
().
equals
(
"p
ublish_article
_count"
)).
findFirst
().
orElse
(
null
);
DictData
dictData2
=
articleConfig
.
stream
().
filter
(
item
->
item
.
getDictLabel
().
equals
(
"p
ay_p
ublish_article_count"
)).
findFirst
().
orElse
(
null
);
DictData
dictData3
=
articleConfig
.
stream
().
filter
(
item
->
item
.
getDictLabel
().
equals
(
"p
ay
_count"
)).
findFirst
().
orElse
(
null
);
Integer
publishCount
=
Integer
.
valueOf
(
dictData1
.
getDictValue
());
//每天最多发a条动态(免费)
Integer
payPublishCount
=
Integer
.
valueOf
(
dictData2
.
getDictValue
());
//每天最多发b条动态(付费)
Integer
publishCountAll
=
publishCount
+
payPublishCount
;
//免费+付费总数
...
...
@@ -127,6 +132,14 @@ public class OpmArticleServiceImpl extends ServiceImpl<OpmArticleRepository, Opm
}
memInfo
.
setGoldCoinsCount
(
memInfo
.
getGoldCoinsCount
()
-
payCount
);
memInfoRepository
.
updateById
(
memInfo
);
//添加消费记录
MemGoldCoinFlow
memGoldCoinFlow
=
new
MemGoldCoinFlow
();
memGoldCoinFlow
.
setType
(
"2"
);
memGoldCoinFlow
.
setActionType
(
"21"
);
memGoldCoinFlow
.
setCount
(
payCount
);
memGoldCoinFlow
.
setEndCount
(
memInfo
.
getGoldCoinsCount
());
memGoldCoinFlow
.
setTargetId
(
BigInteger
.
valueOf
(
Long
.
parseLong
(
userId
)));
memGoldCoinFlowRepository
.
insert
(
memGoldCoinFlow
);
//增加操作
redisTemplate
.
opsForValue
().
increment
(
OpmArticleRedisBean
.
USER_ARTICLE_COUNT
+
date
+
":"
+
userId
,
1L
);
}
...
...
src/main/resources/mapper/business/cmsApplication.mapper/CmsApplicationMapper.xml
View file @
9484fa03
...
...
@@ -88,7 +88,10 @@
and mi.mem_nick_name like concat('%',#{entity.memNickName},'%')
</if>
<if
test=
"entity.status !=null and entity.status != '' "
>
and status = #{entity.status}
and ca2.status = #{entity.status}
</if>
<if
test=
"entity.activityId !=null and entity.activityId != '' "
>
and ca2.activity_id = #{entity.activityId}
</if>
ORDER BY business_id DESC
</select>
...
...
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