Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
open-source
/
rpc-openplatform
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit ab7d72b9
authored
Dec 22, 2020
by
杨林龙
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改插入和修改广告的的SQL语句 yangll
1 parent
40928ed9
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
9 deletions
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/mapper/PlatformCustomerMapper.java
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/service/AdMgrServiceImpl.java
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/service/CustomerMgrServiceImpl.java
rpc-openplatform-container/src/main/resources/META-INF/orm/PlatformAdMapper.xml
rpc-openplatform-container/src/main/resources/META-INF/orm/PlatformCustomerMapper.xml
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/mapper/PlatformCustomerMapper.java
View file @
ab7d72b
...
...
@@ -36,4 +36,6 @@ public interface PlatformCustomerMapper extends OreMapper<PlatformCustomer> {
int
register
(
PlatformCustomer
customer
);
PlatformCustomer
selectOneByAppId
(
@Param
(
"appId"
)
int
appId
);
int
updateByCustomerId
(
@Param
(
"id"
)
int
id
,
@Param
(
"password"
)
String
password
);
}
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/service/AdMgrServiceImpl.java
View file @
ab7d72b
...
...
@@ -35,12 +35,14 @@ public class AdMgrServiceImpl implements AdMgrService {
@Override
public
int
insertAd
(
PlatformAd
ad
)
{
ad
.
setCreateTime
(
new
Date
());
ad
.
setStatus
(
1
);
return
adMapper
.
insert
(
ad
);
}
@Override
public
int
updateAd
(
PlatformAd
ad
)
{
ad
.
setUpdateTime
(
new
Date
());
ad
.
setStatus
(
1
);
return
adMapper
.
updateByPrimaryKeySelective
(
ad
);
}
...
...
rpc-openplatform-container/src/main/java/cn/com/glsx/openplatform/service/CustomerMgrServiceImpl.java
View file @
ab7d72b
...
...
@@ -41,10 +41,8 @@ public class CustomerMgrServiceImpl implements CustomerMgrService {
@Override
public
int
reset
(
int
id
)
{
PlatformCustomer
customer
=
new
PlatformCustomer
();
customer
.
setId
(
id
);
customer
.
setPassword
(
"12345678"
);
return
customerMapper
.
updateByPrimaryKeySelective
(
customer
);
String
password
=
"12345678"
;
return
customerMapper
.
updateByCustomerId
(
id
,
password
);
}
@Override
...
...
rpc-openplatform-container/src/main/resources/META-INF/orm/PlatformAdMapper.xml
View file @
ab7d72b
...
...
@@ -8,10 +8,10 @@
<id
column=
"id"
jdbcType=
"INTEGER"
property=
"id"
/>
<result
column=
"title"
jdbcType=
"VARCHAR"
property=
"title"
/>
<result
column=
"image"
jdbcType=
"VARCHAR"
property=
"image"
/>
<result
column=
"position"
jdbcType=
"
TINYINT
"
property=
"position"
/>
<result
column=
"interface_type"
jdbcType=
"
TINYINT
"
property=
"interfaceType"
/>
<result
column=
"position"
jdbcType=
"
INTEGER
"
property=
"position"
/>
<result
column=
"interface_type"
jdbcType=
"
INTEGER
"
property=
"interfaceType"
/>
<result
column=
"interface_url"
jdbcType=
"VARCHAR"
property=
"interfaceUrl"
/>
<result
column=
"status"
jdbcType=
"
TINYINT
"
property=
"status"
/>
<result
column=
"status"
jdbcType=
"
INTEGER
"
property=
"status"
/>
<result
column=
"create_time"
jdbcType=
"TIMESTAMP"
property=
"createTime"
/>
<result
column=
"update_time"
jdbcType=
"TIMESTAMP"
property=
"updateTime"
/>
<result
column=
"create_by"
jdbcType=
"INTEGER"
property=
"createBy"
/>
...
...
@@ -31,9 +31,20 @@
where id = #{id,jdbcType=INTEGER}
</update>
<select
id=
"getAdMgrList"
result
Type=
"cn.com.glsx.openplatform.model.PlatformAd
"
>
<select
id=
"getAdMgrList"
result
Map=
"BaseResultMap
"
>
select
<include
refid=
"Base_Column_List"
/>
id,
title,
image,
`position`,
interface_type,
interface_url,
`status`,
create_time,
update_time,
create_by,
update_by,
remark
from t_platform_ad
</select>
</mapper>
rpc-openplatform-container/src/main/resources/META-INF/orm/PlatformCustomerMapper.xml
View file @
ab7d72b
...
...
@@ -150,6 +150,13 @@
</trim>
</insert>
<update
id=
"updateByCustomerId"
>
update t_platform_customer
set password = #{password,jdbcType=VARCHAR},
update_time = NOW()
where id = #{id,jdbcType=INTEGER}
</update>
<select
id=
"getCustomerMgrList"
resultMap=
"BaseResultMap"
>
select a.id,
a.customer_name,
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment