From 2855ae89d2ab6268e1edc42c3e9d7e73c8e7259e Mon Sep 17 00:00:00 2001 From: luodangjia <luodangjia> Date: 星期二, 03 九月 2024 10:09:24 +0800 Subject: [PATCH] 8.9 --- ruoyi-service/ruoyi-worker/src/main/java/com/ruoyi/worker/controller/MasterWorkerController.java | 23 +++++++++++++++++++++-- 1 files changed, 21 insertions(+), 2 deletions(-) diff --git a/ruoyi-service/ruoyi-worker/src/main/java/com/ruoyi/worker/controller/MasterWorkerController.java b/ruoyi-service/ruoyi-worker/src/main/java/com/ruoyi/worker/controller/MasterWorkerController.java index 050ff5c..2197757 100644 --- a/ruoyi-service/ruoyi-worker/src/main/java/com/ruoyi/worker/controller/MasterWorkerController.java +++ b/ruoyi-service/ruoyi-worker/src/main/java/com/ruoyi/worker/controller/MasterWorkerController.java @@ -1,6 +1,8 @@ package com.ruoyi.worker.controller; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.ruoyi.admin.api.entity.Agreement; import com.ruoyi.admin.api.feignClient.AdminClient; import com.ruoyi.common.core.constant.Constants; @@ -13,8 +15,10 @@ import com.ruoyi.order.api.entity.WorkerOrderCountVO; import com.ruoyi.order.api.feignClient.OrderClient; import com.ruoyi.system.api.model.LoginUserInfo; +import com.ruoyi.worker.entity.AppVersion; import com.ruoyi.worker.entity.MasterWorker; import com.ruoyi.worker.entity.WorkerProcess; +import com.ruoyi.worker.mapper.AppMapper; import com.ruoyi.worker.request.LoginPasswordRequest; import com.ruoyi.worker.request.LoginPhoneRequest; import com.ruoyi.worker.service.MasterWorkerService; @@ -61,7 +65,16 @@ private AdminClient adminClient; @Resource private OrderClient orderClient; + @Resource + private AppMapper appMapper; + + @PostMapping("/version/check") + @ApiOperation(value = "获取最新的版本信息", tags = {"自动更新"}) + public R<AppVersion> check() { + AppVersion appVersion = appMapper.selectOne(new QueryWrapper<AppVersion>().orderByDesc("createTime").eq("is_delete", 0).last("limit 1")); + return R.ok(appVersion); + } /** * 师傅端-密码登录 * @@ -89,7 +102,6 @@ if (Constants.ZERO.equals(process.getState())) { return R.fail("入驻申请暂未审核通过,请耐心等待!"); } else if (Constants.TWO.equals(process.getState())) { -// return R.fail("入驻申请已驳回,请重新提交入驻申请!"); return R.fail("当前手机号未注册!"); } else { return R.registered("当前账号未提交入驻申请,无法登录!"); @@ -185,7 +197,6 @@ if (Constants.ZERO.equals(process.getState())) { return R.fail("入驻申请暂未审核通过,请耐心等待!"); } else if (Constants.TWO.equals(process.getState())) { -// return R.fail("入驻申请已驳回,请重新提交入驻申请!"); return R.fail("当前手机号未注册!"); } else { return R.registered("当前账号未提交入驻申请,无法登录!"); @@ -364,6 +375,14 @@ return R.ok(masterWorkerService.orderNotHandle(loginWorker.getUserid(), longitude, latitude)); } + @ApiOperation(value = "下拉框", tags = {"后台-下拉框"}) + @GetMapping(value = "/workSelect") + public R<List<MasterWorker>> workSelect() { + + List<MasterWorker> list = masterWorkerService.lambdaQuery().eq(MasterWorker::getIsEnable, 1).eq(MasterWorker::getIsDelete, 0).list(); + return R.ok(list); + } + /** * 师傅端-订单列表-地图模式 */ -- Gitblit v1.7.1