rcvr.go 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819
  1. // Copyright 2019 getensh.com. All rights reserved.
  2. // Use of this source code is governed by getensh.com.
  3. package impl
  4. import (
  5. "context"
  6. "git.getensh.com/common/gopkgs/tasker/rpctasker"
  7. "google.golang.org/grpc"
  8. "property-garden/impl/v1/announcement"
  9. "property-garden/impl/v1/event"
  10. "property-garden/impl/v1/fee"
  11. "property-garden/impl/v1/garden"
  12. "property-garden/impl/v1/house"
  13. "property-garden/impl/v1/household"
  14. "property-garden/impl/v1/repair"
  15. "property-garden/impl/v1/service_phone"
  16. "property-garden/impl/v1/statistic"
  17. "property-garden/impl/v1/suggestion"
  18. "property-garden/impl/v1/system_msg"
  19. "property-garden/impl/v1/vote"
  20. "property-garden/pb"
  21. pb_v1 "property-garden/pb/v1"
  22. )
  23. // 具体实现
  24. type Rcvr struct {
  25. }
  26. func Register(s *grpc.Server) {
  27. pb.RegisterGardenServer(s, &Rcvr{})
  28. }
  29. func (c *Rcvr) GardenInitDb(ctx context.Context, req *pb_v1.GardenInitDbRequest) (reply *pb_v1.GardenInitDbReply, err error) {
  30. t1 := func() error {
  31. reply, err = garden.GardenInitDb(ctx, req)
  32. return err
  33. }
  34. return reply, rpctasker.Exec(ctx, t1)
  35. }
  36. func (c *Rcvr) GardenHouseIsIn(ctx context.Context, req *pb_v1.GardenHouseIsInRequest) (reply *pb_v1.GardenHouseIsInReply, err error) {
  37. t1 := func() error {
  38. reply, err = garden.GardenHouseIsIn(ctx, req)
  39. return err
  40. }
  41. return reply, rpctasker.Exec(ctx, t1)
  42. }
  43. func (c *Rcvr) BuildingAdd(ctx context.Context, req *pb_v1.BuildingAddRequest) (reply *pb_v1.BuildingAddReply, err error) {
  44. t1 := func() error {
  45. reply, err = house.BuildingAdd(ctx, req)
  46. return err
  47. }
  48. return reply, rpctasker.Exec(ctx, t1)
  49. }
  50. func (c *Rcvr) BuildingUpdate(ctx context.Context, req *pb_v1.BuildingUpdateRequest) (reply *pb_v1.BuildingUpdateReply, err error) {
  51. t1 := func() error {
  52. reply, err = house.BuildingUpdate(ctx, req)
  53. return err
  54. }
  55. return reply, rpctasker.Exec(ctx, t1)
  56. }
  57. func (c *Rcvr) BuildingDel(ctx context.Context, req *pb_v1.BuildingDelRequest) (reply *pb_v1.BuildingDelReply, err error) {
  58. t1 := func() error {
  59. reply, err = house.BuildingDel(ctx, req)
  60. return err
  61. }
  62. return reply, rpctasker.Exec(ctx, t1)
  63. }
  64. func (c *Rcvr) BuildingList(ctx context.Context, req *pb_v1.BuildingListRequest) (reply *pb_v1.BuildingListReply, err error) {
  65. t1 := func() error {
  66. reply, err = house.BuildingList(ctx, req)
  67. return err
  68. }
  69. return reply, rpctasker.Exec(ctx, t1)
  70. }
  71. func (c *Rcvr) BuildingAddManager(ctx context.Context, req *pb_v1.BuildingAddManagerRequest) (reply *pb_v1.BuildingAddManagerReply, err error) {
  72. t1 := func() error {
  73. reply, err = house.BuildingAddManager(ctx, req)
  74. return err
  75. }
  76. return reply, rpctasker.Exec(ctx, t1)
  77. }
  78. func (c *Rcvr) BuildingDelManager(ctx context.Context, req *pb_v1.BuildingDelManagerRequest) (reply *pb_v1.BuildingDelManagerReply, err error) {
  79. t1 := func() error {
  80. reply, err = house.BuildingDelManager(ctx, req)
  81. return err
  82. }
  83. return reply, rpctasker.Exec(ctx, t1)
  84. }
  85. func (c *Rcvr) BuildingManagerList(ctx context.Context, req *pb_v1.BuildingManagerListRequest) (reply *pb_v1.BuildingManagerListReply, err error) {
  86. t1 := func() error {
  87. reply, err = house.BuildingManagerList(ctx, req)
  88. return err
  89. }
  90. return reply, rpctasker.Exec(ctx, t1)
  91. }
  92. func (c *Rcvr) UnitAdd(ctx context.Context, req *pb_v1.UnitAddRequest) (reply *pb_v1.UnitAddReply, err error) {
  93. t1 := func() error {
  94. reply, err = house.UnitAdd(ctx, req)
  95. return err
  96. }
  97. return reply, rpctasker.Exec(ctx, t1)
  98. }
  99. func (c *Rcvr) UnitUpdate(ctx context.Context, req *pb_v1.UnitUpdateRequest) (reply *pb_v1.UnitUpdateReply, err error) {
  100. t1 := func() error {
  101. reply, err = house.UnitUpdate(ctx, req)
  102. return err
  103. }
  104. return reply, rpctasker.Exec(ctx, t1)
  105. }
  106. func (c *Rcvr) UnitDel(ctx context.Context, req *pb_v1.UnitDelRequest) (reply *pb_v1.UnitDelReply, err error) {
  107. t1 := func() error {
  108. reply, err = house.UnitDel(ctx, req)
  109. return err
  110. }
  111. return reply, rpctasker.Exec(ctx, t1)
  112. }
  113. func (c *Rcvr) UnitList(ctx context.Context, req *pb_v1.UnitListRequest) (reply *pb_v1.UnitListReply, err error) {
  114. t1 := func() error {
  115. reply, err = house.UnitList(ctx, req)
  116. return err
  117. }
  118. return reply, rpctasker.Exec(ctx, t1)
  119. }
  120. func (c *Rcvr) HouseAdd(ctx context.Context, req *pb_v1.HouseAddRequest) (reply *pb_v1.HouseAddReply, err error) {
  121. t1 := func() error {
  122. reply, err = house.HouseAdd(ctx, req)
  123. return err
  124. }
  125. return reply, rpctasker.Exec(ctx, t1)
  126. }
  127. func (c *Rcvr) HouseUpdate(ctx context.Context, req *pb_v1.HouseUpdateRequest) (reply *pb_v1.HouseUpdateReply, err error) {
  128. t1 := func() error {
  129. reply, err = house.HouseUpdate(ctx, req)
  130. return err
  131. }
  132. return reply, rpctasker.Exec(ctx, t1)
  133. }
  134. func (c *Rcvr) HouseDel(ctx context.Context, req *pb_v1.HouseDelRequest) (reply *pb_v1.HouseDelReply, err error) {
  135. t1 := func() error {
  136. reply, err = house.HouseDel(ctx, req)
  137. return err
  138. }
  139. return reply, rpctasker.Exec(ctx, t1)
  140. }
  141. func (c *Rcvr) HouseList(ctx context.Context, req *pb_v1.HouseListRequest) (reply *pb_v1.HouseListReply, err error) {
  142. t1 := func() error {
  143. reply, err = house.HouseList(ctx, req)
  144. return err
  145. }
  146. return reply, rpctasker.Exec(ctx, t1)
  147. }
  148. func (c *Rcvr) HouseIds(ctx context.Context, req *pb_v1.HouseIdsRequest) (reply *pb_v1.HouseIdsReply, err error) {
  149. t1 := func() error {
  150. reply, err = house.HouseIds(ctx, req)
  151. return err
  152. }
  153. return reply, rpctasker.Exec(ctx, t1)
  154. }
  155. func (c *Rcvr) HouseInfo(ctx context.Context, req *pb_v1.HouseInfoRequest) (reply *pb_v1.HouseInfoReply, err error) {
  156. t1 := func() error {
  157. reply, err = house.HouseInfo(ctx, req)
  158. return err
  159. }
  160. return reply, rpctasker.Exec(ctx, t1)
  161. }
  162. func (c *Rcvr) HouseholdSync(ctx context.Context, req *pb_v1.HouseholdSyncRequest) (reply *pb_v1.HouseholdSyncReply, err error) {
  163. t1 := func() error {
  164. reply, err = household.HouseholdSync(ctx, req)
  165. return err
  166. }
  167. return reply, rpctasker.Exec(ctx, t1)
  168. }
  169. func (c *Rcvr) HouseholdChange(ctx context.Context, req *pb_v1.HouseholdChangeRequest) (reply *pb_v1.HouseholdChangeReply, err error) {
  170. t1 := func() error {
  171. reply, err = household.HouseholdChange(ctx, req)
  172. return err
  173. }
  174. return reply, rpctasker.Exec(ctx, t1)
  175. }
  176. func (c *Rcvr) GardenHouseholdUserList(ctx context.Context, req *pb_v1.GardenHouseholdUserListRequest) (reply *pb_v1.GardenHouseholdUserListReply, err error) {
  177. t1 := func() error {
  178. reply, err = household.GardenHouseholdUserList(ctx, req)
  179. return err
  180. }
  181. return reply, rpctasker.Exec(ctx, t1)
  182. }
  183. func (c *Rcvr) GardenHouseholdList(ctx context.Context, req *pb_v1.GardenHouseholdListRequest) (reply *pb_v1.GardenHouseholdListReply, err error) {
  184. t1 := func() error {
  185. reply, err = household.GardenHouseholdList(ctx, req)
  186. return err
  187. }
  188. return reply, rpctasker.Exec(ctx, t1)
  189. }
  190. func (c *Rcvr) GardenHouseholdUnitIds(ctx context.Context, req *pb_v1.GardenHouseholdUnitIdsRequest) (reply *pb_v1.GardenHouseholdUnitIdsReply, err error) {
  191. t1 := func() error {
  192. reply, err = household.GardenHouseholdUnitIds(ctx, req)
  193. return err
  194. }
  195. return reply, rpctasker.Exec(ctx, t1)
  196. }
  197. func (c *Rcvr) GardenHouseholdUidsFromUnitId(ctx context.Context, req *pb_v1.GardenHouseholdUidsFromUnitIdRequest) (reply *pb_v1.GardenHouseholdUidsFromUnitIdReply, err error) {
  198. t1 := func() error {
  199. reply, err = household.GardenHouseholdUidsFromUnitId(ctx, req)
  200. return err
  201. }
  202. return reply, rpctasker.Exec(ctx, t1)
  203. }
  204. func (c *Rcvr) BatchHouseAdd(ctx context.Context, req *pb_v1.BatchHouseAddRequest) (reply *pb_v1.BatchHouseAddReply, err error) {
  205. t1 := func() error {
  206. reply, err = house.BatchHouseAdd(ctx, req)
  207. return err
  208. }
  209. return reply, rpctasker.Exec(ctx, t1)
  210. }
  211. // 报事报修
  212. func (c *Rcvr) RepairClassList(ctx context.Context, req *pb_v1.RepairClassListRequest) (reply *pb_v1.RepairClassListReply, err error) {
  213. t1 := func() error {
  214. reply, err = repair.RepairClassList(ctx, req)
  215. return err
  216. }
  217. return reply, rpctasker.Exec(ctx, t1)
  218. }
  219. func (c *Rcvr) RepairClassAdd(ctx context.Context, req *pb_v1.RepairClassAddRequest) (reply *pb_v1.RepairClassAddReply, err error) {
  220. t1 := func() error {
  221. reply, err = repair.RepairClassAdd(ctx, req)
  222. return err
  223. }
  224. return reply, rpctasker.Exec(ctx, t1)
  225. }
  226. func (c *Rcvr) RepairClassDel(ctx context.Context, req *pb_v1.RepairClassDelRequest) (reply *pb_v1.RepairClassDelReply, err error) {
  227. t1 := func() error {
  228. reply, err = repair.RepairClassDel(ctx, req)
  229. return err
  230. }
  231. return reply, rpctasker.Exec(ctx, t1)
  232. }
  233. func (c *Rcvr) RepairClassUpdate(ctx context.Context, req *pb_v1.RepairClassUpdateRequest) (reply *pb_v1.RepairClassUpdateReply, err error) {
  234. t1 := func() error {
  235. reply, err = repair.RepairClassUpdate(ctx, req)
  236. return err
  237. }
  238. return reply, rpctasker.Exec(ctx, t1)
  239. }
  240. // 报修工单
  241. func (c *Rcvr) RepairOrderList(ctx context.Context, req *pb_v1.RepairOrderListRequest) (reply *pb_v1.RepairOrderListReply, err error) {
  242. t1 := func() error {
  243. reply, err = repair.RepairOrderList(ctx, req)
  244. return err
  245. }
  246. return reply, rpctasker.Exec(ctx, t1)
  247. }
  248. func (c *Rcvr) RepairOrderAdd(ctx context.Context, req *pb_v1.RepairOrderAddRequest) (reply *pb_v1.RepairOrderAddReply, err error) {
  249. t1 := func() error {
  250. reply, err = repair.RepairOrderAdd(ctx, req)
  251. return err
  252. }
  253. return reply, rpctasker.Exec(ctx, t1)
  254. }
  255. func (c *Rcvr) RepairOrderDel(ctx context.Context, req *pb_v1.RepairOrderDelRequest) (reply *pb_v1.RepairOrderDelReply, err error) {
  256. t1 := func() error {
  257. reply, err = repair.RepairOrderDel(ctx, req)
  258. return err
  259. }
  260. return reply, rpctasker.Exec(ctx, t1)
  261. }
  262. func (c *Rcvr) RepairOrderUpdate(ctx context.Context, req *pb_v1.RepairOrderUpdateRequest) (reply *pb_v1.RepairOrderUpdateReply, err error) {
  263. t1 := func() error {
  264. reply, err = repair.RepairOrderUpdate(ctx, req)
  265. return err
  266. }
  267. return reply, rpctasker.Exec(ctx, t1)
  268. }
  269. // 派单
  270. func (c *Rcvr) RepairOrderSend(ctx context.Context, req *pb_v1.RepairOrderSendRequest) (reply *pb_v1.RepairOrderSendReply, err error) {
  271. t1 := func() error {
  272. reply, err = repair.RepairOrderSend(ctx, req)
  273. return err
  274. }
  275. return reply, rpctasker.Exec(ctx, t1)
  276. }
  277. // 结单
  278. func (c *Rcvr) RepairOrderFinish(ctx context.Context, req *pb_v1.RepairOrderFinishRequest) (reply *pb_v1.RepairOrderFinishReply, err error) {
  279. t1 := func() error {
  280. reply, err = repair.RepairOrderFinish(ctx, req)
  281. return err
  282. }
  283. return reply, rpctasker.Exec(ctx, t1)
  284. }
  285. // 退单
  286. func (c *Rcvr) RepairOrderBack(ctx context.Context, req *pb_v1.RepairOrderBackRequest) (reply *pb_v1.RepairOrderBackReply, err error) {
  287. t1 := func() error {
  288. reply, err = repair.RepairOrderBack(ctx, req)
  289. return err
  290. }
  291. return reply, rpctasker.Exec(ctx, t1)
  292. }
  293. // 报修工单详情
  294. func (c *Rcvr) RepairOrderInfo(ctx context.Context, req *pb_v1.RepairOrderInfoRequest) (reply *pb_v1.RepairOrderInfoReply, err error) {
  295. t1 := func() error {
  296. reply, err = repair.RepairOrderInfo(ctx, req)
  297. return err
  298. }
  299. return reply, rpctasker.Exec(ctx, t1)
  300. }
  301. // 报修回访
  302. func (c *Rcvr) RepairOrderReturnVisit(ctx context.Context, req *pb_v1.RepairOrderReturnVisitRequest) (reply *pb_v1.RepairOrderReturnVisitReply, err error) {
  303. t1 := func() error {
  304. reply, err = repair.RepairOrderReturnVisit(ctx, req)
  305. return err
  306. }
  307. return reply, rpctasker.Exec(ctx, t1)
  308. }
  309. // 公告
  310. func (c *Rcvr) AnnouncementAdd(ctx context.Context, req *pb_v1.AnnouncementAddRequest) (reply *pb_v1.AnnouncementAddReply, err error) {
  311. t1 := func() error {
  312. reply, err = announcement.AnnouncementAdd(ctx, req)
  313. return err
  314. }
  315. return reply, rpctasker.Exec(ctx, t1)
  316. }
  317. func (c *Rcvr) AnnouncementReadAdd(ctx context.Context, req *pb_v1.AnnouncementReadAddRequest) (reply *pb_v1.AnnouncementReadAddReply, err error) {
  318. t1 := func() error {
  319. reply, err = announcement.AnnouncementReadAdd(ctx, req)
  320. return err
  321. }
  322. return reply, rpctasker.Exec(ctx, t1)
  323. }
  324. func (c *Rcvr) AnnouncementDel(ctx context.Context, req *pb_v1.AnnouncementDelRequest) (reply *pb_v1.AnnouncementDelReply, err error) {
  325. t1 := func() error {
  326. reply, err = announcement.AnnouncementDel(ctx, req)
  327. return err
  328. }
  329. return reply, rpctasker.Exec(ctx, t1)
  330. }
  331. func (c *Rcvr) AnnouncementUpdate(ctx context.Context, req *pb_v1.AnnouncementUpdateRequest) (reply *pb_v1.AnnouncementUpdateReply, err error) {
  332. t1 := func() error {
  333. reply, err = announcement.AnnouncementUpdate(ctx, req)
  334. return err
  335. }
  336. return reply, rpctasker.Exec(ctx, t1)
  337. }
  338. func (c *Rcvr) AnnouncementList(ctx context.Context, req *pb_v1.AnnouncementListRequest) (reply *pb_v1.AnnouncementListReply, err error) {
  339. t1 := func() error {
  340. reply, err = announcement.AnnouncementList(ctx, req)
  341. return err
  342. }
  343. return reply, rpctasker.Exec(ctx, t1)
  344. }
  345. func (c *Rcvr) SuggestionOrderList(ctx context.Context, req *pb_v1.SuggestionOrderListRequest) (reply *pb_v1.SuggestionOrderListReply, err error) {
  346. t1 := func() error {
  347. reply, err = suggestion.SuggestionOrderList(ctx, req)
  348. return err
  349. }
  350. return reply, rpctasker.Exec(ctx, t1)
  351. }
  352. func (c *Rcvr) SuggestionOrderAdd(ctx context.Context, req *pb_v1.SuggestionOrderAddRequest) (reply *pb_v1.SuggestionOrderAddReply, err error) {
  353. t1 := func() error {
  354. reply, err = suggestion.SuggestionOrderAdd(ctx, req)
  355. return err
  356. }
  357. return reply, rpctasker.Exec(ctx, t1)
  358. }
  359. func (c *Rcvr) SuggestionOrderDel(ctx context.Context, req *pb_v1.SuggestionOrderDelRequest) (reply *pb_v1.SuggestionOrderDelReply, err error) {
  360. t1 := func() error {
  361. reply, err = suggestion.SuggestionOrderDel(ctx, req)
  362. return err
  363. }
  364. return reply, rpctasker.Exec(ctx, t1)
  365. }
  366. func (c *Rcvr) SuggestionOrderUpdate(ctx context.Context, req *pb_v1.SuggestionOrderUpdateRequest) (reply *pb_v1.SuggestionOrderUpdateReply, err error) {
  367. t1 := func() error {
  368. reply, err = suggestion.SuggestionOrderUpdate(ctx, req)
  369. return err
  370. }
  371. return reply, rpctasker.Exec(ctx, t1)
  372. }
  373. // 派单
  374. func (c *Rcvr) SuggestionOrderSend(ctx context.Context, req *pb_v1.SuggestionOrderSendRequest) (reply *pb_v1.SuggestionOrderSendReply, err error) {
  375. t1 := func() error {
  376. reply, err = suggestion.SuggestionOrderSend(ctx, req)
  377. return err
  378. }
  379. return reply, rpctasker.Exec(ctx, t1)
  380. }
  381. // 结单
  382. func (c *Rcvr) SuggestionOrderFinish(ctx context.Context, req *pb_v1.SuggestionOrderFinishRequest) (reply *pb_v1.SuggestionOrderFinishReply, err error) {
  383. t1 := func() error {
  384. reply, err = suggestion.SuggestionOrderFinish(ctx, req)
  385. return err
  386. }
  387. return reply, rpctasker.Exec(ctx, t1)
  388. }
  389. // 退单
  390. func (c *Rcvr) SuggestionOrderBack(ctx context.Context, req *pb_v1.SuggestionOrderBackRequest) (reply *pb_v1.SuggestionOrderBackReply, err error) {
  391. t1 := func() error {
  392. reply, err = suggestion.SuggestionOrderBack(ctx, req)
  393. return err
  394. }
  395. return reply, rpctasker.Exec(ctx, t1)
  396. }
  397. // 报修工单详情
  398. func (c *Rcvr) SuggestionOrderInfo(ctx context.Context, req *pb_v1.SuggestionOrderInfoRequest) (reply *pb_v1.SuggestionOrderInfoReply, err error) {
  399. t1 := func() error {
  400. reply, err = suggestion.SuggestionOrderInfo(ctx, req)
  401. return err
  402. }
  403. return reply, rpctasker.Exec(ctx, t1)
  404. }
  405. // 报修回访
  406. func (c *Rcvr) SuggestionOrderReturnVisit(ctx context.Context, req *pb_v1.SuggestionOrderReturnVisitRequest) (reply *pb_v1.SuggestionOrderReturnVisitReply, err error) {
  407. t1 := func() error {
  408. reply, err = suggestion.SuggestionOrderReturnVisit(ctx, req)
  409. return err
  410. }
  411. return reply, rpctasker.Exec(ctx, t1)
  412. }
  413. // 生成账单
  414. func (c *Rcvr) GenerateBill(ctx context.Context, req *pb_v1.GenerateBillRequest) (reply *pb_v1.GenerateBillReply, err error) {
  415. t1 := func() error {
  416. reply, err = fee.GenerateBill(ctx, req)
  417. return err
  418. }
  419. return reply, rpctasker.Exec(ctx, t1)
  420. }
  421. func (c *Rcvr) GenerateOverdue(ctx context.Context, req *pb_v1.GenerateOverdueRequest) (reply *pb_v1.GenerateOverdueReply, err error) {
  422. t1 := func() error {
  423. reply, err = fee.GenerateOverdue(ctx, req)
  424. return err
  425. }
  426. return reply, rpctasker.Exec(ctx, t1)
  427. }
  428. func (c *Rcvr) GenerateReminder(ctx context.Context, req *pb_v1.GenerateReminderRequest) (reply *pb_v1.GenerateReminderReply, err error) {
  429. t1 := func() error {
  430. reply, err = fee.GenerateReminder(ctx, req)
  431. return err
  432. }
  433. return reply, rpctasker.Exec(ctx, t1)
  434. }
  435. func (c *Rcvr) SystemMsgAdd(ctx context.Context, req *pb_v1.SystemMsgAddRequest) (reply *pb_v1.SystemMsgAddReply, err error) {
  436. t1 := func() error {
  437. reply, err = system_msg.SystemMsgAdd(ctx, req)
  438. return err
  439. }
  440. return reply, rpctasker.Exec(ctx, t1)
  441. }
  442. func (c *Rcvr) SystemMsgList(ctx context.Context, req *pb_v1.SystemMsgListRequest) (reply *pb_v1.SystemMsgListReply, err error) {
  443. t1 := func() error {
  444. reply, err = system_msg.SystemMsgList(ctx, req)
  445. return err
  446. }
  447. return reply, rpctasker.Exec(ctx, t1)
  448. }
  449. func (c *Rcvr) SystemMsgReaded(ctx context.Context, req *pb_v1.SystemMsgReadedRequest) (reply *pb_v1.SystemMsgReadedReply, err error) {
  450. t1 := func() error {
  451. reply, err = system_msg.SystemMsgReaded(ctx, req)
  452. return err
  453. }
  454. return reply, rpctasker.Exec(ctx, t1)
  455. }
  456. func (c *Rcvr) EventAdd(ctx context.Context, req *pb_v1.EventAddRequest) (reply *pb_v1.EventAddReply, err error) {
  457. t1 := func() error {
  458. reply, err = event.EventAdd(ctx, req)
  459. return err
  460. }
  461. return reply, rpctasker.Exec(ctx, t1)
  462. }
  463. func (c *Rcvr) EventUpdate(ctx context.Context, req *pb_v1.EventUpdateRequest) (reply *pb_v1.EventUpdateReply, err error) {
  464. t1 := func() error {
  465. reply, err = event.EventUpdate(ctx, req)
  466. return err
  467. }
  468. return reply, rpctasker.Exec(ctx, t1)
  469. }
  470. func (c *Rcvr) EventDel(ctx context.Context, req *pb_v1.EventDelRequest) (reply *pb_v1.EventDelReply, err error) {
  471. t1 := func() error {
  472. reply, err = event.EventDel(ctx, req)
  473. return err
  474. }
  475. return reply, rpctasker.Exec(ctx, t1)
  476. }
  477. func (c *Rcvr) EventList(ctx context.Context, req *pb_v1.EventListRequest) (reply *pb_v1.EventListReply, err error) {
  478. t1 := func() error {
  479. reply, err = event.EventList(ctx, req)
  480. return err
  481. }
  482. return reply, rpctasker.Exec(ctx, t1)
  483. }
  484. func (c *Rcvr) EventSignAdd(ctx context.Context, req *pb_v1.EventSignAddRequest) (reply *pb_v1.EventSignAddReply, err error) {
  485. t1 := func() error {
  486. reply, err = event.EventSignAdd(ctx, req)
  487. return err
  488. }
  489. return reply, rpctasker.Exec(ctx, t1)
  490. }
  491. func (c *Rcvr) EventSignDel(ctx context.Context, req *pb_v1.EventSignDelRequest) (reply *pb_v1.EventSignDelReply, err error) {
  492. t1 := func() error {
  493. reply, err = event.EventSignDel(ctx, req)
  494. return err
  495. }
  496. return reply, rpctasker.Exec(ctx, t1)
  497. }
  498. func (c *Rcvr) EventSignList(ctx context.Context, req *pb_v1.EventSignListRequest) (reply *pb_v1.EventSignListReply, err error) {
  499. t1 := func() error {
  500. reply, err = event.EventSignList(ctx, req)
  501. return err
  502. }
  503. return reply, rpctasker.Exec(ctx, t1)
  504. }
  505. // 服务电话分类
  506. func (c *Rcvr) ServicePhoneClassList(ctx context.Context, req *pb_v1.ServicePhoneClassListRequest) (reply *pb_v1.ServicePhoneClassListReply, err error) {
  507. t1 := func() error {
  508. reply, err = service_phone.ServicePhoneClassList(ctx, req)
  509. return err
  510. }
  511. return reply, rpctasker.Exec(ctx, t1)
  512. }
  513. func (c *Rcvr) ServicePhoneClassAdd(ctx context.Context, req *pb_v1.ServicePhoneClassAddRequest) (reply *pb_v1.ServicePhoneClassAddReply, err error) {
  514. t1 := func() error {
  515. reply, err = service_phone.ServicePhoneClassAdd(ctx, req)
  516. return err
  517. }
  518. return reply, rpctasker.Exec(ctx, t1)
  519. }
  520. func (c *Rcvr) ServicePhoneClassDel(ctx context.Context, req *pb_v1.ServicePhoneClassDelRequest) (reply *pb_v1.ServicePhoneClassDelReply, err error) {
  521. t1 := func() error {
  522. reply, err = service_phone.ServicePhoneClassDel(ctx, req)
  523. return err
  524. }
  525. return reply, rpctasker.Exec(ctx, t1)
  526. }
  527. func (c *Rcvr) ServicePhoneClassUpdate(ctx context.Context, req *pb_v1.ServicePhoneClassUpdateRequest) (reply *pb_v1.ServicePhoneClassUpdateReply, err error) {
  528. t1 := func() error {
  529. reply, err = service_phone.ServicePhoneClassUpdate(ctx, req)
  530. return err
  531. }
  532. return reply, rpctasker.Exec(ctx, t1)
  533. }
  534. // 服务电话
  535. func (c *Rcvr) ServicePhoneList(ctx context.Context, req *pb_v1.ServicePhoneListRequest) (reply *pb_v1.ServicePhoneListReply, err error) {
  536. t1 := func() error {
  537. reply, err = service_phone.ServicePhoneList(ctx, req)
  538. return err
  539. }
  540. return reply, rpctasker.Exec(ctx, t1)
  541. }
  542. func (c *Rcvr) ServicePhoneAdd(ctx context.Context, req *pb_v1.ServicePhoneAddRequest) (reply *pb_v1.ServicePhoneAddReply, err error) {
  543. t1 := func() error {
  544. reply, err = service_phone.ServicePhoneAdd(ctx, req)
  545. return err
  546. }
  547. return reply, rpctasker.Exec(ctx, t1)
  548. }
  549. func (c *Rcvr) ServicePhoneDel(ctx context.Context, req *pb_v1.ServicePhoneDelRequest) (reply *pb_v1.ServicePhoneDelReply, err error) {
  550. t1 := func() error {
  551. reply, err = service_phone.ServicePhoneDel(ctx, req)
  552. return err
  553. }
  554. return reply, rpctasker.Exec(ctx, t1)
  555. }
  556. func (c *Rcvr) ServicePhoneUpdate(ctx context.Context, req *pb_v1.ServicePhoneUpdateRequest) (reply *pb_v1.ServicePhoneUpdateReply, err error) {
  557. t1 := func() error {
  558. reply, err = service_phone.ServicePhoneUpdate(ctx, req)
  559. return err
  560. }
  561. return reply, rpctasker.Exec(ctx, t1)
  562. }
  563. func (c *Rcvr) Statistic(ctx context.Context, req *pb_v1.StatisticRequest) (reply *pb_v1.StatisticReply, err error) {
  564. t1 := func() error {
  565. reply, err = statistic.Statistic(ctx, req)
  566. return err
  567. }
  568. return reply, rpctasker.Exec(ctx, t1)
  569. }
  570. func (c *Rcvr) RepairStatisticSet(ctx context.Context, req *pb_v1.RepairStatisticSetRequest) (reply *pb_v1.RepairStatisticSetReply, err error) {
  571. t1 := func() error {
  572. reply, err = statistic.RepairStatisticSet(ctx, req)
  573. return err
  574. }
  575. return reply, rpctasker.Exec(ctx, t1)
  576. }
  577. // 投票
  578. func (c *Rcvr) VoteList(ctx context.Context, req *pb_v1.VoteListRequest) (reply *pb_v1.VoteListReply, err error) {
  579. t1 := func() error {
  580. reply, err = vote.VoteList(ctx, req)
  581. return err
  582. }
  583. return reply, rpctasker.Exec(ctx, t1)
  584. }
  585. func (c *Rcvr) VoteAdd(ctx context.Context, req *pb_v1.VoteAddRequest) (reply *pb_v1.VoteAddReply, err error) {
  586. t1 := func() error {
  587. reply, err = vote.VoteAdd(ctx, req)
  588. return err
  589. }
  590. return reply, rpctasker.Exec(ctx, t1)
  591. }
  592. func (c *Rcvr) VoteDel(ctx context.Context, req *pb_v1.VoteDelRequest) (reply *pb_v1.VoteDelReply, err error) {
  593. t1 := func() error {
  594. reply, err = vote.VoteDel(ctx, req)
  595. return err
  596. }
  597. return reply, rpctasker.Exec(ctx, t1)
  598. }
  599. func (c *Rcvr) VoteUpdate(ctx context.Context, req *pb_v1.VoteUpdateRequest) (reply *pb_v1.VoteUpdateReply, err error) {
  600. t1 := func() error {
  601. reply, err = vote.VoteUpdate(ctx, req)
  602. return err
  603. }
  604. return reply, rpctasker.Exec(ctx, t1)
  605. }
  606. // 投票回答
  607. func (c *Rcvr) VoteAddAnswer(ctx context.Context, req *pb_v1.VoteAddAnswerRequest) (reply *pb_v1.VoteAddAnswerReply, err error) {
  608. t1 := func() error {
  609. reply, err = vote.VoteAddAnswer(ctx, req)
  610. return err
  611. }
  612. return reply, rpctasker.Exec(ctx, t1)
  613. }
  614. // 投票结果列表
  615. func (c *Rcvr) VoteResultList(ctx context.Context, req *pb_v1.VoteResultListRequest) (reply *pb_v1.VoteResultListReply, err error) {
  616. t1 := func() error {
  617. reply, err = vote.VoteResultList(ctx, req)
  618. return err
  619. }
  620. return reply, rpctasker.Exec(ctx, t1)
  621. }
  622. // 投票结果统计
  623. func (c *Rcvr) VoteResultStatistic(ctx context.Context, req *pb_v1.VoteResultStatisticRequest) (reply *pb_v1.VoteResultStatisticReply, err error) {
  624. t1 := func() error {
  625. reply, err = vote.VoteResultStatistic(ctx, req)
  626. return err
  627. }
  628. return reply, rpctasker.Exec(ctx, t1)
  629. }
  630. // 投票列表,业主小程序专用
  631. func (c *Rcvr) VoteListForHousehold(ctx context.Context, req *pb_v1.VoteListForHouseholdRequest) (reply *pb_v1.VoteListForHouseholdReply, err error) {
  632. t1 := func() error {
  633. reply, err = vote.VoteListForHousehold(ctx, req)
  634. return err
  635. }
  636. return reply, rpctasker.Exec(ctx, t1)
  637. }
  638. // 住户退出房屋
  639. func (c *Rcvr) GardenHouseholdDelHouse(ctx context.Context, req *pb_v1.GardenHouseholdDelHouseRequest) (reply *pb_v1.GardenHouseholdDelHouseReply, err error) {
  640. t1 := func() error {
  641. reply, err = household.GardenHouseholdDelHouse(ctx, req)
  642. return err
  643. }
  644. return reply, rpctasker.Exec(ctx, t1)
  645. }