Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
C
chinafrica
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
zhengfg
chinafrica
Commits
b9cc4cc3
提交
b9cc4cc3
authored
10月 09, 2019
作者:
张光耀
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
添加一级分类,并且做了财务统计
上级
440e9ded
隐藏空白字符变更
内嵌
并排
正在显示
19 个修改的文件
包含
998 行增加
和
11 行删除
+998
-11
.gitignore
.gitignore
+42
-0
TbCfFinanceController.java
...n/java/com/platform/controller/TbCfFinanceController.java
+124
-8
TbCfGoodstypeController.java
...java/com/platform/controller/TbCfGoodstypeController.java
+110
-0
TbCfFinanceDao.java
...-admin/src/main/java/com/platform/dao/TbCfFinanceDao.java
+50
-0
TbCfGoodstypeDao.java
...dmin/src/main/java/com/platform/dao/TbCfGoodstypeDao.java
+13
-0
TbCfGoodstypeEntity.java
...rc/main/java/com/platform/entity/TbCfGoodstypeEntity.java
+67
-0
TbCfFinanceService.java
...rc/main/java/com/platform/service/TbCfFinanceService.java
+51
-0
TbCfGoodstypeService.java
.../main/java/com/platform/service/TbCfGoodstypeService.java
+71
-0
TbCfFinanceServiceImpl.java
...ava/com/platform/service/impl/TbCfFinanceServiceImpl.java
+65
-0
TbCfGoodstypeServiceImpl.java
...a/com/platform/service/impl/TbCfGoodstypeServiceImpl.java
+60
-0
TbCfFinanceDao.xml
...in/src/main/resources/com/platform/dao/TbCfFinanceDao.xml
+40
-0
TbCfGoodstypeDao.xml
.../src/main/resources/com/platform/dao/TbCfGoodstypeDao.xml
+83
-0
tbcffinance.html
...m-admin/src/main/webapp/WEB-INF/page/sys/tbcffinance.html
+1
-0
tbcfgoodstype.html
...admin/src/main/webapp/WEB-INF/page/sys/tbcfgoodstype.html
+53
-0
tbcfstationitem.html
...min/src/main/webapp/WEB-INF/page/sys/tbcfstationitem.html
+9
-1
tbcffinance.js
platform-admin/src/main/webapp/js/sys/tbcffinance.js
+25
-1
tbcfgoodstype.js
platform-admin/src/main/webapp/js/sys/tbcfgoodstype.js
+112
-0
tbcfstationitem.js
platform-admin/src/main/webapp/js/sys/tbcfstationitem.js
+17
-1
pom.xml
platform-schedule/pom.xml
+5
-0
没有找到文件。
.gitignore
0 → 100644
浏览文件 @
b9cc4cc3
# Created by .ignore support plugin (hsz.mobi)
### Java template
# Compiled class file
*.class
# Log file
*.log
# BlueJ files
*.ctxt
# Mobile Tools for Java (J2ME)
.mtj.tmp/
# Package Files #
*.jar
*.war
*.nar
*.ear
*.zip
*.tar.gz
*.rar
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*
### Example user template template
### Example user template
# IntelliJ project files
.idea
*.iml
out
gen
/platform-common/target/
/platform-gen/target/
/platform-restful/target/
/platform-schedule/target/
/platform-admin/target/
platform-admin/src/main/java/com/platform/controller/TbCfFinanceController.java
浏览文件 @
b9cc4cc3
...
...
@@ -8,14 +8,10 @@ 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
org.springframework.web.bind.annotation.*
;
import
java.
util.Lis
t
;
import
java.util.
Map
;
import
java.
text.SimpleDateForma
t
;
import
java.util.
*
;
/**
* 财务明细Controller
...
...
@@ -27,7 +23,127 @@ import java.util.Map;
@RequestMapping
(
"tbcffinance"
)
public
class
TbCfFinanceController
{
@Autowired
private
TbCfFinanceService
tbCfFinanceService
;
private
TbCfFinanceService
tbCfFinanceService
;
/**
* 当天的下单总金额
* @return
*/
@RequestMapping
(
"/findBySumPay"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findBySumPay
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
Double
sumPay
=
tbCfFinanceService
.
findBySumPay
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"sumPay"
,
sumPay
);
}
/**
* 当天下单用户数量
* @return
*/
@RequestMapping
(
"/findByCountUser"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findByCountUser
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
List
<
TbCfFinanceEntity
>
countUser
=
tbCfFinanceService
.
findByCountUser
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"countUser"
,
countUser
.
size
());
}
/**
* 今天下单数
* @return
*/
@RequestMapping
(
"/findByCountOrder"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findByCountOrder
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
Integer
countOrder
=
tbCfFinanceService
.
findByCountOrder
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"countOrder"
,
countOrder
);
}
/**
* 今天下单商品总数
* @return
*/
@RequestMapping
(
"/findBySumOrder"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findBySumOrder
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
Integer
sumOrder
=
tbCfFinanceService
.
findBySumOrder
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"sumOrder"
,
sumOrder
);
}
/**
* 今天下单的商品平均价格
* @return
*/
@RequestMapping
(
"/findByAvgGoodsPrice"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findByAvgGoodsPrice
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
Double
avgGoodsPrice
=
tbCfFinanceService
.
findByAvgGoodsPrice
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"avgGoodsPrice"
,
avgGoodsPrice
);
}
/**
* 今天下单的商品平均价格
* @return
*/
@RequestMapping
(
"/findByAvgOrderPrice"
)
@RequiresPermissions
(
"tbcffinance:list"
)
@ResponseBody
public
R
findByAvgOrderPrice
()
{
SimpleDateFormat
df
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//开始时间
String
beginTime
=
df
.
format
(
new
Date
());
beginTime
+=
" 00:00:00"
;
SimpleDateFormat
dfs
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
//设置日期格式
//结束时间
String
endTime
=
dfs
.
format
(
new
Date
());
endTime
+=
" 23:59:59"
;
Double
avgOrderPrice
=
tbCfFinanceService
.
findByAvgOrderPrice
(
beginTime
,
endTime
);
return
R
.
ok
().
put
(
"avgOrderPrice"
,
avgOrderPrice
);
}
/**
* 查看列表
...
...
platform-admin/src/main/java/com/platform/controller/TbCfGoodstypeController.java
0 → 100644
浏览文件 @
b9cc4cc3
package
com
.
platform
.
controller
;
import
com.platform.entity.TbCfGoodstypeEntity
;
import
com.platform.service.TbCfGoodstypeService
;
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 2019-10-08 16:34:40
*/
@Controller
@RequestMapping
(
"tbcfgoodstype"
)
public
class
TbCfGoodstypeController
{
@Autowired
private
TbCfGoodstypeService
tbCfGoodstypeService
;
/**
* 查看列表
*/
@RequestMapping
(
"/list"
)
@RequiresPermissions
(
"tbcfgoodstype:list"
)
@ResponseBody
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
//查询列表数据
Query
query
=
new
Query
(
params
);
List
<
TbCfGoodstypeEntity
>
tbCfGoodstypeList
=
tbCfGoodstypeService
.
queryList
(
query
);
int
total
=
tbCfGoodstypeService
.
queryTotal
(
query
);
PageUtils
pageUtil
=
new
PageUtils
(
tbCfGoodstypeList
,
total
,
query
.
getLimit
(),
query
.
getPage
());
return
R
.
ok
().
put
(
"page"
,
pageUtil
);
}
/**
* 查看信息
*/
@RequestMapping
(
"/info/{goodstypeId}"
)
@RequiresPermissions
(
"tbcfgoodstype:info"
)
@ResponseBody
public
R
info
(
@PathVariable
(
"goodstypeId"
)
String
goodstypeId
)
{
TbCfGoodstypeEntity
tbCfGoodstype
=
tbCfGoodstypeService
.
queryObject
(
goodstypeId
);
return
R
.
ok
().
put
(
"tbCfGoodstype"
,
tbCfGoodstype
);
}
/**
* 保存
*/
@RequestMapping
(
"/save"
)
@RequiresPermissions
(
"tbcfgoodstype:save"
)
@ResponseBody
public
R
save
(
@RequestBody
TbCfGoodstypeEntity
tbCfGoodstype
)
{
tbCfGoodstypeService
.
save
(
tbCfGoodstype
);
return
R
.
ok
();
}
/**
* 修改
*/
@RequestMapping
(
"/update"
)
@RequiresPermissions
(
"tbcfgoodstype:update"
)
@ResponseBody
public
R
update
(
@RequestBody
TbCfGoodstypeEntity
tbCfGoodstype
)
{
tbCfGoodstypeService
.
update
(
tbCfGoodstype
);
return
R
.
ok
();
}
/**
* 删除
*/
@RequestMapping
(
"/delete"
)
@RequiresPermissions
(
"tbcfgoodstype:delete"
)
@ResponseBody
public
R
delete
(
@RequestBody
String
[]
goodstypeIds
)
{
tbCfGoodstypeService
.
deleteBatch
(
goodstypeIds
);
return
R
.
ok
();
}
/**
* 查看所有列表
*/
@RequestMapping
(
"/queryAll"
)
@ResponseBody
public
R
queryAll
(
@RequestParam
Map
<
String
,
Object
>
params
)
{
List
<
TbCfGoodstypeEntity
>
list
=
tbCfGoodstypeService
.
queryList
(
params
);
return
R
.
ok
().
put
(
"list"
,
list
);
}
}
platform-admin/src/main/java/com/platform/dao/TbCfFinanceDao.java
浏览文件 @
b9cc4cc3
package
com
.
platform
.
dao
;
import
com.platform.entity.TbCfFinanceEntity
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
* 财务明细Dao
...
...
@@ -10,4 +13,51 @@ import com.platform.entity.TbCfFinanceEntity;
*/
public
interface
TbCfFinanceDao
extends
BaseDao
<
TbCfFinanceEntity
>
{
/**
* 今日下单总金额
* @param beginTime
* @param endTime
* @return
*/
Double
findBySumPay
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今日下单总人数
* @param beginTime
* @param endTime
* @return
*/
List
<
TbCfFinanceEntity
>
findByCountUser
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单量
* @param beginTime
* @param endTime
* @return
*/
Integer
findByCountOrder
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今日下单商品数量
* @param beginTime
* @param endTime
* @return
*/
Integer
findBySumOrder
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
Double
findByAvgGoodsPrice
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
Double
findByAvgOrderPrice
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
}
platform-admin/src/main/java/com/platform/dao/TbCfGoodstypeDao.java
0 → 100644
浏览文件 @
b9cc4cc3
package
com
.
platform
.
dao
;
import
com.platform.entity.TbCfGoodstypeEntity
;
/**
* Dao
*
* @author lipengjun
* @date 2019-10-08 16:34:40
*/
public
interface
TbCfGoodstypeDao
extends
BaseDao
<
TbCfGoodstypeEntity
>
{
}
platform-admin/src/main/java/com/platform/entity/TbCfGoodstypeEntity.java
0 → 100644
浏览文件 @
b9cc4cc3
package
com
.
platform
.
entity
;
import
java.io.Serializable
;
/**
* 实体
* 表名 tb_cf_goodstype
*
* @author lipengjun
* @date 2019-10-08 16:34:40
*/
public
class
TbCfGoodstypeEntity
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 商品分类Id
*/
private
String
goodstypeId
;
/**
* 商品分类标题
*/
private
String
goodstypeTitle
;
/**
* 商品分类排序编号
*/
private
Integer
goodstypeSort
;
/**
* 设置:商品分类Id
*/
public
void
setGoodstypeId
(
String
goodstypeId
)
{
this
.
goodstypeId
=
goodstypeId
;
}
/**
* 获取:商品分类Id
*/
public
String
getGoodstypeId
()
{
return
goodstypeId
;
}
/**
* 设置:商品分类标题
*/
public
void
setGoodstypeTitle
(
String
goodstypeTitle
)
{
this
.
goodstypeTitle
=
goodstypeTitle
;
}
/**
* 获取:商品分类标题
*/
public
String
getGoodstypeTitle
()
{
return
goodstypeTitle
;
}
/**
* 设置:商品分类排序编号
*/
public
void
setGoodstypeSort
(
Integer
goodstypeSort
)
{
this
.
goodstypeSort
=
goodstypeSort
;
}
/**
* 获取:商品分类排序编号
*/
public
Integer
getGoodstypeSort
()
{
return
goodstypeSort
;
}
}
platform-admin/src/main/java/com/platform/service/TbCfFinanceService.java
浏览文件 @
b9cc4cc3
package
com
.
platform
.
service
;
import
com.platform.entity.TbCfFinanceEntity
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -68,4 +69,54 @@ public interface TbCfFinanceService {
* @return 删除条数
*/
int
deleteBatch
(
String
[]
finaceIds
);
/**
* 查询今天下单的总金额
* @param beginTime
* @param endTime
* @return
*/
Double
findBySumPay
(
String
beginTime
,
String
endTime
);
/**
* 进入下单人数
* @param beginTime
* @param endTime
* @return
*/
List
<
TbCfFinanceEntity
>
findByCountUser
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单量
* @param beginTime
* @param endTime
* @return
*/
Integer
findByCountOrder
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今日下单商品数量
* @param beginTime
* @param endTime
* @return
*/
Integer
findBySumOrder
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
Double
findByAvgGoodsPrice
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
Double
findByAvgOrderPrice
(
@Param
(
"beginTime"
)
String
beginTime
,
@Param
(
"endTime"
)
String
endTime
);
}
platform-admin/src/main/java/com/platform/service/TbCfGoodstypeService.java
0 → 100644
浏览文件 @
b9cc4cc3
package
com
.
platform
.
service
;
import
com.platform.entity.TbCfGoodstypeEntity
;
import
java.util.List
;
import
java.util.Map
;
/**
* Service接口
*
* @author lipengjun
* @date 2019-10-08 16:34:40
*/
public
interface
TbCfGoodstypeService
{
/**
* 根据主键查询实体
*
* @param id 主键
* @return 实体
*/
TbCfGoodstypeEntity
queryObject
(
String
goodstypeId
);
/**
* 分页查询
*
* @param map 参数
* @return list
*/
List
<
TbCfGoodstypeEntity
>
queryList
(
Map
<
String
,
Object
>
map
);
/**
* 分页统计总数
*
* @param map 参数
* @return 总数
*/
int
queryTotal
(
Map
<
String
,
Object
>
map
);
/**
* 保存实体
*
* @param tbCfGoodstype 实体
* @return 保存条数
*/
int
save
(
TbCfGoodstypeEntity
tbCfGoodstype
);
/**
* 根据主键更新实体
*
* @param tbCfGoodstype 实体
* @return 更新条数
*/
int
update
(
TbCfGoodstypeEntity
tbCfGoodstype
);
/**
* 根据主键删除
*
* @param goodstypeId
* @return 删除条数
*/
int
delete
(
String
goodstypeId
);
/**
* 根据主键批量删除
*
* @param goodstypeIds
* @return 删除条数
*/
int
deleteBatch
(
String
[]
goodstypeIds
);
}
platform-admin/src/main/java/com/platform/service/impl/TbCfFinanceServiceImpl.java
浏览文件 @
b9cc4cc3
...
...
@@ -18,6 +18,7 @@ import java.util.Map;
*/
@Service
(
"tbCfFinanceService"
)
public
class
TbCfFinanceServiceImpl
implements
TbCfFinanceService
{
@Autowired
private
TbCfFinanceDao
tbCfFinanceDao
;
...
...
@@ -56,4 +57,68 @@ public class TbCfFinanceServiceImpl implements TbCfFinanceService {
public
int
deleteBatch
(
String
[]
finaceIds
)
{
return
tbCfFinanceDao
.
deleteBatch
(
finaceIds
);
}
/**
* 下单总数
* @param beginTime
* @param endTime
* @return
*/
@Override
public
Double
findBySumPay
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findBySumPay
(
beginTime
,
endTime
);
}
/**
* 进入下单人数
* @param beginTime
* @param endTime
* @return
*/
@Override
public
List
<
TbCfFinanceEntity
>
findByCountUser
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findByCountUser
(
beginTime
,
endTime
);
}
/**
* 今天下单量
* @param beginTime
* @param endTime
* @return
*/
public
Integer
findByCountOrder
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findByCountOrder
(
beginTime
,
endTime
);
}
/**
* 今日下单商品数量
* @param beginTime
* @param endTime
* @return
*/
public
Integer
findBySumOrder
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findBySumOrder
(
beginTime
,
endTime
);
}
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
public
Double
findByAvgGoodsPrice
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findByAvgGoodsPrice
(
beginTime
,
endTime
);
}
/**
* 今天下单的商品平均价格
* @param beginTime
* @param endTime
* @return
*/
public
Double
findByAvgOrderPrice
(
String
beginTime
,
String
endTime
)
{
return
tbCfFinanceDao
.
findByAvgOrderPrice
(
beginTime
,
endTime
);
}
}
platform-admin/src/main/java/com/platform/service/impl/TbCfGoodstypeServiceImpl.java
0 → 100644
浏览文件 @
b9cc4cc3
package
com
.
platform
.
service
.
impl
;
import
com.platform.dao.TbCfGoodstypeDao
;
import
com.platform.entity.TbCfGoodstypeEntity
;
import
com.platform.service.TbCfGoodstypeService
;
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 2019-10-08 16:34:40
*/
@Service
(
"tbCfGoodstypeService"
)
public
class
TbCfGoodstypeServiceImpl
implements
TbCfGoodstypeService
{
@Autowired
private
TbCfGoodstypeDao
tbCfGoodstypeDao
;
@Override
public
TbCfGoodstypeEntity
queryObject
(
String
goodstypeId
)
{
return
tbCfGoodstypeDao
.
queryObject
(
goodstypeId
);
}
@Override
public
List
<
TbCfGoodstypeEntity
>
queryList
(
Map
<
String
,
Object
>
map
)
{
return
tbCfGoodstypeDao
.
queryList
(
map
);
}
@Override
public
int
queryTotal
(
Map
<
String
,
Object
>
map
)
{
return
tbCfGoodstypeDao
.
queryTotal
(
map
);
}
@Override
public
int
save
(
TbCfGoodstypeEntity
tbCfGoodstype
)
{
tbCfGoodstype
.
setGoodstypeId
(
IdUtil
.
createIdbyUUID
());
return
tbCfGoodstypeDao
.
save
(
tbCfGoodstype
);
}
@Override
public
int
update
(
TbCfGoodstypeEntity
tbCfGoodstype
)
{
return
tbCfGoodstypeDao
.
update
(
tbCfGoodstype
);
}
@Override
public
int
delete
(
String
goodstypeId
)
{
return
tbCfGoodstypeDao
.
delete
(
goodstypeId
);
}
@Override
public
int
deleteBatch
(
String
[]
goodstypeIds
)
{
return
tbCfGoodstypeDao
.
deleteBatch
(
goodstypeIds
);
}
}
platform-admin/src/main/resources/com/platform/dao/TbCfFinanceDao.xml
浏览文件 @
b9cc4cc3
...
...
@@ -14,6 +14,46 @@
<result
property=
"receiptUrl"
column=
"receipt_url"
/>
</resultMap>
<!-- 今天下单总金额 -->
<select
id=
"findBySumPay"
resultType=
"Double"
>
SELECT SUM(pay_account) FROM tb_cf_finance
WHERE pay_Time BETWEEN #{beginTime} AND #{endTime}
</select>
<!-- 今天下单用户数 -->
<select
id=
"findByCountUser"
resultType=
"com.platform.entity.TbCfFinanceEntity"
>
SELECT DISTINCT user_id FROM tb_cf_finance
WHERE pay_Time BETWEEN #{beginTime} AND #{endTime}
</select>
<!-- 今天下单量 -->
<select
id=
"findByCountOrder"
resultType=
"java.lang.Integer"
>
SELECT COUNT(order_id) FROM tb_cf_order
WHERE order_status = 20 AND deal_time BETWEEN #{beginTime} AND #{endTime}
</select>
<!-- 今天下单商品数-->
<select
id=
"findBySumOrder"
resultType=
"java.lang.Integer"
>
SELECT SUM(item_num) FROM tb_cf_item_order_r r
INNER JOIN tb_cf_item_detail li ON r.`item_id` = li.item_id
INNER JOIN tb_cf_order od ON r.`order_id` = od.`order_id`
WHERE order_status IN (20,40,50,60)
AND deal_time BETWEEN #{beginTime} AND #{endTime}
</select>
<!-- 今天下单的商品平均价格 -->
<select
id=
"findByAvgGoodsPrice"
resultType=
"Double"
>
SELECT AVG(items_price) FROM tb_cf_order
WHERE order_status IN (20,40,50,60) AND deal_time BETWEEN #{beginTime} AND #{endTime}
</select>
<!-- 今天下单订单平均价格 -->
<select
id=
"findByAvgOrderPrice"
resultType=
"Double"
>
SELECT AVG(total_price) FROM tb_cf_order
WHERE order_status IN (20,40,50,60) AND deal_time BETWEEN #{beginTime} AND #{endTime}
</select>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfFinanceEntity"
>
select
`finace_id`,
...
...
platform-admin/src/main/resources/com/platform/dao/TbCfGoodstypeDao.xml
0 → 100644
浏览文件 @
b9cc4cc3
<?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.TbCfGoodstypeDao"
>
<resultMap
type=
"com.platform.entity.TbCfGoodstypeEntity"
id=
"tbCfGoodstypeMap"
>
<result
property=
"goodstypeId"
column=
"goodstype_id"
/>
<result
property=
"goodstypeTitle"
column=
"goodstype_title"
/>
<result
property=
"goodstypeSort"
column=
"goodstype_sort"
/>
</resultMap>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfGoodstypeEntity"
>
select
`goodstype_id`,
`goodstype_title`,
`goodstype_sort`
from tb_cf_goodstype
where goodstype_id = #{id}
</select>
<select
id=
"queryList"
resultType=
"com.platform.entity.TbCfGoodstypeEntity"
>
select
`goodstype_id`,
`goodstype_title`,
`goodstype_sort`
from tb_cf_goodstype
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 goodstype_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_goodstype
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
</if>
</select>
<insert
id=
"save"
parameterType=
"com.platform.entity.TbCfGoodstypeEntity"
>
insert into tb_cf_goodstype(
`goodstype_id`,
`goodstype_title`,
`goodstype_sort`)
values(
#{goodstypeId},
#{goodstypeTitle},
#{goodstypeSort})
</insert>
<update
id=
"update"
parameterType=
"com.platform.entity.TbCfGoodstypeEntity"
>
update tb_cf_goodstype
<set>
<if
test=
"goodstypeTitle != null"
>
`goodstype_title` = #{goodstypeTitle},
</if>
<if
test=
"goodstypeSort != null"
>
`goodstype_sort` = #{goodstypeSort}
</if>
</set>
where goodstype_id = #{goodstypeId}
</update>
<delete
id=
"delete"
>
delete from tb_cf_goodstype where goodstype_id = #{value}
</delete>
<delete
id=
"deleteBatch"
>
delete from tb_cf_goodstype where goodstype_id in
<foreach
item=
"goodstypeId"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{goodstypeId}
</foreach>
</delete>
</mapper>
\ No newline at end of file
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcffinance.html
浏览文件 @
b9cc4cc3
...
...
@@ -13,6 +13,7 @@
<i-input
v-model=
"q.name"
@
on-enter=
"query"
placeholder=
"名称"
/>
</i-col>
<i-button
@
click=
"query"
>
查询
</i-button>
<i-button
@
click=
"a"
>
test
</i-button>
<i-button
@
click=
"reloadSearch"
>
重置
</i-button>
</div>
<div
class=
"buttons-group"
>
...
...
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfgoodstype.html
0 → 100644
浏览文件 @
b9cc4cc3
<!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("tbcfgoodstype:save"))
<i-button
type=
"info"
@
click=
"add"
><i
class=
"fa fa-plus"
></i>
新增
</i-button>
#end
#if($shiro.hasPermission("tbcfgoodstype:update"))
<i-button
type=
"warning"
@
click=
"update"
><i
class=
"fa fa-pencil-square-o"
></i>
修改
</i-button>
#end
#if($shiro.hasPermission("tbcfgoodstype: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=
"tbCfGoodstype"
:rules=
"ruleValidate"
:label-width=
"80"
>
<Form-item
label=
"商品分类标题"
prop=
"goodstypeTitle"
>
<i-input
v-model=
"tbCfGoodstype.goodstypeTitle"
placeholder=
"商品分类标题"
/>
</Form-item>
<Form-item
label=
"商品分类排序编号"
prop=
"goodstypeSort"
>
<i-input
v-model=
"tbCfGoodstype.goodstypeSort"
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/tbcfgoodstype.js?_${date.systemTime}"
></script>
</body>
</html>
\ No newline at end of file
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfstationitem.html
浏览文件 @
b9cc4cc3
...
...
@@ -43,7 +43,15 @@
<i-input
v-model=
"tbCfStationItem.itemBrief"
placeholder=
"商品标题简介"
/>
</Form-item>
<Form-item
label=
"商品分类"
prop=
"itemCategory"
>
<i-input
v-model=
"tbCfStationItem.itemCategory"
placeholder=
"商品分类"
/>
<i-select
placeholder=
"请选择"
v-model=
"tbCfStationItem.itemCategory"
>
<i-option
v-for=
"(el,i) in Goodstype"
:key =
'i'
:value=
"el.goodstypeId"
>
{{el.goodstypeTitle}}
</i-option>
<!-- <i-option value="beijing">北京市</i-option>-->
<!-- <i-option value="shanghai">上海市</i-option>-->
<!-- <i-option value="shenzhen">深圳市</i-option>-->
</i-select>
</Form-item>
<Form-item
label=
"商品链接"
prop=
"itemUrl"
>
<i-input
v-model=
"tbCfStationItem.itemUrl"
placeholder=
"商品链接"
/>
...
...
platform-admin/src/main/webapp/js/sys/tbcffinance.js
浏览文件 @
b9cc4cc3
...
...
@@ -28,6 +28,7 @@ let vm = new Vue({
name
:
''
}
},
methods
:
{
query
:
function
()
{
vm
.
reload
();
...
...
@@ -62,6 +63,7 @@ let vm = new Vue({
});
},
del
:
function
(
event
)
{
let
finaceIds
=
getSelectedRows
(
"#jqGrid"
);
if
(
finaceIds
==
null
){
return
;
...
...
@@ -112,6 +114,28 @@ let vm = new Vue({
},
handleReset
:
function
(
name
)
{
handleResetForm
(
this
,
name
);
}
},
a
(){
console
.
log
(
'bcs'
)
$
.
get
(
'../tbcffinance/findByAvgOrderPrice'
,
function
(
res
)
{
console
.
log
(
res
)
})
// Ajax.request({
// url: "../tbcffinance/findBySumPay",
// type: "GET",
// contentType: "application/json",
// successCallback: function () {
//
// alert('操作成功', function (index) {
// vm.reload();
// });
// }
// });
}
},
mounted
(){
}
});
\ No newline at end of file
platform-admin/src/main/webapp/js/sys/tbcfgoodstype.js
0 → 100644
浏览文件 @
b9cc4cc3
$
(
function
()
{
$
(
"#jqGrid"
).
Grid
({
url
:
'../tbcfgoodstype/list'
,
colModel
:
[
{
label
:
'goodstypeId'
,
name
:
'goodstypeId'
,
index
:
'goodstype_id'
,
key
:
true
,
hidden
:
true
},
{
label
:
'商品分类标题'
,
name
:
'goodstypeTitle'
,
index
:
'goodstype_title'
,
width
:
80
},
{
label
:
'商品分类排序编号'
,
name
:
'goodstypeSort'
,
index
:
'goodstype_sort'
,
width
:
80
}]
});
});
let
vm
=
new
Vue
({
el
:
'#rrapp'
,
data
:
{
showList
:
true
,
title
:
null
,
tbCfGoodstype
:
{},
ruleValidate
:
{
name
:
[
{
required
:
true
,
message
:
'名称不能为空'
,
trigger
:
'blur'
}
]
},
q
:
{
name
:
''
}
},
methods
:
{
query
:
function
()
{
vm
.
reload
();
},
add
:
function
()
{
vm
.
showList
=
false
;
vm
.
title
=
"新增"
;
vm
.
tbCfGoodstype
=
{};
},
update
:
function
(
event
)
{
let
goodstypeId
=
getSelectedRow
(
"#jqGrid"
);
if
(
goodstypeId
==
null
)
{
return
;
}
vm
.
showList
=
false
;
vm
.
title
=
"修改"
;
vm
.
getInfo
(
goodstypeId
);
},
saveOrUpdate
:
function
(
event
)
{
let
url
=
vm
.
tbCfGoodstype
.
goodstypeId
==
null
?
"../tbcfgoodstype/save"
:
"../tbcfgoodstype/update"
;
Ajax
.
request
({
url
:
url
,
params
:
JSON
.
stringify
(
vm
.
tbCfGoodstype
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
(
r
)
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
},
del
:
function
(
event
)
{
let
goodstypeIds
=
getSelectedRows
(
"#jqGrid"
);
if
(
goodstypeIds
==
null
){
return
;
}
confirm
(
'确定要删除选中的记录?'
,
function
()
{
Ajax
.
request
({
url
:
"../tbcfgoodstype/delete"
,
params
:
JSON
.
stringify
(
goodstypeIds
),
type
:
"POST"
,
contentType
:
"application/json"
,
successCallback
:
function
()
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
});
}
});
});
},
getInfo
:
function
(
goodstypeId
){
Ajax
.
request
({
url
:
"../tbcfgoodstype/info/"
+
goodstypeId
,
async
:
true
,
successCallback
:
function
(
r
)
{
vm
.
tbCfGoodstype
=
r
.
tbCfGoodstype
;
}
});
},
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
platform-admin/src/main/webapp/js/sys/tbcfstationitem.js
浏览文件 @
b9cc4cc3
...
...
@@ -21,6 +21,7 @@ let vm = new Vue({
data
:
{
showList
:
true
,
title
:
null
,
Goodstype
:
null
,
tbCfStationItem
:
{},
ruleValidate
:
{
name
:
[
...
...
@@ -115,6 +116,21 @@ let vm = new Vue({
},
handleReset
:
function
(
name
)
{
handleResetForm
(
this
,
name
);
}
},
// getGoods:function (){
// console.log("bbb");
// $.get('../tbcfgoodstype/queryAll',function (res) {
// console.log(this,"aaa");
// console.log(res,"bbb");
// })
// }
},
created
(){
var
that
=
this
$
.
get
(
'../tbcfgoodstype/queryAll'
,
function
(
res
)
{
// console.log(that,"this");
that
.
Goodstype
=
JSON
.
parse
(
res
).
list
;
// console.log(that.Goodstype);
})
}
});
\ No newline at end of file
platform-schedule/pom.xml
浏览文件 @
b9cc4cc3
...
...
@@ -24,6 +24,11 @@
<artifactId>
platform-common
</artifactId>
<version>
1.0.0
</version>
</dependency>
<dependency>
<groupId>
javax.annotation
</groupId>
<artifactId>
jsr250-api
</artifactId>
<version>
1.0
</version>
</dependency>
<dependency>
<groupId>
org.quartz-scheduler
</groupId>
<artifactId>
quartz
</artifactId>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论