From e56df010b5217926ff0a3b6f8e33beb9231b4fd6 Mon Sep 17 00:00:00 2001
From: Helius <wangdoubleone@gmail.com>
Date: Mon, 11 Jul 2022 19:24:01 +0800
Subject: [PATCH] fix
---
src/main/java/com/xcong/farmer/cms/modules/system/vo/AdminSeeWebSetInfoVo.java | 7 +++++++
src/main/resources/mapper/WebSetMapper.xml | 7 ++++++-
src/main/java/com/xcong/farmer/cms/modules/system/entity/WebSettingEntity.java | 7 +++++++
3 files changed, 20 insertions(+), 1 deletions(-)
diff --git a/src/main/java/com/xcong/farmer/cms/modules/system/entity/WebSettingEntity.java b/src/main/java/com/xcong/farmer/cms/modules/system/entity/WebSettingEntity.java
index c3f6407..631923e 100644
--- a/src/main/java/com/xcong/farmer/cms/modules/system/entity/WebSettingEntity.java
+++ b/src/main/java/com/xcong/farmer/cms/modules/system/entity/WebSettingEntity.java
@@ -1,6 +1,7 @@
package com.xcong.farmer.cms.modules.system.entity;
import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@@ -57,4 +58,10 @@
private String msgTemplate;
private Long companyId;
+
+ @TableField(exist = false)
+ private String companyCode;
+
+ @TableField(exist = false)
+ private String companyUrl;
}
diff --git a/src/main/java/com/xcong/farmer/cms/modules/system/vo/AdminSeeWebSetInfoVo.java b/src/main/java/com/xcong/farmer/cms/modules/system/vo/AdminSeeWebSetInfoVo.java
index 614a369..ce9ccfb 100644
--- a/src/main/java/com/xcong/farmer/cms/modules/system/vo/AdminSeeWebSetInfoVo.java
+++ b/src/main/java/com/xcong/farmer/cms/modules/system/vo/AdminSeeWebSetInfoVo.java
@@ -1,5 +1,6 @@
package com.xcong.farmer.cms.modules.system.vo;
+import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
@@ -34,4 +35,10 @@
@ApiModelProperty(value = "在线留言模板")
private String msgTemplate;
+
+ @ApiModelProperty(value = "公司编码")
+ private String companyCode;
+
+ @ApiModelProperty(value = "公司URL")
+ private String companyUrl;
}
diff --git a/src/main/resources/mapper/WebSetMapper.xml b/src/main/resources/mapper/WebSetMapper.xml
index 32bfe7e..d70179d 100644
--- a/src/main/resources/mapper/WebSetMapper.xml
+++ b/src/main/resources/mapper/WebSetMapper.xml
@@ -3,7 +3,12 @@
<mapper namespace="com.xcong.farmer.cms.modules.system.mapper.WebSetMapper">
<select id="selectByCompanyId" resultType="com.xcong.farmer.cms.modules.system.entity.WebSettingEntity">
- select * from t_web_setting where company_id=#{companyId}
+ select
+ a.*,
+ b.web_address companyUrl,
+ b.code companyCode
+ from t_web_setting a, t_company b
+ where a.company_id=#{companyId} and a.company_id=b.id
</select>
</mapper>
\ No newline at end of file
--
Gitblit v1.9.1