From e3a2245265516fef78b4737d6fffc939e7c5e0af Mon Sep 17 00:00:00 2001
From: huliguo <2023611923@qq.com>
Date: 星期四, 03 七月 2025 17:56:07 +0800
Subject: [PATCH] bug修改

---
 pt-admin/src/main/java/com/ruoyi/web/controller/errand/PhoneController.java |   20 +++++++++++++++++++-
 1 files changed, 19 insertions(+), 1 deletions(-)

diff --git a/pt-admin/src/main/java/com/ruoyi/web/controller/errand/PhoneController.java b/pt-admin/src/main/java/com/ruoyi/web/controller/errand/PhoneController.java
index a084bbe..768ca9e 100644
--- a/pt-admin/src/main/java/com/ruoyi/web/controller/errand/PhoneController.java
+++ b/pt-admin/src/main/java/com/ruoyi/web/controller/errand/PhoneController.java
@@ -1,6 +1,8 @@
 package com.ruoyi.web.controller.errand;
 
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.ruoyi.common.core.domain.R;
+import com.ruoyi.errand.domain.Phone;
 import com.ruoyi.errand.object.vo.app.ConfirmOrderVO;
 import com.ruoyi.errand.service.PhoneService;
 import io.swagger.annotations.Api;
@@ -24,7 +26,7 @@
      * 联系客服
      */
     @GetMapping("/getServletPhone")
-    @ApiOperation(value = "获取客服电话",tags = "app用户端-联系客服")
+    @ApiOperation(value = "获取客服电话",tags = { "app用户端-联系客服" })
     public R<String> getServletPhone() {
         return R.ok(phoneService.getServletPhone());
     }
@@ -39,4 +41,20 @@
         phoneService.saveServicePhone(phone);
         return R.ok();
     }
+
+    /**
+     * 联系客服
+     */
+    @GetMapping("/getSysPhone")
+    @PreAuthorize("@ss.hasPermi('system:feedback:list')")
+    @ApiOperation(value = "获取客服电话",tags = { "管理后台-系统管理" })
+    public R<String> getSysPhone() {
+        Phone one = phoneService.getOne(new LambdaQueryWrapper<Phone>().eq(Phone::getType, 1));
+        if (one != null) {
+            return R.ok(one.getPhone());
+        }else {
+            return R.ok();
+        }
+    }
+
 }    
\ No newline at end of file

--
Gitblit v1.7.1