Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
haoban3.0
haoban-manage3.0
Commits
60378a9d
Commit
60378a9d
authored
Dec 15, 2021
by
墨竹
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/login-token' into developer
parents
415f0e8a
e582517b
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
48 additions
and
101 deletions
+48
-101
WelcomeDTO.java
...c/main/java/com/gic/haoban/manage/api/dto/WelcomeDTO.java
+0
-13
DictApiService.java
...ava/com/gic/haoban/manage/api/service/DictApiService.java
+11
-1
DictMapper.java
.../com/gic/haoban/manage/service/dao/mapper/DictMapper.java
+0
-2
TabWelcome.java
...java/com/gic/haoban/manage/service/entity/TabWelcome.java
+0
-14
WxEnterpriseServiceImpl.java
.../manage/service/service/impl/WxEnterpriseServiceImpl.java
+1
-4
DictApiServiceImpl.java
...n/manage/service/service/out/impl/DictApiServiceImpl.java
+9
-6
MemberUnionidRelatedApiServiceImpl.java
.../service/out/impl/MemberUnionidRelatedApiServiceImpl.java
+0
-46
WxEnterpriseApiServiceImpl.java
.../service/service/out/impl/WxEnterpriseApiServiceImpl.java
+1
-1
DictMapper.xml
...-manage3-service/src/main/resources/mapper/DictMapper.xml
+8
-7
TabHaobanWelcomeMapper.xml
...vice/src/main/resources/mapper/TabHaobanWelcomeMapper.xml
+3
-7
DictController.java
.../com/gic/haoban/manage/web/controller/DictController.java
+15
-0
No files found.
haoban-manage3-api/src/main/java/com/gic/haoban/manage/api/dto/WelcomeDTO.java
View file @
60378a9d
...
...
@@ -35,11 +35,6 @@ public class WelcomeDTO implements Serializable {
private
String
welcomeContent
;
/**
* 图片
*/
private
String
welcomeImg
;
/**
* 0删除 1正常
*/
private
Integer
openFlag
;
...
...
@@ -90,14 +85,6 @@ public class WelcomeDTO implements Serializable {
this
.
welcomeContent
=
welcomeContent
;
}
public
String
getWelcomeImg
()
{
return
welcomeImg
;
}
public
void
setWelcomeImg
(
String
welcomeImg
)
{
this
.
welcomeImg
=
welcomeImg
;
}
public
Integer
getOpenFlag
()
{
return
openFlag
;
}
...
...
haoban-manage3-api/src/main/java/com/gic/haoban/manage/api/service/DictApiService.java
View file @
60378a9d
...
...
@@ -15,7 +15,7 @@ public interface DictApiService {
DictDTO
findOneDict
(
String
dictId
);
Page
<
DictDTO
>
pageList
(
BasePageInfo
pageInfo
);
void
deleteOne
(
String
dictId
);
/**
...
...
@@ -25,4 +25,14 @@ public interface DictApiService {
* @return
*/
List
<
DictDTO
>
queryList
(
List
<
String
>
dictKeys
);
/**
* 根据key 获取一条
*
* @param dictKey dict关键
* @return {@link DictDTO }
* @author mozhu
* @date 2021-12-15 19:47:51
*/
DictDTO
findOneDictByKey
(
String
dictKey
);
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/dao/mapper/DictMapper.java
View file @
60378a9d
...
...
@@ -26,5 +26,4 @@ public interface DictMapper {
TabHaobanDict
selectByDictKey
(
String
dictKey
);
TabHaobanDict
selectByDictName
(
String
dictKey
);
}
\ No newline at end of file
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/entity/TabWelcome.java
View file @
60378a9d
...
...
@@ -4,7 +4,6 @@ import java.io.Serializable;
import
java.util.Date
;
/**
* Created By MBG-GUI-EXTENSION https://github.com/spawpaw/mybatis-generator-gui-extension
* Description:
* 欢迎语配置表
*
...
...
@@ -34,11 +33,6 @@ public class TabWelcome implements Serializable {
private
String
welcomeContent
;
/**
* 图片
*/
private
String
welcomeImg
;
/**
* 0删除 1正常
*/
private
Integer
openFlag
;
...
...
@@ -90,14 +84,6 @@ public class TabWelcome implements Serializable {
this
.
welcomeContent
=
welcomeContent
;
}
public
String
getWelcomeImg
()
{
return
welcomeImg
;
}
public
void
setWelcomeImg
(
String
welcomeImg
)
{
this
.
welcomeImg
=
welcomeImg
;
}
public
Integer
getOpenFlag
()
{
return
openFlag
;
}
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/impl/WxEnterpriseServiceImpl.java
View file @
60378a9d
...
...
@@ -6,7 +6,6 @@ import com.gic.haoban.manage.api.dto.WxEnterpriseDTO;
import
com.gic.haoban.manage.service.dao.mapper.WxEnterpriseMapper
;
import
com.gic.haoban.manage.service.entity.TabHaobanWxEnterprise
;
import
com.gic.haoban.manage.service.service.WxEnterpriseService
;
import
com.gic.wechat.api.service.qywx.QywxUserApiService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -15,10 +14,9 @@ import java.util.List;
@Service
public
class
WxEnterpriseServiceImpl
implements
WxEnterpriseService
{
@Autowired
private
WxEnterpriseMapper
mapper
;
@Autowired
private
QywxUserApiService
qywxUserApiService
;
@Override
public
String
add
(
WxEnterpriseDTO
wxDTO
)
{
...
...
@@ -31,7 +29,6 @@ public class WxEnterpriseServiceImpl implements WxEnterpriseService {
tabHaobanWxEnterprise
.
setBindFlag
(
1
);
mapper
.
insertSelective
(
tabHaobanWxEnterprise
);
return
wxDTO
.
getWxEnterpriseId
();
}
@Override
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/DictApiServiceImpl.java
View file @
60378a9d
package
com
.
gic
.
haoban
.
manage
.
service
.
service
.
out
.
impl
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.gic.api.base.commons.Page
;
import
com.gic.commons.util.EntityUtil
;
import
com.gic.haoban.base.api.common.BasePageInfo
;
import
com.gic.haoban.common.utils.PageUtil
;
import
com.gic.haoban.common.utils.UuidUtil
;
import
com.gic.haoban.manage.api.dto.DepartmentDTO
;
import
com.gic.haoban.manage.api.dto.DictDTO
;
import
com.gic.haoban.manage.api.service.DictApiService
;
import
com.gic.haoban.manage.service.dao.mapper.DictMapper
;
import
com.gic.haoban.manage.service.entity.TabHaobanDict
;
import
com.github.pagehelper.PageHelper
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
...
...
@@ -65,7 +63,7 @@ public class DictApiServiceImpl implements DictApiService{
@Override
public
void
deleteOne
(
String
dictId
)
{
dictMapper
.
deleteByPrimaryKey
(
dictId
);
dictMapper
.
deleteByPrimaryKey
(
dictId
);
}
@Override
...
...
@@ -73,4 +71,9 @@ public class DictApiServiceImpl implements DictApiService{
List
<
TabHaobanDict
>
list
=
dictMapper
.
queryList
(
dictKeys
);
return
EntityUtil
.
changeEntityListByJSON
(
DictDTO
.
class
,
list
);
}
@Override
public
DictDTO
findOneDictByKey
(
String
dictKey
)
{
return
EntityUtil
.
changeEntity
(
DictDTO
.
class
,
dictMapper
.
selectByDictKey
(
dictKey
));
}
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/MemberUnionidRelatedApiServiceImpl.java
View file @
60378a9d
...
...
@@ -1053,52 +1053,6 @@ public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedA
return
PageUtil
.
changePageHelperToCurrentPage
(
memberUnionRelatedService
.
pageMemberUnionByParams
(
userIdList
,
sendMemberIds
,
enterpriseId
),
MemberUnionidRelatedDTO
.
class
);
}
// @Override
// public String sendMessage(String wxEnterpriseId,String userId,List<String> extendUserList,String materialId){
// WxEnterpriseDTO enterprise = wxEnterpriseService.selectById(wxEnterpriseId);
// MaterialDTO material = materialApiService.selectMaterialById(materialId);
// if(material == null){
// return "";
// }
// JSONResponse jp = null;
// if(material.getMaterialType() == 2 || material.getMaterialType() == 4 || material.getMaterialType() == 5){
// Date wxLastTime = material.getWxLastUploadTime();
// String maerialId = material.getMediaId();
// if(DateUtil.addDay(wxLastTime, 3).getTime() < System.currentTimeMillis()){
// maerialId = materialApiService.reUpdalodMetail(materialId);
// }
// QywxImageExternalMessageDTO dto = new QywxImageExternalMessageDTO();
// dto.setMediaId(maerialId);
// dto.setChatType("single");
// dto.setExternalUserid(extendUserList);
// dto.setSenderUserId(userId);
// log.info("【发送消息】dto = {}",JSON.toJSONString(dto));
// jp = qywxSuiteApiService.sendExternalMessage(enterprise.getCorpid(), config.getWxSuiteid(), dto);
// }else if(material.getMaterialType() == 1){
// QywxTextExternalMessageDTO dto = new QywxTextExternalMessageDTO();
// dto.setChatType("single");
// dto.setExternalUserid(extendUserList);
// dto.setSenderUserId(userId);
// dto.setText(material.getMaterialContent());
// log.info("【发送消息】dto = {}",JSON.toJSONString(dto));
// jp = qywxSuiteApiService.sendExternalMessage(enterprise.getCorpid(), config.getWxSuiteid(), dto);
// }else if(material.getMaterialType() == 3){
// QywxIinkExternalMessageDTO dto = new QywxIinkExternalMessageDTO();
// dto.setChatType("single");
// dto.setExternalUserid(extendUserList);
// dto.setSenderUserId(userId);
// dto.setDesc(material.getMaterialDesc());
// dto.setPicurl(material.getWxImgUrl());
// dto.setTitle(material.getMaterialTitle());
// dto.setUrl(material.getLink());
// log.info("【发送消息】dto = {}",JSON.toJSONString(dto));
// jp = qywxSuiteApiService.sendExternalMessage(enterprise.getCorpid(), config.getWxSuiteid(), dto);
// }
// log.info("【发送消息】jp = {}",JSON.toJSONString(jp));
// Map<String,Object> returnMap = jp.getReturnMap();
// return returnMap.get("msgid") == null?"":returnMap.get("msgid").toString();
// }
/**
* 老的单个素材群发的api
*
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/WxEnterpriseApiServiceImpl.java
View file @
60378a9d
...
...
@@ -69,7 +69,7 @@ public class WxEnterpriseApiServiceImpl implements WxEnterpriseApiService {
String
wxEnterpriseId
=
""
;
//授权好办小程序
if
(
isCustomizedApp
==
null
||
isCustomizedApp
!=
1
)
{
//只需要插入好办小程序企业
//只需要插入好办小程序企业
,代开发 企业表不插入
TabHaobanWxEnterprise
enterprise
=
this
.
wxEnterpriseService
.
getEnterpriseBycorpIdNoStatus
(
corpid
);
if
(
enterprise
!=
null
)
{
wxEnterpriseId
=
enterprise
.
getWxEnterpriseId
();
...
...
haoban-manage3-service/src/main/resources/mapper/DictMapper.xml
View file @
60378a9d
...
...
@@ -139,14 +139,14 @@
select
<include
refid=
"Base_Column_List"
/>
from tab_haoban_dict
where dict_key =
#{dictKey,jdbcType=VARCHAR}
and status_flag =
1
where dict_key = #{dictKey,jdbcType=VARCHAR}
and status_flag = 1 limit
1
</select>
<select
id=
"selectByDictName"
resultMap=
"BaseResultMap"
parameterType=
"java.lang.String"
>
select
<include
refid=
"Base_Column_List"
/>
<select
id=
"selectByDictName"
resultMap=
"BaseResultMap"
parameterType=
"java.lang.String"
>
select
<include
refid=
"Base_Column_List"
/>
from tab_haoban_dict
where dict_name =
#{dictName,jdbcType=VARCHAR}
and status_flag =
1
where dict_name = #{dictName,jdbcType=VARCHAR}
and status_flag = 1 limit
1
</select>
</mapper>
\ No newline at end of file
haoban-manage3-service/src/main/resources/mapper/TabHaobanWelcomeMapper.xml
View file @
60378a9d
...
...
@@ -6,7 +6,6 @@
<result
column=
"wx_enterprise_id"
jdbcType=
"VARCHAR"
property=
"wxEnterpriseId"
/>
<result
column=
"title"
jdbcType=
"VARCHAR"
property=
"title"
/>
<result
column=
"welcome_content"
jdbcType=
"VARCHAR"
property=
"welcomeContent"
/>
<result
column=
"welcome_img"
jdbcType=
"VARCHAR"
property=
"welcomeImg"
/>
<result
column=
"status_flag"
jdbcType=
"INTEGER"
property=
"statusFlag"
/>
<result
column=
"open_flag"
jdbcType=
"INTEGER"
property=
"openFlag"
/>
<result
column=
"create_time"
jdbcType=
"TIMESTAMP"
property=
"createTime"
/>
...
...
@@ -14,7 +13,7 @@
</resultMap>
<sql
id=
"Base_Column_List"
>
welcome_id, wx_enterprise_id, title, welcome_content,
welcome_img,
open_flag, status_flag, create_time, update_time
welcome_id, wx_enterprise_id, title, welcome_content,open_flag, status_flag, create_time, update_time
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.String"
resultMap=
"BaseResultMap"
>
...
...
@@ -32,10 +31,10 @@
<insert
id=
"insert"
parameterType=
"com.gic.haoban.manage.service.entity.TabWelcome"
>
insert into tab_haoban_welcome (welcome_id, wx_enterprise_id, title,
welcome_content,
welcome_img,
open_flag, status_flag, create_time,
welcome_content, open_flag, status_flag, create_time,
update_time)
values (#{welcomeId,jdbcType=VARCHAR}, #{wxEnterpriseId,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR},
#{welcomeContent,jdbcType=VARCHAR}, #{
welcomeImg,jdbcType=VARCHAR}, #{
openFlag},
#{welcomeContent,jdbcType=VARCHAR}, #{openFlag},
#{statusFlag,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP})
</insert>
...
...
@@ -52,9 +51,6 @@
<if
test=
"welcomeContent != null"
>
welcome_content = #{welcomeContent,jdbcType=VARCHAR},
</if>
<if
test=
"welcomeImg != null"
>
welcome_img = #{welcomeImg,jdbcType=VARCHAR},
</if>
<if
test=
"openFlag != null"
>
open_flag = #{openFlag,jdbcType=INTEGER},
</if>
...
...
haoban-manage3-wx/src/main/java/com/gic/haoban/manage/web/controller/DictController.java
View file @
60378a9d
...
...
@@ -36,4 +36,19 @@ public class DictController extends WebBaseController {
List
<
DictDTO
>
ret
=
dictApiService
.
queryList
(
Arrays
.
asList
(
split
));
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
EntityUtil
.
changeEntityListByOrika
(
DictVo
.
class
,
ret
));
}
/**
* 根据key查询一条数据
*
* @param dictKey
* @return
*/
@RequestMapping
(
"/find-dict-key"
)
@ResponseBody
public
HaobanResponse
queryDictByKey
(
String
dictKey
)
{
if
(
StringUtils
.
isBlank
(
dictKey
))
{
return
resultResponse
(
HaoBanErrCode
.
ERR_5
);
}
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
dictApiService
.
findOneDictByKey
(
dictKey
));
}
}
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