소스 검색

Merge remote-tracking branch 'origin/developerD' into developerE

JiangChongBo 2 년 전
부모
커밋
e312792828

+ 13 - 1
src/main/java/com/caimei/modules/cmpage/entity/CmPage.java

@@ -47,6 +47,10 @@ public class CmPage extends DataEntity<CmPage> {
     private String enabledStatus;        // 状态 0停用 1启用
     private String crmHeadImage;//crm端首层大图
     private String headLink;//首层大图链接
+
+    // 内容标签
+    private String contentLabel;
+
     private String backgroundType;  //填充背景类型默认不显示 :1使用颜色,2使用背景图
     private String backgroundColour;  //背景颜色,示例#3333b9
     private String backgroundImage;   //背景图
@@ -91,6 +95,14 @@ public class CmPage extends DataEntity<CmPage> {
         this.buttonLink = buttonLink;
     }
 
+    public String getContentLabel() {
+        return contentLabel;
+    }
+
+    public void setContentLabel(String contentLabel) {
+        this.contentLabel = contentLabel;
+    }
+
     public String getBackgroundType() {
         return backgroundType;
     }
@@ -358,4 +370,4 @@ public class CmPage extends DataEntity<CmPage> {
     public void setInfoBarStatus(Integer infoBarStatus) {
         this.infoBarStatus = infoBarStatus;
     }
-}
+}

+ 30 - 0
src/main/java/com/caimei/modules/user/dao/CmBehaviorRecordDao.java

@@ -0,0 +1,30 @@
+package com.caimei.modules.user.dao;
+
+import com.caimei.modules.user.entity.CmBehaviorRecord;
+import com.caimei.modules.user.entity.CmPageType;
+import com.thinkgem.jeesite.common.persistence.CrudDao;
+import com.thinkgem.jeesite.common.persistence.annotation.MyBatisDao;
+
+import java.util.List;
+
+/**
+ * Description
+ *
+ * @author : Charles
+ * @date : 2022/11/1
+ */
+@MyBatisDao
+public interface CmBehaviorRecordDao extends CrudDao<CmBehaviorRecord> {
+    /**
+     * 查询单条详情
+     * @param cmBehaviorRecord
+     * @return
+     */
+    List<CmBehaviorRecord> recordList(CmBehaviorRecord cmBehaviorRecord);
+
+    /**
+     * 页面类型下拉
+     * @return
+     */
+    List<CmPageType> pageType();
+}

+ 251 - 0
src/main/java/com/caimei/modules/user/entity/CmBehaviorRecord.java

@@ -0,0 +1,251 @@
+package com.caimei.modules.user.entity;
+
+import com.alibaba.fastjson.annotation.JSONField;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.thinkgem.jeesite.common.persistence.DataEntity;
+import lombok.Data;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.io.Serializable;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * Description
+ *
+ * @author : Charles
+ * @date : 2022/11/1
+ */
+public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
+    private Integer recordID ;
+    private String IP;  //访问人IP地址
+    private Integer userID; //用户id、0为游客
+    private String pagePath;    //页面路径
+    private String pageType;    //页面类型
+    private String pageLabel;   //页面标签
+    private String productImage;    //商品图片
+    private Integer productID;  //商品ID
+    private String productName; //商品名称
+    private String accessTime;    //访问时间
+    private String accessDuration;  //访问时长
+    private String accessDate;  //访问日期
+
+    private Integer numbers;    //访问页面总数
+    private String userIdentity; //公司类型
+
+    private String name; // 机构公司名称
+    private String linkMan; //机构联系人
+    private String contractMobile;  //联系手机
+
+    private String sname; // 供应商公司名称
+    private String slinkMan; //供应商联系人
+    private String scontractMobile;  //联系手机
+    private String spName;  // 协销名称
+    private String startTime; //开始时间
+    private String endTime; //结束时间
+
+    private Integer shopID; // 供应商ID
+
+    private String pageTypes;   //页面类型下拉
+
+
+    public Integer getRecordID() {
+        return recordID;
+    }
+
+    public void setRecordID(Integer recordID) {
+        this.recordID = recordID;
+    }
+
+    public String getIP() {
+        return IP;
+    }
+
+    public void setIP(String IP) {
+        this.IP = IP;
+    }
+
+    public Integer getUserID() {
+        return userID;
+    }
+
+    public void setUserID(Integer userID) {
+        this.userID = userID;
+    }
+
+    public String getPagePath() {
+        return pagePath;
+    }
+
+    public void setPagePath(String pagePath) {
+        this.pagePath = pagePath;
+    }
+
+    public String getPageType() {
+        return pageType;
+    }
+
+    public void setPageType(String pageType) {
+        this.pageType = pageType;
+    }
+
+    public String getPageLabel() {
+        return pageLabel;
+    }
+
+    public void setPageLabel(String pageLabel) {
+        this.pageLabel = pageLabel;
+    }
+
+    public String getProductImage() {
+        return productImage;
+    }
+
+    public void setProductImage(String productImage) {
+        this.productImage = productImage;
+    }
+
+    public Integer getProductID() {
+        return productID;
+    }
+
+    public void setProductID(Integer productID) {
+        this.productID = productID;
+    }
+
+    public String getProductName() {
+        return productName;
+    }
+
+    public void setProductName(String productName) {
+        this.productName = productName;
+    }
+
+    public String getAccessTime() {
+        return accessTime;
+    }
+
+    public void setAccessTime(String accessTime) {
+        this.accessTime = accessTime;
+    }
+
+    public String getAccessDuration() {
+        return accessDuration;
+    }
+
+    public void setAccessDuration(String accessDuration) {
+        this.accessDuration = accessDuration;
+    }
+
+    public String getAccessDate() {
+        return accessDate;
+    }
+
+    public void setAccessDate(String accessDate) {
+        this.accessDate = accessDate;
+    }
+
+    public Integer getNumbers() {
+        return numbers;
+    }
+
+    public void setNumbers(Integer numbers) {
+        this.numbers = numbers;
+    }
+
+    public String getUserIdentity() {
+        return userIdentity;
+    }
+
+    public void setUserIdentity(String userIdentity) {
+        this.userIdentity = userIdentity;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getLinkMan() {
+        return linkMan;
+    }
+
+    public void setLinkMan(String linkMan) {
+        this.linkMan = linkMan;
+    }
+
+    public String getContractMobile() {
+        return contractMobile;
+    }
+
+    public void setContractMobile(String contractMobile) {
+        this.contractMobile = contractMobile;
+    }
+
+    public String getSname() {
+        return sname;
+    }
+
+    public void setSname(String sname) {
+        this.sname = sname;
+    }
+
+    public String getSlinkMan() {
+        return slinkMan;
+    }
+
+    public void setSlinkMan(String slinkMan) {
+        this.slinkMan = slinkMan;
+    }
+
+    public String getScontractMobile() {
+        return scontractMobile;
+    }
+
+    public void setScontractMobile(String scontractMobile) {
+        this.scontractMobile = scontractMobile;
+    }
+
+    public String getSpName() {
+        return spName;
+    }
+
+    public void setSpName(String spName) {
+        this.spName = spName;
+    }
+
+    public String getStartTime() {
+        return startTime;
+    }
+
+    public void setStartTime(String startTime) {
+        this.startTime = startTime;
+    }
+
+    public String getEndTime() {
+        return endTime;
+    }
+
+    public void setEndTime(String endTime) {
+        this.endTime = endTime;
+    }
+
+    public Integer getShopID() {
+        return shopID;
+    }
+
+    public void setShopID(Integer shopID) {
+        this.shopID = shopID;
+    }
+
+    public String getPageTypes() {
+        return pageTypes;
+    }
+
+    public void setPageTypes(String pageTypes) {
+        this.pageTypes = pageTypes;
+    }
+}

+ 31 - 0
src/main/java/com/caimei/modules/user/entity/CmPageType.java

@@ -0,0 +1,31 @@
+package com.caimei.modules.user.entity;
+
+import com.thinkgem.jeesite.common.persistence.DataEntity;
+
+/**
+ * Description
+ *
+ * @author : Charles
+ * @date : 2022/11/7
+ */
+public class CmPageType extends DataEntity<CmPageType> {
+
+    private Integer idPage; // 页面标签Id
+    private String pageType;    //页面标签名称
+
+    public Integer getIdPage() {
+        return idPage;
+    }
+
+    public void setIdPage(Integer idPage) {
+        this.idPage = idPage;
+    }
+
+    public String getPageType() {
+        return pageType;
+    }
+
+    public void setPageType(String pageType) {
+        this.pageType = pageType;
+    }
+}

+ 88 - 0
src/main/java/com/caimei/modules/user/service/CmBehaviorRecordService.java

@@ -0,0 +1,88 @@
+package com.caimei.modules.user.service;
+
+import com.caimei.modules.user.dao.CmBehaviorRecordDao;
+import com.caimei.modules.user.entity.CmBehaviorRecord;
+import com.caimei.modules.user.entity.CmPageType;
+import com.thinkgem.jeesite.common.persistence.Page;
+import com.thinkgem.jeesite.common.service.CrudService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * Description
+ *
+ * @author : Charles
+ * @date : 2022/11/1
+ */
+@Service
+public class CmBehaviorRecordService extends CrudService<CmBehaviorRecordDao, CmBehaviorRecord> {
+
+    @Autowired private CmBehaviorRecordDao cmBehaviorRecordDao;
+
+
+    public Page<CmBehaviorRecord> findPage(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord) {
+        return super.findPage(page, cmBehaviorRecord);
+    }
+
+    /**
+     * 用户行为详情
+     * @param page
+     * @param cmBehaviorRecord
+     * @return
+     */
+    public Page<CmBehaviorRecord> recordPage(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord){
+        cmBehaviorRecord.setPage(page);
+        // 用户行为详情
+        List<CmBehaviorRecord> cmBehaviorRecordList = cmBehaviorRecordDao.recordList(cmBehaviorRecord);
+
+        for(CmBehaviorRecord record: cmBehaviorRecordList) {
+            String time = calculationTime(record.getAccessDuration());
+            record.setAccessDuration(time);
+        }
+        page.setList(cmBehaviorRecordList);
+        return page;
+    }
+
+    /**
+     * 时间计算
+     * @param recordTime
+     * @return
+     */
+    public String calculationTime(String recordTime){
+        double doc = Double.parseDouble(recordTime);
+        int num = (int)doc;
+        //小时
+        int HH = 0;
+        // 分钟
+        int mm = 0;
+        //秒
+        int ss = 0;
+        int item = num / 1000;
+        if ((item / 60) >0) {
+            mm = item / 60;
+            ss = item % 60;
+        } else {
+            ss = item;
+        }
+        if ((mm / 60) >0) {
+            HH = mm / 60;
+            mm = mm % 60;
+        }
+        String  str= HH+":"+mm+":"+ss;
+        SimpleDateFormat dateFormat = new SimpleDateFormat("HH:mm:ss");
+        Date parse = null;
+        try {
+            parse = dateFormat.parse(str);
+        } catch (ParseException e) {
+            e.printStackTrace();
+        }
+        String format = dateFormat.format(parse);
+        return format;
+    }
+
+}

+ 70 - 0
src/main/java/com/caimei/modules/user/web/CmUserBehaviorRecordController.java

@@ -0,0 +1,70 @@
+package com.caimei.modules.user.web;
+
+import com.caimei.modules.user.dao.CmBehaviorRecordDao;
+import com.caimei.modules.user.entity.CmBehaviorRecord;
+import com.caimei.modules.user.entity.CmPageType;
+import com.caimei.modules.user.service.CmBehaviorRecordService;
+import com.thinkgem.jeesite.common.persistence.Page;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.Model;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * Description
+ *
+ * @author : Charles
+ * @date : 2022/10/28
+ */
+@Controller
+@RequestMapping(value = "${adminPath}/user/behavior/record")
+public class CmUserBehaviorRecordController {
+
+    @Autowired private CmBehaviorRecordService cmBehaviorRecordService;
+
+    @Autowired private CmBehaviorRecordDao cmBehaviorRecordDao;
+
+    /**
+     * 用户行为记录
+     * @param cmBehaviorRecord
+     * @param request
+     * @param response
+     * @param model
+     * @return
+     */
+    @RequestMapping(value = {"list", ""})
+    public String List(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model){
+        Page<CmBehaviorRecord> page = cmBehaviorRecordService.findPage(new Page<>(request, response), cmBehaviorRecord);
+        for(CmBehaviorRecord record: page.getList()) {
+            String time = cmBehaviorRecordService.calculationTime(record.getAccessDuration());
+            record.setAccessDuration(time);
+        }
+        model.addAttribute("page",page);
+        model.addAttribute("cmBehaviorRecord", cmBehaviorRecord);
+        return "modules/user/behaviorRecordList";
+    }
+
+    /**
+     * 用户行为记录详情
+     * @param cmBehaviorRecord
+     * @param request
+     * @param response
+     * @param model
+     * @return
+     */
+    @RequestMapping("/recordList")
+    public String selRecordList(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model) {
+        Page<CmBehaviorRecord> page = cmBehaviorRecordService.recordPage(new Page<>(request, response), cmBehaviorRecord);
+        // 页面类型下拉数据
+        List<CmPageType> cmPageTypes = cmBehaviorRecordDao.pageType();
+        model.addAttribute("page", page);
+        model.addAttribute("cmBehaviorRecord", cmBehaviorRecord);
+        model.addAttribute("pageTypes",cmPageTypes);
+        return "modules/user/behaviorRecordDetailsList";
+    }
+
+}

+ 6 - 2
src/main/resources/mappings/modules/cmpage/CmPageMapper.xml

@@ -26,6 +26,7 @@
 		a.createDate AS "createDate",
 		a.updateBy AS "updateBy.id",
 		a.updateDate AS "updateDate",
+		a.contentLabel as "contentLabel",
 		a.backgroundType AS "backgroundType",
 		a.backgroundColour AS "backgroundColour",
 		a.backgroundImage AS "backgroundImage",
@@ -123,6 +124,7 @@
 			createDate,
 			updateBy,
 			updateDate,
+			contentLabel,
 			backgroundType,
 			backgroundColour,
 			backgroundImage,
@@ -153,6 +155,7 @@
 			#{createDate},
 			#{updateBy.id},
 			#{updateDate},
+		    #{contentLabel},
 			#{backgroundType},
 			#{backgroundColour},
 			#{backgroundImage},
@@ -164,7 +167,7 @@
 	</insert>
 
     <update id="update">
-		UPDATE cm_page SET 	
+		UPDATE cm_page SET
 			title = #{title},
 			typeSort = #{typeSort},
 			keywords = #{keywords},
@@ -186,6 +189,7 @@
 			createDate = #{createDate},
 			updateBy = #{updateBy.id},
 			updateDate = #{updateDate},
+			contentLabel = #{contentLabel},
 			backgroundType = #{backgroundType},
 			backgroundColour = #{backgroundColour},
 			backgroundImage = #{backgroundImage},
@@ -232,4 +236,4 @@
 	<select id="findHotSearch" resultType="com.caimei.modules.cmpage.entity.CmPageHotSearch">
 		SELECT * FROM cm_page_hot_search WHERE pageId = #{pageId}
 	</select>
-</mapper>
+</mapper>

+ 102 - 0
src/main/resources/mappings/modules/user/CmBehaviorRecordMapper.xml

@@ -0,0 +1,102 @@
+<?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.caimei.modules.user.dao.CmBehaviorRecordDao">
+    <sql id="behaviorRecord">
+        b.recordID,
+        b.IP,
+        b.userID,
+        b.pagePath,
+        b.pageType,
+        b.pageLabel,
+        b.productID,
+        b.accessTime,
+        b.accessDate
+    </sql>
+    <select id="findList" resultType="CmBehaviorRecord">
+        SELECT
+          <include refid="behaviorRecord"/>
+          ,SUM(b.accessDuration) AS accessDuration,
+          u.userIdentity,
+          c.name,
+          c.linkMan,
+          c.contractMobile,
+          s.name AS sname,
+          s.linkMan AS slinkMan,
+          s.contractMobile AS scontractMobile,
+          (SELECT CASE STATUS WHEN 91 THEN '采美默认协销经理(官方账号)' ELSE linkMan END FROM serviceprovider WHERE serviceProviderID = c.spID) AS spName,
+          COUNT(IP) as numbers
+        FROM cm_behavior_record b
+        LEFT JOIN USER u ON b.userID = u.userID
+        LEFT JOIN club c ON b.userID = c.userID
+        LEFT JOIN shop s ON b.userID = s.userID
+        LEFT JOIN serviceprovider sp on c.spID = sp.serviceProviderID
+        <where>
+            <if test="name != null and name != ''">
+                u.name = #{name}
+            </if>
+            <if test="userIdentity != null and userIdentity != ''">
+                <if test="userIdentity == 2">
+                    AND u.userIdentity in (2, 4)
+                </if>
+                <if test="userIdentity == 3">
+                    AND u.userIdentity = 3
+                </if>
+                <if test="userIdentity == 1">
+                    AND  b.userID = 0
+                </if>
+            </if>
+            <if test="linkMan != null and linkMan != ''">
+                AND (c.linkMan = #{linkMan} or s.linkMan = #{linkMan})
+            </if>
+            <if test="contractMobile != null and contractMobile != ''">
+                AND (c.contractMobile = #{contractMobile} or s.contractMobile = #{contractMobile})
+            </if>
+            <if test="spName != null and spName != ''">
+                AND sp.name = #{spName}
+            </if>
+            <if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
+                AND b.accessDate between #{startTime} and #{endTime}
+            </if>
+        </where>
+        GROUP BY b.IP, b.accessDate,b.userID ORDER BY b.accessTime DESC
+    </select>
+
+    <select id="recordList" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
+        SELECT
+        <include refid="behaviorRecord"/>
+           ,b.accessDuration,
+           u.userIdentity,
+           c.name,
+           c.linkMan,
+           c.contractMobile,
+           s.name AS sname,
+           s.linkMan AS slinkMan,
+           s.contractMobile AS sncontractMobile,
+           c.spID,
+           p.name AS productName,
+           p.mainImage AS productImage,
+           pt.pagetype AS pageTypes
+        FROM cm_behavior_record b
+        LEFT JOIN USER u ON b.userID = u.userID
+        LEFT JOIN club c ON b.userID = c.userID
+        LEFT JOIN shop s ON b.userID = s.userID
+        LEFT JOIN product p ON b.productID = p.productID
+        LEFT JOIN cm_page_type pt ON b.pageType = pt.id
+        <where>
+            b.IP = #{IP} AND b.accessDate = #{accessDate} AND b.userID = #{userID}
+            <if test="pageType != null and pageType != ''">
+                AND b.pageType = #{pageType}
+            </if>
+            <if test="productID != null and productID != ''">
+                AND p.productID = #{productID}
+            </if>
+            <if test="productName != null and productName != ''">
+                AND p.name like concat('%',#{productName},'%')
+            </if>
+        </where>
+        ORDER BY accessTime DESC
+    </select>
+    <select id="pageType" resultType="com.caimei.modules.user.entity.CmPageType">
+        SELECT id as idPage,pageType FROM cm_page_type
+    </select>
+</mapper>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmLecturerPageForm.jsp

@@ -87,6 +87,13 @@
 			<shiro:hasPermission name="cmpage:cmPage:edit"><input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>&nbsp;</shiro:hasPermission>
 			<input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
 		</div>
+		<div class="control-group">
+			<label class="control-label"><font color="red">*</font>内容标签:</label>
+			<div class="controls">
+				<form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+				<span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+			</div>
+		</div>
 	</form:form>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageActivityForm.jsp

@@ -98,6 +98,13 @@
             <form:input path="headLink" htmlEscape="false" maxlength="255" placeholder="输入URL地址" class="input-xlarge url"/>
         </div>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">填充背景:</label>
         <div class="controls">
@@ -141,4 +148,4 @@
     </div>
 </form:form>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageBeautyForm.jsp

@@ -112,6 +112,13 @@
                    onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
         </div>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">咨询浮窗:</label>
         <div class="controls">
@@ -135,4 +142,4 @@
     </div>
 </form:form>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageDetailsForm.jsp

@@ -95,6 +95,13 @@
             </form:select>
         </div>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">填充背景:</label>
         <div class="controls">
@@ -362,4 +369,4 @@
 
 </script>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageFreedomForm.jsp

@@ -143,6 +143,13 @@
             </tr>
         </table>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">填充背景:</label>
         <div class="controls">
@@ -187,4 +194,4 @@
 
 </form:form>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageProjectDetailForm.jsp

@@ -307,6 +307,13 @@
             <label style="color:#D0D0D0 ;">尺寸:700 * 300 / PX</label>
         </div>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">填充背景:</label>
         <div class="controls">
@@ -350,4 +357,4 @@
 </div>
 </form:form>
 </body>
-</html>
+</html>

+ 8 - 1
src/main/webapp/WEB-INF/views/modules/cmpage/cmPageSecondaryForm.jsp

@@ -158,6 +158,13 @@
             <label style="color:#D0D0D0 ;">尺寸:700 * 300 / PX</label>
         </div>
     </div>
+    <div class="control-group">
+        <label class="control-label"><font color="red">*</font>内容标签:</label>
+        <div class="controls">
+            <form:input path="contentLabel" htmlEscape="false" maxlength="20" class="input-small required"/>
+            <span style="color: red">(请总结本页面的宣传内容,以简短标签关键词的形式填入,多个标签用中文逗号隔开)</span>
+        </div>
+    </div>
     <div class="control-group">
         <label class="control-label">填充背景:</label>
         <div class="controls">
@@ -201,4 +208,4 @@
     </div>
 </form:form>
 </body>
-</html>
+</html>

+ 105 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordDetailsList.jsp

@@ -0,0 +1,105 @@
+<%@ taglib prefix="C" uri="http://java.sun.com/jsp/jstl/core" %>
+<%--
+  Created by IntelliJ IDEA.
+  User: Administrator
+  Date: 2022/10/31
+  Time: 10:57
+  To change this template use File | Settings | File Templates.
+--%>
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
+<html>
+<head>
+    <title>Title</title>
+    <meta name="decorator" content="default"/>
+    <style>
+        .table th{
+            text-align: center;
+        }
+        .table td{
+            text-align: center;
+        }
+    </style>
+</head>
+<body>
+<ul class="nav nav-tabs">
+    <li><a href="${ctx}/user/behavior/record/list">用户行为记录</a></li>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}">查看详情</a></li>
+</ul>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}" method="post" class="breadcrumb form-search">
+    <input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
+    <input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
+    <div class="ul-form">
+        <label>页面类型:</label>
+        <form:select path="pageType" class="input-medium required">
+            <form:option value="" label="请选择"/>
+<%--            <form:options value="${pageTypes}" itemValue="id" itemLabel="pageType"  htmlEscape="false"/>--%>
+            <c:forEach items="${pageTypes}" var="pageTypes" varStatus="omdex">
+                <form:option value="${pageTypes.idPage}">${pageTypes.pageType}</form:option>
+            </c:forEach>
+          <%--  <form:option value="商城首页" label="首页"/>
+            <form:option value="新品橱窗" label="商品详情"/>
+            <form:option value="二手市场" label="供应商主页"/>--%>
+        </form:select>
+        <label>商品ID:</label>
+        <form:input path="productID" htmlEscape="false" maxlength="20" class="input-small"/>
+        <label>商品名称:</label>
+        <form:input path="productName" htmlEscape="false" maxlength="20" class="input-small"/>
+        &nbsp;&nbsp;<input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
+        <div class="clearfix"></div>
+    </div>
+</form:form>
+<sys:message content="${message}"/>
+<table id="contentTable" class="table table-striped table-bordered table-condensed">
+    <thead>
+    <tr>
+        <th>页面路径</th>
+        <th>页面类型</th>
+        <th>页面标签</th>
+        <th>商品图片</th>
+        <th>商品ID</th>
+        <th>商品名称</th>
+        <th>访问时间</th>
+        <th>访问时长</th>
+    </tr>
+    </thead>
+    <tbody>
+    <C:forEach items="${page.list}" var="cmBehaviorRecord" varStatus="index">
+        <tr>
+            <td>
+                <c:if test="${!fn:contains(cmBehaviorRecord.pagePath,'http')}">
+                    <a>${cmBehaviorRecord.pagePath}</a>
+                </c:if>
+                <c:if test="${fn:contains(cmBehaviorRecord.pagePath,'http')}">
+                    <a href="${cmBehaviorRecord.pagePath}" target="_blank">${cmBehaviorRecord.pagePath}</a>
+                </c:if>
+            </td>
+            <td>${cmBehaviorRecord.pageTypes}</td>
+            <td>${cmBehaviorRecord.pageLabel}</td>
+            <c:if test="${cmBehaviorRecord.productID == '0'}">
+                <td>------</td>
+                <td>------</td>
+                <td>------</td>
+            </c:if>
+            <c:if test="${cmBehaviorRecord.productID != '0'}">
+                <td><img src="${cmBehaviorRecord.productImage}" width="50" height="50"></td>
+                <td>${cmBehaviorRecord.productID}</td>
+                <td>${cmBehaviorRecord.productName}</td>
+            </c:if>
+            <td>${cmBehaviorRecord.accessTime}</td>
+            <td>${cmBehaviorRecord.accessDuration}</td>
+        </tr>
+    </C:forEach>
+    </tbody>
+</table>
+<div class="pagination">${page}</div>
+<script type="text/javascript">
+    function page(n,s){
+        $("#pageNo").val(n);
+        $("#pageSize").val(s);
+        $("#searchForm").submit();
+        return false;
+    }
+</script>
+</body>
+</html>

+ 166 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordList.jsp

@@ -0,0 +1,166 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<%--
+  Created by IntelliJ IDEA.
+  User: Administrator
+  Date: 2022/10/31
+  Time: 9:25
+  To change this template use File | Settings | File Templates.
+--%>
+<%@ page import="com.thinkgem.jeesite.common.config.Global" %>
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/WEB-INF/views/include/taglib.jsp" %>
+
+<html>
+<head>
+    <title>用户行为记录</title>
+    <meta name="decorator" content="default"/>
+    <style>
+        .table th{
+            text-align: center;
+        }
+        .table td{
+            text-align: center;
+        }
+        .ul-form input,select{
+            margin-left: 10px;
+        }
+        .ys-kin input,span{
+            margin-left: 10px;
+        }
+    </style>
+</head>
+<body>
+<ul class="nav nav-tabs">
+    <li class="active"><a href="${ctx}/user/behavior/record/list">用户行为记录</a></li>
+</ul>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/list" method="post" class="breadcrumb form-search">
+    <input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
+    <input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
+    <div class="ul-form">
+        <label>公司名称:</label>
+            <form:input path="name" htmlEscape="false" maxlength="11" class="input-mini"/>
+        <label>公司类型:</label>
+            <form:select path="userIdentity" class="input-medium required">
+                <form:option value="" label="请选择"/>
+                <form:option value="2" label="机构"/>
+                <form:option value="3" label="供应商"/>
+                <form:option value="1" label="游客"/>
+            </form:select>
+        <label>联系人:</label>
+            <form:input path="linkMan" htmlEscape="false" maxlength="20" class="input-small"/>
+        <label>手机号码:</label>
+            <form:input path="contractMobile" htmlEscape="false" maxlength="20" class="input-small"/>
+        <label>协销:</label>
+            <form:input path="spName" htmlEscape="false" maxlength="20" class="input-small"/>
+        <div class="ys-kin" style="margin-top: 20px">
+            <label>访问日期:</label>
+            <input name="startTime" type="text" readonly="readonly" maxlength="15" class="input-mini Wdate"
+                   value="${cmBehaviorRecord.startTime}"
+                   onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/> <span> > </span>
+            <input name="endTime" type="text" readonly="readonly" maxlength="15" class="input-mini Wdate"
+                   value="${cmBehaviorRecord.endTime}"
+                   onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
+            <input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
+        </div>
+        <div class="clearfix"></div>
+    </div>
+</form:form>
+<sys:message content="${message}"/>
+<table id="contentTable" class="table table-striped table-bordered table-condensed">
+    <thead>
+        <tr>
+            <th>IP</th>
+            <th>公司类型</th>
+            <th>公司名称</th>
+            <th>联系人</th>
+            <th>手机号码</th>
+            <th>所属协销</th>
+            <th>访问页面数量</th>
+            <th>总时长</th>
+            <th>访问日期</th>
+            <th>操作</th>
+        </tr>
+    </thead>
+    <tbody>
+    <c:forEach items="${page.list}" var="cmBehaviorRecord" varStatus="index">
+        <tr>
+           <td>${cmBehaviorRecord.IP}</td>
+           <td>
+               <c:if test="${cmBehaviorRecord.userIdentity eq 2 || cmBehaviorRecord.userIdentity eq 4}">
+                   机构
+               </c:if>
+               <c:if test="${cmBehaviorRecord.userIdentity eq 3}">
+                   供应商
+               </c:if>
+               <c:if test="${cmBehaviorRecord.userID == '0'}">
+                   游客
+               </c:if>
+               <c:if test="${cmBehaviorRecord.userID != '0' && (cmBehaviorRecord.userIdentity == null || cmBehaviorRecord.userIdentity == '')}">
+                   ---
+               </c:if>
+           </td>
+            <c:if test="${cmBehaviorRecord.userID == '0'}">
+                <td>---</td>
+                <td>---</td>
+                <td>---</td>
+                <td>---</td>
+            </c:if>
+            <c:if test="${cmBehaviorRecord.userID != '0'}">
+               <td>
+                <c:if test="${cmBehaviorRecord.userIdentity eq 2}">
+                    ${cmBehaviorRecord.name}
+                </c:if>
+                <c:if test="${cmBehaviorRecord.userIdentity eq 4}">
+                    ${cmBehaviorRecord.linkMan}
+                </c:if>
+                <c:if test="${cmBehaviorRecord.userIdentity eq 3}">
+                    ${cmBehaviorRecord.sname}
+                </c:if>
+               </td>
+               <td>
+                   <c:if test="${cmBehaviorRecord.userIdentity eq 2 || cmBehaviorRecord.userIdentity eq 4}">
+                       ${cmBehaviorRecord.linkMan}
+                   </c:if>
+                   <c:if test="${cmBehaviorRecord.userIdentity eq 3}">
+                       ${cmBehaviorRecord.slinkMan}
+                   </c:if>
+               </td>
+               <td>
+                   <c:if test="${cmBehaviorRecord.userIdentity eq 2 || cmBehaviorRecord.userIdentity eq 4}">
+                       ${cmBehaviorRecord.contractMobile}
+                   </c:if>
+                   <c:if test="${cmBehaviorRecord.userIdentity eq 3}">
+                       ${cmBehaviorRecord.scontractMobile}
+                   </c:if>
+               </td>
+               <td>
+                   <c:if test="${cmBehaviorRecord.spName ne null}">
+                       ${cmBehaviorRecord.spName}
+                   </c:if>
+                   <c:if test="${cmBehaviorRecord.spName eq null}">
+                       ---
+                   </c:if></td>
+            </c:if>
+           <td>${cmBehaviorRecord.numbers}</td>
+           <td>${cmBehaviorRecord.accessDuration}</td>
+           <td>${cmBehaviorRecord.accessDate}</td>
+           <td>
+               <a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}">查看详情</a>
+           </td>
+        </tr>
+    </c:forEach>
+    </tbody>
+</table>
+<div class="pagination">${page}</div>
+<% request.setAttribute("caimeiCore", Global.getConfig("caimei.core"));%>
+<script type="text/javascript">
+    function page(n,s){
+        $("#pageNo").val(n);
+        $("#pageSize").val(s);
+        $("#searchForm").submit();
+        return false;
+    }
+</script>
+</body>
+
+</html>