puzhibing
2023-07-26 709a4a10be56952ead6340e4822fce41a66e47cd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
package com.supersavedriving.driver.modular.system.service;
 
import com.baomidou.mybatisplus.service.IService;
import com.supersavedriving.driver.modular.system.model.Driver;
import com.supersavedriving.driver.modular.system.util.ResultUtil;
import com.supersavedriving.driver.modular.system.warpper.*;
 
import java.util.List;
 
/**
* 司机
* @author pzb
* @Date 2023/2/8 18:52
*/
public interface IDriverService extends IService<Driver> {
 
 
    /**
     * 司机注册
     * @param driverRegisterWarpper
     * @return
     * @throws Exception
     */
    ResultUtil driverRegister(DriverRegisterWarpper driverRegisterWarpper) throws Exception;
 
 
    /**
     * 司机登录
     * @param receiver  国家代码+86
     * @param phone     登录手机号
     * @param code      短信验证码
     * @return
     * @throws Exception
     */
    ResultUtil<TokenWarpper> driverLogin(String receiver, String phone, String code) throws Exception;
 
 
    /**
     * 司机密码登录
     * @param receiver  国家代码+86
     * @param phone     手机号
     * @param password  密码
     * @return
     * @throws Exception
     */
    ResultUtil<TokenWarpper> driverPassLogin(String receiver, String phone, String password) throws Exception;
 
 
    /**
     * 刷新token
     * @param uid
     * @return
     * @throws Exception
     */
    ResultUtil<TokenWarpper> flushedToken(Integer uid) throws Exception;
 
 
    /**
     * 校验token获取用户信息
     * @return
     */
    Integer getUserByRequest() throws Exception;
 
 
    /**
     * 设置司机密码
     * @param uid
     * @param password
     * @throws Exception
     */
    void setPassword(Integer uid, String password) throws Exception;
 
 
    /**
     * 获取5公里范围内的司机坐标
     * @param uid
     * @return
     * @throws Exception
     */
    ResultUtil<List<String>> queryDriverPosition(Integer uid) throws Exception;
 
 
    /**
     * 存储司机实时位置
     * @throws Exception
     */
    void addDriverPosition(DriverPositionWarpper driverPositionWarpper) throws Exception;
 
 
    /**
     * 获取分享二维码数据
     * @param uid
     * @return
     * @throws Exception
     */
    PromotionWarpper queryPromotionQRCode(Integer uid) throws Exception;
 
 
    /**
     * 获取司机个人信息
     * @param uid
     * @return
     * @throws Exception
     */
    DriverInfoWarpper queryDriverInfo(Integer uid) throws Exception;
 
 
    /**
     * 修改个人信息
     * @param uid
     * @param driverInfo
     * @return
     * @throws Exception
     */
    ResultUtil saveDriverInfo(Integer uid, DriverInfo driverInfo) throws Exception;
 
 
    /**
     * 清空司机积分
     */
    void emptyIntegral();
 
 
    /**
     * 司机账户余额充值
     * @param uid
     * @param amount
     * @return
     * @throws Exception
     */
    ResultUtil balanceRecharge(Integer uid, Double amount) throws Exception;
 
 
 
    /**
     * 司机账户余额充值
     * @param driverId
     * @param amount
     * @return
     * @throws Exception
     */
    ResultUtil balanceRecharge1(Integer driverId, String jscode, Double amount) throws Exception;
 
 
    /**
     * 支付回调通知处理
     * @param out_trade_no
     * @throws Exception
     */
    void balanceRechargeCallback(String out_trade_no, String transaction_id) throws Exception;
 
 
    /**
     * 修改密码
     * @param uid
     * @param oldPass
     * @param newPass
     * @return
     * @throws Exception
     */
    ResultUtil updatePassword(Integer uid, String oldPass, String newPass) throws Exception;
 
 
    /**
     * 设置密码
     * @param uid
     * @param password
     * @return
     * @throws Exception
     */
    ResultUtil recoverPassword(Integer uid, String password) throws Exception;
 
 
    /**
     * 打开下单二维码
     * @param uid
     * @return
     */
    ResultUtil openOrderQRCode(Integer uid) throws Exception;
 
 
    /**
     * 关闭下单二维码
     * @param uid
     * @return
     * @throws Exception
     */
    ResultUtil closeOrderQRCode(Integer uid) throws Exception;
 
 
    /**
     * 开通小微商户
     * @param name
     * @param number
     * @param phone
     * @return
     * @throws Exception
     */
    ResultUtil microenterprise(Integer uid, String name, String number, String phone, String notifyUrl) throws Exception;
}