COperatorServiceProtoRpc.proto
7.8 KB
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
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
syntax = "proto3";
option java_multiple_files = true;
option java_package = "com.infoloop.tianting";
option java_outer_classname = "COperatorsServiceProto";
option objc_class_prefix = "OP";
package com.infoloop.tianting;
service COperatorServiceProtoRpc {
rpc GetCOperatorById(GetCOperatorByIdRpcRequest) returns (GetCOperatorByIdRpcResponse) {}
rpc GetCOperatorByIds(GetCOperatorByIdsRpcRequest) returns (GetCOperatorByIdsRpcResponse) {}
rpc GetCOperatorsByClientIds(GetCOperatorsByIdsRpcRequest) returns (GetCOperatorsByIdsRpcResponse) {}
rpc GetCOperatorByCondition(GetCOperatorByConditionRpcRequest) returns (GetCOperatorByConditionRpcResponse) {}
rpc GetCOperatorByEmail (GetCOperatorByEmailRpcRequest) returns (GetCOperatorByEmailRpcResponse) {}
rpc UpdateCOperatorStatusByClientIds(UpdateCOperatorStatusByClientIdsRpcRequest) returns (UpdateCOperatorStatusByClientIdsRpcResponse) {}
rpc GetCOperatorOnlyById(GetOperatorOnlyByIdRpcRequest) returns (GetOperatorOnlyByIdRpcResponse) {}
rpc GetCOperatorByMobile (GetCOperatorByMobileRpcRequest) returns (GetCOperatorByMobileRpcResponse) {}
rpc UpdateCOperatorPasswordById(UpdateCOperatorPasswordByIdRpcRequest) returns (UpdateCOperatorPasswordByIdRpcResponse) {}
rpc UpdateCOperatorMobileById(UpdateCOperatorMobileByIdRpcRequest) returns (UpdateCOperatorMobileByIdRpcResponse) {}
rpc UpdateCOperatorAliasById(UpdateCOperatorAliasByIdRpcRequest) returns (UpdateCOperatorAliasByIdRpcResponse) {}
rpc CreateCOperator (CreateCOperatorRpcRequest) returns (CreateCOperatorRpcResponse) {}
rpc UpdateCOperator (UpdateCOperatorRpcRequest) returns (UpdateCOperatorRpcResponse) {}
rpc DeleteCOperatorByIds (DeleteCOperatorByIdsRpcRequest) returns (DeleteCOperatorByIdsRpcResponse) {}
rpc GetRoleIdsByOperatorId (GetRoleIdsByOperatorIdRpcRequest) returns (GetRoleIdsByOperatorIdRpcResponse) {}
rpc CreateCRoles (CreateCRolesRpcRequest) returns (CreateCRolesRpcResponse) {}
rpc CreateCRole (CreateCRoleRpcRequest) returns (CreateCRoleRpcResponse) {}
rpc GetCOperatorByMobileOrEmail (GetCOperatorByMobileOrEmailRpcRequest) returns (GetCOperatorByMobileOrEmailRpcResponse) {}
}
enum COperatorStatus {
UN_KNOW_COPERATOR = 0;
ENABLE = 1;
DISABLE = 3;
}
message UpdateCOperatorStatusByClientIdsRpcRequest {
repeated int32 clientIds = 1;
int32 enterpriseId = 2;
COperatorStatus status = 3;
}
message UpdateCOperatorStatusByClientIdsRpcResponse {
bool isUpdated = 1;
}
message GetOperatorOnlyByIdRpcRequest {
int32 id = 1;
}
message GetOperatorOnlyByIdRpcResponse {
SingleCOperatorRpcResponse response = 1;
}
message GetCOperatorByMobileRpcRequest {
string mobile = 1;
}
message GetCOperatorByMobileRpcResponse {
SingleCOperatorRpcResponse response = 1;
}
message GetCOperatorByIdRpcRequest {
int32 enterpriseId = 1;
int32 id = 2;
}
message GetCOperatorByIdsRpcRequest {
repeated int32 ids = 1;
bool includeDeleted = 2;
}
message GetCOperatorsByIdsRpcRequest {
repeated int32 ids = 1;
bool includeDeleted = 2;
bool isPrimary = 3;
bool shouldFilerIsPrimary = 4;
}
message GetCOperatorByConditionRpcResponse {
repeated SingleCOperatorRpcResponse responses = 1;
}
message GetCOperatorByConditionRpcRequest {
int32 enterpriseId = 1;
repeated int32 ids = 2;
repeated int32 clientIds = 3;
string name = 4;
string email = 5;
string password = 6;
COperatorStatus status = 7;
repeated int32 stallIds = 8;
string mobile = 9;
bool isPrimary = 10;
bool shouldFilerIds = 11;
bool shouldFilerClientIds = 12;
bool shouldFilerName = 13;
bool shouldFilerEmail = 14;
bool shouldFilerPassword = 15;
bool shouldFilerStatus = 16;
bool shouldFilerStallIds = 17;
bool shouldFilerMobile = 18;
bool shouldFilerIsPrimary = 19;
}
message UpdateCOperatorPasswordByIdRpcRequest {
int32 id = 1;
string password = 2;
}
message UpdateCOperatorPasswordByIdRpcResponse {
bool isUpdated = 1;
}
message UpdateCOperatorMobileByIdRpcRequest {
int32 id = 1;
string mobile = 2;
}
message UpdateCOperatorAliasByIdRpcRequest {
int32 id = 1;
string alias = 2;
}
message UpdateCOperatorMobileByIdRpcResponse {
bool isUpdated = 1;
}
message UpdateCOperatorAliasByIdRpcResponse {
bool isUpdated = 1;
}
message SingleCOperatorRpcResponse {
int32 id = 1;
int32 enterpriseId = 2;
int32 clientId = 3;
string name = 4;
bool isEmailSet = 5;
string email = 6;
string password = 7;
int32 status = 8;
int64 createdAt = 9;
int64 updatedAt = 10;
bool isDeleted = 11;
bool isStallIdSet = 12;
int32 stallId = 13;
bool isPrimary = 14;
bool isMobileSet = 15;
string mobile = 16;
string phone = 17;
string alias = 18;
}
message GetCOperatorByIdRpcResponse {
SingleCOperatorRpcResponse response = 1;
}
message GetCOperatorsByIdsRpcResponse {
repeated SingleCOperatorRpcResponse responses = 1;
}
message GetCOperatorByIdsRpcResponse {
repeated SingleCOperatorRpcResponse responses = 1;
}
message GetCOperatorByEmailRpcRequest {
string email = 1;
}
message GetCOperatorByEmailRpcResponse {
SingleCOperatorRpcResponse response = 1;
}
message GetRoleIdsByOperatorIdRpcRequest {
int32 enterpriseId = 1;
int32 operatorId = 2;
}
message GetRoleIdsByOperatorIdRpcResponse {
repeated int32 roleIds = 1;
}
message SingleCRoleCreationRpcRequest {
int32 clientId = 1;
string code = 2;
string name = 3;
string description = 4;
int32 status = 5;
}
message CreateCRolesRpcRequest {
int32 enterpriseId = 1;
repeated SingleCRoleCreationRpcRequest creations = 2;
}
message CreateCRolesRpcResponse {
bool isCreated = 1;
repeated int32 ids = 2;
}
message CreateCOperatorRpcResponse {
bool isCreated = 1;
int32 id = 2;
}
message UpdateCOperatorRpcResponse {
bool isUpdated = 1;
}
message CreateCOperatorRpcRequest {
int32 enterpriseId = 1;
int32 clientId = 2;
string code = 3;
string name = 4;
string email = 5;
string password = 6;
string phone = 7;
string note = 8;
string openId = 9;
int32 stallId = 10;
bool isSuper = 11;
bool isPrimary = 12;
int32 bookingMode = 13;
int32 canWriteRealPurchasePrice = 14;
string mobile = 15;
int32 canWriteSkuBarcode = 16;
string description = 17;
int32 status = 18;
int32 creationSource = 19;
int32 createdBy = 20;
}
message DeleteCOperatorByIdsRpcRequest{
int32 enterpriseId = 1;
int32 clientId = 2;
repeated int32 ids = 3;
int32 updateSource = 19;
int32 updatedBy = 20;
}
message DeleteCOperatorByIdsRpcResponse{
bool isDeleted = 1;
}
message UpdateCOperatorRpcRequest {
int32 id = 38;
int32 enterpriseId = 1;
int32 clientId = 2;
string code = 3;
string name = 4;
string email = 5;
string password = 6;
string phone = 7;
string note = 8;
string openId = 9;
int32 stallId = 10;
bool isSuper = 11;
bool isPrimary = 12;
int32 bookingMode = 13;
int32 canWriteRealPurchasePrice = 14;
string mobile = 15;
int32 canWriteSkuBarcode = 16;
string description = 17;
int32 status = 18;
int32 updatedSource = 19;
int32 updatedBy = 20;
bool shouldUpdateClientId = 21;
bool shouldUpdateCode = 22;
bool shouldUpdateName = 23;
bool shouldUpdateEmail = 24;
bool shouldUpdatePassword = 25;
bool shouldUpdatePhone = 26;
bool shouldUpdateNote = 27;
bool shouldUpdateOpenId = 28;
bool shouldUpdateStallId = 29;
bool shouldUpdateIsSuper = 30;
bool shouldUpdateIsPrimary = 31;
bool shouldUpdateBookingMode = 32;
bool shouldUpdateCanWriteRealPurchasePrice = 33;
bool shouldUpdateMobile = 34;
bool shouldUpdateCanWriteSkuBarcode = 35;
bool shouldUpdateDescription = 36;
bool shouldUpdateStatus = 37;
}
message CreateCRoleRpcRequest {
int32 enterpriseId = 1;
SingleCRoleCreationRpcRequest creation = 2;
}
message CreateCRoleRpcResponse {
bool isCreated = 1;
int32 id = 2;
}
message GetCOperatorByMobileOrEmailRpcRequest {
string keyword = 1;
}
message GetCOperatorByMobileOrEmailRpcResponse {
SingleCOperatorRpcResponse response = 1;
}