Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
T
tongmeng-app
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
林海冰
tongmeng-app
Commits
8b5df7df
提交
8b5df7df
authored
1月 18, 2019
作者:
林海冰
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增文件功能
上级
4daf6959
全部展开
显示空白字符变更
内嵌
并排
正在显示
21 个修改的文件
包含
1337 行增加
和
80 行删除
+1337
-80
pom.xml
pom.xml
+2
-1
ClassfyController.java
src/main/java/com/mall/controller/api/ClassfyController.java
+10
-10
StoreApiController.java
...main/java/com/mall/controller/api/StoreApiController.java
+123
-44
ViewLong.java
src/main/java/com/mall/controller/api/ViewLong.java
+50
-0
AdvertisementController.java
...oller/tongmeng/advertisement/AdvertisementController.java
+208
-0
BannerController.java
...com/mall/controller/tongmeng/banner/BannerController.java
+26
-1
QuartzMethod.java
src/main/java/com/mall/quartz/QuartzMethod.java
+18
-0
AdvertisementManager.java
.../service/mengbeng/advertisement/AdvertisementManager.java
+57
-0
AdvertisementService.java
...ice/mengbeng/advertisement/impl/AdvertisementService.java
+83
-0
EveryViewNumberManager.java
...vice/mengbeng/everyViewNumber/EveryViewNumberManager.java
+17
-0
EveryViewNumberService.java
...mengbeng/everyViewNumber/impl/EveryViewNumberService.java
+38
-0
StoreManager.java
...in/java/com/mall/service/mengbeng/store/StoreManager.java
+17
-3
StoreService.java
...va/com/mall/service/mengbeng/store/impl/StoreService.java
+26
-8
ViewStoreManager.java
...com/mall/service/mengbeng/viewstore/ViewStoreManager.java
+18
-3
ViewStoreService.java
...all/service/mengbeng/viewstore/impl/ViewStoreService.java
+14
-6
EveryViewNumberManager.xml
...in/resources/mybatis1/tongmeng/EveryViewNumberManager.xml
+55
-0
StoreManager.xml
src/main/resources/mybatis1/tongmeng/StoreManager.xml
+32
-1
ViewStoreMapper.xml
src/main/resources/mybatis1/tongmeng/ViewStoreMapper.xml
+19
-0
advertisement_edit.jsp
...WEB-INF/jsp/tongmeng/advertisement/advertisement_edit.jsp
+149
-0
advertisement_list.jsp
...WEB-INF/jsp/tongmeng/advertisement/advertisement_list.jsp
+372
-0
banner_list.jsp
src/main/webapp/WEB-INF/jsp/tongmeng/banner/banner_list.jsp
+3
-3
没有找到文件。
pom.xml
浏览文件 @
8b5df7df
...
...
@@ -764,6 +764,7 @@
<version>
3.3.1
</version>
</dependency>
</dependencies>
<build>
...
...
src/main/java/com/mall/controller/api/ClassfyController.java
浏览文件 @
8b5df7df
package
com
.
mall
.
controller
.
api
;
import
java.util.List
;
import
java.util.Map
;
import
javax.annotation.Resource
;
import
com.mall.controller.base.BaseController
;
import
com.mall.service.mengbeng.oneclassfy.OneClassfyManager
;
import
com.mall.util.PageData
;
import
com.mall.util.ResultOutDto
;
import
org.apache.commons.collections.map.HashedMap
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
com.mall.controller.base.BaseController
;
import
com.mall.service.mengbeng.oneclassfy.OneClassfyManager
;
import
com.mall.util.PageData
;
import
com.mall.util.ResultOutDto
;
import
javax.annotation.Resource
;
import
java.util.List
;
import
java.util.Map
;
@Controller
@RequestMapping
(
value
=
"/api/classfy"
,
produces
=
"application/json;charset=UTF-8"
)
public
class
ClassfyController
extends
BaseController
{
/**
* 查看全部一级分类
*/
@Resource
(
name
=
"oneclassfyService"
)
private
OneClassfyManager
oneclassfyService
;
...
...
src/main/java/com/mall/controller/api/StoreApiController.java
浏览文件 @
8b5df7df
package
com
.
mall
.
controller
.
api
;
import
javax.annotation.Resource
;
import
com.mall.service.mengbeng.everyViewNumber.EveryViewNumberManager
;
import
com.mall.service.mengbeng.api.ValidateManager
;
import
com.mall.service.mengbeng.store.StoreManager
;
import
com.mall.util.*
;
import
org.springframework.util.StringUtils
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.multipart.MultipartFile
;
import
com.mall.service.mengbeng.api.ValidateManager
;
import
com.mall.service.mengbeng.store.StoreManager
;
import
com.mall.util.DateHelper
;
import
com.mall.util.DateUtil
;
import
com.mall.util.PageData
;
import
com.mall.util.ResultOutDto
;
import
com.mall.util.SMSUtil
;
import
com.mall.util.UuidUtil
;
import
javax.annotation.Resource
;
import
java.beans.Transient
;
import
java.util.List
;
/**
* ClassName:BannerApiController <br/>
...
...
@@ -36,6 +34,8 @@ public class StoreApiController {
private
StoreManager
storeService
;
@Resource
(
name
=
"validateService"
)
private
ValidateManager
validateService
;
@Resource
(
name
=
"everyViewNumberService"
)
private
EveryViewNumberManager
everyViewNumberService
;
/**
* 注册接口
...
...
@@ -88,40 +88,6 @@ public class StoreApiController {
}
}
// @RequestMapping(value = "/loginStore")
// @ResponseBody
//
// PageData byPhone = storeService.findByPhone(phone);
// if (byPhone==null){
// return ResultOutDto.err(null, "您未注册,请先注册!");
// }
// PageData pageData = validateService.findByPhone(phone,"registerStore");
// if (pageData != null) {
// String create_time = pageData.getString("create_time");
//// 短信验证码的时效性为1分钟
// long minuteDifference = DateUtil.minuteDifference(create_time);
// if (minuteDifference <= 1) {
// return ResultOutDto.err(null, "验证码尚未过期,请填入原来的验证码");
// }
//// 临界值,或者1.5分钟
// if(minuteDifference >1){
// validateService.deleteByPhone(phone);
// return ResultOutDto.err(null,"验证码已经过期,请重新获取");
// }
// }
//// 是快递员,且pageDate为null 则为他新建一个
// SMSUtil smsUtil = new SMSUtil();
// String authcode = smsUtil.yzCode(phone,"快递柜");
// PageData pd = new PageData();
// pd.put("id", this.get32UUID());
// pd.put("phone", phone);
// pd.put("create_time", DateUtil.getTime());
// pd.put("authcode", authcode);
// pd.put("code_from","loginMessageGet");
// validateService.save(pd);
// return ResultOutDto.ok("获取登录短信成功!");
// }
/**
* 登录接口
*/
...
...
@@ -236,22 +202,135 @@ public class StoreApiController {
* @author LHB
* @since JDK 1.8
*/
@Transient
@RequestMapping
(
value
=
"/viewedStore"
)
public
ResultOutDto
viewedStore
(
String
view_store_id
,
String
viewed_store_id
)
{
if
(
StringUtils
.
isEmpty
(
view_store_id
)
||
StringUtils
.
isEmpty
(
viewed_store_id
))
{
return
ResultOutDto
.
err
(
null
,
"参数缺失!"
);
}
try
{
//保存访问记录
PageData
pd
=
new
PageData
();
pd
.
put
(
"view_store_id"
,
view_store_id
);
pd
.
put
(
"viewed_store_id"
,
viewed_store_id
);
pd
.
put
(
"view_time"
,
DateHelper
.
getCurrDateTime
());
storeService
.
viewStore
(
pd
);
//保存或者更新每天访问的记录
PageData
viewnumer
=
new
PageData
();
viewnumer
=
everyViewNumberService
.
findById
(
view_store_id
);
if
(
viewnumer
==
null
){
viewnumer
.
put
(
"store_id"
,
view_store_id
);
viewnumer
.
put
(
"view_number"
,
0
);
everyViewNumberService
.
save
(
viewnumer
);
}
else
{
viewnumer
.
put
(
"view_number"
,(
int
)
viewnumer
.
get
(
"view_number"
)+
1
);
everyViewNumberService
.
edit
(
viewnumer
);
}
return
ResultOutDto
.
ok
();
}
catch
(
Exception
e
)
{
return
ResultOutDto
.
err
(
"访问异常!"
);
}
}
/**
* 分页获取店铺的数据
*/
@RequestMapping
(
value
=
"/getClasstyStore"
)
public
ResultOutDto
getClasstyStore
(
Integer
pageIndex
,
Integer
pageSize
)
{
if
(
StringUtils
.
isEmpty
(
pageIndex
)
||
StringUtils
.
isEmpty
(
pageSize
))
{
return
ResultOutDto
.
err
(
"参数有误!"
);
}
try
{
List
<
PageData
>
stores
=
storeService
.
getClassfyStore
(
pageIndex
,
pageSize
);
return
ResultOutDto
.
ok
(
stores
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"执行异常!"
);
}
}
/**
* 通过ID完整的店铺信息
* @param storeId
* @return
*/
@RequestMapping
(
value
=
"/getOwnerStore"
)
public
ResultOutDto
getOwnerStore
(
String
storeId
)
{
try
{
if
(
StringUtils
.
isEmpty
(
storeId
)){
return
ResultOutDto
.
err
(
"参数有误!"
);
}
return
ResultOutDto
.
ok
(
storeService
.
findByIdOwner
(
storeId
));
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"获取数据异常!"
);
}
}
/**
* 编辑店铺个人基本信息
*/
@RequestMapping
(
value
=
"/updateStorePersion"
)
public
ResultOutDto
updateStorePersion
(
MultipartFile
file
,
String
storeId
,
String
realName
,
String
phone
,
String
wxNumber
,
String
qqNumber
,
String
storeName
)
{
try
{
if
(
file
!=
null
&&
StringUtils
.
isEmpty
(
storeId
)){
return
ResultOutDto
.
err
(
"参数有误!"
);
}
PageData
storePd
=
new
PageData
();
storePd
=
storeService
.
findById
(
storePd
);
if
(
file
.
getSize
()>
0
){
String
path
=
OssUtil
.
upload
(
file
);
storePd
.
put
(
"headportrait"
,
path
);
}
storePd
.
put
(
"store_id"
,
storeId
);
storePd
.
put
(
"name"
,
realName
);
storePd
.
put
(
"mobile"
,
phone
);
storePd
.
put
(
"wx_muner"
,
wxNumber
);
storePd
.
put
(
"qq_munber"
,
qqNumber
);
storePd
.
put
(
"store_name"
,
storeName
);
storeService
.
edit
(
storePd
);
return
ResultOutDto
.
ok
();
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"获取数据异常!"
);
}
}
/**
* 编辑店铺个人基本信息
*/
@Transient
@RequestMapping
(
value
=
"/updateStoreDesc"
)
public
ResultOutDto
updateStoreDesc
(
String
storeId
,
MultipartFile
file
,
String
storeName
,
String
storeDesc
,
String
storeAddress
,
String
Nweek
,
String
NHost
,
String
phone
,
String
telephone
,
String
photoUrls
)
{
try
{
if
(
StringUtils
.
isEmpty
(
storeId
)){
return
ResultOutDto
.
err
(
"参数有误!"
);
}
PageData
storePd
=
new
PageData
();
storePd
=
storeService
.
findByIdOwner
(
storeId
);
if
(
file
!=
null
&&
file
.
getSize
()>
0
){
String
path
=
OssUtil
.
upload
(
file
);
storePd
.
put
(
"store_logo"
,
path
);
}
storePd
.
put
(
"remarks"
,
storeDesc
);
storePd
.
put
(
"store_address"
,
storeAddress
);
storePd
.
put
(
"mobile"
,
phone
);
storePd
.
put
(
"weeks_number"
,
Nweek
);
storePd
.
put
(
"works_date"
,
NHost
);
storePd
.
put
(
"store_name"
,
storeName
);
storePd
.
put
(
"telephone"
,
telephone
);
storePd
.
put
(
"icom_url"
,
photoUrls
);
storeService
.
edit
(
storePd
);
storeService
.
editDesc
(
storePd
);
return
ResultOutDto
.
ok
();
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"获取数据异常!"
);
}
}
}
src/main/java/com/mall/controller/api/ViewLong.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
controller
.
api
;
import
com.mall.service.mengbeng.viewstore.ViewStoreManager
;
import
com.mall.util.ResultOutDto
;
import
org.springframework.util.StringUtils
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
javax.annotation.Resource
;
/**
* @author shkstart
* @create 2019-01-18-上午 10:09
*/
public
class
ViewLong
{
@Resource
(
name
=
"viewstoreService"
)
private
ViewStoreManager
viewstoreService
;
/**
* 查询浏览记录
*/
@RequestMapping
(
value
=
"/getPageViewLog"
)
public
ResultOutDto
getPageView
(
String
storeId
)
{
try
{
if
(
StringUtils
.
isEmpty
(
storeId
)){
return
ResultOutDto
.
err
(
"参数有误!"
);
}
return
ResultOutDto
.
ok
(
viewstoreService
.
getPageView
(
storeId
));
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"获取数据异常!"
);
}
}
/**
* 查询被访记录
*/
@RequestMapping
(
value
=
"/getPageViewedLog"
)
public
ResultOutDto
getPageViewed
(
String
storeId
)
{
try
{
if
(
StringUtils
.
isEmpty
(
storeId
)){
return
ResultOutDto
.
err
(
"参数有误!"
);
}
System
.
out
.
println
(
"============="
);
return
ResultOutDto
.
ok
(
viewstoreService
.
getPageViewed
(
storeId
));
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResultOutDto
.
err
(
"获取数据异常!"
);
}
}
}
src/main/java/com/mall/controller/tongmeng/advertisement/AdvertisementController.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
controller
.
tongmeng
.
advertisement
;
import
com.mall.controller.base.BaseController
;
import
com.mall.entity.Page
;
import
com.mall.service.mengbeng.advertisement.AdvertisementManager
;
import
com.mall.util.AppUtil
;
import
com.mall.util.Jurisdiction
;
import
com.mall.util.ObjectExcelView
;
import
com.mall.util.PageData
;
import
org.springframework.beans.propertyeditors.CustomDateEditor
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.WebDataBinder
;
import
org.springframework.web.bind.annotation.InitBinder
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.servlet.ModelAndView
;
import
javax.annotation.Resource
;
import
java.io.PrintWriter
;
import
java.text.DateFormat
;
import
java.text.SimpleDateFormat
;
import
java.util.*
;
/**
* 说明:广告模块
* 创建时间:2019-01-18
*/
@Controller
@RequestMapping
(
value
=
"/advertisement"
)
public
class
AdvertisementController
extends
BaseController
{
String
menuUrl
=
"advertisement/list.do"
;
//菜单地址(权限用)
@Resource
(
name
=
"advertisementService"
)
private
AdvertisementManager
advertisementService
;
/**保存
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/save"
)
public
ModelAndView
save
()
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"新增Advertisement"
);
if
(!
Jurisdiction
.
buttonJurisdiction
(
menuUrl
,
"add"
)){
return
null
;}
//校验权限
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
advertisementService
.
save
(
pd
);
mv
.
addObject
(
"msg"
,
"success"
);
mv
.
setViewName
(
"save_result"
);
return
mv
;
}
/**删除
* @param out
* @throws Exception
*/
@RequestMapping
(
value
=
"/delete"
)
public
void
delete
(
PrintWriter
out
)
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"删除Advertisement"
);
if
(!
Jurisdiction
.
buttonJurisdiction
(
menuUrl
,
"del"
)){
return
;}
//校验权限
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
advertisementService
.
delete
(
pd
);
out
.
write
(
"success"
);
out
.
close
();
}
/**修改
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/edit"
)
public
ModelAndView
edit
()
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"修改Advertisement"
);
if
(!
Jurisdiction
.
buttonJurisdiction
(
menuUrl
,
"edit"
)){
return
null
;}
//校验权限
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
advertisementService
.
edit
(
pd
);
mv
.
addObject
(
"msg"
,
"success"
);
mv
.
setViewName
(
"save_result"
);
return
mv
;
}
/**列表
* @param page
* @throws Exception
*/
@RequestMapping
(
value
=
"/list"
)
public
ModelAndView
list
(
Page
page
)
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"列表Advertisement"
);
//if(!Jurisdiction.buttonJurisdiction(menuUrl, "cha")){return null;} //校验权限(无权查看时页面会有提示,如果不注释掉这句代码就无法进入列表页面,所以根据情况是否加入本句代码)
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
String
keywords
=
pd
.
getString
(
"keywords"
);
//关键词检索条件
if
(
null
!=
keywords
&&
!
""
.
equals
(
keywords
)){
pd
.
put
(
"keywords"
,
keywords
.
trim
());
}
page
.
setPd
(
pd
);
List
<
PageData
>
varList
=
advertisementService
.
list
(
page
);
//列出Advertisement列表
mv
.
setViewName
(
"tongmeng/advertisement/advertisement_list"
);
mv
.
addObject
(
"varList"
,
varList
);
mv
.
addObject
(
"pd"
,
pd
);
mv
.
addObject
(
"QX"
,
Jurisdiction
.
getHC
());
//按钮权限
return
mv
;
}
/**去新增页面
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/goAdd"
)
public
ModelAndView
goAdd
()
throws
Exception
{
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
mv
.
setViewName
(
"tongmeng/advertisement/advertisement_edit"
);
mv
.
addObject
(
"msg"
,
"save"
);
mv
.
addObject
(
"pd"
,
pd
);
return
mv
;
}
/**去修改页面
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/goEdit"
)
public
ModelAndView
goEdit
()
throws
Exception
{
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
pd
=
advertisementService
.
findById
(
pd
);
//根据ID读取
mv
.
setViewName
(
"tongmeng/advertisement/advertisement_edit"
);
mv
.
addObject
(
"msg"
,
"edit"
);
mv
.
addObject
(
"pd"
,
pd
);
return
mv
;
}
/**批量删除
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/deleteAll"
)
@ResponseBody
public
Object
deleteAll
()
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"批量删除Advertisement"
);
if
(!
Jurisdiction
.
buttonJurisdiction
(
menuUrl
,
"del"
)){
return
null
;}
//校验权限
PageData
pd
=
new
PageData
();
Map
<
String
,
Object
>
map
=
new
HashMap
<
String
,
Object
>();
pd
=
this
.
getPageData
();
List
<
PageData
>
pdList
=
new
ArrayList
<
PageData
>();
String
DATA_IDS
=
pd
.
getString
(
"DATA_IDS"
);
if
(
null
!=
DATA_IDS
&&
!
""
.
equals
(
DATA_IDS
)){
String
ArrayDATA_IDS
[]
=
DATA_IDS
.
split
(
","
);
advertisementService
.
deleteAll
(
ArrayDATA_IDS
);
pd
.
put
(
"msg"
,
"ok"
);
}
else
{
pd
.
put
(
"msg"
,
"no"
);
}
pdList
.
add
(
pd
);
map
.
put
(
"list"
,
pdList
);
return
AppUtil
.
returnObject
(
pd
,
map
);
}
/**导出到excel
* @param
* @throws Exception
*/
@RequestMapping
(
value
=
"/excel"
)
public
ModelAndView
exportExcel
()
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"导出Advertisement到excel"
);
if
(!
Jurisdiction
.
buttonJurisdiction
(
menuUrl
,
"cha"
)){
return
null
;}
ModelAndView
mv
=
new
ModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
Map
<
String
,
Object
>
dataMap
=
new
HashMap
<
String
,
Object
>();
List
<
String
>
titles
=
new
ArrayList
<
String
>();
titles
.
add
(
"标题"
);
//1
titles
.
add
(
"图片或者视频"
);
//2
titles
.
add
(
"是否禁用"
);
//3
titles
.
add
(
"排序"
);
//4
titles
.
add
(
"类型"
);
//5
dataMap
.
put
(
"titles"
,
titles
);
List
<
PageData
>
varOList
=
advertisementService
.
listAll
(
pd
);
List
<
PageData
>
varList
=
new
ArrayList
<
PageData
>();
for
(
int
i
=
0
;
i
<
varOList
.
size
();
i
++){
PageData
vpd
=
new
PageData
();
vpd
.
put
(
"var1"
,
varOList
.
get
(
i
).
getString
(
"ADVERTISEMENT_NAME"
));
//1
vpd
.
put
(
"var2"
,
varOList
.
get
(
i
).
getString
(
"ADVERTISEMENT_ICOM"
));
//2
vpd
.
put
(
"var3"
,
varOList
.
get
(
i
).
get
(
"ADVERTISEMENT_IS_VAILD"
).
toString
());
//3
vpd
.
put
(
"var4"
,
varOList
.
get
(
i
).
get
(
"ADVERTISEMENT_ORDER"
).
toString
());
//4
vpd
.
put
(
"var5"
,
varOList
.
get
(
i
).
get
(
"ADVERTISEMENT_TYPE"
).
toString
());
//5
varList
.
add
(
vpd
);
}
dataMap
.
put
(
"varList"
,
varList
);
ObjectExcelView
erv
=
new
ObjectExcelView
();
mv
=
new
ModelAndView
(
erv
,
dataMap
);
return
mv
;
}
@InitBinder
public
void
initBinder
(
WebDataBinder
binder
){
DateFormat
format
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
binder
.
registerCustomEditor
(
Date
.
class
,
new
CustomDateEditor
(
format
,
true
));
}
}
src/main/java/com/mall/controller/tongmeng/banner/BannerController.java
浏览文件 @
8b5df7df
...
...
@@ -5,6 +5,7 @@ package com.mall.controller.tongmeng.banner;
import
com.mall.controller.base.BaseController
;
import
com.mall.entity.Page
;
import
com.mall.service.mengbeng.banner.BannerManager
;
import
com.mall.service.mengbeng.store.StoreManager
;
import
com.mall.util.*
;
import
org.springframework.beans.propertyeditors.CustomDateEditor
;
import
org.springframework.stereotype.Controller
;
...
...
@@ -33,6 +34,8 @@ public class BannerController extends BaseController {
String
menuUrl
=
"banner/list.do"
;
//菜单地址(权限用)
@Resource
(
name
=
"bannerService"
)
private
BannerManager
bannerService
;
@Resource
(
name
=
"storeService"
)
private
StoreManager
storeService
;
/**保存
* @param
...
...
@@ -306,7 +309,29 @@ public class BannerController extends BaseController {
return
map
;
}
/**列表
* @param page
* @throws Exception
*/
@RequestMapping
(
value
=
"/storeList"
)
public
ModelAndView
storeList
(
Page
page
)
throws
Exception
{
logBefore
(
logger
,
Jurisdiction
.
getUsername
()+
"列表Foruminfo"
);
//if(!Jurisdiction.buttonJurisdiction(menuUrl, "cha")){return null;} //校验权限(无权查看时页面会有提示,如果不注释掉这句代码就无法进入列表页面,所以根据情况是否加入本句代码)
ModelAndView
mv
=
this
.
getModelAndView
();
PageData
pd
=
new
PageData
();
pd
=
this
.
getPageData
();
String
keywords
=
pd
.
getString
(
"keywords"
);
//关键词检索条件
if
(
null
!=
keywords
&&
!
""
.
equals
(
keywords
)){
pd
.
put
(
"keywords"
,
keywords
.
trim
());
}
page
.
setPd
(
pd
);
List
<
PageData
>
varList
=
storeService
.
list
(
page
);
//列出Foruminfo列表
mv
.
setViewName
(
"tongmeng/banner/banner_store_list.jsp"
);
mv
.
addObject
(
"varList"
,
varList
);
mv
.
addObject
(
"pd"
,
pd
);
mv
.
addObject
(
"QX"
,
Jurisdiction
.
getHC
());
//按钮权限
return
mv
;
}
@InitBinder
public
void
initBinder
(
WebDataBinder
binder
){
...
...
src/main/java/com/mall/quartz/QuartzMethod.java
浏览文件 @
8b5df7df
package
com
.
mall
.
quartz
;
import
com.mall.service.mengbeng.everyViewNumber.impl.EveryViewNumberService
;
import
org.springframework.scheduling.annotation.Scheduled
;
import
org.springframework.stereotype.Component
;
import
javax.annotation.Resource
;
@Component
public
class
QuartzMethod
{
@Resource
(
name
=
"everyViewNumberService"
)
private
EveryViewNumberService
everyViewNumberService
;
/*
@Resource(name="dailyService")
private DailyManager dailyService;
...
...
@@ -26,4 +33,15 @@ public class QuartzMethod {
e.printStackTrace();
}
}*/
@Scheduled
(
cron
=
"0 0 0 * * ? "
)
//每天0点执行
public
void
daily
()
{
try
{
System
.
out
.
println
(
"<<<<<<<<<<<<<<<<<<<<<<<<<<<定时器 清理当天访问的记录<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"
);
everyViewNumberService
.
deleteAll
(
null
);
System
.
out
.
println
(
"<<<<<<<<<<<<<<<<<<<<<<<<<<<定时器<<<<<<<<<<<<<<<<<<<<<<<<<<<<<"
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
}
src/main/java/com/mall/service/mengbeng/advertisement/AdvertisementManager.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
advertisement
;
import
java.util.List
;
import
com.mall.entity.Page
;
import
com.mall.util.PageData
;
/**
* 说明: 广告模块接口
* 创建时间:2019-01-18
* @version
*/
public
interface
AdvertisementManager
{
/**新增
* @param pd
* @throws Exception
*/
public
void
save
(
PageData
pd
)
throws
Exception
;
/**删除
* @param pd
* @throws Exception
*/
public
void
delete
(
PageData
pd
)
throws
Exception
;
/**修改
* @param pd
* @throws Exception
*/
public
void
edit
(
PageData
pd
)
throws
Exception
;
/**列表
* @param page
* @throws Exception
*/
public
List
<
PageData
>
list
(
Page
page
)
throws
Exception
;
/**列表(全部)
* @param pd
* @throws Exception
*/
public
List
<
PageData
>
listAll
(
PageData
pd
)
throws
Exception
;
/**通过id获取数据
* @param pd
* @throws Exception
*/
public
PageData
findById
(
PageData
pd
)
throws
Exception
;
/**批量删除
* @param ArrayDATA_IDS
* @throws Exception
*/
public
void
deleteAll
(
String
[]
ArrayDATA_IDS
)
throws
Exception
;
}
src/main/java/com/mall/service/mengbeng/advertisement/impl/AdvertisementService.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
advertisement
.
impl
;
import
com.mall.dao.DaoSupport
;
import
com.mall.entity.Page
;
import
com.mall.service.mengbeng.advertisement.AdvertisementManager
;
import
com.mall.util.PageData
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.util.List
;
/**
* 说明: 广告模块
* 创建时间:2019-01-18
* @version
*/
@Service
(
"advertisementService"
)
public
class
AdvertisementService
implements
AdvertisementManager
{
@Resource
(
name
=
"daoSupport"
)
private
DaoSupport
dao
;
/**新增
* @param pd
* @throws Exception
*/
public
void
save
(
PageData
pd
)
throws
Exception
{
dao
.
save
(
"AdvertisementMapper.save"
,
pd
);
}
/**删除
* @param pd
* @throws Exception
*/
public
void
delete
(
PageData
pd
)
throws
Exception
{
dao
.
delete
(
"AdvertisementMapper.delete"
,
pd
);
}
/**修改
* @param pd
* @throws Exception
*/
public
void
edit
(
PageData
pd
)
throws
Exception
{
dao
.
update
(
"AdvertisementMapper.edit"
,
pd
);
}
/**列表
* @param page
* @throws Exception
*/
@SuppressWarnings
(
"unchecked"
)
public
List
<
PageData
>
list
(
Page
page
)
throws
Exception
{
return
(
List
<
PageData
>)
dao
.
findForList
(
"AdvertisementMapper.datalistPage"
,
page
);
}
/**列表(全部)
* @param pd
* @throws Exception
*/
@SuppressWarnings
(
"unchecked"
)
public
List
<
PageData
>
listAll
(
PageData
pd
)
throws
Exception
{
return
(
List
<
PageData
>)
dao
.
findForList
(
"AdvertisementMapper.listAll"
,
pd
);
}
/**通过id获取数据
* @param pd
* @throws Exception
*/
public
PageData
findById
(
PageData
pd
)
throws
Exception
{
return
(
PageData
)
dao
.
findForObject
(
"AdvertisementMapper.findById"
,
pd
);
}
/**批量删除
* @param ArrayDATA_IDS
* @throws Exception
*/
public
void
deleteAll
(
String
[]
ArrayDATA_IDS
)
throws
Exception
{
dao
.
delete
(
"AdvertisementMapper.deleteAll"
,
ArrayDATA_IDS
);
}
}
src/main/java/com/mall/service/mengbeng/everyViewNumber/EveryViewNumberManager.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
everyViewNumber
;
import
com.mall.util.PageData
;
/**
* @author shkstart
* @create 2019-01-18-下午 3:55
*/
public
interface
EveryViewNumberManager
{
public
void
save
(
PageData
pd
)
throws
Exception
;
public
void
edit
(
PageData
pd
)
throws
Exception
;
public
void
deleteAll
(
PageData
pd
)
throws
Exception
;
public
PageData
findById
(
String
id
)
throws
Exception
;
}
src/main/java/com/mall/service/mengbeng/everyViewNumber/impl/EveryViewNumberService.java
0 → 100644
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
everyViewNumber
.
impl
;
import
com.mall.dao.DaoSupport
;
import
com.mall.service.mengbeng.everyViewNumber.EveryViewNumberManager
;
import
com.mall.util.PageData
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
/**
* @author shkstart
* @create 2019-01-18-下午 3:56
*/
@Service
(
"everyViewNumberService"
)
public
class
EveryViewNumberService
implements
EveryViewNumberManager
{
@Resource
(
name
=
"daoSupport"
)
private
DaoSupport
dao
;
@Override
public
void
save
(
PageData
pd
)
throws
Exception
{
dao
.
findForObject
(
"EveryViewNumberManager.save"
,
pd
);
}
@Override
public
void
edit
(
PageData
pd
)
throws
Exception
{
dao
.
findForObject
(
"EveryViewNumberManager.edit"
,
pd
);
}
@Override
public
void
deleteAll
(
PageData
pd
)
throws
Exception
{
dao
.
findForObject
(
"EveryViewNumberManager.deleteAll"
,
null
);
}
@Override
public
PageData
findById
(
String
id
)
throws
Exception
{
return
(
PageData
)
dao
.
findForObject
(
"EveryViewNumberManager.findById"
,
id
);
}
}
src/main/java/com/mall/service/mengbeng/store/StoreManager.java
浏览文件 @
8b5df7df
...
...
@@ -31,6 +31,11 @@ public interface StoreManager{
*/
public
void
edit
(
PageData
pd
)
throws
Exception
;
/**修改店铺其他详情
* @param pd
* @throws Exception
*/
void
editDesc
(
PageData
storePd
)
throws
Exception
;
/**列表
* @param page
* @throws Exception
...
...
@@ -67,6 +72,15 @@ public interface StoreManager{
public
PageData
findByStore
(
String
storeName
)
throws
Exception
;
List
<
PageData
>
getClassfyStore
(
Integer
pageIndex
,
Integer
pageSize
)
throws
Exception
;
/**
* 通过ID获取完整的店铺信息
* @param storeName
* @return
* @throws Exception
*/
public
PageData
findByIdOwner
(
String
storeName
)
throws
Exception
;
}
...
...
src/main/java/com/mall/service/mengbeng/store/impl/StoreService.java
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
store
.
impl
;
import
java.util.List
;
import
javax.annotation.Resource
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
com.mall.dao.DaoSupport
;
import
com.mall.entity.Page
;
import
com.mall.service.mengbeng.store.StoreManager
;
import
com.mall.service.mengbeng.viewstore.ViewStoreManager
;
import
com.mall.util.PageData
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
javax.annotation.Resource
;
import
java.util.List
;
/**
* 说明: 小程序用户
...
...
@@ -52,6 +50,13 @@ public class StoreService implements StoreManager{
public
void
edit
(
PageData
pd
)
throws
Exception
{
dao
.
update
(
"StoreManager.edit"
,
pd
);
}
/**修改
* @param pd
* @throws Exception
*/
public
void
editDesc
(
PageData
pd
)
throws
Exception
{
dao
.
update
(
"StoreManager.editDesc"
,
pd
);
}
/**列表
* @param page
...
...
@@ -120,5 +125,18 @@ public class StoreService implements StoreManager{
return
(
PageData
)
dao
.
findForObject
(
"StoreManager.findByStore"
,
storeName
);
}
@Override
public
List
<
PageData
>
getClassfyStore
(
Integer
pageIndex
,
Integer
pageSize
)
throws
Exception
{
PageData
pd
=
new
PageData
();
pd
.
put
(
"pageSize"
,
pageSize
);
pd
.
put
(
"pageIndex"
,
(
Integer
.
valueOf
(
pd
.
get
(
"pageIndex"
).
toString
())-
1
)*
pageSize
);
return
(
List
<
PageData
>)
dao
.
findForList
(
"StoreManager.getClassfyStore"
,
pd
);
}
@Override
public
PageData
findByIdOwner
(
String
storeId
)
throws
Exception
{
return
(
PageData
)
dao
.
findForObject
(
"StoreManager.findByIdOwner"
,
storeId
);
}
}
src/main/java/com/mall/service/mengbeng/viewstore/ViewStoreManager.java
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
viewstore
;
import
java.util.List
;
import
com.mall.entity.Page
;
import
com.mall.util.PageData
;
import
java.util.List
;
/**
* 说明: 访问记录 接口
* 创建时间:2019-01-16
...
...
@@ -66,5 +66,20 @@ public interface ViewStoreManager{
*/
public
PageData
viewStoreedCount
(
PageData
pd
)
throws
Exception
;
/**
* 获取访问的数据
* @param storeId
* @return
* @throws Exception
*/
List
<
PageData
>
getPageView
(
String
storeId
)
throws
Exception
;
/**
* 获取被访问的数据
* @param storeId
* @return
* @throws Exception
*/
List
<
PageData
>
getPageViewed
(
String
storeId
)
throws
Exception
;
}
src/main/java/com/mall/service/mengbeng/viewstore/impl/ViewStoreService.java
浏览文件 @
8b5df7df
package
com
.
mall
.
service
.
mengbeng
.
viewstore
.
impl
;
import
java.util.List
;
import
javax.annotation.Resource
;
import
org.springframework.stereotype.Service
;
import
com.mall.dao.DaoSupport
;
import
com.mall.entity.Page
;
import
com.mall.service.mengbeng.viewstore.ViewStoreManager
;
import
com.mall.util.PageData
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.util.List
;
/**
* 说明: 访问记录
...
...
@@ -95,5 +93,15 @@ public class ViewStoreService implements ViewStoreManager{
public
PageData
viewStoreedCount
(
PageData
pd
)
throws
Exception
{
return
(
PageData
)
dao
.
findForObject
(
"ViewStoreMapper.viewStoreedCount"
,
pd
);
}
@Override
public
List
<
PageData
>
getPageView
(
String
storeId
)
throws
Exception
{
return
(
List
<
PageData
>)
dao
.
findForList
(
"ViewStoreMapper.getPageView"
,
storeId
);
}
@Override
public
List
<
PageData
>
getPageViewed
(
String
storeId
)
throws
Exception
{
return
(
List
<
PageData
>)
dao
.
findForList
(
"ViewStoreMapper.getPageViewed"
,
storeId
);
}
}
src/main/resources/mybatis1/tongmeng/EveryViewNumberManager.xml
0 → 100644
浏览文件 @
8b5df7df
<?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=
"EveryViewNumberManager"
>
<!--表名 -->
<sql
id=
"tableName"
>
c_every_view_number
</sql>
<!-- 字段 -->
<sql
id=
"Field"
>
store_id,
view_number
</sql>
<!-- 字段值 -->
<sql
id=
"FieldValue"
>
#{store_id},
#{view_number}
</sql>
<select
id=
"findById"
parameterType=
"String"
resultType=
"pd"
>
select * from
<include
refid=
"tableName"
></include>
where store_id = #{store_id}
</select>
<!-- 新增-->
<insert
id=
"save"
parameterType=
"pd"
>
insert into
<include
refid=
"tableName"
></include>
(
<include
refid=
"Field"
></include>
) values (
<include
refid=
"FieldValue"
></include>
)
</insert>
<!-- 编辑-->
<update
id=
"edit"
parameterType=
"pd"
>
update
<include
refid=
"tableName"
></include>
set
(
view_number = ${view_number}
) where (
store_id = #{store_id}
)
</update>
<delete
id=
"deleteAll"
parameterType=
"pd"
>
delete from
<include
refid=
"tableName"
></include>
</delete>
</mapper>
\ No newline at end of file
src/main/resources/mybatis1/tongmeng/StoreManager.xml
浏览文件 @
8b5df7df
...
...
@@ -121,7 +121,21 @@
end_valid_time= #{end_valid_time},
wx_muner= #{wx_muner},
qq_munber= #{qq_munber},
one_classfy_id= #{one_classfy_id}
one_classfy_id= #{one_classfy_id},
telephone = #{telephone}
where
store_id = #{store_id}
</update>
<!-- 编辑店铺其他详情 -->
<update
id=
"editDesc"
parameterType=
"pd"
>
update
c_store_desc
set
store_address =#{store_address},
weeks_number =#{weeks_number},
works_date =#{works_date},
icom_url =#{icom_url},
remarks =#{remarks}
where
store_id = #{store_id}
</update>
...
...
@@ -136,6 +150,12 @@
store_id = #{store_id}
</select>
<!-- 通过ID获取完整的店铺数据 -->
<select
id=
"findByIdOwner"
parameterType=
"String"
resultType=
"pd"
>
select * from c_store INNER JOIN c_store_desc on c_store.store_id = c_store_desc.store_id where c_store.store_id = #{store_id}
</select>
<!-- 列表 -->
<select
id=
"datalistPage"
parameterType=
"page"
resultType=
"pd"
>
...
...
@@ -223,4 +243,15 @@
where store_name = #{store_name}
</select>
<!-- 通过分类获取分页数据 -->
<select
id=
"getClassfyStore"
parameterType=
"pd"
resultType=
"pd"
>
select
store_name,store_logo
from
<include
refid=
"tableName"
></include>
where one_classfy_id = #{one_classfy_id} and is_valid_store = 0
<!-- 过滤无效的店铺-->
like ${pageIndex},${pageSize}
</select>
</mapper>
\ No newline at end of file
src/main/resources/mybatis1/tongmeng/ViewStoreMapper.xml
浏览文件 @
8b5df7df
...
...
@@ -76,4 +76,23 @@
<include
refid=
"tableName"
></include>
where viewed_store_id = #{viewed_store_id}
</select>
<!-- 查询浏览记录-->
<select
id=
"getPageView"
parameterType=
"String"
resultType=
"pd"
>
select
ed.store_id,ed.store_logo,ed.store_name,log.view_time
from c_store
INNER JOIN c_view_log as log on c_store.store_id = log.view_store_id
INNER JOIN c_store as ed on ed.store_id = log.viewed_store_id
where c_store.store_id = #{store_id}
</select>
<!-- 查询被访记录 -->
<select
id=
"getPageViewed"
parameterType=
"String"
resultType=
"pd"
>
select
e.store_id,e.store_logo,e.store_name,log.view_time
from c_store as e
INNER JOIN c_view_log as log on e.store_id = log.view_store_id
INNER JOIN c_store as ed on ed.store_id = log.viewed_store_id
where ed.store_id = #{store_id}
</select>
</mapper>
\ No newline at end of file
src/main/webapp/WEB-INF/jsp/tongmeng/advertisement/advertisement_edit.jsp
0 → 100644
浏览文件 @
8b5df7df
<%@ page
language=
"java"
contentType=
"text/html; charset=UTF-8"
pageEncoding=
"UTF-8"
%>
<%@ taglib
prefix=
"c"
uri=
"http://java.sun.com/jsp/jstl/core"
%>
<%@ taglib
prefix=
"fmt"
uri=
"http://java.sun.com/jsp/jstl/fmt"
%>
<%@ taglib
prefix=
"fn"
uri=
"http://java.sun.com/jsp/jstl/functions"
%>
<%
String
path
=
request
.
getContextPath
();
String
basePath
=
request
.
getScheme
()+
"://"
+
request
.
getServerName
()+
":"
+
request
.
getServerPort
()+
path
+
"/"
;
%>
<!DOCTYPE html>
<html
lang=
"en"
>
<head>
<!-- 下拉框 -->
<link
rel=
"stylesheet"
href=
"static/ace/css/chosen.css"
/>
<!-- jsp文件头和头部 -->
<%@ include
file=
"../../system/index/top.jsp"
%>
<!-- 日期框 -->
<link
rel=
"stylesheet"
href=
"static/ace/css/datepicker.css"
/>
</head>
<body
class=
"no-skin"
>
<!-- /section:basics/navbar.layout -->
<div
class=
"main-container"
id=
"main-container"
>
<!-- /section:basics/sidebar -->
<div
class=
"main-content"
>
<div
class=
"main-content-inner"
>
<div
class=
"page-content"
>
<div
class=
"row"
>
<div
class=
"col-xs-12"
>
<form
action=
"advertisement/${msg }.do"
name=
"Form"
id=
"Form"
method=
"post"
>
<input
type=
"hidden"
name=
"advertisement_id"
id=
"advertisement_id"
value=
"${pd.advertisement_id}"
/>
<div
id=
"zhongxin"
style=
"padding-top: 13px;"
>
<table
id=
"table_report"
class=
"table table-striped table-bordered table-hover"
>
<tr>
<td
style=
"width:75px;text-align: right;padding-top: 13px;"
>
标题:
</td>
<td><input
type=
"text"
name=
"advertisement_name"
id=
"advertisement_name"
value=
"${pd.advertisement_name}"
maxlength=
"100"
placeholder=
"这里输入标题"
title=
"标题"
style=
"width:98%;"
/></td>
</tr>
<tr>
<td
style=
"width:75px;text-align: right;padding-top: 13px;"
>
图片或者视频:
</td>
<td><input
type=
"text"
name=
"advertisement_icom"
id=
"advertisement_icom"
value=
"${pd.advertisement_icom}"
maxlength=
"255"
placeholder=
"这里输入图片或者视频"
title=
"图片或者视频"
style=
"width:98%;"
/></td>
</tr>
<tr>
<td
style=
"width:75px;text-align: right;padding-top: 13px;"
>
是否禁用:
</td>
<td><input
type=
"number"
name=
"advertisement_is_vaild"
id=
"advertisement_is_vaild"
value=
"${pd.advertisement_is_vaild}"
maxlength=
"32"
placeholder=
"这里输入是否禁用"
title=
"是否禁用"
style=
"width:98%;"
/></td>
</tr>
<tr>
<td
style=
"width:75px;text-align: right;padding-top: 13px;"
>
排序:
</td>
<td><input
type=
"number"
name=
"advertisement_order"
id=
"advertisement_order"
value=
"${pd.advertisement_order}"
maxlength=
"32"
placeholder=
"这里输入排序"
title=
"排序"
style=
"width:98%;"
/></td>
</tr>
<tr>
<td
style=
"width:75px;text-align: right;padding-top: 13px;"
>
类型:
</td>
<td><input
type=
"number"
name=
"advertisement_type"
id=
"advertisement_type"
value=
"${pd.advertisement_type}"
maxlength=
"32"
placeholder=
"这里输入类型"
title=
"类型"
style=
"width:98%;"
/></td>
</tr>
<tr>
<td
style=
"text-align: center;"
colspan=
"10"
>
<a
class=
"btn btn-mini btn-primary"
onclick=
"save();"
>
保存
</a>
<a
class=
"btn btn-mini btn-danger"
onclick=
"top.Dialog.close();"
>
取消
</a>
</td>
</tr>
</table>
</div>
<div
id=
"zhongxin2"
class=
"center"
style=
"display:none"
><br/><br/><br/><br/><br/><img
src=
"static/images/jiazai.gif"
/><br/><h4
class=
"lighter block green"
>
提交中...
</h4></div>
</form>
</div>
<!-- /.col -->
</div>
<!-- /.row -->
</div>
<!-- /.page-content -->
</div>
</div>
<!-- /.main-content -->
</div>
<!-- /.main-container -->
<!-- 页面底部js¨ -->
<%@ include
file=
"../../system/index/foot.jsp"
%>
<!-- 下拉框 -->
<script
src=
"static/ace/js/chosen.jquery.js"
></script>
<!-- 日期框 -->
<script
src=
"static/ace/js/date-time/bootstrap-datepicker.js"
></script>
<!--提示框-->
<script
type=
"text/javascript"
src=
"static/js/jquery.tips.js"
></script>
<script
type=
"text/javascript"
>
$
(
top
.
hangge
());
//保存
function
save
(){
if
(
$
(
"#advertisement_name"
).
val
()
==
""
){
$
(
"#advertisement_name"
).
tips
({
side
:
3
,
msg
:
'请输入标题'
,
bg
:
'#ae81ff'
,
time
:
2
});
$
(
"#advertisement_name"
).
focus
();
return
false
;
}
if
(
$
(
"#advertisement_icom"
).
val
()
==
""
){
$
(
"#advertisement_icom"
).
tips
({
side
:
3
,
msg
:
'请输入图片或者视频'
,
bg
:
'#ae81ff'
,
time
:
2
});
$
(
"#advertisement_icom"
).
focus
();
return
false
;
}
if
(
$
(
"#advertisement_is_vaild"
).
val
()
==
""
){
$
(
"#advertisement_is_vaild"
).
tips
({
side
:
3
,
msg
:
'请输入是否禁用'
,
bg
:
'#ae81ff'
,
time
:
2
});
$
(
"#advertisement_is_vaild"
).
focus
();
return
false
;
}
if
(
$
(
"#advertisement_order"
).
val
()
==
""
){
$
(
"#advertisement_order"
).
tips
({
side
:
3
,
msg
:
'请输入排序'
,
bg
:
'#ae81ff'
,
time
:
2
});
$
(
"#advertisement_order"
).
focus
();
return
false
;
}
if
(
$
(
"#advertisement_type"
).
val
()
==
""
){
$
(
"#advertisement_type"
).
tips
({
side
:
3
,
msg
:
'请输入类型'
,
bg
:
'#ae81ff'
,
time
:
2
});
$
(
"#advertisement_type"
).
focus
();
return
false
;
}
$
(
"#form"
).
submit
();
$
(
"#zhongxin"
).
hide
();
$
(
"#zhongxin2"
).
show
();
}
$
(
function
()
{
//日期框
$
(
'.date-picker'
).
datepicker
({
autoclose
:
true
,
todayHighlight
:
true
});
});
</script>
</body>
</html>
\ No newline at end of file
src/main/webapp/WEB-INF/jsp/tongmeng/advertisement/advertisement_list.jsp
0 → 100644
浏览文件 @
8b5df7df
差异被折叠。
点击展开。
src/main/webapp/WEB-INF/jsp/tongmeng/banner/banner_list.jsp
浏览文件 @
8b5df7df
...
...
@@ -218,7 +218,7 @@
</span>
</a>
<a
style=
"cursor:pointer;"
onclick=
"
foruminfo
List('${var.banner_id}','${var.type }');"
class=
"btn btn-xs btn-danger"
data-rel=
"tooltip"
title=
"外部链接设置"
>
<a
style=
"cursor:pointer;"
onclick=
"
store
List('${var.banner_id}','${var.type }');"
class=
"btn btn-xs btn-danger"
data-rel=
"tooltip"
title=
"外部链接设置"
>
<span
class=
"while"
>
<i
class=
"ace-icon fa fa-random bigger-120"
></i>
</span>
...
...
@@ -419,12 +419,12 @@
}
//绑定FORUMINDO_show_id
function
foruminfo
List
(
id
,
type
){
function
store
List
(
id
,
type
){
top
.
jzts
();
var
diag
=
new
top
.
Dialog
();
diag
.
Drag
=
true
;
diag
.
Title
=
"编辑"
;
diag
.
URL
=
'${pageContext.request.contextPath}/banner/
foruminfo
List.do?bannerId='
+
id
+
'&TYPE='
+
type
;
diag
.
URL
=
'${pageContext.request.contextPath}/banner/
store
List.do?bannerId='
+
id
+
'&TYPE='
+
type
;
diag
.
Width
=
1024
;
diag
.
Height
=
1024
;
diag
.
Modal
=
true
;
//有无遮罩窗口
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论