Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
C
chinafrica
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
zhengfg
chinafrica
Commits
fbe7430c
提交
fbe7430c
authored
3月 03, 2020
作者:
zgy
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
完成标题栏管理
上级
da8ed706
隐藏空白字符变更
内嵌
并排
正在显示
16 个修改的文件
包含
1433 行增加
和
0 行删除
+1433
-0
TbCfColumnController.java
...in/java/com/platform/controller/TbCfColumnController.java
+109
-0
TbCfSortController.java
...main/java/com/platform/controller/TbCfSortController.java
+109
-0
TbCfColumnDao.java
...m-admin/src/main/java/com/platform/dao/TbCfColumnDao.java
+13
-0
TbCfSortDao.java
...orm-admin/src/main/java/com/platform/dao/TbCfSortDao.java
+13
-0
TbCfColumnEntity.java
...n/src/main/java/com/platform/entity/TbCfColumnEntity.java
+119
-0
TbCfSortEntity.java
...min/src/main/java/com/platform/entity/TbCfSortEntity.java
+187
-0
TbCfColumnService.java
...src/main/java/com/platform/service/TbCfColumnService.java
+71
-0
TbCfSortService.java
...n/src/main/java/com/platform/service/TbCfSortService.java
+71
-0
TbCfColumnServiceImpl.java
...java/com/platform/service/impl/TbCfColumnServiceImpl.java
+63
-0
TbCfSortServiceImpl.java
...n/java/com/platform/service/impl/TbCfSortServiceImpl.java
+59
-0
TbCfColumnDao.xml
...min/src/main/resources/com/platform/dao/TbCfColumnDao.xml
+101
-0
TbCfSortDao.xml
...admin/src/main/resources/com/platform/dao/TbCfSortDao.xml
+125
-0
tbcfcolumn.html
...rm-admin/src/main/webapp/WEB-INF/page/sys/tbcfcolumn.html
+62
-0
tbcfsort.html
...form-admin/src/main/webapp/WEB-INF/page/sys/tbcfsort.html
+74
-0
tbcfcolumn.js
platform-admin/src/main/webapp/js/sys/tbcfcolumn.js
+138
-0
tbcfsort.js
platform-admin/src/main/webapp/js/sys/tbcfsort.js
+119
-0
没有找到文件。
platform-admin/src/main/java/com/platform/controller/TbCfColumnController.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
controller
;
import
com.platform.entity.TbCfColumnEntity
;
import
com.platform.service.TbCfColumnService
;
import
com.platform.utils.PageUtils
;
import
com.platform.utils.Query
;
import
com.platform.utils.R
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
java.util.List
;
import
java.util.Map
;
/**
* 标题栏Controller
*
* @author lipengjun
* @date 2020-03-03 11:35:34
*/
@Controller
@RequestMapping
(
"tbcfcolumn"
)
public
class
TbCfColumnController
{
@Autowired
private
TbCfColumnService
tbCfColumnService
;
/**
* 查看列表
*/
@RequestMapping
(
"/list"
)
@RequiresPermissions
(
"tbcfcolumn:list"
)
@ResponseBody
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
//查询列表数据
Query
query
=
new
Query
(
params
);
List
<
TbCfColumnEntity
>
tbCfColumnList
=
tbCfColumnService
.
queryList
(
query
);
int
total
=
tbCfColumnService
.
queryTotal
(
query
);
PageUtils
pageUtil
=
new
PageUtils
(
tbCfColumnList
,
total
,
query
.
getLimit
(),
query
.
getPage
());
return
R
.
ok
().
put
(
"page"
,
pageUtil
);
}
/**
* 查看信息
*/
@RequestMapping
(
"/info/{id}"
)
@RequiresPermissions
(
"tbcfcolumn:info"
)
@ResponseBody
public
R
info
(
@PathVariable
(
"id"
)
String
id
)
{
TbCfColumnEntity
tbCfColumn
=
tbCfColumnService
.
queryObject
(
id
);
return
R
.
ok
().
put
(
"tbCfColumn"
,
tbCfColumn
);
}
/**
* 保存
*/
@RequestMapping
(
"/save"
)
@RequiresPermissions
(
"tbcfcolumn:save"
)
@ResponseBody
public
R
save
(
@RequestBody
TbCfColumnEntity
tbCfColumn
)
{
tbCfColumnService
.
save
(
tbCfColumn
);
return
R
.
ok
();
}
/**
* 修改
*/
@RequestMapping
(
"/update"
)
@RequiresPermissions
(
"tbcfcolumn:update"
)
@ResponseBody
public
R
update
(
@RequestBody
TbCfColumnEntity
tbCfColumn
)
{
tbCfColumnService
.
update
(
tbCfColumn
);
return
R
.
ok
();
}
/**
* 删除
*/
@RequestMapping
(
"/delete"
)
@RequiresPermissions
(
"tbcfcolumn:delete"
)
@ResponseBody
public
R
delete
(
@RequestBody
String
[]
ids
)
{
tbCfColumnService
.
deleteBatch
(
ids
);
return
R
.
ok
();
}
/**
* 查看所有列表
*/
@RequestMapping
(
"/queryAll"
)
@ResponseBody
public
R
queryAll
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
List
<
TbCfColumnEntity
>
list
=
tbCfColumnService
.
queryList
(
params
);
return
R
.
ok
().
put
(
"list"
,
list
);
}
}
platform-admin/src/main/java/com/platform/controller/TbCfSortController.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
controller
;
import
com.platform.entity.TbCfSortEntity
;
import
com.platform.service.TbCfSortService
;
import
com.platform.utils.PageUtils
;
import
com.platform.utils.Query
;
import
com.platform.utils.R
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
java.util.List
;
import
java.util.Map
;
/**
* 首页排序Controller
*
* @author lipengjun
* @date 2020-03-02 10:44:34
*/
@Controller
@RequestMapping
(
"tbcfsort"
)
public
class
TbCfSortController
{
@Autowired
private
TbCfSortService
tbCfSortService
;
/**
* 查看列表
*/
@RequestMapping
(
"/list"
)
@RequiresPermissions
(
"tbcfsort:list"
)
@ResponseBody
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
//查询列表数据
Query
query
=
new
Query
(
params
);
List
<
TbCfSortEntity
>
tbCfSortList
=
tbCfSortService
.
queryList
(
query
);
int
total
=
tbCfSortService
.
queryTotal
(
query
);
PageUtils
pageUtil
=
new
PageUtils
(
tbCfSortList
,
total
,
query
.
getLimit
(),
query
.
getPage
());
return
R
.
ok
().
put
(
"page"
,
pageUtil
);
}
/**
* 查看信息
*/
@RequestMapping
(
"/info/{id}"
)
@RequiresPermissions
(
"tbcfsort:info"
)
@ResponseBody
public
R
info
(
@PathVariable
(
"id"
)
String
id
)
{
TbCfSortEntity
tbCfSort
=
tbCfSortService
.
queryObject
(
id
);
return
R
.
ok
().
put
(
"tbCfSort"
,
tbCfSort
);
}
/**
* 保存
*/
@RequestMapping
(
"/save"
)
@RequiresPermissions
(
"tbcfsort:save"
)
@ResponseBody
public
R
save
(
@RequestBody
TbCfSortEntity
tbCfSort
)
{
tbCfSortService
.
save
(
tbCfSort
);
return
R
.
ok
();
}
/**
* 修改
*/
@RequestMapping
(
"/update"
)
@RequiresPermissions
(
"tbcfsort:update"
)
@ResponseBody
public
R
update
(
@RequestBody
TbCfSortEntity
tbCfSort
)
{
tbCfSortService
.
update
(
tbCfSort
);
return
R
.
ok
();
}
/**
* 删除
*/
@RequestMapping
(
"/delete"
)
@RequiresPermissions
(
"tbcfsort:delete"
)
@ResponseBody
public
R
delete
(
@RequestBody
String
[]
ids
)
{
tbCfSortService
.
deleteBatch
(
ids
);
return
R
.
ok
();
}
/**
* 查看所有列表
*/
@RequestMapping
(
"/queryAll"
)
@ResponseBody
public
R
queryAll
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
List
<
TbCfSortEntity
>
list
=
tbCfSortService
.
queryList
(
params
);
return
R
.
ok
().
put
(
"list"
,
list
);
}
}
platform-admin/src/main/java/com/platform/dao/TbCfColumnDao.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
dao
;
import
com.platform.entity.TbCfColumnEntity
;
/**
* 标题栏Dao
*
* @author lipengjun
* @date 2020-03-03 11:35:34
*/
public
interface
TbCfColumnDao
extends
BaseDao
<
TbCfColumnEntity
>
{
}
platform-admin/src/main/java/com/platform/dao/TbCfSortDao.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
dao
;
import
com.platform.entity.TbCfSortEntity
;
/**
* 首页排序Dao
*
* @author lipengjun
* @date 2020-03-02 10:25:49
*/
public
interface
TbCfSortDao
extends
BaseDao
<
TbCfSortEntity
>
{
}
platform-admin/src/main/java/com/platform/entity/TbCfColumnEntity.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
entity
;
import
java.io.Serializable
;
import
java.util.Date
;
/**
* 标题栏实体
* 表名 tb_cf_column
*
* @author lipengjun
* @date 2020-03-03 11:35:34
*/
public
class
TbCfColumnEntity
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 标题栏ID
*/
private
String
id
;
/**
* 标题栏
*/
private
String
columnName
;
/**
* 类型 1:爬虫 2:其他
*/
private
Integer
columnType
;
/**
* 栏目图片
*/
private
String
columuPicture
;
/**
* 创建时间
*/
private
Date
createTime
;
/**
* 更新时间
*/
private
Date
updaeTime
;
/**
* 设置:标题栏ID
*/
public
void
setId
(
String
id
)
{
this
.
id
=
id
;
}
/**
* 获取:标题栏ID
*/
public
String
getId
()
{
return
id
;
}
/**
* 设置:标题栏
*/
public
void
setColumnName
(
String
columnName
)
{
this
.
columnName
=
columnName
;
}
/**
* 获取:标题栏
*/
public
String
getColumnName
()
{
return
columnName
;
}
/**
* 设置:类型 1:爬虫 2:其他
*/
public
void
setColumnType
(
Integer
columnType
)
{
this
.
columnType
=
columnType
;
}
/**
* 获取:类型 1:爬虫 2:其他
*/
public
Integer
getColumnType
()
{
return
columnType
;
}
/**
* 设置:栏目图片
*/
public
void
setColumuPicture
(
String
columuPicture
)
{
this
.
columuPicture
=
columuPicture
;
}
/**
* 获取:栏目图片
*/
public
String
getColumuPicture
()
{
return
columuPicture
;
}
/**
* 设置:创建时间
*/
public
void
setCreateTime
(
Date
createTime
)
{
this
.
createTime
=
createTime
;
}
/**
* 获取:创建时间
*/
public
Date
getCreateTime
()
{
return
createTime
;
}
/**
* 设置:更新时间
*/
public
void
setUpdaeTime
(
Date
updaeTime
)
{
this
.
updaeTime
=
updaeTime
;
}
/**
* 获取:更新时间
*/
public
Date
getUpdaeTime
()
{
return
updaeTime
;
}
}
platform-admin/src/main/java/com/platform/entity/TbCfSortEntity.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
entity
;
import
java.io.Serializable
;
import
java.util.Date
;
/**
* 首页排序实体
* 表名 tb_cf_sort
*
* @author lipengjun
* @date 2020-03-02 10:44:34
*/
public
class
TbCfSortEntity
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 首页排序ID
*/
private
String
id
;
/**
* 模块ID
*/
private
String
moduleId
;
/**
* 序号
*/
private
Integer
sort
;
/**
* 模块
*/
private
String
module
;
/**
* 名称
*/
private
String
name
;
/**
* 1:分类导航栏 2.海报图 3.爬虫品牌
*/
private
Integer
type
;
/**
* 备注
*/
private
String
remark
;
/**
* 创建时间
*/
private
Date
createTime
;
/**
* 更新时间
*/
private
Date
updateTime
;
/**
* 是否展示
*/
private
Integer
isShow
;
/**
* 设置:首页排序ID
*/
public
void
setId
(
String
id
)
{
this
.
id
=
id
;
}
/**
* 获取:首页排序ID
*/
public
String
getId
()
{
return
id
;
}
/**
* 设置:模块ID
*/
public
void
setModuleId
(
String
moduleId
)
{
this
.
moduleId
=
moduleId
;
}
/**
* 获取:模块ID
*/
public
String
getModuleId
()
{
return
moduleId
;
}
/**
* 设置:序号
*/
public
void
setSort
(
Integer
sort
)
{
this
.
sort
=
sort
;
}
/**
* 获取:序号
*/
public
Integer
getSort
()
{
return
sort
;
}
/**
* 设置:模块
*/
public
void
setModule
(
String
module
)
{
this
.
module
=
module
;
}
/**
* 获取:模块
*/
public
String
getModule
()
{
return
module
;
}
/**
* 设置:名称
*/
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
/**
* 获取:名称
*/
public
String
getName
()
{
return
name
;
}
/**
* 设置:1:分类导航栏 2.海报图 3.爬虫品牌
*/
public
void
setType
(
Integer
type
)
{
this
.
type
=
type
;
}
/**
* 获取:1:分类导航栏 2.海报图 3.爬虫品牌
*/
public
Integer
getType
()
{
return
type
;
}
/**
* 设置:备注
*/
public
void
setRemark
(
String
remark
)
{
this
.
remark
=
remark
;
}
/**
* 获取:备注
*/
public
String
getRemark
()
{
return
remark
;
}
/**
* 设置:创建时间
*/
public
void
setCreateTime
(
Date
createTime
)
{
this
.
createTime
=
createTime
;
}
/**
* 获取:创建时间
*/
public
Date
getCreateTime
()
{
return
createTime
;
}
/**
* 设置:更新时间
*/
public
void
setUpdateTime
(
Date
updateTime
)
{
this
.
updateTime
=
updateTime
;
}
/**
* 获取:更新时间
*/
public
Date
getUpdateTime
()
{
return
updateTime
;
}
/**
* 设置:是否展示
*/
public
void
setIsShow
(
Integer
isShow
)
{
this
.
isShow
=
isShow
;
}
/**
* 获取:是否展示
*/
public
Integer
getIsShow
()
{
return
isShow
;
}
}
platform-admin/src/main/java/com/platform/service/TbCfColumnService.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
service
;
import
com.platform.entity.TbCfColumnEntity
;
import
java.util.List
;
import
java.util.Map
;
/**
* 标题栏Service接口
*
* @author lipengjun
* @date 2020-03-03 11:35:34
*/
public
interface
TbCfColumnService
{
/**
* 根据主键查询实体
*
* @param id 主键
* @return 实体
*/
TbCfColumnEntity
queryObject
(
String
id
);
/**
* 分页查询
*
* @param map 参数
* @return list
*/
List
<
TbCfColumnEntity
>
queryList
(
Map
<
String
,
Object
>
map
);
/**
* 分页统计总数
*
* @param map 参数
* @return 总数
*/
int
queryTotal
(
Map
<
String
,
Object
>
map
);
/**
* 保存实体
*
* @param tbCfColumn 实体
* @return 保存条数
*/
int
save
(
TbCfColumnEntity
tbCfColumn
);
/**
* 根据主键更新实体
*
* @param tbCfColumn 实体
* @return 更新条数
*/
int
update
(
TbCfColumnEntity
tbCfColumn
);
/**
* 根据主键删除
*
* @param id
* @return 删除条数
*/
int
delete
(
String
id
);
/**
* 根据主键批量删除
*
* @param ids
* @return 删除条数
*/
int
deleteBatch
(
String
[]
ids
);
}
platform-admin/src/main/java/com/platform/service/TbCfSortService.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
service
;
import
com.platform.entity.TbCfSortEntity
;
import
java.util.List
;
import
java.util.Map
;
/**
* 首页排序Service接口
*
* @author lipengjun
* @date 2020-03-02 10:25:49
*/
public
interface
TbCfSortService
{
/**
* 根据主键查询实体
*
* @param id 主键
* @return 实体
*/
TbCfSortEntity
queryObject
(
String
id
);
/**
* 分页查询
*
* @param map 参数
* @return list
*/
List
<
TbCfSortEntity
>
queryList
(
Map
<
String
,
Object
>
map
);
/**
* 分页统计总数
*
* @param map 参数
* @return 总数
*/
int
queryTotal
(
Map
<
String
,
Object
>
map
);
/**
* 保存实体
*
* @param tbCfSort 实体
* @return 保存条数
*/
int
save
(
TbCfSortEntity
tbCfSort
);
/**
* 根据主键更新实体
*
* @param tbCfSort 实体
* @return 更新条数
*/
int
update
(
TbCfSortEntity
tbCfSort
);
/**
* 根据主键删除
*
* @param id
* @return 删除条数
*/
int
delete
(
String
id
);
/**
* 根据主键批量删除
*
* @param ids
* @return 删除条数
*/
int
deleteBatch
(
String
[]
ids
);
}
platform-admin/src/main/java/com/platform/service/impl/TbCfColumnServiceImpl.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
service
.
impl
;
import
com.platform.dao.TbCfColumnDao
;
import
com.platform.entity.TbCfColumnEntity
;
import
com.platform.service.TbCfColumnService
;
import
com.platform.utils.IdUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
/**
* 标题栏Service实现类
*
* @author lipengjun
* @date 2020-03-03 11:35:34
*/
@Service
(
"tbCfColumnService"
)
public
class
TbCfColumnServiceImpl
implements
TbCfColumnService
{
@Autowired
private
TbCfColumnDao
tbCfColumnDao
;
@Override
public
TbCfColumnEntity
queryObject
(
String
id
)
{
return
tbCfColumnDao
.
queryObject
(
id
);
}
@Override
public
List
<
TbCfColumnEntity
>
queryList
(
Map
<
String
,
Object
>
map
)
{
return
tbCfColumnDao
.
queryList
(
map
);
}
@Override
public
int
queryTotal
(
Map
<
String
,
Object
>
map
)
{
return
tbCfColumnDao
.
queryTotal
(
map
);
}
@Override
public
int
save
(
TbCfColumnEntity
tbCfColumn
)
{
tbCfColumn
.
setId
(
IdUtil
.
createIdbyUUID
());
tbCfColumn
.
setCreateTime
(
new
Date
());
tbCfColumn
.
setUpdaeTime
(
new
Date
());
return
tbCfColumnDao
.
save
(
tbCfColumn
);
}
@Override
public
int
update
(
TbCfColumnEntity
tbCfColumn
)
{
tbCfColumn
.
setUpdaeTime
(
new
Date
());
return
tbCfColumnDao
.
update
(
tbCfColumn
);
}
@Override
public
int
delete
(
String
id
)
{
return
tbCfColumnDao
.
delete
(
id
);
}
@Override
public
int
deleteBatch
(
String
[]
ids
)
{
return
tbCfColumnDao
.
deleteBatch
(
ids
);
}
}
platform-admin/src/main/java/com/platform/service/impl/TbCfSortServiceImpl.java
0 → 100644
浏览文件 @
fbe7430c
package
com
.
platform
.
service
.
impl
;
import
com.platform.dao.TbCfSortDao
;
import
com.platform.entity.TbCfSortEntity
;
import
com.platform.service.TbCfSortService
;
import
com.platform.utils.IdUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
import
java.util.Map
;
/**
* 首页排序Service实现类
*
* @author lipengjun
* @date 2020-03-02 10:25:49
*/
@Service
(
"tbCfSortService"
)
public
class
TbCfSortServiceImpl
implements
TbCfSortService
{
@Autowired
private
TbCfSortDao
tbCfSortDao
;
@Override
public
TbCfSortEntity
queryObject
(
String
id
)
{
return
tbCfSortDao
.
queryObject
(
id
);
}
@Override
public
List
<
TbCfSortEntity
>
queryList
(
Map
<
String
,
Object
>
map
)
{
return
tbCfSortDao
.
queryList
(
map
);
}
@Override
public
int
queryTotal
(
Map
<
String
,
Object
>
map
)
{
return
tbCfSortDao
.
queryTotal
(
map
);
}
@Override
public
int
save
(
TbCfSortEntity
tbCfSort
)
{
tbCfSort
.
setId
(
IdUtil
.
createIdbyUUID
());
return
tbCfSortDao
.
save
(
tbCfSort
);
}
@Override
public
int
update
(
TbCfSortEntity
tbCfSort
)
{
return
tbCfSortDao
.
update
(
tbCfSort
);
}
@Override
public
int
delete
(
String
id
)
{
return
tbCfSortDao
.
delete
(
id
);
}
@Override
public
int
deleteBatch
(
String
[]
ids
)
{
return
tbCfSortDao
.
deleteBatch
(
ids
);
}
}
platform-admin/src/main/resources/com/platform/dao/TbCfColumnDao.xml
0 → 100644
浏览文件 @
fbe7430c
<?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.platform.dao.TbCfColumnDao"
>
<resultMap
type=
"com.platform.entity.TbCfColumnEntity"
id=
"tbCfColumnMap"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"columnName"
column=
"column_name"
/>
<result
property=
"columnType"
column=
"column_type"
/>
<result
property=
"columuPicture"
column=
"columu_picture"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updaeTime"
column=
"updae_time"
/>
</resultMap>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfColumnEntity"
>
select
`id`,
`column_name`,
`column_type`,
`columu_picture`,
`create_time`,
`updae_time`
from tb_cf_column
where id = #{id}
</select>
<select
id=
"queryList"
resultType=
"com.platform.entity.TbCfColumnEntity"
>
select
`id`,
`column_name`,
`column_type`,
`columu_picture`,
`create_time`,
`updae_time`
from tb_cf_column
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
</if>
<choose>
<when
test=
"sidx != null and sidx.trim() != ''"
>
order by ${sidx} ${order}
</when>
<otherwise>
order by id desc
</otherwise>
</choose>
<if
test=
"offset != null and limit != null"
>
limit #{offset}, #{limit}
</if>
</select>
<select
id=
"queryTotal"
resultType=
"int"
>
select count(*) from tb_cf_column
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
</if>
</select>
<insert
id=
"save"
parameterType=
"com.platform.entity.TbCfColumnEntity"
>
insert into tb_cf_column(
`id`,
`column_name`,
`column_type`,
`columu_picture`,
`create_time`,
`updae_time`)
values(
#{id},
#{columnName},
#{columnType},
#{columuPicture},
#{createTime},
#{updaeTime})
</insert>
<update
id=
"update"
parameterType=
"com.platform.entity.TbCfColumnEntity"
>
update tb_cf_column
<set>
<if
test=
"columnName != null"
>
`column_name` = #{columnName},
</if>
<if
test=
"columnType != null"
>
`column_type` = #{columnType},
</if>
<if
test=
"columuPicture != null"
>
`columu_picture` = #{columuPicture},
</if>
<if
test=
"createTime != null"
>
`create_time` = #{createTime},
</if>
<if
test=
"updaeTime != null"
>
`updae_time` = #{updaeTime}
</if>
</set>
where id = #{id}
</update>
<delete
id=
"delete"
>
delete from tb_cf_column where id = #{value}
</delete>
<delete
id=
"deleteBatch"
>
delete from tb_cf_column where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
platform-admin/src/main/resources/com/platform/dao/TbCfSortDao.xml
0 → 100644
浏览文件 @
fbe7430c
<?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.platform.dao.TbCfSortDao"
>
<resultMap
type=
"com.platform.entity.TbCfSortEntity"
id=
"tbCfSortMap"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"moduleId"
column=
"module_id"
/>
<result
property=
"sort"
column=
"sort"
/>
<result
property=
"module"
column=
"module"
/>
<result
property=
"name"
column=
"name"
/>
<result
property=
"type"
column=
"type"
/>
<result
property=
"remark"
column=
"remark"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"isShow"
column=
"is_show"
/>
</resultMap>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfSortEntity"
>
select
`id`,
`module_id`,
`sort`,
`module`,
`name`,
`type`,
`remark`,
`create_time`,
`update_time`,
`is_show`
from tb_cf_sort
where id = #{id}
</select>
<select
id=
"queryList"
resultType=
"com.platform.entity.TbCfSortEntity"
>
select
`id`,
`module_id`,
`sort`,
`module`,
`name`,
`type`,
`remark`,
`create_time`,
`update_time`,
`is_show`
from tb_cf_sort
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
</if>
<choose>
<when
test=
"sidx != null and sidx.trim() != ''"
>
order by ${sidx} ${order}
</when>
<otherwise>
order by id desc
</otherwise>
</choose>
<if
test=
"offset != null and limit != null"
>
limit #{offset}, #{limit}
</if>
</select>
<select
id=
"queryTotal"
resultType=
"int"
>
select count(*) from tb_cf_sort
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
</if>
</select>
<insert
id=
"save"
parameterType=
"com.platform.entity.TbCfSortEntity"
>
insert into tb_cf_sort(
`id`,
`module_id`,
`sort`,
`module`,
`name`,
`type`,
`remark`,
`create_time`,
`update_time`,
`is_show`)
values(
#{id},
#{moduleId},
#{sort},
#{module},
#{name},
#{type},
#{remark},
#{createTime},
#{updateTime},
#{isShow})
</insert>
<update
id=
"update"
parameterType=
"com.platform.entity.TbCfSortEntity"
>
update tb_cf_sort
<set>
<if
test=
"moduleId != null"
>
`module_id` = #{moduleId},
</if>
<if
test=
"sort != null"
>
`sort` = #{sort},
</if>
<if
test=
"module != null"
>
`module` = #{module},
</if>
<if
test=
"name != null"
>
`name` = #{name},
</if>
<if
test=
"type != null"
>
`type` = #{type},
</if>
<if
test=
"remark != null"
>
`remark` = #{remark},
</if>
<if
test=
"createTime != null"
>
`create_time` = #{createTime},
</if>
<if
test=
"updateTime != null"
>
`update_time` = #{updateTime},
</if>
<if
test=
"isShow != null"
>
`is_show` = #{isShow}
</if>
</set>
where id = #{id}
</update>
<delete
id=
"delete"
>
delete from tb_cf_sort where id = #{value}
</delete>
<delete
id=
"deleteBatch"
>
delete from tb_cf_sort where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfcolumn.html
0 → 100644
浏览文件 @
fbe7430c
<!DOCTYPE html>
<html
xmlns:v-bind=
"http://www.w3.org/1999/xhtml"
>
<head>
<title>
标题栏
</title>
#parse("sys/header.html")
</head>
<body>
<div
id=
"rrapp"
v-cloak
style=
"height: calc(100% - 15px);"
>
<div
v-show=
"showList"
style=
"height: 100%;"
>
<Row
:gutter=
"16"
>
<div
class=
"search-group"
>
<i-col
span=
"4"
>
<i-input
v-model=
"q.name"
@
on-enter=
"query"
placeholder=
"名称"
/>
</i-col>
<i-button
@
click=
"query"
>
查询
</i-button>
<i-button
@
click=
"reloadSearch"
>
重置
</i-button>
</div>
<div
class=
"buttons-group"
>
#if($shiro.hasPermission("tbcfcolumn:save"))
<i-button
type=
"info"
@
click=
"add"
><i
class=
"fa fa-plus"
></i>
新增
</i-button>
#end
#if($shiro.hasPermission("tbcfcolumn:update"))
<i-button
type=
"warning"
@
click=
"update"
><i
class=
"fa fa-pencil-square-o"
></i>
修改
</i-button>
#end
#if($shiro.hasPermission("tbcfcolumn:delete"))
<i-button
type=
"error"
@
click=
"del"
><i
class=
"fa fa-trash-o"
></i>
删除
</i-button>
#end
</div>
</Row>
<table
id=
"jqGrid"
></table>
</div>
<Card
v-show=
"!showList"
>
<p
slot=
"title"
>
{{title}}
</p>
<i-form
ref=
"formValidate"
:model=
"tbCfColumn"
:rules=
"ruleValidate"
:label-width=
"80"
>
<Form-item
label=
"标题栏"
prop=
"columnName"
>
<i-input
v-model=
"tbCfColumn.columnName"
placeholder=
"标题栏"
/>
</Form-item>
<Form-item
label=
"类型"
prop=
"columnType"
>
<i-input
v-model=
"tbCfColumn.columnType"
placeholder=
"类型 1:爬虫 2:其他"
/>
</Form-item>
<!-- <Form-item label="栏目图片" prop="columuPicture">
<i-input v-model="tbCfColumn.columuPicture" placeholder="栏目图片"/>
</Form-item>-->
<Form-item
label=
"栏目图片"
prop=
"columuPicture"
>
<img
v-bind:src=
"tbCfColumn.columuPicture"
v-show=
"!!tbCfColumn.columuPicture"
/>
<input
type=
"file"
placeholder=
"栏目图片"
@
change=
"tirggerFile($event)"
/>
</Form-item>
</Form-item>
<Form-item>
<i-button
type=
"primary"
@
click=
"handleSubmit('formValidate')"
>
提交
</i-button>
<i-button
type=
"warning"
@
click=
"reload"
style=
"margin-left: 8px"
/>
返回
</i-button>
<i-button
type=
"ghost"
@
click=
"handleReset('formValidate')"
style=
"margin-left: 8px"
>
重置
</i-button>
</Form-item>
</i-form>
</Card>
</div>
<script
src=
"${rc.contextPath}/js/sys/tbcfcolumn.js?_${date.systemTime}"
></script>
</body>
</html>
\ No newline at end of file
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfsort.html
0 → 100644
浏览文件 @
fbe7430c
<!DOCTYPE html>
<html>
<head>
<title>
首页排序
</title>
#parse("sys/header.html")
</head>
<body>
<div
id=
"rrapp"
v-cloak
style=
"height: calc(100% - 15px);"
>
<div
v-show=
"showList"
style=
"height: 100%;"
>
<Row
:gutter=
"16"
>
<div
class=
"search-group"
>
<i-col
span=
"4"
>
<i-input
v-model=
"q.name"
@
on-enter=
"query"
placeholder=
"名称"
/>
</i-col>
<i-button
@
click=
"query"
>
查询
</i-button>
<i-button
@
click=
"reloadSearch"
>
重置
</i-button>
</div>
<div
class=
"buttons-group"
>
#if($shiro.hasPermission("tbcfsort:save"))
<i-button
type=
"info"
@
click=
"add"
><i
class=
"fa fa-plus"
></i>
新增
</i-button>
#end
#if($shiro.hasPermission("tbcfsort:update"))
<i-button
type=
"warning"
@
click=
"update"
><i
class=
"fa fa-pencil-square-o"
></i>
修改
</i-button>
#end
#if($shiro.hasPermission("tbcfsort:delete"))
<i-button
type=
"error"
@
click=
"del"
><i
class=
"fa fa-trash-o"
></i>
删除
</i-button>
#end
</div>
</Row>
<table
id=
"jqGrid"
></table>
</div>
<Card
v-show=
"!showList"
>
<p
slot=
"title"
>
{{title}}
</p>
<i-form
ref=
"formValidate"
:model=
"tbCfSort"
:rules=
"ruleValidate"
:label-width=
"80"
>
<Form-item
label=
"模块ID"
prop=
"moduleId"
>
<i-input
v-model=
"tbCfSort.moduleId"
placeholder=
"模块ID"
/>
</Form-item>
<Form-item
label=
"序号"
prop=
"sort"
>
<i-input
v-model=
"tbCfSort.sort"
placeholder=
"序号"
/>
</Form-item>
<Form-item
label=
"模块"
prop=
"module"
>
<i-input
v-model=
"tbCfSort.module"
placeholder=
"模块"
/>
</Form-item>
<Form-item
label=
"名称"
prop=
"name"
>
<i-input
v-model=
"tbCfSort.name"
placeholder=
"名称"
/>
</Form-item>
<Form-item
label=
"1:分类导航栏 2.海报图 3.爬虫品牌"
prop=
"type"
>
<i-input
v-model=
"tbCfSort.type"
placeholder=
"1:分类导航栏 2.海报图 3.爬虫品牌"
/>
</Form-item>
<Form-item
label=
"备注"
prop=
"remark"
>
<i-input
v-model=
"tbCfSort.remark"
placeholder=
"备注"
/>
</Form-item>
<Form-item
label=
"创建时间"
prop=
"createTime"
>
<i-input
v-model=
"tbCfSort.createTime"
placeholder=
"创建时间"
/>
</Form-item>
<Form-item
label=
"更新时间"
prop=
"updateTime"
>
<i-input
v-model=
"tbCfSort.updateTime"
placeholder=
"更新时间"
/>
</Form-item>
<Form-item
label=
"是否展示"
prop=
"isShow"
>
<i-input
v-model=
"tbCfSort.isShow"
placeholder=
"是否展示"
/>
</Form-item>
<Form-item>
<i-button
type=
"primary"
@
click=
"handleSubmit('formValidate')"
>
提交
</i-button>
<i-button
type=
"warning"
@
click=
"reload"
style=
"margin-left: 8px"
/>
返回
</i-button>
<i-button
type=
"ghost"
@
click=
"handleReset('formValidate')"
style=
"margin-left: 8px"
>
重置
</i-button>
</Form-item>
</i-form>
</Card>
</div>
<script
src=
"${rc.contextPath}/js/sys/tbcfsort.js?_${date.systemTime}"
></script>
</body>
</html>
\ No newline at end of file
platform-admin/src/main/webapp/js/sys/tbcfcolumn.js
0 → 100644
浏览文件 @
fbe7430c
$
(
function
()
{
$
(
"#jqGrid"
).
Grid
({
url
:
'../tbcfcolumn/list'
,
colModel
:
[
{
label
:
'id'
,
name
:
'id'
,
index
:
'id'
,
key
:
true
,
hidden
:
true
},
{
label
:
'标题栏'
,
name
:
'columnName'
,
index
:
'column_name'
,
width
:
80
},
{
label
:
'类型 '
,
name
:
'columnType'
,
index
:
'column_type'
,
width
:
80
},
{
label
:
'栏目图片'
,
name
:
'columuPicture'
,
index
:
'columu_picture'
,
width
:
80
,
formatter
:
imageFormat
},
{
label
:
'创建时间'
,
name
:
'createTime'
,
index
:
'create_time'
,
width
:
80
}
]
});
});
let
vm
=
new
Vue
({
el
:
'#rrapp'
,
data
:
{
showList
:
true
,
title
:
null
,
tbCfColumn
:
{},
ruleValidate
:
{
name
:
[
{
required
:
true
,
message
:
'名称不能为空'
,
trigger
:
'blur'
}
]
},
q
:
{
name
:
''
}
},
methods
:
{
query
:
function
()
{
vm
.
reload
();
},
add
:
function
()
{
vm
.
showList
=
false
;
vm
.
title
=
"新增"
;
vm
.
tbCfColumn
=
{};
},
update
:
function
(
event
)
{
let
id
=
getSelectedRow
(
"#jqGrid"
);
if
(
id
==
null
)
{
return
;
}
vm
.
showList
=
false
;
vm
.
title
=
"修改"
;
vm
.
getInfo
(
id
);
},
saveOrUpdate
:
function
(
event
)
{
let
url
=
vm
.
tbCfColumn
.
id
==
null
?
"../tbcfcolumn/save"
:
"../tbcfcolumn/update"
;
Ajax
.
request
({
url
:
url
,
params
:
JSON
.
stringify
(
vm
.
tbCfColumn
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
(
r
)
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
},
del
:
function
(
event
)
{
let
ids
=
getSelectedRows
(
"#jqGrid"
);
if
(
ids
==
null
){
return
;
}
confirm
(
'确定要删除选中的记录?'
,
function
()
{
Ajax
.
request
({
url
:
"../tbcfcolumn/delete"
,
params
:
JSON
.
stringify
(
ids
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
()
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
});
},
getInfo
:
function
(
id
){
Ajax
.
request
({
url
:
"../tbcfcolumn/info/"
+
id
,
async
:
true
,
successCallback
:
function
(
r
)
{
vm
.
tbCfColumn
=
r
.
tbCfColumn
;
}
});
},
reload
:
function
(
event
)
{
vm
.
showList
=
true
;
let
page
=
$
(
"#jqGrid"
).
jqGrid
(
'getGridParam'
,
'page'
);
$
(
"#jqGrid"
).
jqGrid
(
'setGridParam'
,
{
postData
:
{
'name'
:
vm
.
q
.
name
},
page
:
page
}).
trigger
(
"reloadGrid"
);
vm
.
handleReset
(
'formValidate'
);
},
reloadSearch
:
function
()
{
vm
.
q
=
{
name
:
''
};
vm
.
reload
();
},
handleSubmit
:
function
(
name
)
{
handleSubmitValidate
(
this
,
name
,
function
()
{
vm
.
saveOrUpdate
()
});
},
handleReset
:
function
(
name
)
{
handleResetForm
(
this
,
name
);
},
tirggerFile
:
function
(
event
)
{
var
file
=
event
.
target
.
files
[
0
];
var
formData
=
new
FormData
();
formData
.
append
(
"file"
,
file
);
$
.
ajax
({
url
:
"../api/upload/image/"
,
type
:
"POST"
,
data
:
formData
,
cache
:
false
,
//不设置缓存
processData
:
false
,
// 不处理数据
contentType
:
false
,
// 不设置内容类型
success
:
function
(
result
)
{
result
=
JSON
.
parse
(
result
);
//console.log(result)
if
(
result
.
errno
==
0
)
{
//成功
vm
.
tbCfColumn
.
columuPicture
=
result
.
data
;
vm
.
$forceUpdate
();
}
else
{
iview
.
Message
.
error
(
result
.
errmsg
);
}
}
});
}
}
});
\ No newline at end of file
platform-admin/src/main/webapp/js/sys/tbcfsort.js
0 → 100644
浏览文件 @
fbe7430c
$
(
function
()
{
$
(
"#jqGrid"
).
Grid
({
url
:
'../tbcfsort/list'
,
colModel
:
[
{
label
:
'id'
,
name
:
'id'
,
index
:
'id'
,
key
:
true
,
hidden
:
true
},
{
label
:
'模块ID'
,
name
:
'moduleId'
,
index
:
'module_id'
,
width
:
80
},
{
label
:
'序号'
,
name
:
'sort'
,
index
:
'sort'
,
width
:
80
},
{
label
:
'模块'
,
name
:
'module'
,
index
:
'module'
,
width
:
80
},
{
label
:
'名称'
,
name
:
'name'
,
index
:
'name'
,
width
:
80
},
{
label
:
'/*1:分类导航栏 2.海报图 3.爬虫品牌*/ 类型'
,
name
:
'type'
,
index
:
'type'
,
width
:
80
},
{
label
:
'备注'
,
name
:
'remark'
,
index
:
'remark'
,
width
:
80
},
{
label
:
'创建时间'
,
name
:
'createTime'
,
index
:
'create_time'
,
width
:
80
},
{
label
:
'更新时间'
,
name
:
'updateTime'
,
index
:
'update_time'
,
width
:
80
},
{
label
:
'是否展示'
,
name
:
'isShow'
,
index
:
'is_show'
,
width
:
80
}]
});
});
let
vm
=
new
Vue
({
el
:
'#rrapp'
,
data
:
{
showList
:
true
,
title
:
null
,
tbCfSort
:
{},
ruleValidate
:
{
name
:
[
{
required
:
true
,
message
:
'名称不能为空'
,
trigger
:
'blur'
}
]
},
q
:
{
name
:
''
}
},
methods
:
{
query
:
function
()
{
vm
.
reload
();
},
add
:
function
()
{
vm
.
showList
=
false
;
vm
.
title
=
"新增"
;
vm
.
tbCfSort
=
{};
},
update
:
function
(
event
)
{
let
id
=
getSelectedRow
(
"#jqGrid"
);
if
(
id
==
null
)
{
return
;
}
vm
.
showList
=
false
;
vm
.
title
=
"修改"
;
vm
.
getInfo
(
id
);
},
saveOrUpdate
:
function
(
event
)
{
let
url
=
vm
.
tbCfSort
.
id
==
null
?
"../tbcfsort/save"
:
"../tbcfsort/update"
;
Ajax
.
request
({
url
:
url
,
params
:
JSON
.
stringify
(
vm
.
tbCfSort
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
(
r
)
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
},
del
:
function
(
event
)
{
let
ids
=
getSelectedRows
(
"#jqGrid"
);
if
(
ids
==
null
){
return
;
}
confirm
(
'确定要删除选中的记录?'
,
function
()
{
Ajax
.
request
({
url
:
"../tbcfsort/delete"
,
params
:
JSON
.
stringify
(
ids
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
()
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
});
},
getInfo
:
function
(
id
){
Ajax
.
request
({
url
:
"../tbcfsort/info/"
+
id
,
async
:
true
,
successCallback
:
function
(
r
)
{
vm
.
tbCfSort
=
r
.
tbCfSort
;
}
});
},
reload
:
function
(
event
)
{
vm
.
showList
=
true
;
let
page
=
$
(
"#jqGrid"
).
jqGrid
(
'getGridParam'
,
'page'
);
$
(
"#jqGrid"
).
jqGrid
(
'setGridParam'
,
{
postData
:
{
'name'
:
vm
.
q
.
name
},
page
:
page
}).
trigger
(
"reloadGrid"
);
vm
.
handleReset
(
'formValidate'
);
},
reloadSearch
:
function
()
{
vm
.
q
=
{
name
:
''
};
vm
.
reload
();
},
handleSubmit
:
function
(
name
)
{
handleSubmitValidate
(
this
,
name
,
function
()
{
vm
.
saveOrUpdate
()
});
},
handleReset
:
function
(
name
)
{
handleResetForm
(
this
,
name
);
}
}
});
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论