Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dsk-operate-sys-cscec
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fulixin
dsk-operate-sys-cscec
Commits
0ef1f2fc
Commit
0ef1f2fc
authored
Nov 17, 2023
by
tianhongyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'V20230915' of
http://192.168.60.201/root/dsk-operate-sys
into V20230915
parents
43aa5bbe
4cbecf10
Changes
35
Show whitespace changes
Inline
Side-by-side
Showing
35 changed files
with
1294 additions
and
49 deletions
+1294
-49
pom.xml
dsk-admin/pom.xml
+6
-0
SysTenantController.java
...va/com/dsk/web/controller/system/SysTenantController.java
+3
-1
application.yml
dsk-admin/src/main/resources/application.yml
+23
-1
pom.xml
dsk-module/dsk-biz-bi/pom.xml
+99
-0
BaseController.java
...n/java/com/dsk/biz/goview/common/base/BaseController.java
+111
-0
BaseService.java
...main/java/com/dsk/biz/goview/common/base/BaseService.java
+36
-0
AjaxResult.java
.../main/java/com/dsk/biz/goview/common/bean/AjaxResult.java
+104
-0
GoviewProject.java
.../java/com/dsk/biz/goview/common/domain/GoviewProject.java
+44
-0
GoviewProjectData.java
...a/com/dsk/biz/goview/common/domain/GoviewProjectData.java
+34
-0
MagicHttp.java
...main/java/com/dsk/biz/goview/common/domain/MagicHttp.java
+83
-0
ResultTable.java
...in/java/com/dsk/biz/goview/common/domain/ResultTable.java
+88
-0
Tablepar.java
.../main/java/com/dsk/biz/goview/common/domain/Tablepar.java
+61
-0
DataVTenantHandler.java
...in/java/com/dsk/biz/goview/config/DataVTenantHandler.java
+53
-0
GoviewProperties.java
...main/java/com/dsk/biz/goview/config/GoviewProperties.java
+44
-0
MybatisAutoConfiguration.java
...a/com/dsk/biz/goview/config/MybatisAutoConfiguration.java
+56
-0
YamlPropertySourceFactory.java
.../com/dsk/biz/goview/config/YamlPropertySourceFactory.java
+42
-0
GoViewProjectAPIController.java
...dsk/biz/goview/controller/GoViewProjectAPIController.java
+202
-0
GoviewPageController.java
...a/com/dsk/biz/goview/controller/GoviewPageController.java
+39
-0
GoviewProjectDataMapper.java
...va/com/dsk/biz/goview/mapper/GoviewProjectDataMapper.java
+14
-0
GoviewProjectMapper.java
...n/java/com/dsk/biz/goview/mapper/GoviewProjectMapper.java
+14
-0
index.html
...module/dsk-biz-bi/src/main/resources/templates/index.html
+58
-0
pom.xml
dsk-module/pom.xml
+1
-0
.env.production
dsk-operate-ui/.env.production
+1
-1
index.scss
dsk-operate-ui/src/assets/styles/index.scss
+2
-2
public.scss
dsk-operate-ui/src/assets/styles/public.scss
+3
-3
ruoyi.scss
dsk-operate-ui/src/assets/styles/ruoyi.scss
+2
-1
index.js
dsk-operate-ui/src/router/index.js
+1
-0
index.vue
dsk-operate-ui/src/views/detail/party-a/index.vue
+1
-0
index.vue
.../views/enterpriseData/components/searchTheOwner/index.vue
+1
-1
index.vue
dsk-operate-ui/src/views/macro/urban/index.vue
+0
-1
index.vue
...rate-ui/src/views/radar/components/MajorProject/index.vue
+6
-3
ISysUserService.java
...src/main/java/com/dsk/system/service/ISysUserService.java
+9
-0
ISysTenantServiceImpl.java
...va/com/dsk/system/service/impl/ISysTenantServiceImpl.java
+24
-26
SysUserServiceImpl.java
.../java/com/dsk/system/service/impl/SysUserServiceImpl.java
+23
-6
pom.xml
pom.xml
+6
-3
No files found.
dsk-admin/pom.xml
View file @
0ef1f2fc
...
@@ -61,6 +61,11 @@
...
@@ -61,6 +61,11 @@
<artifactId>
dsk-biz-api
</artifactId>
<artifactId>
dsk-biz-api
</artifactId>
</dependency>
</dependency>
<dependency>
<groupId>
com.dsk
</groupId>
<artifactId>
dsk-biz-bi
</artifactId>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-test
</artifactId>
<artifactId>
spring-boot-starter-test
</artifactId>
...
@@ -84,6 +89,7 @@
...
@@ -84,6 +89,7 @@
<!-- <version>${与你的agent探针版本保持一致}</version>-->
<!-- <version>${与你的agent探针版本保持一致}</version>-->
<!-- </dependency>-->
<!-- </dependency>-->
</dependencies>
</dependencies>
<build>
<build>
...
...
dsk-admin/src/main/java/com/dsk/web/controller/system/SysTenantController.java
View file @
0ef1f2fc
...
@@ -104,10 +104,12 @@ public class SysTenantController extends BaseController {
...
@@ -104,10 +104,12 @@ public class SysTenantController extends BaseController {
@Log
(
title
=
"用户管理"
,
businessType
=
BusinessType
.
INSERT
)
@Log
(
title
=
"用户管理"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/addTenantAdmin"
)
@PostMapping
(
"/addTenantAdmin"
)
public
R
<
Void
>
addTenantAdmin
(
@Validated
@RequestBody
SysTenantAdminBo
tenantAdminBo
)
{
public
R
<
Void
>
addTenantAdmin
(
@Validated
@RequestBody
SysTenantAdminBo
tenantAdminBo
)
{
if
(!
userService
.
checkPhoneUnique
(
BeanUtil
.
toBean
(
tenantAdminBo
,
SysUser
.
class
)))
{
//校验手机号是否已存在
if
(
TenantHelper
.
ignore
(()->
userService
.
checkTenantAdminPhoneUnique
(
tenantAdminBo
)))
{
return
R
.
fail
(
"新增用户'"
+
tenantAdminBo
.
getPhonenumber
()
+
"'失败,手机号码已存在"
);
return
R
.
fail
(
"新增用户'"
+
tenantAdminBo
.
getPhonenumber
()
+
"'失败,手机号码已存在"
);
}
}
return
toAjax
(
TenantHelper
.
ignore
(()
->
tenantService
.
addTenantAdmin
(
tenantAdminBo
)));
return
toAjax
(
TenantHelper
.
ignore
(()
->
tenantService
.
addTenantAdmin
(
tenantAdminBo
)));
//return R.ok("手机号验证成功");
}
}
/**
/**
...
...
dsk-admin/src/main/resources/application.yml
View file @
0ef1f2fc
...
@@ -140,7 +140,7 @@ security:
...
@@ -140,7 +140,7 @@ security:
-
/*/api-docs
-
/*/api-docs
-
/*/api-docs/**
-
/*/api-docs/**
# actuator 监控配置
# actuator 监控配置
-
/a
ctuator
-
/a
pi/**
-
/actuator/**
-
/actuator/**
...
@@ -300,3 +300,25 @@ management:
...
@@ -300,3 +300,25 @@ management:
show-details
:
ALWAYS
show-details
:
ALWAYS
logfile
:
logfile
:
external-file
:
./logs/sys-console.log
external-file
:
./logs/sys-console.log
gv
:
img-path
:
D:\dsk\dsk-operate-sys\
#spring:
# datasource:
# type: com.alibaba.druid.pool.DruidDataSource
# druid:
# driver-class-name: com.mysql.cj.jdbc.Driver
# username: ${MYSQL_USER:root}
# password: ${MYSQL_PWD:root}
# url: jdbc:mysql://${MYSQL_HOST:pigx-mysql}:${MYSQL_PORT:3306}/${MYSQL_DB:pigxx_report}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true
# jpa:
# database-platform:
# org.hibernate.dialect.MySQL8Dialectsecurity:
# oauth2:
# client:
# ignore-urls:
# - /
# - /api/project/getData
# - /static/**
# - /api/project/get-file/*
# # 文件上传路径
dsk-module/dsk-biz-bi/pom.xml
0 → 100644
View file @
0ef1f2fc
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns=
"http://maven.apache.org/POM/4.0.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<modelVersion>
4.0.0
</modelVersion>
<parent>
<artifactId>
dsk-module
</artifactId>
<groupId>
com.dsk
</groupId>
<version>
4.8.0
</version>
</parent>
<groupId>
com.dsk
</groupId>
<artifactId>
dsk-biz-bi
</artifactId>
<name>
dsk-biz-bi
</name>
<description>
BI数字大屏
</description>
<properties>
<java.version>
1.8
</java.version>
</properties>
<dependencies>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-web
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-test
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
com.dsk
</groupId>
<artifactId>
dsk-common
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-validation
</artifactId>
</dependency>
<!-- ORM -->
<dependency>
<groupId>
com.baomidou
</groupId>
<artifactId>
mybatis-plus-boot-starter
</artifactId>
<version>
${mybatis-plus.version}
</version>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-data-jpa
</artifactId>
</dependency>
<!-- hutool-core -->
<dependency>
<groupId>
cn.hutool
</groupId>
<artifactId>
hutool-core
</artifactId>
</dependency>
<!-- hutool-core -->
<dependency>
<groupId>
cn.hutool
</groupId>
<artifactId>
hutool-json
</artifactId>
</dependency>
<!-- hutool-http -->
<dependency>
<groupId>
cn.hutool
</groupId>
<artifactId>
hutool-http
</artifactId>
</dependency>
<!-- hutool-extra -->
<dependency>
<groupId>
cn.hutool
</groupId>
<artifactId>
hutool-extra
</artifactId>
</dependency>
<!--数据库-->
<dependency>
<groupId>
com.h2database
</groupId>
<artifactId>
h2
</artifactId>
<scope>
runtime
</scope>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-thymeleaf
</artifactId>
</dependency>
</dependencies>
<!-- <build>-->
<!-- <plugins>-->
<!-- <plugin>-->
<!-- <groupId>org.springframework.boot</groupId>-->
<!-- <artifactId>spring-boot-maven-plugin</artifactId>-->
<!-- <configuration>-->
<!-- <image>-->
<!-- <builder>paketobuildpacks/builder-jammy-base:latest</builder>-->
<!-- </image>-->
<!-- </configuration>-->
<!-- </plugin>-->
<!-- </plugins>-->
<!-- </build>-->
</project>
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/base/BaseController.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
base
;
import
cn.hutool.core.util.StrUtil
;
import
com.dsk.biz.goview.common.bean.AjaxResult
;
import
com.dsk.biz.goview.common.domain.ResultTable
;
import
org.springframework.beans.propertyeditors.CustomDateEditor
;
import
org.springframework.web.bind.WebDataBinder
;
import
org.springframework.web.bind.annotation.InitBinder
;
import
java.text.SimpleDateFormat
;
import
java.util.Date
;
/**
* web层通用数据处理
*
* @author fuce
* @ClassName: BaseController
* @date 2018年8月18日
*/
public
class
BaseController
{
/**
* 将前台传递过来的日期格式的字符串,自动转化为Date类型
*/
@InitBinder
public
void
initBinder
(
WebDataBinder
binder
)
{
SimpleDateFormat
dateFormat
=
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
);
dateFormat
.
setLenient
(
false
);
binder
.
registerCustomEditor
(
Date
.
class
,
new
CustomDateEditor
(
dateFormat
,
true
));
}
/**
* 响应返回结果
* @param rows 影响行数
* @return 操作结果
*/
protected
AjaxResult
toAjax
(
int
rows
)
{
return
rows
>
0
?
success
()
:
error
();
}
/**
* 返回成功
*/
public
AjaxResult
success
()
{
return
AjaxResult
.
success
();
}
/**
* 返回失败消息
*/
public
AjaxResult
error
()
{
return
AjaxResult
.
error
();
}
/**
* 返回成功消息
*/
public
AjaxResult
success
(
String
message
)
{
return
AjaxResult
.
success
(
message
);
}
/**
* 返回失败消息
*/
public
AjaxResult
error
(
String
message
)
{
return
AjaxResult
.
error
(
message
);
}
/**
* 返回错误码消息
*/
public
AjaxResult
error
(
int
code
,
String
message
)
{
return
AjaxResult
.
error
(
code
,
message
);
}
/**
* 返回object数据
*/
public
AjaxResult
retobject
(
int
code
,
Object
data
)
{
return
AjaxResult
.
successData
(
code
,
data
);
}
/**
* 页面跳转
*/
public
String
redirect
(
String
url
)
{
return
StrUtil
.
format
(
"redirect:{}"
,
url
);
}
/**
* Describe: 返回数据表格数据 分页 Param data Return 表格分页数据
*/
protected
static
ResultTable
pageTable
(
Object
data
,
long
count
)
{
return
ResultTable
.
pageTable
(
count
,
data
);
}
/**
* Describe: 返回数据表格数据 Param data Return 表格分页数据
*/
protected
static
ResultTable
dataTable
(
Object
data
)
{
return
ResultTable
.
dataTable
(
data
);
}
/**
* Describe: 返回树状表格数据 分页 Param data Return 表格分页数据
*/
protected
static
ResultTable
treeTable
(
Object
data
)
{
return
ResultTable
.
dataTable
(
data
);
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/base/BaseService.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
base
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
* 抽象类BaseService
*
* @ClassName: BaseService
* @Description: Service实现这个
* @author fuce
* @date 2018年6月3日
*
*/
public
interface
BaseService
<
T
,
T2
>
{
int
deleteByPrimaryKey
(
String
id
);
int
insertSelective
(
T
record
);
T
selectByPrimaryKey
(
String
id
);
int
updateByPrimaryKeySelective
(
T
record
);
int
updateByExampleSelective
(
@Param
(
"record"
)
T
record
,
@Param
(
"example"
)
T2
example
);
int
updateByExample
(
@Param
(
"record"
)
T
record
,
@Param
(
"example"
)
T2
example
);
List
<
T
>
selectByExample
(
T2
example
);
long
countByExample
(
T2
example
);
int
deleteByExample
(
T2
example
);
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/bean/AjaxResult.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
bean
;
import
java.util.HashMap
;
/**
* @ClassName: AjaxResult
* @Description: ajax操作消息提醒
* @author fuce
* @date 2018年8月18日
*
*/
public
class
AjaxResult
extends
HashMap
<
String
,
Object
>
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 初始化一个新创建的 Message 对象
*/
public
AjaxResult
()
{
}
/**
* 返回错误消息
* @return 错误消息
*/
public
static
AjaxResult
error
()
{
return
error
(
500
,
"操作失败"
);
}
/**
* 返回错误消息
* @param msg 内容
* @return 错误消息
*/
public
static
AjaxResult
error
(
String
msg
)
{
return
error
(
500
,
msg
);
}
/**
* 返回错误消息
* @param code 错误码
* @param msg 内容
* @return 错误消息
*/
public
static
AjaxResult
error
(
int
code
,
String
msg
)
{
AjaxResult
json
=
new
AjaxResult
();
json
.
put
(
"code"
,
code
);
json
.
put
(
"msg"
,
msg
);
return
json
;
}
/**
* 返回成功消息
* @param msg 内容
* @return 成功消息
*/
public
static
AjaxResult
success
(
String
msg
)
{
AjaxResult
json
=
new
AjaxResult
();
json
.
put
(
"msg"
,
msg
);
json
.
put
(
"code"
,
200
);
return
json
;
}
/**
* 返回成功消息
* @param msg 内容
* @return 成功消息
*/
public
static
AjaxResult
successNullData
(
String
msg
)
{
AjaxResult
json
=
new
AjaxResult
();
json
.
put
(
"msg"
,
msg
);
json
.
put
(
"data"
,
null
);
json
.
put
(
"code"
,
200
);
return
json
;
}
/**
* 返回成功消息
* @return 成功消息
*/
public
static
AjaxResult
success
()
{
return
AjaxResult
.
success
(
"操作成功"
);
}
public
static
AjaxResult
successData
(
int
code
,
Object
value
)
{
AjaxResult
json
=
new
AjaxResult
();
json
.
put
(
"code"
,
code
);
json
.
put
(
"data"
,
value
);
return
json
;
}
/**
* 返回成功消息
* @param key 键值
* @param value 内容
* @return 成功消息
*/
@Override
public
AjaxResult
put
(
String
key
,
Object
value
)
{
super
.
put
(
key
,
value
);
return
this
;
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/domain/GoviewProject.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
domain
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
javax.persistence.Entity
;
import
javax.persistence.Id
;
import
javax.persistence.Transient
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
@Data
@Entity
public
class
GoviewProject
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@Id
@TableId
(
type
=
IdType
.
ASSIGN_UUID
)
private
String
id
;
private
String
projectName
;
private
Integer
state
;
private
LocalDateTime
createTime
;
private
String
createUserId
;
private
Integer
isDelete
;
private
String
indexImage
;
private
String
remarks
;
private
Long
tenantId
;
@Transient
@TableField
(
exist
=
false
)
private
String
content
;
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/domain/GoviewProjectData.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
domain
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
javax.persistence.*
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
@Data
@Entity
public
class
GoviewProjectData
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@Id
@TableId
(
type
=
IdType
.
ASSIGN_UUID
)
private
String
id
;
private
String
projectId
;
private
LocalDateTime
createTime
;
private
String
createUserId
;
private
Long
tenantId
;
@Lob
@Basic
(
fetch
=
FetchType
.
LAZY
)
@Column
(
columnDefinition
=
"TEXT"
)
private
String
content
;
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/domain/MagicHttp.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
domain
;
import
java.util.Map
;
public
class
MagicHttp
{
/**
* 请求url
*/
private
String
url
;
/**
* 请求类型 get post
*/
private
String
requestType
;
private
Map
<
String
,
String
>
head
;
private
String
body
;
private
Integer
timeout
;
private
Map
<
String
,
Object
>
form
;
private
String
cookie
;
public
String
getUrl
()
{
return
url
;
}
public
void
setUrl
(
String
url
)
{
this
.
url
=
url
;
}
public
String
getRequestType
()
{
return
requestType
;
}
public
void
setRequestType
(
String
requestType
)
{
this
.
requestType
=
requestType
;
}
public
Map
<
String
,
String
>
getHead
()
{
return
head
;
}
public
void
setHead
(
Map
<
String
,
String
>
head
)
{
this
.
head
=
head
;
}
public
String
getBody
()
{
return
body
;
}
public
void
setBody
(
String
body
)
{
this
.
body
=
body
;
}
public
String
getCookie
()
{
return
cookie
;
}
public
void
setCookie
(
String
cookie
)
{
this
.
cookie
=
cookie
;
}
public
Integer
getTimeout
()
{
return
timeout
;
}
public
void
setTimeout
(
Integer
timeout
)
{
this
.
timeout
=
timeout
;
}
public
Map
<
String
,
Object
>
getForm
()
{
return
form
;
}
public
void
setForm
(
Map
<
String
,
Object
>
form
)
{
this
.
form
=
form
;
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/domain/ResultTable.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
domain
;
public
class
ResultTable
{
/**
* 状态码
*/
private
Integer
code
;
/**
* 提示消息
*/
private
String
msg
;
/**
* 消息总量
*/
private
Long
count
;
/**
* 数据对象
*/
private
Object
data
;
public
Integer
getCode
()
{
return
code
;
}
public
void
setCode
(
Integer
code
)
{
this
.
code
=
code
;
}
public
String
getMsg
()
{
return
msg
;
}
public
void
setMsg
(
String
msg
)
{
this
.
msg
=
msg
;
}
public
Long
getCount
()
{
return
count
;
}
public
void
setCount
(
Long
count
)
{
this
.
count
=
count
;
}
public
Object
getData
()
{
return
data
;
}
public
void
setData
(
Object
data
)
{
this
.
data
=
data
;
}
/**
* 构 建
*/
public
static
ResultTable
pageTable
(
long
count
,
Object
data
)
{
ResultTable
resultTable
=
new
ResultTable
();
resultTable
.
setData
(
data
);
resultTable
.
setCode
(
0
);
resultTable
.
setCount
(
count
);
if
(
data
!=
null
)
{
resultTable
.
setMsg
(
"获取成功"
);
}
else
{
resultTable
.
setMsg
(
"获取失败"
);
}
return
resultTable
;
}
public
static
ResultTable
dataTable
(
Object
data
)
{
ResultTable
resultTable
=
new
ResultTable
();
resultTable
.
setData
(
data
);
resultTable
.
setCode
(
0
);
if
(
data
!=
null
)
{
resultTable
.
setMsg
(
"获取成功"
);
}
else
{
resultTable
.
setMsg
(
"获取失败"
);
}
return
resultTable
;
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/common/domain/Tablepar.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
common
.
domain
;
/**
* boostrap table post 参数
*
* @author fc
*
*/
public
class
Tablepar
{
private
int
page
;
// 页码
private
int
limit
;
// 数量
private
String
orderByColumn
;
// 排序字段
private
String
isAsc
;
// 排序字符 asc desc
private
String
searchText
;
// 列表table里面的搜索
public
int
getPage
()
{
return
page
;
}
public
void
setPage
(
int
page
)
{
this
.
page
=
page
;
}
public
int
getLimit
()
{
return
limit
;
}
public
void
setLimit
(
int
limit
)
{
this
.
limit
=
limit
;
}
public
String
getOrderByColumn
()
{
return
orderByColumn
;
}
public
void
setOrderByColumn
(
String
orderByColumn
)
{
this
.
orderByColumn
=
orderByColumn
;
}
public
String
getIsAsc
()
{
return
isAsc
;
}
public
void
setIsAsc
(
String
isAsc
)
{
this
.
isAsc
=
isAsc
;
}
public
String
getSearchText
()
{
return
searchText
;
}
public
void
setSearchText
(
String
searchText
)
{
this
.
searchText
=
searchText
;
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/config/DataVTenantHandler.java
0 → 100644
View file @
0ef1f2fc
///*
// * Copyright (c) 2018-2025, lengleng All rights reserved.
// *
// * Redistribution and use in source and binary forms, with or without
// * modification, are permitted provided that the following conditions are met:
// *
// * Redistributions of source code must retain the above copyright notice,
// * this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above copyright
// * notice, this list of conditions and the following disclaimer in the
// * documentation and/or other materials provided with the distribution.
// * Neither the name of the pig4cloud.com developer nor the names of its
// * contributors may be used to endorse or promote products derived from
// * this software without specific prior written permission.
// * Author: lengleng (wangiegie@gmail.com)
// */
//
//package com.dsk.biz.goview.config;
//
//import com.baomidou.mybatisplus.extension.plugins.handler.TenantLineHandler;
//import lombok.RequiredArgsConstructor;
//import lombok.extern.slf4j.Slf4j;
//import net.sf.jsqlparser.expression.Expression;
//import net.sf.jsqlparser.expression.LongValue;
//import net.sf.jsqlparser.expression.NullValue;
//
///**
// * @author lengleng
// * @date 2018-12-26
// * <p>
// * 租户维护处理器
// */
//@Slf4j
//@RequiredArgsConstructor
//public class DataVTenantHandler implements TenantLineHandler {
//
// /**
// * 获取租户 ID 值表达式,只支持单个 ID 值
// * <p>
// * @return 租户 ID 值表达式
// */
// @Override
// public Expression getTenantId() {
// Long tenantId = TenantContextHolder.getTenantId();
// log.debug("当前租户为 >> {}", tenantId);
//
// if (tenantId == null) {
// return new NullValue();
// }
// return new LongValue(tenantId);
// }
//
//}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/config/GoviewProperties.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
config
;
import
lombok.Data
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.stereotype.Component
;
/**
* @author lengleng
* @date 2022/5/2
* <p>
* 数据大屏配置
*/
@Data
//@ConfigurationProperties("gv")
@Component
@ConfigurationProperties
(
prefix
=
"gv"
)
public
class
GoviewProperties
{
/**
* 服务 http://IP:port
*/
private
String
host
=
""
;
/**
* 路由前缀
*/
private
String
gatewayPrefix
=
"/api/gv"
;
/**
* 图片存放路径
*/
private
String
imgPath
;
/**
* 项目 license
*/
private
String
license
;
/**
* 是否开启检查更新
*/
private
boolean
checkUpdate
=
true
;
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/config/MybatisAutoConfiguration.java
0 → 100644
View file @
0ef1f2fc
///*
// * Copyright (c) 2020 pig4cloud Authors. All Rights Reserved.
// *
// * Licensed under the Apache License, Version 2.0 (the "License");
// * you may not use this file except in compliance with the License.
// * You may obtain a copy of the License at
// *
// * http://www.apache.org/licenses/LICENSE-2.0
// *
// * Unless required by applicable law or agreed to in writing, software
// * distributed under the License is distributed on an "AS IS" BASIS,
// * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// * See the License for the specific language governing permissions and
// * limitations under the License.
// */
//
//package com.dsk.biz.goview.config;
//
//import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
//import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
//import com.baomidou.mybatisplus.extension.plugins.inner.TenantLineInnerInterceptor;
//import org.mybatis.spring.annotation.MapperScan;
//import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
//import org.springframework.boot.autoconfigure.domain.EntityScan;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//
///**
// * @author lengleng
// * @date 2020-03-14
// * <p>
// * mybatis plus 统一配置
// */
//@Configuration(proxyBeanMethods = false)
//@MapperScan(basePackages = "io.springboot.plugin.goview.mapper")
//@EntityScan(basePackages = "io.springboot.plugin.goview.common.domain")
//public class MybatisAutoConfiguration {
//
// @Bean
// public TenantContextHolderFilter tenantContextHolderFilter() {
// return new TenantContextHolderFilter();
// }
//
// /**
// * 分页插件, 对于单一数据库类型来说,都建议配置该值,避免每次分页都去抓取数据库类型
// */
// @Bean
// @ConditionalOnMissingBean
// public MybatisPlusInterceptor mybatisPlusInterceptor() {
// MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
// interceptor.addInnerInterceptor(new TenantLineInnerInterceptor(new DataVTenantHandler()));
// interceptor.addInnerInterceptor(new PaginationInnerInterceptor());
// return interceptor;
// }
//
//}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/config/YamlPropertySourceFactory.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
config
;
import
org.springframework.beans.factory.config.YamlPropertiesFactoryBean
;
import
org.springframework.core.env.PropertiesPropertySource
;
import
org.springframework.core.env.PropertySource
;
import
org.springframework.core.io.support.EncodedResource
;
import
org.springframework.core.io.support.PropertySourceFactory
;
import
org.springframework.lang.Nullable
;
import
java.io.FileNotFoundException
;
import
java.io.IOException
;
import
java.util.Properties
;
/**
* @author lengleng
* @date 2023/4/5
*/
public
class
YamlPropertySourceFactory
implements
PropertySourceFactory
{
@Override
public
PropertySource
<?>
createPropertySource
(
@Nullable
String
name
,
EncodedResource
resource
)
throws
IOException
{
Properties
propertiesFromYaml
=
loadYamlIntoProperties
(
resource
);
String
sourceName
=
name
!=
null
?
name
:
resource
.
getResource
().
getFilename
();
return
new
PropertiesPropertySource
(
sourceName
,
propertiesFromYaml
);
}
private
Properties
loadYamlIntoProperties
(
EncodedResource
resource
)
throws
FileNotFoundException
{
try
{
YamlPropertiesFactoryBean
factory
=
new
YamlPropertiesFactoryBean
();
factory
.
setResources
(
resource
.
getResource
());
factory
.
afterPropertiesSet
();
return
factory
.
getObject
();
}
catch
(
IllegalStateException
e
)
{
Throwable
cause
=
e
.
getCause
();
if
(
cause
instanceof
FileNotFoundException
)
throw
(
FileNotFoundException
)
e
.
getCause
();
throw
e
;
}
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/controller/GoViewProjectAPIController.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
controller
;
import
cn.hutool.core.collection.CollUtil
;
import
cn.hutool.core.util.StrUtil
;
import
com.baomidou.mybatisplus.core.plugins.IgnoreStrategy
;
import
com.baomidou.mybatisplus.core.plugins.InterceptorIgnoreHelper
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.dsk.biz.goview.common.base.BaseController
;
import
com.dsk.biz.goview.common.bean.AjaxResult
;
import
com.dsk.biz.goview.common.domain.*
;
import
com.dsk.biz.goview.config.GoviewProperties
;
import
com.dsk.biz.goview.mapper.GoviewProjectDataMapper
;
import
com.dsk.biz.goview.mapper.GoviewProjectMapper
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.http.ContentDisposition
;
import
org.springframework.http.HttpHeaders
;
import
org.springframework.http.HttpStatus
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.ui.ModelMap
;
import
org.springframework.util.FileCopyUtils
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.multipart.MultipartFile
;
import
java.io.File
;
import
java.io.IOException
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
* 项目表Controller
*
* @author fuce
* @ClassName: GoviewProjectController
* @date 2022-05-18 21:43:25
*/
@Slf4j
@RestController
@RequiredArgsConstructor
@RequestMapping
(
"/api/goview/project"
)
public
class
GoViewProjectAPIController
extends
BaseController
{
private
final
GoviewProjectDataMapper
projectDataMapper
;
private
final
GoviewProjectMapper
projectMapper
;
private
final
GoviewProperties
goviewProperties
;
@GetMapping
(
"/list"
)
public
ResultTable
list
(
Tablepar
tablepar
,
GoviewProject
goviewProject
)
{
Page
page
=
new
Page
(
tablepar
.
getPage
(),
tablepar
.
getLimit
());
Page
result
=
projectMapper
.
selectPage
(
page
,
Wrappers
.
query
(
goviewProject
));
ResultTable
resultTable
=
pageTable
(
result
.
getRecords
(),
result
.
getTotal
());
resultTable
.
setCode
(
200
);
return
resultTable
;
}
/**
* 新增保存
* @param
* @return
*/
@PostMapping
(
"/create"
)
public
AjaxResult
add
(
@RequestBody
GoviewProject
goviewProject
)
{
projectMapper
.
insert
(
goviewProject
);
return
AjaxResult
.
successData
(
200
,
goviewProject
).
put
(
"msg"
,
"创建成功"
);
}
/**
* 项目表删除
* @param ids
* @return
*/
@DeleteMapping
(
"/delete"
)
public
AjaxResult
delete
(
String
ids
)
{
projectMapper
.
deleteById
(
ids
);
return
success
();
}
@PostMapping
(
"/edit"
)
public
AjaxResult
editSave
(
@RequestBody
GoviewProject
goviewProject
)
{
projectMapper
.
updateById
(
goviewProject
);
return
success
();
}
@PostMapping
(
"/rename"
)
public
AjaxResult
rename
(
@RequestBody
GoviewProject
goviewProject
)
{
projectMapper
.
updateById
(
goviewProject
);
return
success
();
}
// 发布/取消项目状态
@PutMapping
(
"/publish"
)
@ResponseBody
public
AjaxResult
updateVisible
(
@RequestBody
GoviewProject
goviewProject
)
{
projectMapper
.
updateById
(
goviewProject
);
return
success
();
}
/**
* 获取项目存储数据
* @param id 项目id
* @param mmap
* @return
*/
@GetMapping
(
"/getData"
)
public
AjaxResult
getData
(
String
projectId
,
ModelMap
map
)
{
InterceptorIgnoreHelper
.
handle
(
IgnoreStrategy
.
builder
().
tenantLine
(
true
).
build
());
GoviewProject
goviewProject
=
projectMapper
.
selectById
(
projectId
);
if
(
goviewProject
==
null
)
{
return
AjaxResult
.
successData
(
200
,
null
).
put
(
"msg"
,
"无数据"
);
}
List
<
GoviewProjectData
>
goviewProjectDataList
=
projectDataMapper
.
selectList
(
Wrappers
.<
GoviewProjectData
>
lambdaQuery
().
eq
(
GoviewProjectData:
:
getProjectId
,
projectId
));
if
(
CollUtil
.
isNotEmpty
(
goviewProjectDataList
))
{
goviewProject
.
setContent
(
goviewProjectDataList
.
get
(
0
).
getContent
());
return
AjaxResult
.
successData
(
200
,
goviewProject
).
put
(
"msg"
,
"获取成功"
);
}
return
AjaxResult
.
successData
(
200
,
null
).
put
(
"msg"
,
"无数据"
);
}
@PostMapping
(
"/save/data"
)
public
AjaxResult
saveData
(
GoviewProjectData
data
)
{
boolean
exists
=
projectDataMapper
.
exists
(
Wrappers
.<
GoviewProjectData
>
lambdaQuery
().
eq
(
GoviewProjectData:
:
getProjectId
,
data
.
getProjectId
()));
if
(
exists
)
{
projectDataMapper
.
update
(
data
,
Wrappers
.<
GoviewProjectData
>
lambdaQuery
().
eq
(
GoviewProjectData:
:
getProjectId
,
data
.
getProjectId
()));
}
else
{
projectDataMapper
.
insert
(
data
);
}
return
AjaxResult
.
success
(
"操作成功"
);
}
/**
* 模拟请求
* @return
*/
@PostMapping
(
"/magicHttp"
)
public
AjaxResult
magicHttp
(
@RequestBody
MagicHttp
magicHttp
)
{
return
AjaxResult
.
successNullData
(
"参数异常为null"
);
}
/**
* 上传文件
* @param file 文件流对象
* @return
* @throws Exception
*/
@PostMapping
(
"/upload"
)
@ResponseBody
public
AjaxResult
upload
(
@RequestBody
MultipartFile
object
)
throws
IOException
{
File
dest
=
new
File
(
goviewProperties
.
getImgPath
()
+
object
.
getOriginalFilename
());
object
.
transferTo
(
dest
);
Map
<
String
,
String
>
map
=
new
HashMap
(
4
);
String
url
;
if
(
StrUtil
.
isNotBlank
(
goviewProperties
.
getHost
()))
{
url
=
goviewProperties
.
getHost
()
+
goviewProperties
.
getGatewayPrefix
()
+
"/api/project/get-file/"
+
object
.
getOriginalFilename
();
}
else
{
url
=
goviewProperties
.
getGatewayPrefix
()
+
"/api/project/get-file/"
+
object
.
getOriginalFilename
();
}
map
.
put
(
"link"
,
url
);
return
AjaxResult
.
successData
(
200
,
map
);
}
/**
* 文件获取
* @param fileName 文件名
*/
@GetMapping
(
"/get-file/{fileName}"
)
public
ResponseEntity
<
byte
[]>
getFile
(
@PathVariable
String
fileName
)
{
HttpHeaders
headers
=
new
HttpHeaders
();
// 通知浏览器以下载文件方式打开
ContentDisposition
contentDisposition
=
ContentDisposition
.
builder
(
"attachment"
).
filename
(
fileName
).
build
();
headers
.
setContentDisposition
(
contentDisposition
);
try
{
return
new
ResponseEntity
<>(
FileCopyUtils
.
copyToByteArray
(
new
File
(
goviewProperties
.
getImgPath
()
+
fileName
)),
headers
,
HttpStatus
.
OK
);
}
catch
(
IOException
e
)
{
log
.
warn
(
e
.
getLocalizedMessage
());
}
return
null
;
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/controller/GoviewPageController.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
controller
;
import
cn.dev33.satoken.annotation.SaIgnore
;
import
com.dsk.biz.goview.common.bean.AjaxResult
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
static
com
.
dsk
.
biz
.
goview
.
common
.
bean
.
AjaxResult
.
success
;
/**
* @author lengleng
* @date 2022/5/21
*/
@Slf4j
@Controller
@RequestMapping
@RequiredArgsConstructor
public
class
GoviewPageController
{
@SaIgnore
@GetMapping
({
"/"
,
"/chart/**"
,
"/project/**"
})
public
String
index
()
{
return
"index"
;
}
@GetMapping
(
"/api/goview/sys/getOssInfo"
)
@ResponseBody
public
AjaxResult
getOssInfo
()
{
return
success
();
}
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/mapper/GoviewProjectDataMapper.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.dsk.biz.goview.common.domain.GoviewProjectData
;
import
org.apache.ibatis.annotations.Mapper
;
/**
* @author lengleng
* @date 2023/4/4
*/
@Mapper
public
interface
GoviewProjectDataMapper
extends
BaseMapper
<
GoviewProjectData
>
{
}
dsk-module/dsk-biz-bi/src/main/java/com/dsk/biz/goview/mapper/GoviewProjectMapper.java
0 → 100644
View file @
0ef1f2fc
package
com
.
dsk
.
biz
.
goview
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.dsk.biz.goview.common.domain.GoviewProject
;
import
org.apache.ibatis.annotations.Mapper
;
/**
* @author lengleng
* @date 2023/4/4
*/
@Mapper
public
interface
GoviewProjectMapper
extends
BaseMapper
<
GoviewProject
>
{
}
dsk-module/dsk-biz-bi/src/main/resources/templates/index.html
0 → 100644
View file @
0ef1f2fc
<!DOCTYPE html>
<html
lang=
"zh-cmn-Hans"
>
<head>
<script>
self
[
"MonacoEnvironment"
]
=
(
function
(
paths
)
{
return
{
globalAPI
:
false
,
getWorkerUrl
:
function
(
moduleId
,
label
)
{
var
result
=
paths
[
label
];
if
(
/^
((
http:
)
|
(
https:
)
|
(
file:
)
|
(\/\/))
/
.
test
(
result
))
{
var
currentUrl
=
String
(
window
.
location
);
var
currentOrigin
=
currentUrl
.
substr
(
0
,
currentUrl
.
length
-
window
.
location
.
hash
.
length
-
window
.
location
.
search
.
length
-
window
.
location
.
pathname
.
length
);
if
(
result
.
substring
(
0
,
currentOrigin
.
length
)
!==
currentOrigin
)
{
var
js
=
'/*'
+
label
+
'*/importScripts("'
+
result
+
'");'
;
var
blob
=
new
Blob
([
js
],
{
type
:
'application/javascript'
});
return
URL
.
createObjectURL
(
blob
);
}
}
return
result
;
}
};
})({
"editorWorkerService"
:
"/api/gv/monacoeditorwork/editor.worker.bundle.js"
,
"typescript"
:
"/api/gv/monacoeditorwork/ts.worker.bundle.js"
,
"json"
:
"/api/gv/monacoeditorwork/json.worker.bundle.js"
,
"html"
:
"/api/gv/monacoeditorwork/html.worker.bundle.js"
,
"javascript"
:
"/api/gv/monacoeditorwork/ts.worker.bundle.js"
,
"handlebars"
:
"/api/gv/monacoeditorwork/html.worker.bundle.js"
,
"razor"
:
"/api/gv/monacoeditorwork/html.worker.bundle.js"
});
</script>
<meta
charset=
"UTF-8"
/>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge,chrome=1"
/>
<meta
name=
"renderer"
content=
"webkit"
/>
<meta
name=
"description"
content=
"GoView 是高效、高性能的拖拽式低代码数据可视化开发平台,将页面元素封装为基础组件,无需编写代码即可完成业务需求。"
>
<meta
name=
"keywords"
content=
"GoView,goview,低代码,可视化"
>
<meta
name=
"author"
content=
"奔跑的面条,面条"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0"
/>
<link
rel=
"icon"
href=
"./favicon.ico"
/>
<title>
GoView
</title>
<script
type=
"module"
crossorigin
src=
"/api/gv/static/js/index-ebdecea3.js"
></script>
<link
rel=
"stylesheet"
href=
"/api/gv/static/css/index-9c2eb289.css"
>
</head>
<body>
<div
id=
"appProvider"
style=
"display: none;"
></div>
<div
id=
"app"
>
<div
class=
"first-loading-wrp"
>
<div
class=
"loading-wrp"
>
<span
class=
"dot dot-spin"
><i></i><i></i><i></i><i></i></span>
</div>
</div>
</div>
</body>
</html>
dsk-module/pom.xml
View file @
0ef1f2fc
...
@@ -22,6 +22,7 @@
...
@@ -22,6 +22,7 @@
<modules>
<modules>
<module>
dsk-biz-api
</module>
<module>
dsk-biz-api
</module>
<module>
dsk-biz-bi
</module>
</modules>
</modules>
<build>
<build>
...
...
dsk-operate-ui/.env.production
View file @
0ef1f2fc
dsk-operate-ui/src/assets/styles/index.scss
View file @
0ef1f2fc
...
@@ -322,14 +322,14 @@ li {
...
@@ -322,14 +322,14 @@ li {
.table-item
{
.table-item
{
width
:
100%
;
width
:
100%
;
.el-table
{
.el-table
{
font-size
:
1
3
px
;
font-size
:
1
4
px
;
color
:
#232323
;
color
:
#232323
;
th
{
th
{
font-size
:
13px
!
important
;
font-size
:
13px
!
important
;
font-weight
:
400
!
important
;
font-weight
:
400
!
important
;
}
}
td
{
td
{
font-size
:
1
3
px
;
font-size
:
1
4
px
;
}
}
.cell
{
.cell
{
padding-right
:
12px
!
important
;
padding-right
:
12px
!
important
;
...
...
dsk-operate-ui/src/assets/styles/public.scss
View file @
0ef1f2fc
...
@@ -762,7 +762,7 @@ select {
...
@@ -762,7 +762,7 @@ select {
.checkbox
.el-checkbox__label
{
.checkbox
.el-checkbox__label
{
padding-left
:
6px
;
padding-left
:
6px
;
color
:
#
232323
;
color
:
#
606266
;
}
}
.checkbox
.checkbox-content
.checkbox-content-qx
{
.checkbox
.checkbox-content
.checkbox-content-qx
{
...
@@ -1171,11 +1171,11 @@ select {
...
@@ -1171,11 +1171,11 @@ select {
.table-item
.el-table
tr
,
.table-item
.el-table
tr
,
.table-item
.el-table
td
{
.table-item
.el-table
td
{
font-size
:
1
3
px
;
font-size
:
1
4
px
;
}
}
.table-item-jf
.el-table
tr
,
.table-item-jf
.el-table
tr
,
.table-item-jf
.el-table
td
{
.table-item-jf
.el-table
td
{
font-size
:
1
3
px
;
font-size
:
1
4
px
;
}
}
...
...
dsk-operate-ui/src/assets/styles/ruoyi.scss
View file @
0ef1f2fc
...
@@ -145,7 +145,8 @@
...
@@ -145,7 +145,8 @@
}
}
.el-table
.el-dropdown
,
.el-icon-arrow-down
{
.el-table
.el-dropdown
,
.el-icon-arrow-down
{
font-size
:
12px
;
color
:
#232323
;
font-size
:
14px
;
}
}
.el-tree-node__content
>
.el-checkbox
{
.el-tree-node__content
>
.el-checkbox
{
...
...
dsk-operate-ui/src/router/index.js
View file @
0ef1f2fc
...
@@ -28,6 +28,7 @@ import Layout from '@/layout';
...
@@ -28,6 +28,7 @@ import Layout from '@/layout';
}
}
*/
*/
// 公共路由
// 公共路由
export
const
constantRoutes
=
[
export
const
constantRoutes
=
[
{
{
...
...
dsk-operate-ui/src/views/detail/party-a/index.vue
View file @
0ef1f2fc
...
@@ -377,6 +377,7 @@ export default {
...
@@ -377,6 +377,7 @@ export default {
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.part-container
{
.part-container
{
padding
:
0
;
padding
:
0
;
margin
:
0
24px
;
}
}
.part-main
{
.part-main
{
margin-top
:
12px
;
margin-top
:
12px
;
...
...
dsk-operate-ui/src/views/enterpriseData/components/searchTheOwner/index.vue
View file @
0ef1f2fc
...
@@ -842,7 +842,7 @@ export default {
...
@@ -842,7 +842,7 @@ export default {
.
el
-
checkbox
-
group
{
.
el
-
checkbox
-
group
{
.
el
-
checkbox
{
.
el
-
checkbox
{
.
el
-
checkbox__label
{
.
el
-
checkbox__label
{
color
:
#
333333
;
color
:
#
606266
;
}
}
&
.
is
-
checked
{
&
.
is
-
checked
{
.
el
-
checkbox__label
{
.
el
-
checkbox__label
{
...
...
dsk-operate-ui/src/views/macro/urban/index.vue
View file @
0ef1f2fc
...
@@ -289,7 +289,6 @@
...
@@ -289,7 +289,6 @@
import
skeleton
from
'../component/skeleton'
import
skeleton
from
'../component/skeleton'
import
dataRegion
from
'@/assets/json/dataRegion'
import
dataRegion
from
'@/assets/json/dataRegion'
import
api
from
'@/api/enterpriseData/enterpriseData.js'
;
import
api
from
'@/api/enterpriseData/enterpriseData.js'
;
import
elementResizeDetectorMaker
from
"element-resize-detector"
import
{
uipGroupData
,
urbanInvestmentPage
,
urbanInvestmentStatistics
,
claim
,
location
,
customerStatus
,
historyClaim
}
from
'@/api/macro/macro'
import
{
uipGroupData
,
urbanInvestmentPage
,
urbanInvestmentStatistics
,
claim
,
location
,
customerStatus
,
historyClaim
}
from
'@/api/macro/macro'
import
{
infoHeader
}
from
'@/api/detail/party-a/index'
import
{
infoHeader
}
from
'@/api/detail/party-a/index'
import
Region
from
'../component/region'
import
Region
from
'../component/region'
...
...
dsk-operate-ui/src/views/radar/components/MajorProject/index.vue
View file @
0ef1f2fc
...
@@ -93,8 +93,8 @@
...
@@ -93,8 +93,8 @@
<el-checkbox
v-if=
"index
<showNum
"
:label=
"item"
:key=
"index"
>
{{
item
}}
</el-checkbox>
<el-checkbox
v-if=
"index
<showNum
"
:label=
"item"
:key=
"index"
>
{{
item
}}
</el-checkbox>
</
template
>
</
template
>
</el-checkbox-group>
</el-checkbox-group>
<
span
class=
"more"
v-if=
"showNum==10"
@
click=
"showNum=99"
>
更多
<img
src=
"@/assets/images/more.png"
alt=
""
></span
>
<
!--<span class="more" v-if="showNum==10" @click="showNum=99">更多<img src="@/assets/images/more.png" alt=""></span>--
>
<
span
class=
"more more1"
v-if=
"showNum==99"
@
click=
"showNum=10"
>
收起
<img
src=
"@/assets/images/more.png"
alt=
""
></span
>
<
!--<span class="more more1" v-if="showNum==99" @click="showNum=10">收起<img src="@/assets/images/more.png" alt=""></span>--
>
</div>
</div>
</div>
</div>
<div
class=
"content_item content_item_padding0"
>
<div
class=
"content_item content_item_padding0"
>
...
@@ -811,6 +811,9 @@ export default {
...
@@ -811,6 +811,9 @@ export default {
.ename_input
{
.ename_input
{
width
:
240px
;
width
:
240px
;
margin-right
:
20px
;
margin-right
:
20px
;
::v-deep
.el-input__inner
::placeholder
{
color
:
rgba
(
35
,
35
,
35
,
0
.2
)
!
important
;
}
}
}
.keyword_checkbox
{
.keyword_checkbox
{
margin-top
:
6px
;
margin-top
:
6px
;
...
@@ -819,7 +822,7 @@ export default {
...
@@ -819,7 +822,7 @@ export default {
display
:
inline-block
;
display
:
inline-block
;
}
}
.checkbox_1122
{
.checkbox_1122
{
width
:
1122px
;
/*width: 1122px;*/
margin-right
:
6px
;
margin-right
:
6px
;
}
}
.el-checkbox
{
.el-checkbox
{
...
...
dsk-system/src/main/java/com/dsk/system/service/ISysUserService.java
View file @
0ef1f2fc
...
@@ -3,6 +3,7 @@ package com.dsk.system.service;
...
@@ -3,6 +3,7 @@ package com.dsk.system.service;
import
com.dsk.common.core.domain.PageQuery
;
import
com.dsk.common.core.domain.PageQuery
;
import
com.dsk.system.domain.SysUser
;
import
com.dsk.system.domain.SysUser
;
import
com.dsk.common.core.page.TableDataInfo
;
import
com.dsk.common.core.page.TableDataInfo
;
import
com.dsk.system.domain.bo.SysTenantAdminBo
;
import
com.dsk.system.domain.vo.SysUserImportVo
;
import
com.dsk.system.domain.vo.SysUserImportVo
;
import
java.util.List
;
import
java.util.List
;
...
@@ -103,6 +104,14 @@ public interface ISysUserService {
...
@@ -103,6 +104,14 @@ public interface ISysUserService {
*/
*/
boolean
checkPhoneUnique
(
SysUser
user
);
boolean
checkPhoneUnique
(
SysUser
user
);
/**
* 校验企业普通管理员手机号码是否唯一
*
* @param tenantAdminBo 用户信息
* @return 结果
*/
boolean
checkTenantAdminPhoneUnique
(
SysTenantAdminBo
tenantAdminBo
);
/**
/**
* 校验email是否唯一
* 校验email是否唯一
*
*
...
...
dsk-system/src/main/java/com/dsk/system/service/impl/ISysTenantServiceImpl.java
View file @
0ef1f2fc
...
@@ -16,6 +16,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...
@@ -16,6 +16,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.dsk.common.constant.CacheNames
;
import
com.dsk.common.constant.CacheNames
;
import
com.dsk.common.constant.Constants
;
import
com.dsk.common.constant.Constants
;
import
com.dsk.common.constant.TenantConstants
;
import
com.dsk.common.constant.TenantConstants
;
import
com.dsk.common.constant.UserConstants
;
import
com.dsk.common.core.domain.PageQuery
;
import
com.dsk.common.core.domain.PageQuery
;
import
com.dsk.common.core.domain.entity.SysDictData
;
import
com.dsk.common.core.domain.entity.SysDictData
;
import
com.dsk.common.core.domain.entity.SysDictType
;
import
com.dsk.common.core.domain.entity.SysDictType
;
...
@@ -281,20 +282,33 @@ public class ISysTenantServiceImpl implements ISysTenantService {
...
@@ -281,20 +282,33 @@ public class ISysTenantServiceImpl implements ISysTenantService {
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Boolean
addTenantAdmin
(
SysTenantAdminBo
tenantAdminBo
)
{
public
Boolean
addTenantAdmin
(
SysTenantAdminBo
tenantAdminBo
)
{
String
tenantId
=
tenantAdminBo
.
getTenantId
();
String
tenantId
=
tenantAdminBo
.
getTenantId
();
// 根据套餐创建角色
Long
roleId
=
createTenantRole
(
tenantId
,
tenantAdminBo
.
getPackageId
(),
TenantConstants
.
TENANT_ADMIN_ROLE_NAME
,
TenantConstants
.
TENANT_ADMIN_ROLE_KEY
);
//获取部门ID
//获取部门ID
Long
deptId
=
deptMapper
.
selectOne
(
new
LambdaQueryWrapper
<
SysDept
>()
Long
deptId
=
deptMapper
.
selectOne
(
new
LambdaQueryWrapper
<
SysDept
>()
.
eq
(
SysDept:
:
getTenantId
,
tenantId
)).
getDeptId
();
.
eq
(
SysDept:
:
getTenantId
,
tenantId
)).
getDeptId
();
SysRole
sysRole
=
roleMapper
.
selectOne
(
new
LambdaQueryWrapper
<
SysRole
>()
.
eq
(
SysRole:
:
getStatus
,
UserConstants
.
ROLE_NORMAL
)
.
eq
(
SysRole:
:
getDelFlag
,
UserConstants
.
ROLE_NORMAL
)
.
eq
(
SysRole:
:
getTenantId
,
tenantId
)
.
eq
(
SysRole:
:
getRoleKey
,
TenantConstants
.
TENANT_ADMIN_ROLE_KEY
));
Long
roleId
=
null
;
//校验当前企业是否已存在普通管理员角色
if
(
ObjectUtil
.
isNull
(
sysRole
))
{
//不存在,则根据套餐创建角色
roleId
=
createTenantRole
(
tenantId
,
tenantAdminBo
.
getPackageId
(),
TenantConstants
.
TENANT_ADMIN_ROLE_NAME
,
TenantConstants
.
TENANT_ADMIN_ROLE_KEY
);
// 角色和部门关联表
// 角色和部门关联表
SysRoleDept
roleDept
=
new
SysRoleDept
();
SysRoleDept
roleDept
=
new
SysRoleDept
();
roleDept
.
setRoleId
(
roleId
);
roleDept
.
setRoleId
(
roleId
);
roleDept
.
setDeptId
(
deptId
);
roleDept
.
setDeptId
(
deptId
);
roleDeptMapper
.
insert
(
roleDept
);
roleDeptMapper
.
insert
(
roleDept
);
}
else
{
roleId
=
sysRole
.
getRoleId
();
}
// 创建系统用户
// 创建系统用户
SysUser
user
=
new
SysUser
();
SysUser
user
=
new
SysUser
();
...
@@ -316,25 +330,9 @@ public class ISysTenantServiceImpl implements ISysTenantService {
...
@@ -316,25 +330,9 @@ public class ISysTenantServiceImpl implements ISysTenantService {
userRole
.
setRoleId
(
roleId
);
userRole
.
setRoleId
(
roleId
);
userRoleMapper
.
insert
(
userRole
);
userRoleMapper
.
insert
(
userRole
);
String
defaultTenantId
=
TenantConstants
.
DEFAULT_TENANT_ID
;
//List<SysDictType> dictTypeList = dictTypeMapper.selectList(
// new LambdaQueryWrapper<SysDictType>().eq(SysDictType::getTenantId, defaultTenantId));
//List<SysDictData> dictDataList = dictDataMapper.selectList(
// new LambdaQueryWrapper<SysDictData>().eq(SysDictData::getTenantId, defaultTenantId));
//for (SysDictType dictType : dictTypeList) {
// dictType.setDictId(null);
// dictType.setTenantId(tenantId);
//}
//for (SysDictData dictData : dictDataList) {
// dictData.setDictCode(null);
// dictData.setTenantId(tenantId);
//}
//dictTypeMapper.insertBatch(dictTypeList);
//dictDataMapper.insertBatch(dictDataList);
List
<
SysConfig
>
sysConfigList
=
configMapper
.
selectList
(
List
<
SysConfig
>
sysConfigList
=
configMapper
.
selectList
(
new
LambdaQueryWrapper
<
SysConfig
>()
new
LambdaQueryWrapper
<
SysConfig
>()
.
eq
(
SysConfig:
:
getTenantId
,
defaultTenantId
)
.
eq
(
SysConfig:
:
getTenantId
,
TenantConstants
.
DEFAULT_TENANT_ID
)
.
eq
(
SysConfig:
:
getConfigType
,
"Y"
));
.
eq
(
SysConfig:
:
getConfigType
,
"Y"
));
for
(
SysConfig
config
:
sysConfigList
)
{
for
(
SysConfig
config
:
sysConfigList
)
{
config
.
setConfigId
(
null
);
config
.
setConfigId
(
null
);
...
...
dsk-system/src/main/java/com/dsk/system/service/impl/SysUserServiceImpl.java
View file @
0ef1f2fc
...
@@ -26,6 +26,7 @@ import com.dsk.common.utils.StreamUtils;
...
@@ -26,6 +26,7 @@ import com.dsk.common.utils.StreamUtils;
import
com.dsk.common.utils.StringUtils
;
import
com.dsk.common.utils.StringUtils
;
import
com.dsk.common.utils.ValidatorUtils
;
import
com.dsk.common.utils.ValidatorUtils
;
import
com.dsk.system.domain.*
;
import
com.dsk.system.domain.*
;
import
com.dsk.system.domain.bo.SysTenantAdminBo
;
import
com.dsk.system.domain.vo.SysUserImportVo
;
import
com.dsk.system.domain.vo.SysUserImportVo
;
import
com.dsk.system.mapper.*
;
import
com.dsk.system.mapper.*
;
import
com.dsk.system.service.ISysUserService
;
import
com.dsk.system.service.ISysUserService
;
...
@@ -68,9 +69,10 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
...
@@ -68,9 +69,10 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
public
Long
queryTenantAdminNumCreatedByDSK
(
Long
tenantId
)
{
public
Long
queryTenantAdminNumCreatedByDSK
(
Long
tenantId
)
{
LambdaQueryWrapper
<
SysUser
>
queryWrapper
=
new
LambdaQueryWrapper
<
SysUser
>()
LambdaQueryWrapper
<
SysUser
>
queryWrapper
=
new
LambdaQueryWrapper
<
SysUser
>()
.
select
(
SysUser:
:
getUserId
)
.
select
(
SysUser:
:
getUserId
)
.
eq
(
SysUser:
:
getStatus
,
UserConstants
.
USER_NORMAL
)
.
eq
(
SysUser:
:
getStatus
,
UserConstants
.
NORMAL
)
.
eq
(
SysUser:
:
getTenantId
,
tenantId
)
.
eq
(
SysUser:
:
getDelFlag
,
UserConstants
.
NORMAL
)
.
eq
(
SysUser:
:
getCreateBy
,
"suadmin"
);
.
eq
(
SysUser:
:
getTenantId
,
tenantId
);
//.eq(SysUser::getCreateBy, "suadmin");
return
baseMapper
.
selectCount
(
queryWrapper
);
return
baseMapper
.
selectCount
(
queryWrapper
);
}
}
...
@@ -252,6 +254,20 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
...
@@ -252,6 +254,20 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
return
!
exist
;
return
!
exist
;
}
}
/**
* 校验企业普通管理员手机号码是否唯一
*
* @param tenantAdminBo 用户信息
* @return 结果
*/
@Override
public
boolean
checkTenantAdminPhoneUnique
(
SysTenantAdminBo
tenantAdminBo
)
{
return
baseMapper
.
exists
(
new
LambdaQueryWrapper
<
SysUser
>()
.
eq
(
SysUser:
:
getTenantId
,
tenantAdminBo
.
getTenantId
())
.
eq
(
SysUser:
:
getPhonenumber
,
tenantAdminBo
.
getPhonenumber
())
.
eq
(
SysUser:
:
getStatus
,
UserConstants
.
NORMAL
));
}
/**
/**
* 校验email是否唯一
* 校验email是否唯一
*
*
...
@@ -424,9 +440,10 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
...
@@ -424,9 +440,10 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
int
updateUser
(
SysUser
user
)
{
public
int
updateUser
(
SysUser
user
)
{
Long
userId
=
user
.
getUserId
();
Long
userId
=
user
.
getUserId
();
if
(
LoginHelper
.
isTenantAdmin
(
LoginHelper
.
getLoginUser
().
getRolePermission
()))
{
//校验企业管理员角色下是否至少有一个账号
//校验企业管理员角色下是否至少有一个账号
checkAdminHasUsers
(
user
);
checkAdminHasUsers
(
user
);
}
// 删除用户与角色关联
// 删除用户与角色关联
userRoleMapper
.
delete
(
new
LambdaQueryWrapper
<
SysUserRole
>().
eq
(
SysUserRole:
:
getUserId
,
userId
));
userRoleMapper
.
delete
(
new
LambdaQueryWrapper
<
SysUserRole
>().
eq
(
SysUserRole:
:
getUserId
,
userId
));
// 新增用户与角色管理
// 新增用户与角色管理
...
...
pom.xml
View file @
0ef1f2fc
...
@@ -48,9 +48,6 @@
...
@@ -48,9 +48,6 @@
<aws-java-sdk-s3.version>
1.12.400
</aws-java-sdk-s3.version>
<aws-java-sdk-s3.version>
1.12.400
</aws-java-sdk-s3.version>
<!-- SMS 配置 -->
<!-- SMS 配置 -->
<sms4j.version>
2.2.0
</sms4j.version>
<sms4j.version>
2.2.0
</sms4j.version>
<!--中文转拼音-->
<pinyin4j.version>
2.5.1
</pinyin4j.version>
</properties>
</properties>
<profiles>
<profiles>
...
@@ -334,6 +331,12 @@
...
@@ -334,6 +331,12 @@
<version>
${pinyin4j.version}
</version>
<version>
${pinyin4j.version}
</version>
</dependency>
</dependency>
<dependency>
<groupId>
com.dsk
</groupId>
<artifactId>
dsk-biz-bi
</artifactId>
<version>
${dsk-operate-sys.version}
</version>
</dependency>
</dependencies>
</dependencies>
</dependencyManagement>
</dependencyManagement>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment