feat: wx pay update
This commit is contained in:
@@ -42,6 +42,13 @@ spring:
|
||||
# url:
|
||||
# driver-class-name:
|
||||
|
||||
wx:
|
||||
pay:
|
||||
appId: app_id
|
||||
mchId: merchant_id
|
||||
mchKey: merchant_key
|
||||
keyPath: /path/to/your/apiclient_key.pem
|
||||
|
||||
# mybatis-plus配置
|
||||
mybatis-plus:
|
||||
# 搜索指定包别名
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.wfc.payment.mapper.WechatPayMapper">
|
||||
<mapper namespace="org.wfc.payment.mapper.WxPayMapper">
|
||||
|
||||
<resultMap type="WechatPay" id="WechatPayResult">
|
||||
<resultMap type="WxPay" id="WxPayResult">
|
||||
<id property="deptId" column="dept_id" />
|
||||
<result property="parentId" column="parent_id" />
|
||||
<result property="ancestors" column="ancestors" />
|
||||
@@ -23,13 +23,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectWechatPayInfoVo">
|
||||
<sql id="selectWxPayInfoVo">
|
||||
select d.dept_id, d.parent_id, d.ancestors, d.remark, d.dept_name, d.order_num, d.leader, d.phone, d.email, d.status, d.del_flag, d.create_by, d.create_time
|
||||
from sys_dept d
|
||||
</sql>
|
||||
|
||||
<select id="selectWechatPayInfoByUserId" parameterType="WechatPay" resultMap="WechatPayResult">
|
||||
<include refid="selectWechatPayInfoVo"/>
|
||||
<select id="selectWxPayInfoByUserId" parameterType="WxPay" resultMap="WxPayResult">
|
||||
<include refid="selectWxPayInfoVo"/>
|
||||
where d.del_flag = '0'
|
||||
<if test="deptId != null and deptId != 0">
|
||||
AND dept_id = #{deptId}
|
||||
@@ -48,7 +48,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
order by d.parent_id, d.order_num
|
||||
</select>
|
||||
|
||||
<insert id="insertWechatPayInfo" parameterType="WechatPay">
|
||||
<insert id="insertWxPayInfo" parameterType="WxPay">
|
||||
insert into sys_dept(
|
||||
<if test="deptId != null and deptId != 0">dept_id,</if>
|
||||
<if test="parentId != null and parentId != 0">parent_id,</if>
|
||||
@@ -78,7 +78,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
)
|
||||
</insert>
|
||||
|
||||
<update id="updateWechatPayInfoById" parameterType="WechatPay">
|
||||
<update id="updateWxPayInfoById" parameterType="WxPay">
|
||||
update sys_dept
|
||||
<set>
|
||||
<if test="parentId != null and parentId != 0">parent_id = #{parentId},</if>
|
||||
@@ -96,7 +96,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where dept_id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteWechatPayInfoById" parameterType="Long">
|
||||
<delete id="deleteWxPayInfoById" parameterType="Long">
|
||||
update sys_dept set del_flag = '2' where dept_id = #{id}
|
||||
</delete>
|
||||
|
||||
Reference in New Issue
Block a user