Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
R
ruoyi
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
范晓龙
ruoyi
Commits
ef5bed33
提交
ef5bed33
authored
6月 17, 2024
作者:
Administrator
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
增加发送短信功能
上级
ec4c0189
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
31 个修改的文件
包含
2081 行增加
和
308 行删除
+2081
-308
TbInformationPlatformController.java
.../controller/business/TbInformationPlatformController.java
+140
-0
CommonController.java
...ava/com/ruoyi/web/controller/common/CommonController.java
+36
-7
TbInformationPlatformCheckController.java
...er/contentCheck/TbInformationPlatformCheckController.java
+77
-0
TbMaterialDemoController.java
...ruoyi/web/controller/school/TbMaterialDemoController.java
+0
-5
SysIndexController.java
...a/com/ruoyi/web/controller/system/SysIndexController.java
+27
-4
HumanCustomerServiceWebSocket.java
...om/ruoyi/web/websocket/HumanCustomerServiceWebSocket.java
+0
-0
WebSocketConfig.java
...rc/main/java/com/ruoyi/web/websocket/WebSocketConfig.java
+31
-31
chatRecord.rar
...dmin/src/main/resources/templates/business/chatRecord.rar
+0
-0
add.html
...n/src/main/resources/templates/business/platform/add.html
+153
-0
edit.html
.../src/main/resources/templates/business/platform/edit.html
+169
-0
editCheckStatus.html
...esources/templates/business/platform/editCheckStatus.html
+180
-0
platform.html
.../main/resources/templates/business/platform/platform.html
+143
-0
platformCheck.html
.../resources/templates/business/platform/platformCheck.html
+141
-0
uploadPlatformCover.html
...rces/templates/business/platform/uploadPlatformCover.html
+124
-0
index.html
ruoyi-admin/src/main/resources/templates/index.html
+54
-53
login.html
ruoyi-admin/src/main/resources/templates/login.html
+1
-1
add.html
...-admin/src/main/resources/templates/system/major/add.html
+2
-2
RuoYiConfig.java
...on/src/main/java/com/ruoyi/common/config/RuoYiConfig.java
+4
-0
Constants.java
...on/src/main/java/com/ruoyi/common/constant/Constants.java
+9
-0
DictUtils.java
...ommon/src/main/java/com/ruoyi/common/utils/DictUtils.java
+2
-0
ShiroConfig.java
...src/main/java/com/ruoyi/framework/config/ShiroConfig.java
+1
-0
TbInformationPlatform.java
...n/java/com/ruoyi/system/domain/TbInformationPlatform.java
+247
-0
TbRegion.java
...ystem/src/main/java/com/ruoyi/system/domain/TbRegion.java
+44
-189
TbInformationPlatformMapper.java
.../com/ruoyi/system/mapper/TbInformationPlatformMapper.java
+67
-0
ITbInformationPlatformService.java
...m/ruoyi/system/service/ITbInformationPlatformService.java
+67
-0
ITbMaterialDemoService.java
...java/com/ruoyi/system/service/ITbMaterialDemoService.java
+1
-1
CommonServiceImpl.java
...java/com/ruoyi/system/service/impl/CommonServiceImpl.java
+5
-1
StudentFileServiceImpl.java
...com/ruoyi/system/service/impl/StudentFileServiceImpl.java
+0
-1
TbInformationPlatformServiceImpl.java
...system/service/impl/TbInformationPlatformServiceImpl.java
+196
-0
TbNewsServiceImpl.java
...java/com/ruoyi/system/service/impl/TbNewsServiceImpl.java
+22
-13
TbInformationPlatformMapper.xml
...n/resources/mapper/system/TbInformationPlatformMapper.xml
+138
-0
没有找到文件。
ruoyi-admin/src/main/java/com/ruoyi/web/controller/business/TbInformationPlatformController.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
controller
.
business
;
import
java.util.List
;
import
com.ruoyi.system.domain.TbNews
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.ui.ModelMap
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
com.ruoyi.common.annotation.Log
;
import
com.ruoyi.common.enums.BusinessType
;
import
com.ruoyi.system.domain.TbInformationPlatform
;
import
com.ruoyi.system.service.ITbInformationPlatformService
;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
com.ruoyi.common.utils.poi.ExcelUtil
;
import
com.ruoyi.common.core.page.TableDataInfo
;
/**
* 海外国家人文,交通,饮食信息Controller
*
* @author ruoyi
* @date 2024-02-29
*/
@Controller
@RequestMapping
(
"/system/platform"
)
public
class
TbInformationPlatformController
extends
BaseController
{
private
String
prefix
=
"business/platform"
;
@Autowired
private
ITbInformationPlatformService
tbInformationPlatformService
;
@RequiresPermissions
(
"system:platform:view"
)
@GetMapping
()
public
String
platform
()
{
return
prefix
+
"/platform"
;
}
/**
* 查询海外国家人文,交通,饮食信息列表
*/
@RequiresPermissions
(
"system:platform:list"
)
@PostMapping
(
"/list"
)
@ResponseBody
public
TableDataInfo
list
(
TbInformationPlatform
tbInformationPlatform
)
{
startPage
();
List
<
TbInformationPlatform
>
list
=
tbInformationPlatformService
.
selectTbInformationPlatformList
(
tbInformationPlatform
);
return
getDataTable
(
list
);
}
/**
* 导出海外国家人文,交通,饮食信息列表
*/
@RequiresPermissions
(
"system:platform:export"
)
@Log
(
title
=
"海外国家人文,交通,饮食信息"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
@ResponseBody
public
AjaxResult
export
(
TbInformationPlatform
tbInformationPlatform
)
{
List
<
TbInformationPlatform
>
list
=
tbInformationPlatformService
.
selectTbInformationPlatformList
(
tbInformationPlatform
);
ExcelUtil
<
TbInformationPlatform
>
util
=
new
ExcelUtil
<
TbInformationPlatform
>(
TbInformationPlatform
.
class
);
return
util
.
exportExcel
(
list
,
"海外国家人文,交通,饮食信息数据"
);
}
/**
* 新增海外国家人文,交通,饮食信息
*/
@GetMapping
(
"/add"
)
public
String
add
(
ModelMap
mmap
)
{
TbInformationPlatform
platform
=
new
TbInformationPlatform
();
mmap
.
put
(
"platform"
,
platform
);
return
prefix
+
"/add"
;
}
@GetMapping
(
"/uploadCover"
)
public
String
uploadImages
(
ModelMap
mmap
)
{
TbInformationPlatform
platform
=
new
TbInformationPlatform
();
mmap
.
put
(
"platform"
,
platform
);
return
prefix
+
"/uploadPlatformCover"
;
}
/**
* 新增保存海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:add"
)
@Log
(
title
=
"海外国家人文,交通,饮食信息"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/add"
)
@ResponseBody
public
AjaxResult
addSave
(
TbInformationPlatform
tbInformationPlatform
)
{
tbInformationPlatform
.
setCreator
(
getUserId
());
return
toAjax
(
tbInformationPlatformService
.
insertTbInformationPlatform
(
tbInformationPlatform
));
}
/**
* 修改海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:edit"
)
@GetMapping
(
"/edit/{id}"
)
public
String
edit
(
@PathVariable
(
"id"
)
Long
id
,
ModelMap
mmap
)
{
TbInformationPlatform
tbInformationPlatform
=
tbInformationPlatformService
.
selectTbInformationPlatformById
(
id
);
mmap
.
put
(
"tbInformationPlatform"
,
tbInformationPlatform
);
return
prefix
+
"/edit"
;
}
/**
* 修改保存海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:edit"
)
@Log
(
title
=
"海外国家人文,交通,饮食信息"
,
businessType
=
BusinessType
.
UPDATE
)
@PostMapping
(
"/edit"
)
@ResponseBody
public
AjaxResult
editSave
(
TbInformationPlatform
tbInformationPlatform
)
{
return
toAjax
(
tbInformationPlatformService
.
updateTbInformationPlatform
(
tbInformationPlatform
));
}
/**
* 删除海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:remove"
)
@Log
(
title
=
"海外国家人文,交通,饮食信息"
,
businessType
=
BusinessType
.
DELETE
)
@PostMapping
(
"/remove"
)
@ResponseBody
public
AjaxResult
remove
(
String
ids
)
{
return
toAjax
(
tbInformationPlatformService
.
deleteTbInformationPlatformByIds
(
ids
));
}
}
ruoyi-admin/src/main/java/com/ruoyi/web/controller/common/CommonController.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
controller
.
common
;
import
java.awt.image.BufferedImage
;
import
java.io.File
;
import
java.io.FileInputStream
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javax.annotation.Resource
;
import
javax.imageio.ImageIO
;
import
javax.imageio.ImageReader
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.common.utils.DictUtils
;
import
com.ruoyi.system.domain.TbMaterialDemo
;
import
com.ruoyi.system.domain.TbRegion
;
import
com.ruoyi.system.mapper.TbMaterialDemoMapper
;
import
com.ruoyi.system.service.impl.CommonServiceImpl
;
import
net.coobird.thumbnailator.Thumbnails
;
import
org.slf4j.Logger
;
...
...
@@ -89,7 +83,7 @@ public class CommonController
*/
@PostMapping
(
"/upload"
)
@ResponseBody
public
AjaxResult
uploadFile
(
MultipartFile
file
)
throws
Exception
public
AjaxResult
uploadFile
(
MultipartFile
file
)
{
try
{
...
...
@@ -445,6 +439,41 @@ public class CommonController
}
}
/**
* 上传信息平台封面
*/
@PostMapping
(
"/uploadPlatformCover"
)
@ResponseBody
public
AjaxResult
uploadPlatformCover
(
MultipartFile
file
)
throws
Exception
{
try
{
// 上传文件路径
String
filePath
=
RuoYiConfig
.
getInfoPlatformPath
();
// 上传并返回新文件名称
String
fileName
=
FileUploadUtils
.
upload
(
filePath
,
file
);
String
fileFullPath
=
filePath
+
fileName
.
substring
(
fileName
.
indexOf
(
"/info/"
)+
5
);
//封面2大小 456 * 324
String
newsCover2
=
fileFullPath
.
substring
(
0
,
fileFullPath
.
lastIndexOf
(
"/"
))+
"/PlatformCover1_"
+
FileUtils
.
getName
(
fileName
);
Thumbnails
.
of
(
fileFullPath
).
size
(
456
,
324
).
keepAspectRatio
(
false
).
toFile
(
newsCover2
);
String
relativePath2
=
newsCover2
.
replace
(
filePath
,
Constants
.
RESOURCE_PREFIX3
);
StringBuffer
fileNames
=
new
StringBuffer
();
String
url
=
serverConfig
.
getUrl
()
+
fileName
;
AjaxResult
ajax
=
AjaxResult
.
success
();
ajax
.
put
(
"url"
,
url
);
ajax
.
put
(
"fileName"
,
relativePath2
);
ajax
.
put
(
"newFileName"
,
FileUtils
.
getName
(
fileName
));
ajax
.
put
(
"originalFilename"
,
file
.
getOriginalFilename
());
return
ajax
;
}
catch
(
Exception
e
)
{
return
AjaxResult
.
error
(
e
.
getMessage
());
}
}
@RequestMapping
(
"/del"
)
@ResponseBody
public
AjaxResult
del
(){
...
...
ruoyi-admin/src/main/java/com/ruoyi/web/controller/contentCheck/TbInformationPlatformCheckController.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
controller
.
contentCheck
;
import
com.ruoyi.common.annotation.Log
;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
com.ruoyi.common.core.page.TableDataInfo
;
import
com.ruoyi.common.enums.BusinessType
;
import
com.ruoyi.system.domain.TbInformationPlatform
;
import
com.ruoyi.system.service.ITbInformationPlatformService
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.ui.ModelMap
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
/**
* 海外国家人文,交通,饮食信息Controller
*
* @author ruoyi
* @date 2024-02-29
*/
@Controller
@RequestMapping
(
"/system/platformCheck"
)
public
class
TbInformationPlatformCheckController
extends
BaseController
{
private
String
prefix
=
"business/platform"
;
@Autowired
private
ITbInformationPlatformService
tbInformationPlatformService
;
@RequiresPermissions
(
"system:platform:view"
)
@GetMapping
()
public
String
platform
()
{
return
prefix
+
"/platformCheck"
;
}
/**
* 查询海外国家人文,交通,饮食信息列表
*/
@RequiresPermissions
(
"system:platform:list"
)
@PostMapping
(
"/list"
)
@ResponseBody
public
TableDataInfo
list
(
TbInformationPlatform
tbInformationPlatform
)
{
startPage
();
List
<
TbInformationPlatform
>
list
=
tbInformationPlatformService
.
selectTbInformationPlatformNotPassList
(
tbInformationPlatform
);
return
getDataTable
(
list
);
}
/**
* 修改海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:edit"
)
@GetMapping
(
"/edit/{id}"
)
public
String
edit
(
@PathVariable
(
"id"
)
Long
id
,
ModelMap
mmap
)
{
TbInformationPlatform
tbInformationPlatform
=
tbInformationPlatformService
.
selectTbInformationPlatformById
(
id
);
mmap
.
put
(
"tbInformationPlatform"
,
tbInformationPlatform
);
return
prefix
+
"/editCheckStatus"
;
}
/**
* 修改保存海外国家人文,交通,饮食信息
*/
@RequiresPermissions
(
"system:platform:edit"
)
@Log
(
title
=
"海外国家人文,交通,饮食信息"
,
businessType
=
BusinessType
.
UPDATE
)
@PostMapping
(
"/edit"
)
@ResponseBody
public
AjaxResult
editSave
(
TbInformationPlatform
tbInformationPlatform
)
{
tbInformationPlatform
.
setChecker
(
getUserId
());
return
toAjax
(
tbInformationPlatformService
.
updateCheckStatus
(
tbInformationPlatform
));
}
}
ruoyi-admin/src/main/java/com/ruoyi/web/controller/school/TbMaterialDemoController.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
controller
.
school
;
import
java.io.IOException
;
import
java.util.List
;
import
com.ruoyi.common.config.RuoYiConfig
;
import
com.ruoyi.common.utils.file.FileUploadUtils
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
...
...
@@ -18,7 +14,6 @@ import com.ruoyi.common.core.controller.BaseController;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
com.ruoyi.common.utils.poi.ExcelUtil
;
import
com.ruoyi.common.core.page.TableDataInfo
;
import
org.springframework.web.multipart.MultipartFile
;
/**
* 材料样例Controller
...
...
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysIndexController.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
controller
.
system
;
import
java.io.IOException
;
import
java.util.Arrays
;
import
java.util.Date
;
import
java.util.List
;
import
javax.servlet.http.Cookie
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
com.ruoyi.common.constant.Constants
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.ui.ModelMap
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.*
;
import
com.ruoyi.common.config.RuoYiConfig
;
import
com.ruoyi.common.constant.ShiroConstants
;
import
com.ruoyi.common.core.controller.BaseController
;
...
...
@@ -31,6 +34,7 @@ import com.ruoyi.system.service.ISysMenuService;
*
* @author ruoyi
*/
@Slf4j
@Controller
public
class
SysIndexController
extends
BaseController
{
...
...
@@ -175,4 +179,23 @@ public class SysIndexController extends BaseController
}
return
false
;
}
@RequestMapping
(
"/"
)
public
void
test
(
HttpServletRequest
request
,
HttpServletResponse
response
){
String
serverName
=
request
.
getServerName
();
if
(
Arrays
.
asList
(
Constants
.
domainNames
).
contains
(
serverName
)){
try
{
response
.
sendRedirect
(
"https://"
+
serverName
);
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
}
else
{
try
{
response
.
sendRedirect
(
"http://39.105.118.63:8080/login"
);
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
}
}
}
ruoyi-admin/src/main/java/com/ruoyi/web/websocket/HumanCustomerServiceWebSocket.java
浏览文件 @
ef5bed33
差异被折叠。
点击展开。
ruoyi-admin/src/main/java/com/ruoyi/web/websocket/WebSocketConfig.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
web
.
websocket
;
import
com.ruoyi.system.service.ITbCustomerserviceRecordService
;
import
com.ruoyi.system.service.ITbUserService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.web.socket.server.standard.ServerEndpointExporter
;
/**
* @Author:fanxiaolong
* @Date: 2023-05-11 13:59
* @Description:
*/
@Configuration
public
class
WebSocketConfig
{
@Bean
public
ServerEndpointExporter
serverEndpointExporter
(){
return
new
ServerEndpointExporter
();
}
@Autowired
private
void
setCustomerserviceRecordService
(
ITbCustomerserviceRecordService
customerserviceRecordService
){
HumanCustomerServiceWebSocket
.
customerserviceRecordService
=
customerserviceRecordService
;
}
@Autowired
private
void
setUserService
(
ITbUserService
userService
){
HumanCustomerServiceWebSocket
.
userService
=
userService
;
}
}
//
package com.ruoyi.web.websocket;
//
//
import com.ruoyi.system.service.ITbCustomerserviceRecordService;
//
import com.ruoyi.system.service.ITbUserService;
//
import org.springframework.beans.factory.annotation.Autowired;
//
import org.springframework.context.annotation.Bean;
//
import org.springframework.context.annotation.Configuration;
//
import org.springframework.web.socket.server.standard.ServerEndpointExporter;
//
/
//
**
//
* @Author:fanxiaolong
//
* @Date: 2023-05-11 13:59
//
* @Description:
//
*/
//
@Configuration
//
public class WebSocketConfig {
//
@Bean
//
public ServerEndpointExporter serverEndpointExporter(){
//
return new ServerEndpointExporter();
//
}
//
//
@Autowired
//
private void setCustomerserviceRecordService(ITbCustomerserviceRecordService customerserviceRecordService){
//
HumanCustomerServiceWebSocket.customerserviceRecordService=customerserviceRecordService;
//
}
//
//
@Autowired
//
private void setUserService(ITbUserService userService){
//
HumanCustomerServiceWebSocket.userService=userService;
//
}
//
}
ruoyi-admin/src/main/resources/templates/business/chatRecord.rar
deleted
100644 → 0
浏览文件 @
ec4c0189
File deleted
ruoyi-admin/src/main/resources/templates/business/platform/add.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('新增海外国家人文,交通,饮食信息')"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-css"
/>
<script
type=
"text/javascript"
src=
"/js/jscolor.js"
></script>
<style>
/*百度编辑器代码块不能自动换行的问题:*/
.syntaxhighlighter
div
.container
code
{
word-break
:
break-all
!important
;
white-space
:
normal
;
}
</style>
</head>
<body
class=
"white-bg"
>
<div
class=
"wrapper wrapper-content animated fadeInRight ibox-content"
>
<form
class=
"form-horizontal m"
id=
"form-platform-add"
>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">国家代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="countryCode" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
国家名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"country"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">城市代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="cityCode" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
城市名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"city"
class=
"form-control"
type=
"text"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容类型:
</label>
<div
class=
"col-sm-8"
>
<select
id=
"contentType"
class=
"form-control select2-multiple"
>
<option>
请选择内容类型
</option>
</select>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
标题:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"title"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
摘要:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"summary"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容:
</label>
<div
class=
"col-sm-10"
>
<script
id=
"editor"
name=
"content"
type=
"text/plain"
style=
"height: 300px;width:1000px;"
></script>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
图片封面:
</label>
<input
name=
"cover"
id=
"cover"
type=
"hidden"
>
<div
class=
"col-sm-8"
>
<img
id=
"platformCover"
th:src=
"(${#strings.isEmpty(platform.cover)}) ? @{/img/profile.jpg} : @{${platform.cover}}"
th:onerror=
"'this.src=\'' + @{'/img/profile.jpg'} + '\''"
width=
"320px"
height=
"200px"
>
<p><a
href=
"javascript:uploadCover()"
>
上传图像
</a></p>
</div>
</div>
</form>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: ueditor-js"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<th:block
th:include=
"include :: cropper-js"
/>
<script
th:inline=
"javascript"
>
var
prefix
=
ctx
+
"system/platform"
$
(
"#form-platform-add"
).
validate
({
focusCleanup
:
true
});
function
submitHandler
()
{
if
(
$
.
validate
.
form
())
{
$
.
operate
.
save
(
prefix
+
"/add"
,
$
(
'#form-platform-add'
).
serialize
()
+
"&contentType="
+
$
(
"#contentType"
)[
0
].
value
);
}
}
var
ue
=
UE
.
getEditor
(
'editor'
);
function
getContentTxt
()
{
return
UE
.
getEditor
(
'editor'
).
getContentTxt
();
}
//****************上传封面 begin****************
function
setCover
(
a
){
$
(
"#platformCover"
).
attr
(
'src'
,
a
);
$
(
"#cover"
).
val
(
a
);
}
function
uploadCover
()
{
var
url
=
prefix
+
'/uploadCover'
;
top
.
layer
.
open
({
type
:
2
,
area
:
[
$
(
window
).
width
()
+
'px'
,
$
(
window
).
height
()
+
'px'
],
fix
:
false
,
//不固定
maxmin
:
true
,
shade
:
0.3
,
title
:
"上传封面"
,
content
:
url
,
btn
:
[
'确定'
,
'关闭'
],
// 弹层外区域关闭
shadeClose
:
true
,
yes
:
function
(
index
,
layero
)
{
var
iframeWin
=
layero
.
find
(
'iframe'
)[
0
];
iframeWin
.
contentWindow
.
submitHandler
(
index
,
layero
,
setCover
);
},
cancel
:
function
(
index
)
{
return
true
;
}
});
}
//****************上传封面 end****************
$
(
function
()
{
<!--
异步请求
-->
$
.
ajax
({
<!--
请求路径,与后端对应
-->
url
:
ctx
+
"common/getDict/business_content_type"
,
<!--
请求类型
-->
type
:
"get"
,
<!--
期待的返回数据类型
-->
dataType
:
"json"
,
<!--
前端接收数据成功时执行该函数
-->
success
:
function
(
data
)
{
<!--
清空下拉框中的缓存
-->
// $("#city").empty();
<!--
使用循环解析后端传来的数据,并用使用
js
动态拼接
html
语言
-->
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
$
(
"#contentType"
).
append
(
"<option value='"
+
data
[
i
].
dictValue
+
"'>"
+
data
[
i
].
dictLabel
+
"</option>"
);
}
});
});
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/business/platform/edit.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('修改海外国家人文,交通,饮食信息')"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-css"
/>
<script
type=
"text/javascript"
src=
"/js/jscolor.js"
></script>
<style>
/*百度编辑器代码块不能自动换行的问题:*/
.syntaxhighlighter
div
.container
code
{
word-break
:
break-all
!important
;
white-space
:
normal
;
}
</style>
</head>
<body
class=
"white-bg"
>
<div
class=
"wrapper wrapper-content animated fadeInRight ibox-content"
>
<form
class=
"form-horizontal m"
id=
"form-platform-edit"
th:object=
"${tbInformationPlatform}"
>
<input
name=
"id"
th:field=
"*{id}"
type=
"hidden"
>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">国家代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="countryCode" th:field="*{countryCode}" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
国家名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"country"
th:field=
"*{country}"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">城市代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="cityCode" th:field="*{cityCode}" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
城市名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"city"
th:field=
"*{city}"
class=
"form-control"
type=
"text"
>
</div>
</div>
<input
id=
"contentTypeDesc"
th:field=
"*{contentTypeDesc}"
type=
"hidden"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容类型:
</label>
<div
class=
"col-sm-8"
>
<select
id=
"contentType"
class=
"form-control select2-multiple"
>
<option>
请选择内容类型
</option>
</select>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
标题:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"title"
th:field=
"*{title}"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
摘要:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"summary"
th:field=
"*{summary}"
class=
"form-control"
type=
"text"
required
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容:
</label>
<div
class=
"col-sm-10"
>
<script
id=
"editor"
name=
"content"
type=
"text/plain"
style=
"height: 300px;width:1000px;"
></script>
<textarea
id=
"content"
style=
"display: none;"
>
[[*{content}]]
</textarea>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
图片封面:
</label>
<input
name=
"cover"
id=
"cover"
type=
"hidden"
>
<div
class=
"col-sm-8"
>
<img
id=
"platformCover"
th:src=
"*{cover}"
width=
"320px"
height=
"200px"
>
<p><a
href=
"javascript:uploadCover()"
>
上传图像
</a></p>
</div>
</div>
</form>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: ueditor-js"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<th:block
th:include=
"include :: ueditor-js"
/>
<script
th:inline=
"javascript"
>
var
prefix
=
ctx
+
"system/platform"
;
$
(
"#form-platform-edit"
).
validate
({
focusCleanup
:
true
});
function
submitHandler
()
{
if
(
$
.
validate
.
form
())
{
$
.
operate
.
save
(
prefix
+
"/edit"
,
$
(
'#form-platform-edit'
).
serialize
()
+
"&contentType="
+
$
(
"#contentType"
)[
0
].
value
);
}
}
//****************上传封面 begin****************
function
setCover
(
a
){
$
(
"#platformCover"
).
attr
(
'src'
,
a
);
$
(
"#cover"
).
val
(
a
);
}
function
uploadCover
()
{
var
url
=
prefix
+
'/uploadCover'
;
top
.
layer
.
open
({
type
:
2
,
area
:
[
$
(
window
).
width
()
+
'px'
,
$
(
window
).
height
()
+
'px'
],
fix
:
false
,
//不固定
maxmin
:
true
,
shade
:
0.3
,
title
:
"上传封面"
,
content
:
url
,
btn
:
[
'确定'
,
'关闭'
],
// 弹层外区域关闭
shadeClose
:
true
,
yes
:
function
(
index
,
layero
)
{
var
iframeWin
=
layero
.
find
(
'iframe'
)[
0
];
iframeWin
.
contentWindow
.
submitHandler
(
index
,
layero
,
setCover
);
},
cancel
:
function
(
index
)
{
return
true
;
}
});
}
//****************上传封面 end****************
$
(
function
()
{
var
text
=
$
(
"#content"
).
text
();
var
ue
=
UE
.
getEditor
(
'editor'
);
ue
.
ready
(
function
()
{
ue
.
setContent
(
text
);
});
<!--
异步请求
-->
$
.
ajax
({
<!--
请求路径,与后端对应
-->
url
:
ctx
+
"common/getDict/business_content_type"
,
<!--
请求类型
-->
type
:
"get"
,
<!--
期待的返回数据类型
-->
dataType
:
"json"
,
<!--
前端接收数据成功时执行该函数
-->
success
:
function
(
data
)
{
<!--
清空下拉框中的缓存
-->
// $("#city").empty();
<!--
使用循环解析后端传来的数据,并用使用
js
动态拼接
html
语言
-->
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
$
(
"#contentType"
).
append
(
"<option value='"
+
data
[
i
].
dictValue
+
"'>"
+
data
[
i
].
dictLabel
+
"</option>"
);
var
vtext
=
$
(
"#contentTypeDesc"
).
val
();
$
(
"#contentType"
).
find
(
"option"
).
each
(
function
(){
if
(
$
(
this
).
text
()
==
vtext
)
{
$
(
this
).
attr
(
"selected"
,
true
);
}
}
);
}
});
// function getContentTxt() {
// return UE.getEditor('editor').getContentTxt();
// }
});
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/business/platform/editCheckStatus.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('修改海外国家人文,交通,饮食信息')"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-css"
/>
<script
type=
"text/javascript"
src=
"/js/jscolor.js"
></script>
<style>
/*百度编辑器代码块不能自动换行的问题:*/
.syntaxhighlighter
div
.container
code
{
word-break
:
break-all
!important
;
white-space
:
normal
;
}
</style>
</head>
<body
class=
"white-bg"
>
<div
class=
"wrapper wrapper-content animated fadeInRight ibox-content"
>
<form
class=
"form-horizontal m"
id=
"form-platform-edit"
th:object=
"${tbInformationPlatform}"
>
<input
name=
"id"
th:field=
"*{id}"
type=
"hidden"
>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">国家代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="countryCode" th:field="*{countryCode}" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
国家名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"country"
th:field=
"*{country}"
class=
"form-control"
type=
"text"
disabled=
"true"
>
</div>
</div>
<!-- <div class="form-group"> -->
<!-- <label class="col-sm-2 control-label">城市代码:</label>-->
<!-- <div class="col-sm-8">-->
<!-- <input name="cityCode" th:field="*{cityCode}" class="form-control" type="text">-->
<!-- </div>-->
<!-- </div>-->
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
城市名称:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"city"
th:field=
"*{city}"
class=
"form-control"
type=
"text"
disabled=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容类型:
</label>
<div
class=
"col-sm-8"
>
<input
th:field=
"*{contentTypeDesc}"
type=
"text"
class=
"form-control"
disabled=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
标题:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"title"
th:field=
"*{title}"
class=
"form-control"
type=
"text"
disabled=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
摘要:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"summary"
th:field=
"*{summary}"
class=
"form-control"
type=
"text"
disabled=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
内容:
</label>
<div
class=
"col-sm-10"
>
<textarea
rows=
"8"
cols=
"40"
id=
"content"
th:field=
"*{content}"
class=
"form-control"
disabled=
"true"
>
</textarea>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
图片封面:
</label>
<input
type=
"hidden"
th:field=
"*{cover}"
>
<div
class=
"col-sm-8"
>
<div
class=
"file-loading"
>
<input
id=
"platformCover"
name=
"file"
type=
"file"
>
</div>
</div>
</div>
<input
id=
"checkStatusDesc"
name=
"checkStatusDesc"
th:field=
"*{checkStatusDesc}"
type=
"hidden"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
审核状态:
</label>
<div
class=
"col-sm-8"
>
<select
id=
"checkStatus"
class=
"form-control select2-multiple"
>
<option>
请选择审核状态
</option>
</select>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label is-required"
>
审核结果:
</label>
<div
class=
"col-sm-8"
>
<input
name=
"checkResult"
id=
"checkResult"
th:field=
"*{checkResult}"
class=
"form-control"
type=
"text"
>
</div>
</div>
</form>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: ueditor-js"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<th:block
th:include=
"include :: ueditor-js"
/>
<script
th:inline=
"javascript"
>
var
prefix
=
ctx
+
"system/platformCheck"
;
$
(
"#form-platform-edit"
).
validate
({
focusCleanup
:
true
});
function
submitHandler
()
{
if
(
$
.
validate
.
form
())
{
$
.
operate
.
save
(
prefix
+
"/edit"
,
$
(
'#form-platform-edit'
).
serialize
()
+
"&checkStatus="
+
$
(
'#checkStatus'
)[
0
].
value
);
}
}
function
initCover
()
{
var
logoUrl
=
$
(
"#cover"
).
val
();
//拿到图片路径
var
preList
=
new
Array
();
var
initialPreviewConfig
=
new
Array
();
//设置初始化区域值
if
(
logoUrl
!=
null
&&
logoUrl
!=
''
){
var
a
=
{
// caption : '主图'+(i+1),
// width: '120px',
url
:
'/common/del'
,
// key: i,
extra
:
{
url
:
logoUrl
}
}
preList
.
push
(
logoUrl
);
initialPreviewConfig
.
push
(
a
);
}
$
(
"#platformCover"
).
fileinput
({
language
:
'zh'
,
//设置语言
uploadUrl
:
"/common/upload"
,
//上传的地址,改成自己的
allowedFileExtensions
:[
'bmp'
,
'gif'
,
'jpg'
,
'jpeg'
,
'png'
],
//接收的文件后缀
initialPreviewAsData
:
true
,
initialPreview
:
preList
,
//预览图片
uploadAsync
:
true
,
//默认异步上传
showUpload
:
true
,
//是否显示上传按钮
showRemove
:
false
,
//显示移除按钮
showPreview
:
true
,
//是否显示预览
showCaption
:
false
,
//是否显示标题
browseClass
:
"btn btn-primary"
,
//按钮样式
dropZoneEnabled
:
false
,
//是否显示拖拽区域
maxFileCount
:
1
,
//表示允许同时上传的最大文件个数
maxFileSize
:
10
*
1024
*
1024
,
messages
:
{
maxFileSize
:
'文件上传的最大大小为 10MB'
,
acceptFileTypes
:
'此文件是不支持的图片格式'
},
enctype
:
'multipart/form-data'
,
validateInitialCount
:
true
,
msgFilesTooMany
:
5
,
autoReplace
:
false
,
initialPreviewConfig
:
initialPreviewConfig
});
}
$
(
function
()
{
// var text = $("#content").text();
// var ue = UE.getEditor('editor');
// ue.ready(function () {
// ue.setContent(text);
// });
$
.
ajax
({
url
:
ctx
+
"system/dict/data/business_check_status"
,
type
:
"get"
,
dataType
:
"json"
,
success
:
function
(
data
){
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
){
$
(
"#checkStatus"
).
append
(
"<option value='"
+
data
[
i
].
dictValue
+
"'>"
+
data
[
i
].
dictLabel
+
"</option>"
);
}
var
vtext
=
$
(
"#checkStatusDesc"
)[
0
].
value
;
$
(
"#checkStatus"
).
find
(
"option"
).
each
(
function
(){
if
(
$
(
this
).
text
()
==
vtext
)
{
$
(
this
).
attr
(
"selected"
,
true
);
}
});
}
});
initCover
();
});
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/business/platform/platform.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
xmlns:shiro=
"http://www.pollix.at/thymeleaf/shiro"
>
<head>
<th:block
th:include=
"include :: header('海外国家人文,交通,饮食信息列表')"
/>
</head>
<body
class=
"gray-bg"
>
<div
class=
"container-div"
>
<div
class=
"row"
>
<div
class=
"col-sm-12 search-collapse"
>
<form
id=
"formId"
>
<div
class=
"select-list"
>
<ul>
<!-- <li>-->
<!-- <label>国家代码:</label>-->
<!-- <input type="text" name="countryCode"/>-->
<!-- </li>-->
<li>
<label>
国家名称:
</label>
<input
type=
"text"
name=
"country"
/>
</li>
<!-- <li>-->
<!-- <label>城市代码:</label>-->
<!-- <input type="text" name="cityCode"/>-->
<!-- </li>-->
<li>
<label>
城市名称:
</label>
<input
type=
"text"
name=
"city"
/>
</li>
<li>
<label>
标题:
</label>
<input
type=
"text"
name=
"title"
/>
</li>
<!-- <li>-->
<!-- <label>图片封面:</label>-->
<!-- <input type="text" name="cover"/>-->
<!-- </li>-->
<li>
<a
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
class=
"btn btn-warning btn-rounded btn-sm"
onclick=
"$.form.reset()"
><i
class=
"fa fa-refresh"
></i>
重置
</a>
</li>
</ul>
</div>
</form>
</div>
<div
class=
"btn-group-sm"
id=
"toolbar"
role=
"group"
>
<a
class=
"btn btn-success"
onclick=
"$.operate.add()"
shiro:hasPermission=
"system:platform:add"
>
<i
class=
"fa fa-plus"
></i>
添加
</a>
<a
class=
"btn btn-primary single disabled"
onclick=
"$.operate.edit()"
shiro:hasPermission=
"system:platform:edit"
>
<i
class=
"fa fa-edit"
></i>
修改
</a>
<a
class=
"btn btn-danger multiple disabled"
onclick=
"$.operate.removeAll()"
shiro:hasPermission=
"system:platform:remove"
>
<i
class=
"fa fa-remove"
></i>
删除
</a>
<a
class=
"btn btn-warning"
onclick=
"$.table.exportExcel()"
shiro:hasPermission=
"system:platform:export"
>
<i
class=
"fa fa-download"
></i>
导出
</a>
</div>
<div
class=
"col-sm-12 select-table table-striped"
>
<table
id=
"bootstrap-table"
></table>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<script
th:inline=
"javascript"
>
var
editFlag
=
[[
$
{@
permission
.
hasPermi
(
'system:platform:edit'
)}]];
var
removeFlag
=
[[
$
{@
permission
.
hasPermi
(
'system:platform:remove'
)}]];
var
prefix
=
ctx
+
"system/platform"
;
$
(
function
()
{
var
options
=
{
url
:
prefix
+
"/list"
,
createUrl
:
prefix
+
"/add"
,
updateUrl
:
prefix
+
"/edit/{id}"
,
removeUrl
:
prefix
+
"/remove"
,
exportUrl
:
prefix
+
"/export"
,
modalName
:
"海外国家人文,交通,饮食信息"
,
columns
:
[{
checkbox
:
true
},
{
field
:
'id'
,
title
:
'${comment}'
,
visible
:
false
},
// {
// field: 'countryCode',
// title: '国家代码'
// },
{
field
:
'country'
,
title
:
'国家名称'
},
// {
// field: 'cityCode',
// title: '城市代码'
// },
{
field
:
'city'
,
title
:
'城市名称'
},
{
field
:
'contentType'
,
title
:
'内容分类'
},
{
field
:
'title'
,
title
:
'标题'
},
{
field
:
'createBy'
,
title
:
'作者'
},
{
field
:
'createTime'
,
title
:
'创建时间'
},
// {
// field: 'content',
// title: '内容'
// },
// {
// field: 'cover',
// title: '图片封面'
// },
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
var
actions
=
[];
actions
.
push
(
'<a class="btn btn-success btn-xs '
+
editFlag
+
'" href="javascript:void(0)" onclick="$.operate.edit(
\'
'
+
row
.
id
+
'
\'
)"><i class="fa fa-edit"></i>编辑</a> '
);
actions
.
push
(
'<a class="btn btn-danger btn-xs '
+
removeFlag
+
'" href="javascript:void(0)" onclick="$.operate.remove(
\'
'
+
row
.
id
+
'
\'
)"><i class="fa fa-remove"></i>删除</a>'
);
return
actions
.
join
(
''
);
}
}]
};
$
.
table
.
init
(
options
);
});
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/business/platform/platformCheck.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
xmlns:shiro=
"http://www.pollix.at/thymeleaf/shiro"
>
<head>
<th:block
th:include=
"include :: header('海外国家人文,交通,饮食信息列表')"
/>
</head>
<body
class=
"gray-bg"
>
<div
class=
"container-div"
>
<div
class=
"row"
>
<div
class=
"col-sm-12 search-collapse"
>
<form
id=
"formId"
>
<div
class=
"select-list"
>
<ul>
<!-- <li>-->
<!-- <label>国家代码:</label>-->
<!-- <input type="text" name="countryCode"/>-->
<!-- </li>-->
<li>
<label>
国家名称:
</label>
<input
type=
"text"
name=
"country"
/>
</li>
<!-- <li>-->
<!-- <label>城市代码:</label>-->
<!-- <input type="text" name="cityCode"/>-->
<!-- </li>-->
<li>
<label>
城市名称:
</label>
<input
type=
"text"
name=
"city"
/>
</li>
<li>
<label>
标题:
</label>
<input
type=
"text"
name=
"title"
/>
</li>
<!-- <li>-->
<!-- <label>图片封面:</label>-->
<!-- <input type="text" name="cover"/>-->
<!-- </li>-->
<li>
<a
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
class=
"btn btn-warning btn-rounded btn-sm"
onclick=
"$.form.reset()"
><i
class=
"fa fa-refresh"
></i>
重置
</a>
</li>
</ul>
</div>
</form>
</div>
<div
class=
"btn-group-sm"
id=
"toolbar"
role=
"group"
>
<a
class=
"btn btn-primary single disabled"
onclick=
"$.operate.edit()"
shiro:hasPermission=
"system:platform:edit"
>
<i
class=
"fa fa-edit"
></i>
审核
</a>
</div>
<div
class=
"col-sm-12 select-table table-striped"
>
<table
id=
"bootstrap-table"
></table>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<script
th:inline=
"javascript"
>
var
editFlag
=
[[
$
{@
permission
.
hasPermi
(
'system:platform:edit'
)}]];
var
prefix
=
ctx
+
"system/platformCheck"
;
$
(
function
()
{
var
options
=
{
url
:
prefix
+
"/list"
,
updateUrl
:
prefix
+
"/edit/{id}"
,
modalName
:
"海外国家人文,交通,饮食信息"
,
columns
:
[{
checkbox
:
true
},
{
field
:
'id'
,
title
:
'${comment}'
,
visible
:
false
},
// {
// field: 'countryCode',
// title: '国家代码'
// },
{
field
:
'country'
,
title
:
'国家名称'
},
// {
// field: 'cityCode',
// title: '城市代码'
// },
{
field
:
'city'
,
title
:
'城市名称'
},
{
field
:
'contentType'
,
title
:
'内容分类'
},
{
field
:
'title'
,
title
:
'标题'
},
{
field
:
'summary'
,
title
:
'摘要'
},
{
field
:
'createBy'
,
title
:
'作者'
},
{
field
:
'createTime'
,
title
:
'创建时间'
},
{
field
:
'checker'
,
title
:
'审核人员'
},
{
field
:
'checkTime'
,
title
:
'审核时间'
},
{
field
:
'checkStatusDesc'
,
title
:
'审核状态'
},
{
field
:
'checkResult'
,
title
:
'审核结果'
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
var
actions
=
[];
actions
.
push
(
'<a class="btn btn-success btn-xs '
+
editFlag
+
'" href="javascript:void(0)" onclick="$.operate.edit(
\'
'
+
row
.
id
+
'
\'
)"><i class="fa fa-edit"></i>审核</a> '
);
return
actions
.
join
(
''
);
}
}]
};
$
.
table
.
init
(
options
);
});
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/business/platform/uploadPlatformCover.html
0 → 100644
浏览文件 @
ef5bed33
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<link
rel=
"stylesheet"
href=
"https://unpkg.com/bootstrap@4/dist/css/bootstrap.min.css"
crossorigin=
"anonymous"
>
<th:block
th:include=
"include :: cropper-css"
/>
<style>
.label
{
cursor
:
pointer
;
}
.img-container
img
{
max-width
:
100%
;
}
</style>
</head>
<body>
<div
class=
"container"
>
<label
class=
"label"
data-toggle=
"tooltip"
title=
"上传图像"
>
<img
id=
"avatar"
th:src=
"(${#strings.isEmpty(platform.cover)}) ? @{/img/profile.jpg} : @{${platform.cover}}"
th:onerror=
"'this.src=\'' + @{'/img/profile.jpg'} + '\''"
>
<input
type=
"file"
class=
"sr-only"
id=
"input"
name=
"image"
accept=
"image/*"
>
</label>
<div
class=
"modal fade"
id=
"modal"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"modalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-content"
>
<div
class=
"modal-body"
>
<div
class=
"img-container"
>
<img
id=
"image"
th:src=
"@{/img/profile.jpg}"
>
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-secondary"
data-dismiss=
"modal"
>
取消
</button>
<button
type=
"button"
class=
"btn btn-primary"
id=
"crop"
>
裁剪
</button>
</div>
</div>
</div>
</div>
<input
type=
"hidden"
name=
"platformCover"
id=
"platformCover"
>
</div>
<script
src=
"https://unpkg.com/jquery@3/dist/jquery.min.js"
crossorigin=
"anonymous"
></script>
<script
src=
"https://unpkg.com/bootstrap@4/dist/js/bootstrap.bundle.min.js"
crossorigin=
"anonymous"
></script>
<th:block
th:include=
"include :: cropper-js"
/>
<script
th:inline=
"javascript"
>
window
.
addEventListener
(
'DOMContentLoaded'
,
function
()
{
var
avatar
=
document
.
getElementById
(
'avatar'
);
var
image
=
document
.
getElementById
(
'image'
);
var
input
=
document
.
getElementById
(
'input'
);
var
$modal
=
$
(
'#modal'
);
var
cropper
;
input
.
addEventListener
(
'change'
,
function
(
e
)
{
var
files
=
e
.
target
.
files
;
var
done
=
function
(
url
)
{
input
.
value
=
''
;
image
.
src
=
url
;
$modal
.
modal
(
'show'
);
};
var
reader
;
var
file
;
if
(
files
&&
files
.
length
>
0
)
{
file
=
files
[
0
];
if
(
URL
)
{
done
(
URL
.
createObjectURL
(
file
));
}
else
if
(
FileReader
)
{
reader
=
new
FileReader
();
reader
.
onload
=
function
(
e
)
{
done
(
reader
.
result
);
};
reader
.
readAsDataURL
(
file
);
}
}
});
$modal
.
on
(
'shown.bs.modal'
,
function
()
{
cropper
=
new
Cropper
(
image
,
{
viewMode
:
0
,
zoomable
:
true
,
zoomOnWheel
:
true
,
aspectRatio
:
6
/
5
,
crop
:
function
(
event
)
{
var
width
=
event
.
detail
.
width
;
var
height
=
event
.
detail
.
height
;
cropper
.
setData
({
width
:
width
,
height
:
height
,
});
},
});
}).
on
(
'hidden.bs.modal'
,
function
()
{
cropper
.
destroy
();
cropper
=
null
;
});
document
.
getElementById
(
'crop'
).
addEventListener
(
'click'
,
function
()
{
var
canvas
;
$modal
.
modal
(
'hide'
);
if
(
cropper
)
{
canvas
=
cropper
.
getCroppedCanvas
();
avatar
.
src
=
canvas
.
toDataURL
();
canvas
.
toBlob
(
function
(
blob
)
{
var
formdata
=
new
FormData
();
formdata
.
append
(
"file"
,
blob
,
'platformCover.jpeg'
);
$
.
ajax
({
url
:
"http://39.105.118.63:8080/common/uploadPlatformCover"
,
data
:
formdata
,
type
:
"post"
,
processData
:
false
,
contentType
:
false
,
dataType
:
"json"
,
success
:
function
(
data
)
{
$
(
"#platformCover"
).
val
(
data
.
fileName
);
}
})
},
'image/jpeg'
);
}
});
});
function
submitHandler
(
index
,
layero
,
fun
)
{
fun
(
$
(
"#platformCover"
).
val
());
top
.
layer
.
close
(
top
.
layer
.
index
);
}
</script>
</body>
</html>
\ No newline at end of file
ruoyi-admin/src/main/resources/templates/index.html
浏览文件 @
ef5bed33
...
...
@@ -196,8 +196,8 @@
<ul
class=
"nav navbar-top-links navbar-right welcome-message"
>
<!-- <li><a data-toggle="tooltip" data-trigger="hover" data-placement="bottom" title="开发文档" href="http://doc.ruoyi.vip/ruoyi" target="_blank"><i class="fa fa-question-circle"></i> 文档</a></li>-->
<input
th:value=
"${@permission.getPrincipalProperty('userId')}"
id=
"userid"
type=
"hidden"
>
<input
th:value=
"${@permission.isAnyRoles('check')}"
id=
"ischeck"
type=
"hidden"
>
<li
class=
"kefu-init"
><a
data-toggle=
"tooltip"
data-trigger=
"hover"
shiro:hasPermission=
"business:chatRecord:view"
onclick=
" openKeFuWindow()"
data-placement=
"bottom"
title=
"在线客服"
>
客服
<i
class=
"kf-tip"
></i></a></li
>
<!-- <input th:value="${@permission.isAnyRoles('check')}" id="ischeck" type="hidden">--
>
<!-- <li class="kefu-init"><a data-toggle="tooltip" data-trigger="hover" shiro:hasPermission="business:chatRecord:view" onclick=" openKeFuWindow()" data-placement="bottom" title="在线客服" > 客服<i class="kf-tip"></i></a></li>--
>
<li><a
data-toggle=
"tooltip"
data-trigger=
"hover"
data-placement=
"bottom"
title=
"锁定屏幕"
href=
"#"
id=
"lockScreen"
><i
class=
"fa fa-lock"
></i>
锁屏
</a></li>
<li><a
data-toggle=
"tooltip"
data-trigger=
"hover"
data-placement=
"bottom"
title=
"全屏显示"
href=
"#"
id=
"fullScreen"
><i
class=
"fa fa-arrows-alt"
></i>
全屏
</a></li>
<li
class=
"dropdown user-menu"
>
...
...
@@ -366,45 +366,46 @@ var shakeTitle = {
};
// shakeTitle.show();
// 生成客服窗体
if
(
$
(
'#ischeck'
).
val
()
==
'true'
){
var
url
=
ctx
+
'business/chatRecord/customer'
;
var
kefuwindow
=
$
.
modal
.
openOptions
({
id
:
'kefuwindow10086'
,
title
:
'客服'
,
url
:
url
,
shadeClose
:
false
,
btn
:
0
,
maxmin
:
true
,
min
:
true
,
closeBtn
:
0
},
true
);
//socket监听
if
(
$
(
'#userid'
).
val
())
{
var
kfid
=
$
(
'#userid'
).
val
();
}
if
(
window
.
ws
)
{
console
.
log
(
'关闭窗口'
)
window
.
ws
.
close
();
window
.
ws
=
null
;
}
window
.
ws
=
new
WebSocket
(
`ws://39.105.118.63:8080/kf/1/
${
kfid
}
`
);
window
.
ws
.
onopen
=
function
()
{
console
.
log
(
'链接'
);
}
};
//
if($('#ischeck').val()=='true'){
//
var url = ctx + 'business/chatRecord/customer';
//
var kefuwindow = $.modal.openOptions({
//
id:'kefuwindow10086',
//
title: '客服',
//
url:url,
//
shadeClose: false,
//
btn:0,
//
maxmin:true,
//
min:true,
//
closeBtn: 0
//
},true);
//
//
//socket监听
//
if($('#userid').val()) {
//
var kfid = $('#userid').val();
//
}
//
if(window.ws) {
//
console.log('关闭窗口')
//
window.ws.close();
//
window.ws = null;
//
}
//
window.ws = new WebSocket(`ws://39.105.118.63:8080/kf/1/${ kfid }`);
//
window.ws.onopen = function () {
//
console.log('链接');
//
}
//
};
// 弹出客服窗体
var
openKeFuWindow
=
function
()
{
shakeTitle
.
clear
();
$
(
'.kefu-init .kf-tip'
).
hide
();
$
.
modal
.
setfull
(
kefuwindow
);
}
// var openKeFuWindow = function() {
// shakeTitle.clear();
// $('.kefu-init .kf-tip').hide();
// $.modal.setfull(kefuwindow);
// }
// function showMessageTip() {
// shakeTitle.start();
// $('.kefu-init .kf-tip').show();
// }
function
showMessageTip
()
{
shakeTitle
.
start
();
$
(
'.kefu-init .kf-tip'
).
show
();
}
$
(
function
()
{
var
lockPath
=
storage
.
get
(
'lockPath'
);
if
(
$
.
common
.
equals
(
"history"
,
mode
)
&&
window
.
performance
.
navigation
.
type
==
1
)
{
...
...
@@ -455,20 +456,20 @@ $(function() {
$
(
"[data-toggle='tooltip']"
).
tooltip
();
});
</script>
<
style
>
.kefu-init
{
position
:
relative
;
}
.kefu-init
.kf-tip
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
border-radius
:
3px
;
background
:
#f00
;
position
:
absolute
;
right
:
5px
;
top
:
15px
;
}
<
/style
>
<
!--<style>--
>
<!-- .kefu-init{-->
<!-- position: relative;-->
<!-- }-->
<!-- .kefu-init .kf-tip{-->
<!-- display:inline-block;-->
<!-- width:6px;-->
<!-- height:6px;-->
<!-- border-radius: 3px;-->
<!-- background:#f00;-->
<!-- position: absolute;-->
<!-- right:5px;-->
<!-- top:15px;-->
<!-- }-->
<
!--</style>--
>
</body>
</html>
ruoyi-admin/src/main/resources/templates/login.html
浏览文件 @
ef5bed33
...
...
@@ -30,7 +30,7 @@
<!-- <h1><img alt="[ 直申 ]" src="../static/logo.png"></h1>-->
</div>
<div
class=
"m-b"
></div>
<h4>
欢迎使用
<strong>
直申后台管理系统
</strong></h4>
<h4>
欢迎使用
<strong>
直申后台管理系统
</strong></h4>
<ul
class=
"m-b"
>
<li><i
class=
"fa fa-arrow-circle-o-right m-r-xs"
></i>
SpringBoot
</li>
<li><i
class=
"fa fa-arrow-circle-o-right m-r-xs"
></i>
Mybatis
</li>
...
...
ruoyi-admin/src/main/resources/templates/system/major/add.html
浏览文件 @
ef5bed33
...
...
@@ -29,11 +29,11 @@
<!-- <div class="col-sm-8">-->
<!-- <label>-->
<!-- <input type="checkbox" id="a" value="1"/>-->
<!-- <img src="http://
localhost
:8080/profile/upload/2022/11/09/logo_20221109113052A001.png"/>-->
<!-- <img src="http://
39.105.118.63
:8080/profile/upload/2022/11/09/logo_20221109113052A001.png"/>-->
<!-- </label>-->
<!-- <label>-->
<!-- <input type="checkbox" id="b" value="1"/>-->
<!-- <img src="http://
localhost
:8080/profile/upload/2022/11/10/logo_20221110091430A003.png"/>-->
<!-- <img src="http://
39.105.118.63
:8080/profile/upload/2022/11/10/logo_20221110091430A003.png"/>-->
<!-- </label>-->
<!-- </div>-->
<!-- </div>-->
...
...
ruoyi-common/src/main/java/com/ruoyi/common/config/RuoYiConfig.java
浏览文件 @
ef5bed33
...
...
@@ -140,4 +140,8 @@ public class RuoYiConfig
public
void
setFontpath
(
String
fontpath
)
{
RuoYiConfig
.
fontpath
=
fontpath
;
}
public
static
String
getInfoPlatformPath
(){
return
getProfile
()+
"/info"
;
}
}
ruoyi-common/src/main/java/com/ruoyi/common/constant/Constants.java
浏览文件 @
ef5bed33
...
...
@@ -126,6 +126,7 @@ public class Constants
public
static
final
String
RESOURCE_PREFIX
=
"/profile"
;
public
static
final
String
RESOURCE_PREFIX1
=
"/profile/upload"
;
public
static
final
String
RESOURCE_PREFIX2
=
"/profile/news"
;
public
static
final
String
RESOURCE_PREFIX3
=
"/profile/info"
;
/**
* RMI 远程方法调用
...
...
@@ -163,4 +164,11 @@ public class Constants
public
static
final
String
AGENT_ROLE_EKY
=
"agent"
;
public
static
final
String
BOSS_NAME
=
"boss"
;
public
static
final
String
SERVERIP
=
"http://39.105.118.63:8080"
;
public
static
final
String
DOMAINNAME
=
"https://zhishen.net/img"
;
public
static
String
[]
domainNames
={
"fanshen.cn"
,
"www.fanshen.cn"
,
"zhishen.net"
,
"www.zhishen.net"
,
"ewglobal.cn"
,
"www.ewglobal.cn"
};
}
\ No newline at end of file
ruoyi-common/src/main/java/com/ruoyi/common/utils/DictUtils.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
common
.
utils
;
import
java.util.List
;
import
org.springframework.stereotype.Component
;
import
com.ruoyi.common.constant.Constants
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
...
...
@@ -187,4 +188,5 @@ public class DictUtils
{
return
Constants
.
SYS_DICT_KEY
+
configKey
;
}
}
ruoyi-framework/src/main/java/com/ruoyi/framework/config/ShiroConfig.java
浏览文件 @
ef5bed33
...
...
@@ -302,6 +302,7 @@ public class ShiroConfig
filterChainDefinitionMap
.
put
(
"/register"
,
"anon,captchaValidate"
);
//2023.5.11 开放在线客服
filterChainDefinitionMap
.
put
(
"/kf/**"
,
"anon"
);
filterChainDefinitionMap
.
put
(
"/"
,
"anon"
);
// filterChainDefinitionMap.put("/business/chatRecord/list/**", "anon");
// filterChainDefinitionMap.put("/common/atlas/**", "anon");
// 系统权限列表
...
...
ruoyi-system/src/main/java/com/ruoyi/system/domain/TbInformationPlatform.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
system
.
domain
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
com.ruoyi.common.annotation.Excel
;
import
com.ruoyi.common.core.domain.BaseEntity
;
/**
* 海外国家人文,交通,饮食信息对象 tb_information_platform
*
* @author ruoyi
* @date 2024-03-01
*/
public
class
TbInformationPlatform
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/** $column.columnComment */
private
Long
id
;
/** 国家代码 */
@Excel
(
name
=
"国家代码"
)
private
Long
countryCode
;
/** $column.columnComment */
@Excel
(
name
=
"${comment}"
,
readConverterExp
=
"$column.readConverterExp()"
)
private
String
country
;
/** 城市代码 */
@Excel
(
name
=
"城市代码"
)
private
Long
cityCode
;
/** $column.columnComment */
@Excel
(
name
=
"${comment}"
,
readConverterExp
=
"$column.readConverterExp()"
)
private
String
city
;
/** 内容分类 */
@Excel
(
name
=
"内容分类"
)
private
String
contentType
;
private
String
contentTypeDesc
;
/** 标题 */
@Excel
(
name
=
"标题"
)
private
String
title
;
/** 摘要 */
@Excel
(
name
=
"摘要"
)
private
String
summary
;
/** 内容 */
@Excel
(
name
=
"内容"
)
private
String
content
;
/** 图片封面 */
@Excel
(
name
=
"图片封面"
)
private
String
cover
;
/** 创建者 */
@Excel
(
name
=
"创建者"
)
private
Long
creator
;
/** 修改人 */
@Excel
(
name
=
"修改人"
)
private
Long
modifiedBy
;
@Excel
(
name
=
"创建人"
)
private
String
creatorDesc
;
@Excel
(
name
=
"修改人"
)
private
String
modifiedByDesc
;
@Excel
(
name
=
"审核人员"
)
private
String
checkerDesc
;
/**审核状态*/
@Excel
(
name
=
"审核状态"
)
private
String
checkStatusDesc
;
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
public
Long
getId
()
{
return
id
;
}
public
void
setCountryCode
(
Long
countryCode
)
{
this
.
countryCode
=
countryCode
;
}
public
Long
getCountryCode
()
{
return
countryCode
;
}
public
void
setCountry
(
String
country
)
{
this
.
country
=
country
;
}
public
String
getCountry
()
{
return
country
;
}
public
void
setCityCode
(
Long
cityCode
)
{
this
.
cityCode
=
cityCode
;
}
public
Long
getCityCode
()
{
return
cityCode
;
}
public
void
setCity
(
String
city
)
{
this
.
city
=
city
;
}
public
String
getCity
()
{
return
city
;
}
public
void
setContentType
(
String
contentType
)
{
this
.
contentType
=
contentType
;
}
public
String
getContentType
()
{
return
contentType
;
}
public
void
setTitle
(
String
title
)
{
this
.
title
=
title
;
}
public
String
getTitle
()
{
return
title
;
}
public
void
setContent
(
String
content
)
{
this
.
content
=
content
;
}
public
String
getContent
()
{
return
content
;
}
public
void
setCover
(
String
cover
)
{
this
.
cover
=
cover
;
}
public
String
getCover
()
{
return
cover
;
}
public
String
getContentTypeDesc
()
{
return
contentTypeDesc
;
}
public
void
setContentTypeDesc
(
String
contentTypeDesc
)
{
this
.
contentTypeDesc
=
contentTypeDesc
;
}
@Override
public
Long
getCreator
()
{
return
creator
;
}
@Override
public
void
setCreator
(
Long
creator
)
{
this
.
creator
=
creator
;
}
@Override
public
Long
getModifiedBy
()
{
return
modifiedBy
;
}
@Override
public
void
setModifiedBy
(
Long
modifiedBy
)
{
this
.
modifiedBy
=
modifiedBy
;
}
public
String
getCheckerDesc
()
{
return
checkerDesc
;
}
public
void
setCheckerDesc
(
String
checkerDesc
)
{
this
.
checkerDesc
=
checkerDesc
;
}
public
String
getCheckStatusDesc
()
{
return
checkStatusDesc
;
}
public
void
setCheckStatusDesc
(
String
checkStatusDesc
)
{
this
.
checkStatusDesc
=
checkStatusDesc
;
}
public
String
getCreatorDesc
()
{
return
creatorDesc
;
}
public
void
setCreatorDesc
(
String
creatorDesc
)
{
this
.
creatorDesc
=
creatorDesc
;
}
public
String
getModifiedByDesc
()
{
return
modifiedByDesc
;
}
public
void
setModifiedByDesc
(
String
modifiedByDesc
)
{
this
.
modifiedByDesc
=
modifiedByDesc
;
}
public
String
getSummary
()
{
return
summary
;
}
public
void
setSummary
(
String
summary
)
{
this
.
summary
=
summary
;
}
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"countryCode"
,
getCountryCode
())
.
append
(
"country"
,
getCountry
())
.
append
(
"cityCode"
,
getCityCode
())
.
append
(
"city"
,
getCity
())
.
append
(
"contentType"
,
getContentType
())
.
append
(
"title"
,
getTitle
())
.
append
(
"content"
,
getContent
())
.
append
(
"cover"
,
getCover
())
.
append
(
"creator"
,
getCreator
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"modifiedBy"
,
getModifiedBy
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
toString
();
}
}
ruoyi-system/src/main/java/com/ruoyi/system/domain/TbRegion.java
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
system
.
domain
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
com.ruoyi.common.annotation.Excel
;
import
com.ruoyi.common.core.domain.BaseEntity
;
/**
...
...
@@ -14,222 +11,80 @@ import com.ruoyi.common.core.domain.BaseEntity;
public
class
TbRegion
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/** 自增ID */
private
Long
id
;
/** 代码 */
@Excel
(
name
=
"代码"
)
private
Long
code
;
/** 名称 */
@Excel
(
name
=
"名称"
)
/**
* 自增ID
*/
private
Integer
id
;
/**
* 代码
*/
private
Integer
code
;
/**
* 名称
*/
private
String
name
;
/** 简称 */
@Excel
(
name
=
"简称"
)
private
String
shortName
;
/** 上级代码 */
@Excel
(
name
=
"上级代码"
)
private
Long
parentCode
;
/** 经度 */
@Excel
(
name
=
"经度"
)
private
String
lng
;
/** 纬度 */
@Excel
(
name
=
"纬度"
)
private
String
lat
;
/** 排序 */
@Excel
(
name
=
"排序"
)
private
Integer
sort
;
/**
* 上级代码
*/
private
Integer
parentCode
;
/** 备注 */
@Excel
(
name
=
"备注"
)
private
String
memo
;
/** 状态 */
@Excel
(
name
=
"状态"
)
private
Long
status
;
/** 级别 */
@Excel
(
name
=
"级别"
)
/**
* 级别
*/
private
String
level
;
/** 是否热门 */
@Excel
(
name
=
"是否热门"
)
private
Long
hotStatus
;
/** 拼音首字母(查询一级用到) */
@Excel
(
name
=
"拼音首字母(查询一级用到)"
)
private
String
cqlszx
;
/** 归属大区code */
@Excel
(
name
=
"归属大区code"
)
private
Integer
bigAreaCode
;
/** 国内国外1国内2国外 */
@Excel
(
name
=
"国内国外1国内2国外"
)
private
Integer
isHomeAndAbroad
;
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
public
Long
getId
()
{
public
Integer
getId
()
{
return
id
;
}
public
void
setCode
(
Long
code
)
{
this
.
code
=
code
;
public
void
setId
(
Integer
id
)
{
this
.
id
=
id
;
}
public
Long
getCode
()
{
public
Integer
getCode
()
{
return
code
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
nam
e
;
public
void
setCode
(
Integer
code
)
{
this
.
code
=
cod
e
;
}
public
String
getName
()
{
public
String
getName
()
{
return
name
;
}
public
void
setShortName
(
String
shortName
)
{
this
.
shortName
=
shortName
;
}
public
String
getShortName
()
{
return
shortName
;
}
public
void
setParentCode
(
Long
parentCode
)
{
this
.
parentCode
=
parentCode
;
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
Long
getParentCode
()
{
public
Integer
getParentCode
()
{
return
parentCode
;
}
public
void
setLng
(
String
lng
)
{
this
.
lng
=
lng
;
}
public
String
getLng
()
{
return
lng
;
}
public
void
setLat
(
String
lat
)
{
this
.
lat
=
lat
;
}
public
String
getLat
()
{
return
lat
;
}
public
void
setSort
(
Integer
sort
)
{
this
.
sort
=
sort
;
}
public
Integer
getSort
()
{
return
sort
;
}
public
void
setMemo
(
String
memo
)
{
this
.
memo
=
memo
;
}
public
String
getMemo
()
{
return
memo
;
}
public
void
setStatus
(
Long
status
)
{
this
.
status
=
status
;
}
public
Long
getStatus
()
{
return
status
;
}
public
void
setLevel
(
String
level
)
{
this
.
level
=
level
;
public
void
setParentCode
(
Integer
parentCode
)
{
this
.
parentCode
=
parentCode
;
}
public
String
getLevel
()
{
public
String
getLevel
()
{
return
level
;
}
public
void
setHotStatus
(
Long
hotStatus
)
{
this
.
hotStatus
=
hotStatus
;
}
public
Long
getHotStatus
()
{
return
hotStatus
;
}
public
void
setCqlszx
(
String
cqlszx
)
{
this
.
cqlszx
=
cqlszx
;
}
public
String
getCqlszx
()
{
return
cqlszx
;
}
public
void
setBigAreaCode
(
Integer
bigAreaCode
)
{
this
.
bigAreaCode
=
bigAreaCode
;
}
public
Integer
getBigAreaCode
()
{
return
bigAreaCode
;
}
public
void
setIsHomeAndAbroad
(
Integer
isHomeAndAbroad
)
{
this
.
isHomeAndAbroad
=
isHomeAndAbroad
;
}
public
Integer
getIsHomeAndAbroad
()
{
return
isHomeAndAbroad
;
public
void
setLevel
(
String
level
)
{
this
.
level
=
level
;
}
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"code"
,
getCode
())
.
append
(
"name"
,
getName
())
.
append
(
"shortName"
,
getShortName
())
.
append
(
"parentCode"
,
getParentCode
())
.
append
(
"lng"
,
getLng
())
.
append
(
"lat"
,
getLat
())
.
append
(
"sort"
,
getSort
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
append
(
"memo"
,
getMemo
())
.
append
(
"status"
,
getStatus
())
.
append
(
"level"
,
getLevel
())
.
append
(
"hotStatus"
,
getHotStatus
())
.
append
(
"cqlszx"
,
getCqlszx
())
.
append
(
"bigAreaCode"
,
getBigAreaCode
())
.
append
(
"isHomeAndAbroad"
,
getIsHomeAndAbroad
())
.
toString
();
return
"Region{"
+
"id="
+
id
+
", code="
+
code
+
", name="
+
name
+
", parentCode="
+
parentCode
+
", level="
+
level
+
"}"
;
}
}
ruoyi-system/src/main/java/com/ruoyi/system/mapper/TbInformationPlatformMapper.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
system
.
mapper
;
import
java.util.List
;
import
com.ruoyi.system.domain.TbInformationPlatform
;
import
org.apache.ibatis.annotations.Mapper
;
/**
* 海外国家人文,交通,饮食信息Mapper接口
*
* @author ruoyi
* @date 2024-02-29
*/
@Mapper
public
interface
TbInformationPlatformMapper
{
/**
* 查询海外国家人文,交通,饮食信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 海外国家人文,交通,饮食信息
*/
TbInformationPlatform
selectTbInformationPlatformById
(
Long
id
);
/**
* 查询海外国家人文,交通,饮食信息列表
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 海外国家人文,交通,饮食信息集合
*/
List
<
TbInformationPlatform
>
selectTbInformationPlatformList
(
TbInformationPlatform
tbInformationPlatform
);
List
<
TbInformationPlatform
>
selectTbInformationPlatformNotPassList
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 新增海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
int
insertTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 修改海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
int
updateTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 删除海外国家人文,交通,饮食信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 结果
*/
int
deleteTbInformationPlatformById
(
Long
id
);
/**
* 批量删除海外国家人文,交通,饮食信息
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
int
deleteTbInformationPlatformByIds
(
String
[]
ids
);
int
updateCheckStatus
(
TbInformationPlatform
tbInformationPlatform
);
}
ruoyi-system/src/main/java/com/ruoyi/system/service/ITbInformationPlatformService.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
system
.
service
;
import
java.util.List
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.system.domain.TbInformationPlatform
;
/**
* 海外国家人文,交通,饮食信息Service接口
*
* @author ruoyi
* @date 2024-02-29
*/
public
interface
ITbInformationPlatformService
{
/**
* 查询海外国家人文,交通,饮食信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 海外国家人文,交通,饮食信息
*/
TbInformationPlatform
selectTbInformationPlatformById
(
Long
id
);
/**
* 查询海外国家人文,交通,饮食信息列表
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 海外国家人文,交通,饮食信息集合
*/
List
<
TbInformationPlatform
>
selectTbInformationPlatformList
(
TbInformationPlatform
tbInformationPlatform
);
List
<
TbInformationPlatform
>
selectTbInformationPlatformNotPassList
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 新增海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
int
insertTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 修改海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
int
updateTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
);
/**
* 批量删除海外国家人文,交通,饮食信息
*
* @param ids 需要删除的海外国家人文,交通,饮食信息主键集合
* @return 结果
*/
int
deleteTbInformationPlatformByIds
(
String
ids
);
/**
* 删除海外国家人文,交通,饮食信息信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 结果
*/
int
deleteTbInformationPlatformById
(
Long
id
);
int
updateCheckStatus
(
TbInformationPlatform
tbInformationPlatform
);
}
ruoyi-system/src/main/java/com/ruoyi/system/service/ITbMaterialDemoService.java
浏览文件 @
ef5bed33
...
...
@@ -47,7 +47,7 @@ public interface ITbMaterialDemoService
* @param tbMaterialDemo 材料样例
* @return 结果
*/
public
int
updateTbMaterialDemo
(
TbMaterialDemo
tbMaterialDemo
);
int
updateTbMaterialDemo
(
TbMaterialDemo
tbMaterialDemo
);
public
int
updateCheckStatus
(
TbMaterialDemo
tbMaterialDemo
);
/**
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CommonServiceImpl.java
浏览文件 @
ef5bed33
...
...
@@ -7,6 +7,7 @@ import com.ruoyi.system.domain.TbMajorSorted;
import
com.ruoyi.system.domain.TbRegion
;
import
com.ruoyi.system.domain.TbSchool
;
import
com.ruoyi.system.mapper.*
;
import
org.apache.commons.lang3.ObjectUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
...
...
@@ -63,7 +64,10 @@ public class CommonServiceImpl {
public
String
getUserName
(
Long
userId
){
SysUser
su
=
sysUserMapper
.
selectUserById
(
userId
);
return
su
.
getLoginName
();
if
(
ObjectUtils
.
isNotEmpty
(
su
)){
return
su
.
getLoginName
();
}
return
""
;
}
public
String
getMajorName
(
Long
id
){
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/StudentFileServiceImpl.java
浏览文件 @
ef5bed33
...
...
@@ -6,7 +6,6 @@ import com.itextpdf.text.Font;
import
com.itextpdf.text.Image
;
import
com.itextpdf.text.pdf.*
;
import
com.ruoyi.common.config.RuoYiConfig
;
import
com.ruoyi.common.constant.ApplyStatusEnum
;
import
com.ruoyi.common.constant.Constants
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.common.io.TBCell
;
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TbInformationPlatformServiceImpl.java
0 → 100644
浏览文件 @
ef5bed33
package
com
.
ruoyi
.
system
.
service
.
impl
;
import
java.util.List
;
import
com.ruoyi.common.constant.Constants
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.utils.DictUtils
;
import
com.ruoyi.common.utils.StringUtils
;
import
com.ruoyi.system.mapper.SysUserMapper
;
import
org.apache.commons.lang3.ObjectUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.ruoyi.system.mapper.TbInformationPlatformMapper
;
import
com.ruoyi.system.domain.TbInformationPlatform
;
import
com.ruoyi.system.service.ITbInformationPlatformService
;
import
com.ruoyi.common.core.text.Convert
;
import
javax.annotation.Resource
;
/**
* 海外国家人文,交通,饮食信息Service业务层处理
*
* @author ruoyi
* @date 2024-02-29
*/
@Service
public
class
TbInformationPlatformServiceImpl
implements
ITbInformationPlatformService
{
@Autowired
private
TbInformationPlatformMapper
tbInformationPlatformMapper
;
@Autowired
private
CommonServiceImpl
commonService
;
@Resource
private
SysUserMapper
sysUserMapper
;
/**
* 查询海外国家人文,交通,饮食信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 海外国家人文,交通,饮食信息
*/
@Override
public
TbInformationPlatform
selectTbInformationPlatformById
(
Long
id
)
{
TbInformationPlatform
platform
=
tbInformationPlatformMapper
.
selectTbInformationPlatformById
(
id
);
List
<
SysDictData
>
dictCache
=
DictUtils
.
getDictCache
(
"business_content_type"
);
SysDictData
sysDictData
=
dictCache
.
stream
().
filter
(
sysDictData1
->
{
if
(
sysDictData1
.
getDictValue
().
equals
(
platform
.
getContentType
())){
return
true
;
}
return
false
;
}).
findFirst
().
get
();
platform
.
setContentTypeDesc
(
sysDictData
.
getDictLabel
());
return
platform
;
}
/**
* 查询海外国家人文,交通,饮食信息列表
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 海外国家人文,交通,饮食信息
*/
@Override
public
List
<
TbInformationPlatform
>
selectTbInformationPlatformList
(
TbInformationPlatform
tbInformationPlatform
)
{
List
<
TbInformationPlatform
>
list
=
tbInformationPlatformMapper
.
selectTbInformationPlatformList
(
tbInformationPlatform
);
if
(
ObjectUtils
.
isNotEmpty
(
list
)){
List
<
SysDictData
>
dictCache
=
DictUtils
.
getDictCache
(
"business_content_type"
);
list
.
stream
().
forEach
(
platform
->
{
platform
.
setCreateBy
(
commonService
.
getUserName
(
platform
.
getCreator
()));
SysDictData
sysDictData
=
dictCache
.
stream
().
filter
(
sysDictData1
->
{
if
(
sysDictData1
.
getDictValue
().
equals
(
platform
.
getContentType
())){
return
true
;
}
return
false
;
}).
findFirst
().
get
();
platform
.
setContentType
(
sysDictData
.
getDictLabel
());
});
}
return
list
;
}
@Override
public
List
<
TbInformationPlatform
>
selectTbInformationPlatformNotPassList
(
TbInformationPlatform
tbInformationPlatform
){
List
<
TbInformationPlatform
>
list
=
tbInformationPlatformMapper
.
selectTbInformationPlatformNotPassList
(
tbInformationPlatform
);
if
(
ObjectUtils
.
isNotEmpty
(
list
)){
List
<
SysDictData
>
dictCache
=
DictUtils
.
getDictCache
(
"business_content_type"
);
list
.
stream
().
forEach
(
platform
->
{
// platform.setCreateBy(commonService.getUserName(platform.getCreator()));
SysDictData
sysDictData
=
dictCache
.
stream
().
filter
(
sysDictData1
->
{
if
(
sysDictData1
.
getDictValue
().
equals
(
platform
.
getContentType
())){
return
true
;
}
return
false
;
}).
findFirst
().
get
();
platform
.
setContentType
(
sysDictData
.
getDictLabel
());
convertCheckStatusToString
(
platform
);
convertUserIDToString
(
platform
);
});
}
return
list
;
}
/**
* @Author : fanxiaolong
* @Description : 学校审核状态转换成文字
* @DateTime : 2022/9/2 16:51
* @param : tbSchool
* @param : dictDataList
* @return : void
*/
private
void
convertCheckStatusToString
(
TbInformationPlatform
tbInformationPlatform
){
List
<
SysDictData
>
checkStatusList
=
DictUtils
.
getDictCache
(
Constants
.
BUSINESS_CHECK_STATUS
);
checkStatusList
.
stream
().
forEach
(
sysDictData
->
{
if
(
StringUtils
.
compare
(
String
.
valueOf
(
tbInformationPlatform
.
getCheckStatus
()),
sysDictData
.
getDictValue
())==
0
){
tbInformationPlatform
.
setCheckStatusDesc
(
sysDictData
.
getDictLabel
());
}
});
}
/**
* @Author : fanxiaolong
* @Description : 转换userID为loginName
* @DateTime : 2022/9/5 10:48
* @param : tbSchool
* @return : void
*/
private
void
convertUserIDToString
(
TbInformationPlatform
tbInformationPlatform
){
SysUser
su
=
null
;
su
=
sysUserMapper
.
selectUserById
(
tbInformationPlatform
.
getCreator
());
tbInformationPlatform
.
setCreatorDesc
(
su
.
getLoginName
());
su
=
sysUserMapper
.
selectUserById
(
tbInformationPlatform
.
getModifiedBy
());
if
(
ObjectUtils
.
isNotEmpty
(
su
)){
tbInformationPlatform
.
setModifiedByDesc
(
su
.
getLoginName
());
}
su
=
sysUserMapper
.
selectUserById
(
tbInformationPlatform
.
getChecker
());
if
(
ObjectUtils
.
isNotEmpty
(
su
)){
tbInformationPlatform
.
setCheckerDesc
(
su
.
getLoginName
());
}
}
/**
* 新增海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
@Override
public
int
insertTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
)
{
return
tbInformationPlatformMapper
.
insertTbInformationPlatform
(
tbInformationPlatform
);
}
/**
* 修改海外国家人文,交通,饮食信息
*
* @param tbInformationPlatform 海外国家人文,交通,饮食信息
* @return 结果
*/
@Override
public
int
updateTbInformationPlatform
(
TbInformationPlatform
tbInformationPlatform
)
{
return
tbInformationPlatformMapper
.
updateTbInformationPlatform
(
tbInformationPlatform
);
}
/**
* 批量删除海外国家人文,交通,饮食信息
*
* @param ids 需要删除的海外国家人文,交通,饮食信息主键
* @return 结果
*/
@Override
public
int
deleteTbInformationPlatformByIds
(
String
ids
)
{
return
tbInformationPlatformMapper
.
deleteTbInformationPlatformByIds
(
Convert
.
toStrArray
(
ids
));
}
/**
* 删除海外国家人文,交通,饮食信息信息
*
* @param id 海外国家人文,交通,饮食信息主键
* @return 结果
*/
@Override
public
int
deleteTbInformationPlatformById
(
Long
id
)
{
return
tbInformationPlatformMapper
.
deleteTbInformationPlatformById
(
id
);
}
@Override
public
int
updateCheckStatus
(
TbInformationPlatform
tbInformationPlatform
){
return
tbInformationPlatformMapper
.
updateCheckStatus
(
tbInformationPlatform
);
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TbNewsServiceImpl.java
浏览文件 @
ef5bed33
...
...
@@ -3,6 +3,7 @@ package com.ruoyi.system.service.impl;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
com.ruoyi.common.constant.Constants
;
import
com.ruoyi.common.utils.DateUtils
;
import
com.ruoyi.system.domain.TbSchool
;
import
com.ruoyi.system.mapper.TbSchoolMapper
;
...
...
@@ -83,23 +84,28 @@ public class TbNewsServiceImpl implements ITbNewsService
@Override
public
int
insertTbNews
(
TbNewsReq
tbNews
)
{
if
(
tbNews
.
getNewsContent
().
contains
(
Constants
.
SERVERIP
)){
tbNews
.
setNewsContent
(
tbNews
.
getNewsContent
().
replace
(
Constants
.
SERVERIP
,
Constants
.
DOMAINNAME
));
}
tbNews
.
setStatus
(
1
);
tbNews
.
setCreateTime
(
DateUtils
.
getNowDate
());
//判断该院校是否有多个分校,如果有,则将新闻一起复制到其他分校
TbSchool
tbSchool
=
new
TbSchool
();
if
(
tbNews
.
getNewsSchoolCnName
().
contains
(
"("
)){
tbSchool
.
setSchoolCnName
(
tbNews
.
getNewsSchoolCnName
().
split
(
"\\("
)[
0
]);
}
else
{
tbSchool
.
setSchoolCnName
(
tbNews
.
getNewsSchoolCnName
());
}
List
<
TbSchool
>
tbSchools
=
tbSchoolMapper
.
selectTbSchoolList
(
tbSchool
);
if
(
tbSchools
.
size
()>
1
){
for
(
TbSchool
tbSchool1
:
tbSchools
){
if
(!
tbSchool1
.
getId
().
equals
(
Long
.
valueOf
(
tbNews
.
getNewsSchool
()))){
TbNews
req
=
new
TbNews
();
BeanUtils
.
copyProperties
(
tbNews
,
req
);
req
.
setNewsSchool
(
tbSchool1
.
getId
().
intValue
());
tbNewsMapper
.
insertTbNews
(
req
);
if
(
ObjectUtils
.
isNotEmpty
(
tbNews
.
getNewsSchoolCnName
())){
if
(
tbNews
.
getNewsSchoolCnName
().
contains
(
"("
)){
tbSchool
.
setSchoolCnName
(
tbNews
.
getNewsSchoolCnName
().
split
(
"\\("
)[
0
]);
}
else
{
tbSchool
.
setSchoolCnName
(
tbNews
.
getNewsSchoolCnName
());
}
List
<
TbSchool
>
tbSchools
=
tbSchoolMapper
.
selectTbSchoolList
(
tbSchool
);
if
(
tbSchools
.
size
()>
1
){
for
(
TbSchool
tbSchool1
:
tbSchools
){
if
(!
tbSchool1
.
getId
().
equals
(
Long
.
valueOf
(
tbNews
.
getNewsSchool
()))){
TbNews
req
=
new
TbNews
();
BeanUtils
.
copyProperties
(
tbNews
,
req
);
req
.
setNewsSchool
(
tbSchool1
.
getId
().
intValue
());
tbNewsMapper
.
insertTbNews
(
req
);
}
}
}
}
...
...
@@ -118,6 +124,9 @@ public class TbNewsServiceImpl implements ITbNewsService
@Override
public
int
updateTbNews
(
TbNews
tbNews
)
{
if
(
tbNews
.
getNewsContent
().
contains
(
Constants
.
SERVERIP
)){
tbNews
.
setNewsContent
(
tbNews
.
getNewsContent
().
replace
(
Constants
.
SERVERIP
,
Constants
.
DOMAINNAME
));
}
tbNews
.
setUpdateTime
(
DateUtils
.
getNowDate
());
//判断该新闻是否有多条
TbNews
tbNews1
=
tbNewsMapper
.
selectTbNewsById
(
tbNews
.
getId
());
...
...
ruoyi-system/src/main/resources/mapper/system/TbInformationPlatformMapper.xml
0 → 100644
浏览文件 @
ef5bed33
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.ruoyi.system.mapper.TbInformationPlatformMapper"
>
<resultMap
type=
"TbInformationPlatform"
id=
"TbInformationPlatformResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"countryCode"
column=
"country_code"
/>
<result
property=
"country"
column=
"country"
/>
<result
property=
"cityCode"
column=
"city_code"
/>
<result
property=
"city"
column=
"city"
/>
<result
property=
"contentType"
column=
"content_type"
/>
<result
property=
"title"
column=
"title"
/>
<result
property=
"summary"
column=
"summary"
/>
<result
property=
"content"
column=
"content"
/>
<result
property=
"cover"
column=
"cover"
/>
<result
property=
"creator"
column=
"creator"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"modifiedBy"
column=
"modified_by"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"checker"
column=
"checker"
/>
<result
property=
"checkTime"
column=
"check_time"
/>
<result
property=
"checkStatus"
column=
"check_status"
/>
<result
property=
"checkResult"
column=
"check_result"
/>
</resultMap>
<sql
id=
"selectTbInformationPlatformVo"
>
select id, country_code, country, city_code, city, content_type, title, summary, content, cover, creator, create_time,
modified_by, update_time,checker,check_time,check_status,check_result from tb_information_platform
</sql>
<select
id=
"selectTbInformationPlatformList"
parameterType=
"TbInformationPlatform"
resultMap=
"TbInformationPlatformResult"
>
<include
refid=
"selectTbInformationPlatformVo"
/>
<where>
<if
test=
"countryCode != null "
>
and country_code = #{countryCode}
</if>
<if
test=
"country != null and country != ''"
>
and country = #{country}
</if>
<if
test=
"cityCode != null "
>
and city_code = #{cityCode}
</if>
<if
test=
"city != null and city != ''"
>
and city = #{city}
</if>
<if
test=
"contentType != null and contentType != ''"
>
and content_type = #{contentType}
</if>
<if
test=
"title != null and title != ''"
>
and title = #{title}
</if>
<if
test=
"content != null and content != ''"
>
and content = #{content}
</if>
<if
test=
"cover != null and cover != ''"
>
and cover = #{cover}
</if>
<if
test=
"creator != null "
>
and creator = #{creator}
</if>
<if
test=
"modifiedBy != null "
>
and modified_by = #{modifiedBy}
</if>
</where>
order by create_time desc
</select>
<select
id=
"selectTbInformationPlatformNotPassList"
parameterType=
"TbInformationPlatform"
resultMap=
"TbInformationPlatformResult"
>
<include
refid=
"selectTbInformationPlatformVo"
/>
<where>
<if
test=
"country != null and country != ''"
>
and country = #{country}
</if>
<if
test=
"city != null and city != ''"
>
and city = #{city}
</if>
<if
test=
"title != null and title != ''"
>
and title = #{title}
</if>
and check_status != 2
</where>
order by create_time desc
</select>
<select
id=
"selectTbInformationPlatformById"
parameterType=
"Long"
resultMap=
"TbInformationPlatformResult"
>
<include
refid=
"selectTbInformationPlatformVo"
/>
where id = #{id}
</select>
<insert
id=
"insertTbInformationPlatform"
parameterType=
"TbInformationPlatform"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into tb_information_platform
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"countryCode != null"
>
country_code,
</if>
<if
test=
"country != null and country != ''"
>
country,
</if>
<if
test=
"cityCode != null"
>
city_code,
</if>
<if
test=
"city != null and city != ''"
>
city,
</if>
<if
test=
"contentType != null and contentType != ''"
>
content_type,
</if>
<if
test=
"title != null and title != ''"
>
title,
</if>
<if
test=
"summary != null and summary != ''"
>
summary,
</if>
<if
test=
"content != null and content != ''"
>
content,
</if>
<if
test=
"cover != null and cover != ''"
>
cover,
</if>
<if
test=
"creator != null"
>
creator,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"modifiedBy != null"
>
modified_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
check_status
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"countryCode != null"
>
#{countryCode},
</if>
<if
test=
"country != null and country != ''"
>
#{country},
</if>
<if
test=
"cityCode != null"
>
#{cityCode},
</if>
<if
test=
"city != null and city != ''"
>
#{city},
</if>
<if
test=
"contentType != null and contentType != ''"
>
#{contentType},
</if>
<if
test=
"title != null and title != ''"
>
#{title},
</if>
<if
test=
"summary != null and summary != ''"
>
#{summary},
</if>
<if
test=
"content != null and content != ''"
>
#{content},
</if>
<if
test=
"cover != null and cover != ''"
>
#{cover},
</if>
<if
test=
"creator != null"
>
#{creator},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"modifiedBy != null"
>
#{modifiedBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
1
</trim>
</insert>
<update
id=
"updateTbInformationPlatform"
parameterType=
"TbInformationPlatform"
>
update tb_information_platform
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"countryCode != null"
>
country_code = #{countryCode},
</if>
<if
test=
"country != null and country != ''"
>
country = #{country},
</if>
<if
test=
"cityCode != null"
>
city_code = #{cityCode},
</if>
<if
test=
"city != null and city != ''"
>
city = #{city},
</if>
<if
test=
"contentType != null and contentType != ''"
>
content_type = #{contentType},
</if>
<if
test=
"title != null and title != ''"
>
title = #{title},
</if>
<if
test=
"summary != null and summary != ''"
>
summary = #{summary},
</if>
<if
test=
"content != null and content != ''"
>
content = #{content},
</if>
<if
test=
"cover != null and cover != ''"
>
cover = #{cover},
</if>
<if
test=
"modifiedBy != null"
>
modified_by = #{modifiedBy},
</if>
update_time = sysdate(),check_status=1,check_result=null,check_time=null,checker=null
</trim>
where id = #{id}
</update>
<update
id=
"updateCheckStatus"
parameterType=
"TbInformationPlatform"
>
update tb_information_platform
set checker=#{checker}, check_time=sysdate(),check_status=#{checkStatus},check_result=#{checkResult}
where id=#{id}
</update>
<delete
id=
"deleteTbInformationPlatformById"
parameterType=
"Long"
>
delete from tb_information_platform where id = #{id}
</delete>
<delete
id=
"deleteTbInformationPlatformByIds"
parameterType=
"String"
>
delete from tb_information_platform where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论