Pārlūkot izejas kodu

用户行为记录优化

huangzhiguo 2 gadi atpakaļ
vecāks
revīzija
3fd9875ef5
19 mainītis faili ar 2178 papildinājumiem un 56 dzēšanām
  1. 17 0
      src/main/java/com/caimei/modules/user/dao/CmBehaviorRecordDao.java
  2. 2 0
      src/main/java/com/caimei/modules/user/dao/NewCmClubDao.java
  3. 63 0
      src/main/java/com/caimei/modules/user/entity/CmBehaviorRecord.java
  4. 157 5
      src/main/java/com/caimei/modules/user/service/CmBehaviorRecordService.java
  5. 160 17
      src/main/java/com/caimei/modules/user/web/CmUserBehaviorRecordController.java
  6. 43 0
      src/main/java/com/caimei/modules/user/web/newUser/AgencyController.java
  7. 6 0
      src/main/resources/mappings/modules/order/OrderMapper.xml
  8. 160 5
      src/main/resources/mappings/modules/user/CmBehaviorRecordMapper.xml
  9. 3 0
      src/main/resources/mappings/modules/user/CmClubinfoMapper.xml
  10. 12 1
      src/main/resources/mappings/modules/user/NewCmClubMapper.xml
  11. 265 0
      src/main/webapp/WEB-INF/views/modules/user/behaviorNewOrder.jsp
  12. 537 0
      src/main/webapp/WEB-INF/views/modules/user/behaviorRecordAgency.jsp
  13. 51 21
      src/main/webapp/WEB-INF/views/modules/user/behaviorRecordDetailsList.jsp
  14. 12 1
      src/main/webapp/WEB-INF/views/modules/user/behaviorRecordList.jsp
  15. 10 1
      src/main/webapp/WEB-INF/views/modules/user/behaviorRecordRossList.jsp
  16. 246 0
      src/main/webapp/WEB-INF/views/modules/user/behaviorRemarks.jsp
  17. 373 0
      src/main/webapp/WEB-INF/views/modules/user/behaviorReport.jsp
  18. 1 0
      src/main/webapp/WEB-INF/views/modules/userNew/cmAgencyForm.jsp
  19. 60 5
      src/main/webapp/WEB-INF/views/modules/userNew/recordLinkageForm.jsp

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

@@ -15,6 +15,13 @@ import java.util.List;
  */
 @MyBatisDao
 public interface CmBehaviorRecordDao extends CrudDao<CmBehaviorRecord> {
+
+    /**
+     * 查询当天以外的数据
+     * @param cmBehaviorRecord
+     * @return
+     */
+    List<CmBehaviorRecord> findListBefore(CmBehaviorRecord cmBehaviorRecord);
     /**
      * 查询单条详情
      * @param cmBehaviorRecord
@@ -34,4 +41,14 @@ public interface CmBehaviorRecordDao extends CrudDao<CmBehaviorRecord> {
      * @return
      */
     CmBehaviorRecord selConsult(CmBehaviorRecord cmBehaviorRecord);
+
+    /**
+     * 当天访问人数
+     * @param cmBehaviorRecord
+     * @return
+     */
+    List<CmBehaviorRecord> countData(CmBehaviorRecord cmBehaviorRecord);
+
+
+    List<CmBehaviorRecord> behaviorAgency(CmBehaviorRecord cmBehaviorRecord);
 }

+ 2 - 0
src/main/java/com/caimei/modules/user/dao/NewCmClubDao.java

@@ -83,4 +83,6 @@ public interface NewCmClubDao extends CrudDao<NewCmClub> {
     String recordLinkage(Integer clubId);
 
     String recordDescribe(Integer clubId);
+
+    List<CmBehaviorRecord> selRegisterIP(Integer clubId);
 }

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

@@ -19,6 +19,9 @@ import java.util.List;
 public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
     private Integer recordID ;
     private String IP;  //访问人IP地址
+    private String region;  //ip对应地区地址
+    private String accessSource;  //访问来源
+    private String accessClient;  //访问客户端
     private Integer userID; //用户id、0为游客
     private String pagePath;    //页面路径
     private String pageType;    //页面类型
@@ -31,7 +34,9 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
     private String accessDate;  //访问日期
     private String consultName;
     private String consultMobile;
+    private String lastAccessTime;  //最后访问时间
     private String behaviorType;  //是否是roos页面行为 1:用户行为、2:roos行为统计
+    private Integer count;
 
     private Integer numbers;    //访问页面总数
     private String userIdentity; //公司类型
@@ -42,6 +47,8 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
     private String linkMan; //机构联系人
     private String contractMobile;  //联系手机
     private String userName; //用户名
+    private String registerIP; // 注册IP
+    private String registerTime; // 注册时间
 
     private String sname; // 供应商公司名称
     private String slinkMan; //供应商联系人
@@ -71,6 +78,30 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
         this.IP = IP;
     }
 
+    public String getRegion() {
+        return region;
+    }
+
+    public void setRegion(String region) {
+        this.region = region;
+    }
+
+    public String getAccessSource() {
+        return accessSource;
+    }
+
+    public void setAccessSource(String accessSource) {
+        this.accessSource = accessSource;
+    }
+
+    public String getAccessClient() {
+        return accessClient;
+    }
+
+    public void setAccessClient(String accessClient) {
+        this.accessClient = accessClient;
+    }
+
     public Integer getUserID() {
         return userID;
     }
@@ -167,6 +198,14 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
         this.consultMobile = consultMobile;
     }
 
+    public String getLastAccessTime() {
+        return lastAccessTime;
+    }
+
+    public void setLastAccessTime(String lastAccessTime) {
+        this.lastAccessTime = lastAccessTime;
+    }
+
     public String getBehaviorType() {
         return behaviorType;
     }
@@ -175,6 +214,14 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
         this.behaviorType = behaviorType;
     }
 
+    public Integer getCount() {
+        return count;
+    }
+
+    public void setCount(Integer count) {
+        this.count = count;
+    }
+
     public Integer getNumbers() {
         return numbers;
     }
@@ -239,6 +286,22 @@ public class CmBehaviorRecord extends DataEntity<CmBehaviorRecord> {
         this.userName = userName;
     }
 
+    public String getRegisterIP() {
+        return registerIP;
+    }
+
+    public void setRegisterIP(String registerIP) {
+        this.registerIP = registerIP;
+    }
+
+    public String getRegisterTime() {
+        return registerTime;
+    }
+
+    public void setRegisterTime(String registerTime) {
+        this.registerTime = registerTime;
+    }
+
     public String getSname() {
         return sname;
     }

+ 157 - 5
src/main/java/com/caimei/modules/user/service/CmBehaviorRecordService.java

@@ -1,18 +1,26 @@
 package com.caimei.modules.user.service;
 
+import com.alibaba.fastjson.JSONObject;
 import com.caimei.modules.user.dao.CmBehaviorRecordDao;
 import com.caimei.modules.user.entity.CmBehaviorRecord;
-import com.caimei.modules.user.entity.CmPageType;
 import com.caimei.utils.AppUtils;
 import com.thinkgem.jeesite.common.persistence.Page;
 import com.thinkgem.jeesite.common.service.CrudService;
+import okhttp3.OkHttpClient;
+import okhttp3.Request;
+import okhttp3.Response;
+import org.apache.commons.lang.StringEscapeUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
-import java.io.UnsupportedEncodingException;
+import java.io.*;
+import java.net.HttpURLConnection;
+import java.net.MalformedURLException;
+import java.net.URL;
 import java.net.URLDecoder;
 import java.text.ParseException;
 import java.text.SimpleDateFormat;
+import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
 
@@ -28,10 +36,66 @@ public class CmBehaviorRecordService extends CrudService<CmBehaviorRecordDao, Cm
     @Autowired private CmBehaviorRecordDao cmBehaviorRecordDao;
 
 
-    public Page<CmBehaviorRecord> findPage(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord) {
-        return super.findPage(page, cmBehaviorRecord);
+    public Page<CmBehaviorRecord> findPageList(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord) {
+        cmBehaviorRecord.setPage(page);
+        List<CmBehaviorRecord> list = behaviorList(cmBehaviorRecord);
+        int pageNo = page.getPageNo();
+        int pageSize = page.getPageSize();
+        int number = 0;
+        if (pageNo == 1) {
+            number = 0;
+        } else {
+            number = pageNo * pageSize;
+        }
+        List<CmBehaviorRecord> behaviorList = new ArrayList<>();
+        for (int i = 0; i < list.size() ; i++) {
+            if (i >= number && i <= number+pageSize) {
+                behaviorList.add(list.get(i));
+            }
+        }
+        page.setCount(list.size());
+        page.setList(behaviorList);
+        return page;
     }
 
+    public List<CmBehaviorRecord> behaviorList(CmBehaviorRecord cmBehaviorRecord) {
+        List<CmBehaviorRecord> list = new ArrayList<>();
+        SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
+        String format = dateFormat.format(new Date());
+
+        List<CmBehaviorRecord> listData  = new ArrayList<>();
+        List<CmBehaviorRecord> listDataMerge  = new ArrayList<>();
+        // 每天访问用户数
+        CmBehaviorRecord cmRecord = new CmBehaviorRecord();
+        cmRecord = cmBehaviorRecord;
+        cmRecord.setPage(null);
+        List<CmBehaviorRecord> countData = cmBehaviorRecordDao.countData(cmRecord);
+        for (CmBehaviorRecord record: countData) {
+
+            cmBehaviorRecord.setAccessDate(record.getAccessDate());
+            // 获取当天数据,按照ip、时间、userID分组
+            if (record.getAccessDate().equals(format)) {
+                listData = cmBehaviorRecordDao.findList(cmBehaviorRecord);
+                list.addAll(listData);
+                continue;
+            }
+            // 访问人数大于2,说明不能合并IP 否则合并
+            if (record.getCount() > 2) {
+                listData = cmBehaviorRecordDao.findList(cmBehaviorRecord);
+                list.addAll(listData);
+            } else {
+                listData = cmBehaviorRecordDao.findListBefore(cmBehaviorRecord);
+                if (listData.size() != 0) {
+                    CmBehaviorRecord behaviorRecord = listData.get(0);
+                    listDataMerge.add(behaviorRecord);
+                    listData = listDataMerge;
+                }
+                list.addAll(listData);
+            }
+            listDataMerge.clear();
+        }
+        return list;
+    }
     /**
      * 用户行为详情
      * @param page
@@ -40,9 +104,28 @@ public class CmBehaviorRecordService extends CrudService<CmBehaviorRecordDao, Cm
      */
     public Page<CmBehaviorRecord> recordPage(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord){
         cmBehaviorRecord.setPage(page);
+        Integer userID = cmBehaviorRecord.getUserID();
+        // 每天访问用户数
+        CmBehaviorRecord cmRecord = new CmBehaviorRecord();
+        cmRecord.setIP(cmBehaviorRecord.getIP());
+        cmRecord.setAccessDate(cmBehaviorRecord.getAccessDate());
+        cmRecord.setUserID(cmBehaviorRecord.getUserID());
+        cmRecord.setClubID(cmBehaviorRecord.getClubID());
+        cmRecord.setBehaviorType(cmBehaviorRecord.getBehaviorType());
+//        cmRecord.setPage(null);
+         // 查看当天是否合并
+        List<CmBehaviorRecord> countData = cmBehaviorRecordDao.countData(cmRecord);
+        SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
+        String format = dateFormat.format(new Date());
+        Integer count = countData.get(0).getCount();
+        if (count <= 2) {
+            if (!cmBehaviorRecord.getAccessDate().equals(format)) {
+                cmBehaviorRecord.setUserID(null);
+            }
+        }
         // 用户行为详情
         List<CmBehaviorRecord> cmBehaviorRecordList = cmBehaviorRecordDao.recordList(cmBehaviorRecord);
-
+        cmBehaviorRecord.setUserID(userID);
         for(CmBehaviorRecord record: cmBehaviorRecordList) {
             record.setProductImage(AppUtils.getImageURL("product", record.getProductImage(), 0, ""));
             String time = calculationTime(record.getAccessDuration());
@@ -59,6 +142,35 @@ public class CmBehaviorRecordService extends CrudService<CmBehaviorRecordDao, Cm
         return page;
     }
 
+    /**
+     * 机构一周内的访问记录
+     * @param page
+     * @param cmBehaviorRecord
+     * @return
+     */
+    public Page<CmBehaviorRecord> behaviorAgencyPage(Page<CmBehaviorRecord> page, CmBehaviorRecord cmBehaviorRecord) {
+        cmBehaviorRecord.setPage(page);
+
+        // 机构用户行为详情
+        List<CmBehaviorRecord> behaviorAgencyList = cmBehaviorRecordDao.behaviorAgency(cmBehaviorRecord);
+
+        for (CmBehaviorRecord record: behaviorAgencyList) {
+            record.setProductImage(AppUtils.getImageURL("product", record.getProductImage(), 0, ""));
+            String time = calculationTime(record.getAccessDuration());
+            record.setAccessDuration(time);
+            String decode = null;
+            try {
+                decode = URLDecoder.decode(record.getPagePath(),"UTF-8");
+            } catch (UnsupportedEncodingException e) {
+                e.printStackTrace();
+            }
+            record.setPagePath(decode);
+        }
+
+        page.setList(behaviorAgencyList);
+        return page;
+    }
+
     /**
      * 时间计算
      * @param recordTime
@@ -96,4 +208,44 @@ public class CmBehaviorRecordService extends CrudService<CmBehaviorRecordDao, Cm
         return format;
     }
 
+    // 获取IP对应地址 ---- 太平洋
+    public static String recordIp(String ip) throws IOException {
+        URL url = null;
+        HttpURLConnection connection = null;
+        String encoding = "gbk";
+        String text = "";
+        String line = "";
+        String region = "";
+        String urlStr = "http://whois.pconline.com.cn/ipJson.jsp?ip="+ip+"&json=true";
+        try {
+            url = new URL(urlStr);
+            connection = (HttpURLConnection) url.openConnection();	//新建链接实例
+            connection.setConnectTimeout(20000);	//设置链接超时时间,单位毫秒
+            connection.setReadTimeout(20000);		//设置读取数据超时时间,单位毫秒
+            connection.setDoOutput(true);		//是否打开输出流true|false
+            connection.setDoInput(true);		//是否打开输入流true|false
+            connection.setRequestMethod("GET");		// 提交方式get|post
+            connection.setUseCaches(false);		// 是否加入缓存true|false
+            connection.connect();	//打开链接端口
+
+            BufferedReader reader = new BufferedReader(new InputStreamReader(connection.getInputStream(), encoding));	// 往对端写完数据对端服务器返回数据。以BufferedReader流来读取
+
+            while ((line = reader.readLine()) != null) {
+                text += line+"\n";
+            }
+            reader.close();
+
+            JSONObject jsonObject = JSONObject.parseObject(text);
+            region = jsonObject.get("addr").toString();
+        } catch (MalformedURLException e) {
+            e.printStackTrace();
+        } finally {
+            if (connection != null) {
+                connection.disconnect();	//关闭谅解
+            }
+        }
+
+        return region;
+    }
+
 }

+ 160 - 17
src/main/java/com/caimei/modules/user/web/CmUserBehaviorRecordController.java

@@ -1,9 +1,14 @@
 package com.caimei.modules.user.web;
 
+import com.caimei.modules.order.entity.NewOrder;
+import com.caimei.modules.order.service.NewOrderService;
 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.entity.*;
 import com.caimei.modules.user.service.CmBehaviorRecordService;
+import com.caimei.modules.user.service.CmClubinfoService;
+import com.caimei.modules.user.service.NewCmClubService;
+import com.caimei.utils.AppKeys;
+import com.caimei.utils.AppUtils;
 import com.thinkgem.jeesite.common.config.Global;
 import com.thinkgem.jeesite.common.persistence.Page;
 import com.thinkgem.jeesite.common.utils.ObjectUtils;
@@ -15,8 +20,10 @@ import org.springframework.ui.Model;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 
+import javax.annotation.Resource;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
 import java.util.List;
 
 /**
@@ -34,6 +41,11 @@ public class CmUserBehaviorRecordController extends BaseController {
 
     @Autowired private CmBehaviorRecordDao cmBehaviorRecordDao;
 
+    @Autowired private NewCmClubService newCmClubService;
+
+    @Autowired CmClubinfoService cmClubinfoService;
+
+    @Resource private NewOrderService newOrderService;
     /**
      * 用户行为记录
      * @param cmBehaviorRecord
@@ -43,8 +55,8 @@ public class CmUserBehaviorRecordController extends BaseController {
      * @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);
+    public String List(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model)  throws IOException {
+        Page<CmBehaviorRecord> page = cmBehaviorRecordService.findPageList(new Page<>(request, response,20), cmBehaviorRecord);
         for(CmBehaviorRecord record: page.getList()) {
             // 是roos页面统计判断咨询人信息是否为空并赋值
             if ("2".equals(cmBehaviorRecord.getBehaviorType())) {
@@ -57,9 +69,14 @@ public class CmUserBehaviorRecordController extends BaseController {
                         record.setConsultMobile(consult.getConsultMobile());
                     }
                 }
+
             }
+            // 计算访问时长
             String time = cmBehaviorRecordService.calculationTime(record.getAccessDuration());
             record.setAccessDuration(time);
+            // 获取IP躲在地区
+            /*String region = cmBehaviorRecordService.recordIp(record.getIP());
+            record.setRegion(region);*/
         }
         model.addAttribute("page",page);
         model.addAttribute("cmBehaviorRecord", cmBehaviorRecord);
@@ -81,32 +98,158 @@ public class CmUserBehaviorRecordController extends BaseController {
     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";
     }
 
     /**
-     * 跳转机构、供应商编辑页
+     * 机构详情
      * @param cmBehaviorRecord
+     * @param request
+     * @param response
      * @param model
-     * @param redirectAttributes
      * @return
      */
-    @RequestMapping("/clubOrShop")
-    public String clubOrShop(CmBehaviorRecord cmBehaviorRecord,Model model, RedirectAttributes redirectAttributes){
+    @RequestMapping("/recordAgency")
+    public String behaviorRecordAgency(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model) {
+        NewCmClub newCmClub = new NewCmClub();
+        if (cmBehaviorRecord.getUserID() == 0) {
+            newCmClub.setClubID(1);
+        } else {
+            newCmClub.setClubID(cmBehaviorRecord.getClubID());
+        }
+        // 查询机构基本信息
+        Page<NewCmClub> page = newCmClubService.findPage(new Page<NewCmClub>(request, response, 20), newCmClub);
+        if (page.getList().size() > 0) {
+            newCmClub = page.getList().get(0);
+        }
+        // 机构详细信息
+        CmClubinfo cmClubinfo = new CmClubinfo();
+        cmClubinfo.setClubID(newCmClub.getClubID());
+        List<CmClubinfo> cmClubinfos = cmClubinfoService.findList(cmClubinfo);
+
+        if (null != cmClubinfos && cmClubinfos.size() > 0) {
+            cmClubinfo = cmClubinfos.get(0);
+        }
+        cmClubinfo.setClubID(newCmClub.getClubID());
+        cmClubinfo.setUserID(newCmClub.getUserID());
+
+        cmClubinfo.setContractPhone(newCmClub.getContractPhone());
+        cmClubinfo.setFax(newCmClub.getFax());
+        cmClubinfo.setInfo(newCmClub.getInfo());
+        cmClubinfo.setBusinessLicenseImage(newCmClub.getBusinessLicenseImage());
+        cmClubinfo.setHeadpic(newCmClub.getHeadpic());
+        cmClubinfo.setSocialCreditCode(newCmClub.getSocialCreditCode());
+        cmClubinfo.setProvinceID(newCmClub.getProvinceID());
+        cmClubinfo.setCityID(newCmClub.getCityID());
+        cmClubinfo.setTownID(newCmClub.getTownID());
+        cmClubinfo.setAddress(newCmClub.getAddress());
+        cmClubinfo.setFirstClubType(newCmClub.getFirstClubType());
+        cmClubinfo.setSecondClubType(newCmClub.getSecondClubType());
+        cmClubinfo.setDepartment(newCmClub.getDepartment());
+        String  mainpro = newCmClub.getMainpro();
+        if (StringUtils.isNotEmpty(mainpro)) {
+            mainpro = mainpro.replaceAll("/",",");
+        }
+        cmClubinfo.setMainpro(mainpro);
+        cmClubinfo.setMedicalPracticeLicenseImg(newCmClub.getMedicalPracticeLicenseImg());
+        cmClubinfo.setContractEmail(newCmClub.getContractEmail());
+        cmClubinfo.setLinkManIdentity(newCmClub.getLinkManIdentity());
+
+        String wwwServer = Global.getConfig("wwwServer");
+        //营业执照
+        newCmClub.setBusinessLicenseImage(AppUtils.getImageURL("clubBusinessLicenseImage", newCmClub.getBusinessLicenseImage(), 0, wwwServer));
+        //门头照
+        newCmClub.setHeadpic(AppUtils.getImageURL("club", newCmClub.getHeadpic(), AppKeys.CLUB_LOGO_SIZE, wwwServer));
+
+        model.addAttribute("cmClubinfo", cmClubinfo);
+        model.addAttribute("newCmClub", newCmClub);
+        model.addAttribute("cmBehaviorRecord",cmBehaviorRecord);
+        return "modules/user/behaviorRecordAgency";
+    }
+
+    /**
+     * 咨询记录
+     * @param cmBehaviorRecord
+     * @param request
+     * @param response
+     * @param model
+     * @return
+     */
+    @RequestMapping("/behaviorRemarks")
+    public String behaviorRemarks(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model) {
+
+        // 用户咨询记录
+        CmClubRemarks cmClubRemarks = new CmClubRemarks();
+        if (cmBehaviorRecord.getUserID() == 0) {
+            cmClubRemarks.setClubId(0);
+        } else {
+            cmClubRemarks.setClubId(cmBehaviorRecord.getClubID());
+        }
+        cmClubRemarks.setClubId(cmBehaviorRecord.getClubID());
+        Page<CmClubRemarks> page = newCmClubService.findRegistPage(new Page<CmClubRemarks>(request, response, 20), cmClubRemarks);
+        if (page.getList().size() > 0) {
+            cmClubRemarks = page.getList().get(0);
+        }
+        cmClubRemarks.setConsults(newCmClubService.findConsults());
+        cmClubRemarks.setTeams(newCmClubService.findTeams());
+        model.addAttribute("page",page);
+        model.addAttribute("cmClubRemarks", cmClubRemarks);
+        model.addAttribute("cmBehaviorRecord",cmBehaviorRecord);
+        return "modules/user/behaviorRemarks";
+    }
 
-        System.out.println(ObjectUtils.isEmpty(cmBehaviorRecord.getClubID()));
-        if (!ObjectUtils.isEmpty(cmBehaviorRecord.getClubID())) {
-            return "redirect:" + Global.getAdminPath() + "/new/user/agency/form?id="+cmBehaviorRecord.getClubID()+"&source=1";
+    /**
+     * 报备记录
+     * @param cmBehaviorRecord
+     * @param request
+     * @param response
+     * @param model
+     * @return
+     */
+    @RequestMapping("/behaviorReport")
+    public String behaviorReport(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model) {
+        // 报备记录查询
+        CmReport cmReport = new CmReport();
+        if (cmBehaviorRecord.getUserID() == 0) {
+            cmReport.setClubID(0);
+        } else {
+            cmReport.setClubID(cmBehaviorRecord.getClubID());
         }
-        if (!ObjectUtils.isEmpty(cmBehaviorRecord.getShopID())) {
-            return "redirect:" + Global.getAdminPath() + "/user/newCmShop/form?id=+"+cmBehaviorRecord.getShopID()+"&editStatus=1";
+        Page<CmReport> page = newCmClubService.ReportList(new Page<CmReport>(request, response,20), cmReport);
+
+        model.addAttribute("page", page);
+        model.addAttribute("cmReport", cmReport);
+        model.addAttribute("cmBehaviorRecord", cmBehaviorRecord);
+        return "modules/user/behaviorReport";
+    }
+
+
+    /**
+     * 订单信息
+     * @param cmBehaviorRecord
+     * @param request
+     * @param response
+     * @param model
+     * @return
+     */
+    @RequestMapping("/behaviorNewOrder")
+    public String behaviorNewOrder(CmBehaviorRecord cmBehaviorRecord, HttpServletRequest request, HttpServletResponse response, Model model) {
+        // 订单列表
+        NewOrder order = new NewOrder();
+        order.setUserID(cmBehaviorRecord.getUserID());
+        if (cmBehaviorRecord.getUserID() == 0) {
+            order.setClubID(0);
+        } else {
+            order.setClubID(cmBehaviorRecord.getClubID());
         }
-        addMessage(redirectAttributes,"查看失败");
-        return "redirect:" + Global.getAdminPath() + "/user/behavior/record/list";
+        //查询内部处理了已收,未付统计(包含运费)
+        Page<NewOrder> page = newOrderService.findPage(new Page<>(request, response, 20), order);
+
+        model.addAttribute("page", page);
+        model.addAttribute("cmBehaviorRecord", cmBehaviorRecord);
+        return "modules/user/behaviorNewOrder";
     }
 
 }

+ 43 - 0
src/main/java/com/caimei/modules/user/web/newUser/AgencyController.java

@@ -85,6 +85,8 @@ public class AgencyController extends BaseController {
     @Autowired
     private ClubChangeSpReviewService clubChangeSpReviewService;
     @Autowired
+    private CmBehaviorRecordService cmBehaviorRecordService;
+    @Autowired
     CmSpService cmSpService;
     @Autowired
     private CmOperationUserService cmOperationUserService;
@@ -1202,6 +1204,9 @@ private VisitRemarkDao visitRemarkDao;
     public String RecordLinkage(Integer clubId,HttpServletRequest request, HttpServletResponse response, Model model) {
        String link= newCmClubDao.recordLinkage(clubId);
         String describe= newCmClubDao.recordDescribe(clubId);
+        if (describe == null) {
+            describe = "";
+        }
        String linkage="";
         if(domain.contains("-b")){
             linkage="http://zzjtest.gz.aeert.com/clubinfo.html?clubId="+clubId;
@@ -1210,6 +1215,44 @@ private VisitRemarkDao visitRemarkDao;
         }else {
             linkage="http://localhost:8081/clubinfo.html?clubId="+clubId;
         }
+        // 机构注册IP
+        List<CmBehaviorRecord> behaviorList = newCmClubDao.selRegisterIP(clubId);
+        CmBehaviorRecord record = new CmBehaviorRecord();
+        record.setClubID(clubId);
+        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
+        // 获取注册时间一周前时间
+        Calendar calendar = Calendar.getInstance();
+        for (CmBehaviorRecord behaviorRecord: behaviorList) {
+            try {
+                Date date = simpleDateFormat.parse(behaviorRecord.getRegisterTime());
+                String registerTime = simpleDateFormat.format(date);
+                calendar.setTime(date);
+                // 获取注册时间一周前时间
+                calendar.set(Calendar.DAY_OF_YEAR, calendar.get(Calendar.DAY_OF_YEAR) - 7);
+                Date today = calendar.getTime();
+                String startTime = simpleDateFormat.format(today);
+                // 获取注册时间一周后时间
+                calendar.setTime(date);
+                calendar.set(Calendar.DAY_OF_YEAR, calendar.get(Calendar.DAY_OF_YEAR) + 7);
+                Date lastDay = calendar.getTime();
+                String endTime = simpleDateFormat.format(lastDay);
+                record.setIP(behaviorRecord.getRegisterIP());
+                record.setStartTime(startTime);
+                record.setEndTime(endTime);
+                record.setRegisterTime(registerTime);
+            } catch (ParseException e) {
+                e.printStackTrace();
+            }
+        }
+        Page<CmBehaviorRecord> page = cmBehaviorRecordService.behaviorAgencyPage(new Page<>(request, response), record);
+        List<CmBehaviorRecord> list = page.getList();
+        for (int i = 0; i <= list.size()-1; i++) {
+            describe += list.get(i).getPageLabel();
+            if (list.size()-1 != i) {
+                describe += ",";
+            }
+        }
+        model.addAttribute("page",page);
         model.addAttribute("link",link);
         model.addAttribute("linkage",linkage);
         model.addAttribute("describe",describe);

+ 6 - 0
src/main/resources/mappings/modules/order/OrderMapper.xml

@@ -141,6 +141,12 @@
         left join cm_shop_order cso on co.orderid=cso.orderID
         <where>
             co.orderType != 2
+            <if test="clubID == 0">
+                AND c.clubID = #{clubID}
+            </if>
+            <if test="userID != null and userID != ''">
+                AND u.userID = #{userID}
+            </if>
             <if test="orderID != null and orderID != ''">
                 AND co.orderID = #{orderID}
             </if>

+ 160 - 5
src/main/resources/mappings/modules/user/CmBehaviorRecordMapper.xml

@@ -22,13 +22,13 @@
           c.name,
           c.linkMan,
           c.contractMobile,
-          cri.consultName,
-          cri.consultMobile,
           s.name AS sname,
           s.linkMan AS slinkMan,
           s.contractMobile AS scontractMobile,
           c.clubID as clubID,
           s.shopID as shopID,
+          max(b.region) as region,
+          max(accessTime) AS lastAccessTime,
           (SELECT CASE STATUS WHEN 91 THEN '采美默认协销经理(官方账号)' ELSE linkMan END FROM serviceprovider WHERE serviceProviderID = c.spID) AS spName,
           COUNT(b.IP) as numbers
         FROM cm_behavior_record b
@@ -36,9 +36,8 @@
         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
-        LEFT JOIN cm_roos_information cri on b.IP = cri.IP
         <where>
-            b.IP != '106.55.202.118'
+            b.IP != '106.55.202.118' AND b.accessDate = #{accessDate}
             <if test="behaviorType == 2">
                 AND b.behaviorType = #{behaviorType}
             </if>
@@ -75,12 +74,77 @@
         GROUP BY b.IP, b.accessDate,b.userID ORDER BY b.accessTime DESC
     </select>
 
+    <select id="findListBefore" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
+        SELECT
+        <include refid="behaviorRecord"/>
+        ,SUM(b.accessDuration) AS accessDuration,
+        u.userIdentity,
+        u.userName,
+        c.sname AS cSname,
+        c.name,
+        c.linkMan,
+        c.contractMobile,
+        s.name AS sname,
+        s.linkMan AS slinkMan,
+        s.contractMobile AS scontractMobile,
+        c.clubID as clubID,
+        s.shopID as shopID,
+        max(b.region) as region,
+        max(accessTime) AS lastAccessTime,
+        (SELECT CASE STATUS WHEN 91 THEN '采美默认协销经理(官方账号)' ELSE linkMan END FROM serviceprovider WHERE serviceProviderID = c.spID) AS spName,
+        (SELECT COUNT(IP) FROM cm_behavior_record WHERE b.IP != '106.55.202.118' AND accessDate= #{accessDate}  GROUP BY accessDate) 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>
+                b.IP != '106.55.202.118' AND b.accessDate = #{accessDate}
+            <if test="behaviorType == 2">
+                AND b.behaviorType = #{behaviorType}
+            </if>
+            <if test="IP != null and IP != ''">
+                AND b.IP = #{IP}
+            </if>
+            <if test="name != null and name != ''">
+                AND c.sname = #{name} or s.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.userID ORDER BY b.userID DESC
+    </select>
+
     <select id="recordList" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
         SELECT
         <include refid="behaviorRecord"/>
            ,b.accessDuration,
+           b.accessSource,
+           b.accessClient,
            u.userIdentity,
            c.name,
+           c.clubID,
            c.linkMan,
            c.contractMobile,
            s.name AS sname,
@@ -97,10 +161,13 @@
         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} AND b.IP != '106.55.202.118'
+             b.accessDate = #{accessDate}  AND b.IP != '106.55.202.118'
             <if test="behaviorType == 2">
                 AND behaviorType = #{behaviorType}
             </if>
+            <if test="userID != null">
+                AND b.userID = #{userID} AND b.IP = #{IP}
+            </if>
             <if test="pageType != null and pageType != ''">
                 AND b.pageType = #{pageType}
             </if>
@@ -123,4 +190,92 @@
                FROM cm_roos_information
         WHERE IP = #{IP} AND createTime like concat('%',#{accessDate},'%') AND (consultName IS NOT NULL OR consultName = '') LIMIT 1
     </select>
+
+    <select id="countData" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
+        SELECT  COUNT(DISTINCT userID) as count,accessDate FROM cm_behavior_record
+        <where>
+            <if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
+                AND accessDate between #{startTime} and #{endTime}
+            </if>
+            <if test="accessDate != null and accessDate != ''">
+                AND accessDate = #{accessDate}
+            </if>
+        </where>
+        GROUP BY accessDate ORDER BY accessTime ASC
+    </select>
+
+    <select id="behaviorAgency" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
+            SELECT
+            <include refid="behaviorRecord"/>
+            ,b.accessDuration,
+            u.userIdentity,
+            c.name,
+            c.clubID,
+            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 BETWEEN #{startTime} AND #{registerTime}
+            GROUP BY b.pageLabel
+        UNION
+            SELECT
+            <include refid="behaviorRecord"/>
+            ,b.accessDuration,
+            u.userIdentity,
+            c.name,
+            c.clubID,
+            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 BETWEEN #{registerTime} AND #{endTime}
+            GROUP BY b.pageLabel
+        UNION
+            SELECT
+            <include refid="behaviorRecord"/>
+            ,b.accessDuration,
+            u.userIdentity,
+            c.name,
+            c.clubID,
+            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 c.clubID = #{clubID} AND b.accessDate BETWEEN #{registerTime} AND #{endTime}
+        GROUP BY b.pageLabel
+        ORDER BY accessTime DESC
+    </select>
 </mapper>

+ 3 - 0
src/main/resources/mappings/modules/user/CmClubinfoMapper.xml

@@ -60,6 +60,9 @@
 			<if test="clubID != null and clubID != ''">
 				AND a.clubID = #{clubID}
 			</if>
+			<if test="clubID == 0">
+				AND a.clubID = #{clubID}
+			</if>
 			<if test="userID != null and userID != ''">
 				AND a.userID = #{userID}
 			</if>

+ 12 - 1
src/main/resources/mappings/modules/user/NewCmClubMapper.xml

@@ -105,6 +105,9 @@
             <if test="clubID != null and clubID != ''">
                 AND a.clubID = #{clubID}
             </if>
+            <if test="clubID == 0">
+                AND a.clubID = #{clubID}
+            </if>
             <if test="userID != null and userID != ''">
                 AND a.userID = #{userID}
             </if>
@@ -492,6 +495,9 @@
             <if test="remarks != null and remarks !=''">
                 AND ccr.remarks LIKE concat('%',#{remarks},'%')
             </if>
+            <if test="clubId != null">
+                AND c.clubID = #{clubId}
+            </if>
             <if test="clubName !=null and clubName !=''">
                 AND c.Name like concat('%',#{clubName},'%')
             </if>
@@ -606,6 +612,9 @@
             <if test="productName!=null and productName!=''">
                 AND p.name LIKE concat('%',#{productName},'%')
             </if>
+            <if test="clubID != null">
+                c.clubID = #{clubID}
+            </if>
             <if test="clubName!=null and clubName!=''">
                 AND c.name LIKE concat('%',#{clubName},'%')
             </if>
@@ -706,5 +715,7 @@
         ORDER BY id DESC
         LIMIT 1
     </select>
-
+    <select id="selRegisterIP" resultType="com.caimei.modules.user.entity.CmBehaviorRecord">
+        SELECT u.registerIP, u.registerTime FROM USER u LEFT JOIN club c ON u.userID = c.userID WHERE c.clubID = #{clubId}
+    </select>
 </mapper>

+ 265 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorNewOrder.jsp

@@ -0,0 +1,265 @@
+<%@ page import="java.util.Date" %>
+<%@ 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 type="text/css">
+        .table th{text-align:center}
+        .table td{text-align:center}
+        .data-title{width:100%;display:table}
+        .data-title ul li{word-break:break-all;display:table-cell;width:100px;border:1px solid #000;text-align:center;height:35px;vertical-align:middle;border-right:0;border-bottom:0}
+        .data-title ul{margin-bottom:0 !important;display:table-row}
+        .data-title ul li:last-of-type{width:120px;border-right:1px solid #000000}
+        .data-title ul:last-of-type li{border-bottom:1px solid #000000}
+        .data-title ul li:nth-child(6){width:80px}
+        .spileOrder li:nth-of-type(1){position:relative}
+        .san{width:10px;height:10px;border-top:2px solid #000;border-right:2px solid #000;transform:rotate(45deg);position:absolute;right:-2px;top:50%;margin-top:-5px;cursor:pointer}
+        .red-waring{margin:0 !important;background-color:#f3f3f3 !important}
+        .red-waring li{border-color:red !important}
+        #biao1{position:absolute;left:-9999px;top:-9999px;z-index:-99;width:1px;height:1px}
+        #searchForm{line-height:40px}
+        #searchForm .ul-form{overflow:visible}
+        #searchForm{white-space:nowrap}
+        #searchForm label{margin-top:15px}
+        .ul-form{white-space:nowrap;margin-left:-10px !important}
+        .ul-form label{width:90px;text-align:right}
+        #btnSubmit{width:128px;margin-left:152px}
+        .select-ele{width:177px}
+    </style>
+    <script type="text/javascript">
+
+    </script>
+</head>
+<body>
+<textarea cols="20" rows="10" id="biao1"></textarea>
+<ul class="nav nav-tabs">
+    <c:if test="${cmBehaviorRecord.behaviorType eq '2'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">ROSS页面统计</a></li>
+    </c:if>
+    <c:if test="${cmBehaviorRecord.behaviorType eq '1'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">用户行为记录</a></li>
+    </c:if>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
+
+</ul>
+<sys:message content="${message}"/>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}" 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">
+        <ul class="nav nav-tabs">
+            <li><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">访问详情</a></li>
+            <li><a href="${ctx}/user/behavior/record/recordAgency?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">机构信息</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">咨询记录</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">报备记录</a></li>
+            <li class="active"><a href="${ctx}/user/behavior/record/behaviorNewOrder?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">订单信息</a></li>
+        </ul>
+    </div>
+</form:form>
+<div class="data-title">
+    <ul>
+        <li>订单ID</li>
+        <li>订单编号</li>
+        <li>订单类型</li>
+        <li>返佣订单</li>
+        <%--        <li>二手订单</li>--%>
+        <li>机构</li>
+        <li>收货人</li>
+        <li>订单来源</li>
+        <li>订单状态</li>
+        <li>收款状态</li>
+        <li>付款状态</li>
+        <li>发货状态</li>
+        <li>退款状态</li>
+        <li>待审核退款</li>
+        <li>订单金额</li>
+        <li>返佣服务费</li>
+        <li>下单时间</li>
+        <li>确认时间</li>
+        <li>操作</li>
+    </ul>
+    <c:forEach items="${page.list}" var="order">
+        <%--颜色区分分期不分期订单以及终止订单--%>
+        <ul class="spileOrder" data-id="${order.orderNo}">
+            <li>${order.orderID}</li>
+            <li style="position: relative">${order.orderNo}
+            </li>
+            <li>
+                <c:if test="${order.orderType == 1}">
+                    自主订单
+                </c:if>
+                <c:if test="${order.orderType == 0}">
+                    协销订单
+                    <c:if test="${not empty order.spName}">
+                        <br>${fns:appendLast1('(',order.spName,')')}
+                    </c:if>
+                </c:if>
+            </li>
+            <li>
+                <c:if test="${order.rebateOrder == '0'}">
+                    否
+                </c:if>
+                <c:if test="${order.rebateOrder ne '0'}">
+                    是
+                </c:if>
+            </li>
+                <%--            <li>--%>
+                <%--                <c:if test="${order.secondHandOrderFlag == '1'}">--%>
+                <%--                    是--%>
+                <%--                </c:if>--%>
+                <%--                <c:if test="${order.secondHandOrderFlag ne '1'}">--%>
+                <%--                    否--%>
+                <%--                </c:if>--%>
+                <%--            </li>--%>
+            <li>
+
+                <c:if test="${order.organizeID == 1}">
+                    <span class="org-note">星范</span>
+                </c:if>
+
+                    ${order.buyer}
+            </li>
+            <li>${order.receiver}</li>
+            <li>${fns:getDictLabel(order.orderSource,"bp_orderSource","" )}</li>
+            <li class="sd-li">
+                <c:if test="${order.status eq 11 || order.status eq 12 || order.status eq 13 ||order.status eq 21 ||order.status eq 22 ||
+				order.status eq 23 || order.status eq 31 ||order.status eq 32 ||order.status eq 33}">
+                    交易中<br>(${fns:getDictLabel(order.status,"order_detail_status","" )})
+                </c:if>
+                <c:if test="${order.status eq 0 || order.status eq 4 || order.status eq 5 || order.status eq 6 || order.status eq 7}">${fns:getDictLabel(order.status,"order_detail_status","" )}</c:if>
+            </li>
+            <li>
+                <c:if test="${order.receiptStatus == 1}">
+                    <font color="red">待收款</font>
+                </c:if>
+                <c:if test="${order.receiptStatus == 2}">
+                    <font color="#ff8c00">部分收款</font>
+                </c:if>
+                <c:if test="${order.receiptStatus == 3}">
+                    <font color="green">已收款</font>
+                </c:if>
+                <br>
+                    <%--抹平明细--%>
+                <c:if test="${order.confirmType eq 1}">
+                    <c:if test="${order.receiptOrderFlag}">
+                        一款多单:少收抹平金额未知
+                    </c:if>
+                    <c:if test="${!order.receiptOrderFlag}">
+                        <font>少收抹平:<br>
+                            ¥<fmt:formatNumber
+                                    value="${order.payableAmount - (empty order.orderReceivedAmount ? 0 : order.orderReceivedAmount)}"
+                                    pattern="#0.00"/>
+                        </font>
+                    </c:if>
+                </c:if>
+                <c:if test="${order.confirmType eq 2}">
+                    <c:if test="${order.receiptOrderFlag}">
+                        一款多单:多收抹平金额未知
+                    </c:if>
+                    <c:if test="${!order.receiptOrderFlag}">
+                        <font>多收抹平:<br>
+                            ¥<fmt:formatNumber
+                                    value="${(empty order.orderReceivedAmount ? 0 : order.orderReceivedAmount) - order.payableAmount}"
+                                    pattern="#0.00"/>
+                        </font>
+                    </c:if>
+                </c:if>
+                <c:if test="${order.confirmType eq 3}">
+                    <c:if test="${order.receiptOrderFlag}">
+                        一款多单:多收退余额
+                    </c:if>
+                    <c:if test="${!order.receiptOrderFlag}">
+                        <font>多收退余额&nbsp;&nbsp;${order.associationType eq 2 ? "(自动)" : ""}:<br>
+                            ¥<fmt:formatNumber
+                                    value="${(empty order.returnBalanceAmount ? 0 : order.returnBalanceAmount)}"
+                                    pattern="#0.00"/>
+                        </font>
+                    </c:if>
+                </c:if>
+            </li>
+            <li>
+                <c:if test="${order.payStatus == 1}">
+                    <font color="red">待付款</font>
+                </c:if>
+                <c:if test="${order.payStatus == 2}">
+                    <font color="#ff8c00">部分付款</font>
+                </c:if>
+                <c:if test="${order.payStatus == 3}">
+                    <font color="green">已付款</font>
+                </c:if>
+            </li>
+            <li>
+                <c:if test="${order.sendOutStatus == 1}">
+                    <font color="red">待发货</font>
+                </c:if>
+                <c:if test="${order.sendOutStatus == 2}">
+                    <font color="#ff8c00">部分发货</font>
+                </c:if>
+                <c:if test="${order.sendOutStatus == 3}">
+                    <font color="green">已发货</font>
+                </c:if>
+            </li>
+            <li>
+                <c:if test="${order.refundType == 1}">
+                    <font>部分退款</font>
+                </c:if>
+                <c:if test="${order.refundType == 2}">
+                    <font>已退款</font>
+                </c:if>
+                <c:if test="${order.refundType ne 1 and order.refundType ne 2 }">
+                    <font>无退款</font>
+                </c:if>
+            </li>
+            <li>
+                <c:if test="${order.returnedPurchaseStatus == 1}">
+                    <a href="${ctx}/bulkpurchase/cmRefundsProduct/toRecturnRecordByOrderID.rpc?orderID=${order.orderID}">
+                        有
+                    </a>
+                </c:if>
+                <c:if test="${order.returnedPurchaseStatus == 0}">
+                    无
+                </c:if>
+            </li>
+            <li>                    <%-- 订单金额 --%>
+                <fmt:formatNumber value="${order.payTotalFee}" type="currency"/>
+            </li>
+            <li>                    <%-- 返佣服务费 --%>
+                <c:if test="${not empty order.rebateFee}">
+                    <fmt:formatNumber value="${order.rebateFee}" type="currency"/>
+                </c:if>
+                <c:if test="${empty order.rebateFee}">
+                    ---
+                </c:if>
+            </li>
+            <li>${order.orderTime}</li>
+            <li>
+                <c:if test="${empty order.confirmTime}">
+                    ---
+                </c:if>
+                <c:if test="${not empty order.confirmTime}">
+                    ${order.confirmTime}
+                </c:if>
+            </li>
+            <li class="operation-wrap">
+                <a href="${ctx}/order/detail?id=${order.orderID}">查看详情</a>
+            </li>
+        </ul>
+    </c:forEach>
+</div>
+
+<div class="pagination">${page}</div>
+<c:if test="${empty page.list}">
+    <p style="text-align: center;"><font color="#1e90ff">暂无订单信息……</font></p>
+</c:if>
+<script type="text/javascript">
+    function page(n,s){
+        $("#pageNo").val(n);
+        $("#pageSize").val(s);
+        $("#searchForm").submit();
+        return false;
+    }
+</script>
+</body>
+</html>

+ 537 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordAgency.jsp

@@ -0,0 +1,537 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/WEB-INF/views/include/taglib.jsp" %>
+<html>
+<head>
+    <title>机构信息</title>
+    <meta name="decorator" content="default"/>
+    <script src="/static/modules/bulkpurchase/loadAddressById.js"></script>
+    <script type="text/javascript">
+
+    </script>
+    <style>
+        #auditBox {
+            padding: 20px;
+            line-height: 30px;
+        }
+
+        #auditBox .bd-row {
+            display: flex;
+            margin-bottom: 15px;
+        }
+
+        #auditBox .bd-row > span {
+            display: inline-block;
+            width: 60px;
+        }
+
+        #auditBox .auditCheckBox {
+            width: 250px;
+        }
+
+        #auditBox .auditCheckBox label {
+            margin: 0 5px 5px 0
+        }
+
+        #auditBox .auditCheckBox input {
+            display: none;
+        }
+
+        #auditBox .auditCheckBox input + span {
+            display: inline-block;
+            line-height: 24px;
+            padding: 0 12px;
+            border: 1px solid #666;
+            border-radius: 5px;
+        }
+
+        #auditBox .auditCheckBox input:checked + span {
+            background-color: #E6633A
+        }
+
+        .detailTitle {
+            margin: 16px 0px 4px 20px;
+            font-weight: bold;
+        }
+
+        .detailLine {
+            width: 98%;
+            margin-left: 10px;
+        }
+
+        .clubInfo {
+            float: left;
+            width: 25%;
+        }
+
+        .clubInfoTitle {
+            text-align: center;
+            text-decoration: underline;
+            font-weight: bold;
+        }
+
+        th {
+            text-align: right;
+            white-space: nowrap;
+        }
+
+        td {
+            padding: 5px 0;
+        }
+
+        #headpicPreview li, #businessLicenseImagePreview li {
+            min-height: 100px;
+        }
+
+        /*----------------------------------*/
+        .the-oradio {
+            display: inline-block;
+            vertical-align: top;
+        }
+
+        .the-oradio div {
+            width: 85px;
+            display: inline-block;
+            font-size: 12px;
+            color: #666;
+        }
+
+        .med-option {
+            display: block;
+            margin: 10px 0 0 160px;
+        }
+
+        .raw-option {
+            display: block;
+            margin: 10px 0 0 160px;
+        }
+
+        .control-group .new-tag {
+            display: inline-block;
+            width: 78px;
+            height: 30px;
+            border: 1px solid #e5e5e5;
+            border-radius: 5px;
+            margin: 7px;
+            text-align: center;
+            line-height: 30px;
+            font-size: 14px;
+            overflow: hidden;
+            text-overflow: ellipsis;
+            white-space: nowrap;
+            cursor: pointer;
+        }
+
+        .control-group .new-tag.active {
+            border-color: #e15616;
+            color: #e15616;
+        }
+
+        #clubArea {
+            display: inline-block;
+            width: 450px;
+        }
+
+        #clubOther {
+            height: 40px;
+            line-height: 40px;
+            vertical-align: middle
+        }
+
+        #clubInput {
+            width: 159px;
+            margin: 7px;
+            display: inline-block;
+            height: 30px;
+            display: none;
+        }
+
+        .tags-operate {
+            margin-left: 160px;
+        }
+
+        .control-group .tags-operate .tag-add {
+            height: 40px;
+            line-height: 40px;
+            vertical-align: middle;
+            display: none;
+        }
+
+        .top-label {
+            width: 160px;
+            text-align: right;
+            vertical-align: top;
+            margin-top: 10px;
+        }
+    </style>
+</head>
+<body>
+<ul class="nav nav-tabs">
+    <c:if test="${cmBehaviorRecord.behaviorType eq '2'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">ROSS页面统计</a></li>
+    </c:if>
+    <c:if test="${cmBehaviorRecord.behaviorType eq '1'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">用户行为记录</a></li>
+    </c:if>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
+
+</ul>
+<div class="ul-form">
+    <ul class="nav nav-tabs">
+        <li><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">访问详情</a></li>
+        <li class="active"><a href="${ctx}/user/behavior/record/recordAgency?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">机构信息</a></li>
+        <li><a href="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">咨询记录</a></li>
+        <li><a href="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">报备记录</a></li>
+        <li><a href="${ctx}/user/behavior/record/behaviorNewOrder?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">订单信息</a></li>
+    </ul>
+</div>
+<form:form id="inputForm" modelAttribute="cmClubinfo" action="#" method="post"
+           class="form-horizontal">
+<form:hidden path="id" value="${newCmClub.clubID}"/>
+<form:hidden path="clubInfoID"/>
+<form:hidden path="userID"/>
+<form:hidden path="clubID"/>
+<div style="max-width:1200px;padding:15px;">
+    <table border="0" cellspacing="0" cellpadding="0" width="100%">
+        <tr height="28">
+            <th width="12%">状态:</th>
+            <td width="13%">${fns:getDictLabel(newCmClub.status, 'club_status', newCmClub.status)}</td>
+            <th width="12%">注册时间:</th>
+            <td width="13%"><fmt:formatDate value="${newCmClub.registerTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></td>
+        </tr>
+        <tr height="28">
+            <th width="12%">机构名称:</th>
+            <td width="13%">${newCmClub.name}
+            <th width="12%">机构简称:</th>
+            <td width="13%">${newCmClub.sname}
+            <th width="12%">注册邮箱:</th>
+            <td width="13%">${newCmClub.contractEmail}
+        </tr>
+        <tr height="28">
+            <th width="12%">联系人:</th>
+            <td width="13%">${newCmClub.userName}
+            </td>
+            <th width="12%">手机号:</th>
+            <td width="13%">${newCmClub.bindMobile}
+            <th width="12%">联系人身份:</th>
+            <td width="13%">
+                <c:if test="${newCmClub.linkManIdentity eq '1'}">老板</c:if>
+                <c:if test="${newCmClub.linkManIdentity eq '2'}">采购</c:if>
+                <c:if test="${newCmClub.linkManIdentity eq '3'}">运营</c:if>
+            </td>
+        </tr>
+    </table>
+</div>
+
+<input type="hidden" id="curProvince" name="curProvince" value="${newCmClub.province }" disabled="disabled">
+<input type="hidden" id="curCity" name="curCity" value="${newCmClub.city }" disabled="disabled">
+<input type="hidden" id="curTown" name="curTown" value="${newCmClub.town }" disabled="disabled">
+<sys:message content="${message}"/>
+<hr class="detailLine">
+<div>
+    <table border="0" cellspacing="0" cellpadding="0" width="100%">
+        <tr>
+            <td colspan="2">
+                <div class="control-group">
+                    <label class="control-label"><b>地址:</b></label>
+                    <div class="controls">
+                        <form:select path="provinceID" class="input-xlarge" id="province"
+                                     onchange="loadCity()" style="width:100px;">
+                            <form:option value="" label="省" provinceId=""/>
+                        </form:select>
+                        <form:select path="cityID" class="input-xlarge" id="city" onchange="loadTown()"
+                                     style="width:100px;">
+                            <form:option value="" label="市" cityId=""/>
+                        </form:select>
+                        <form:select path="townID" class="input-xlarge" id="town" style="width:100px;">
+                            <form:option value="" label="区"/>
+                        </form:select>
+                        <%--<form:input path="address" id="address" name="address" class="input-xlarge userAddress" width="20px" maxlength="60"
+                                    placeholder="请填写会所详细的地址"/>--%>
+                        ${newCmClub.address}
+                    </div>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td colspan="2">
+                <div class="control-group">
+                    <label class="control-label"><b>营业执照编号:</b></label>
+                    <div class="controls">${newCmClub.socialCreditCode}</div>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td>
+                <div class="control-group">
+                    <label class="control-label"><b>营业执照:</b></label>
+                    <img width="100" height="100" src="${newCmClub.businessLicenseImage}">
+                    <%--<div class="controls">
+                        <form:hidden id="businessLicenseImage" name="businessLicenseImage" path="businessLicenseImage" htmlEscape="false"
+                                     maxlength="255" class="input-xlarge required"/>
+                        <sys:ckfinder input="businessLicenseImage" type="images" uploadPath="/photo"
+                                      selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                    </div>--%>
+                </div>
+            </td>
+            <td>
+                <div class="control-group">
+                    <label class="control-label"><b>门头照:</b></label>
+                    <img width="100" height="100" src="${newCmClub.headpic}">
+                    <%--<div class="controls">
+                        <form:hidden id="headpic" name="headpic" path="headpic" htmlEscape="false" maxlength="255"
+                                     class="input-xlarge"/>
+                        <sys:ckfinder input="headpic" type="images" uploadPath="/photo" maxWidth="100" maxHeight="100"/>
+                    </div>--%>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td>
+                <div class="control-group">
+                    <label class="control-label" for=""><b>机构类型:</b></label>
+                    <div class="medical-radio the-oradio">
+                        <input value="${cmClubinfo.firstClubType}" class="hide" type="text" id="firstClubType"/>
+                        <div class="med-beauty">
+                            <c:if test="${cmClubinfo.firstClubType == '1'}">医美</c:if>
+                            <c:if test="${cmClubinfo.firstClubType == '2'}">生美</c:if>
+                            <c:if test="${cmClubinfo.firstClubType == '3'}">项目公司</c:if>
+                            <c:if test="${cmClubinfo.firstClubType == '4'}">个人</c:if>
+                            <c:if test="${cmClubinfo.firstClubType == '5'}">其他</c:if>
+
+                            <c:if test="${cmClubinfo.secondClubType eq '1'}"> - 诊所</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '2'}"> - 门诊</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '3'}"> - 医院</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '4'}"> - 其他</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '5'}"> - 美容院</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '6'}"> - 养生馆</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '7'}"> - 其他</c:if>
+<%--                            <input name="firstClubType" value="1" type="radio" ${cmClubinfo.firstClubType == "1" ? "checked" : ""}/>医美--%>
+                        </div>
+                        <%--<div class="raw-beauty">
+                            <input name="firstClubType" value="2" type="radio" ${cmClubinfo.firstClubType == "2" ? "checked" : ""}/>生美
+                        </div>
+                        <div class="raw-beauty">
+                            <input name="firstClubType" value="3" type="radio" ${cmClubinfo.firstClubType == "3" ? "checked" : ""}/>项目公司
+                        </div>
+                        <div class="raw-beauty">
+                            <input name="firstClubType" value="4" type="radio" ${cmClubinfo.firstClubType == "4" ? "checked" : ""}/>个人
+                        </div>
+                        <div class="raw-beauty">
+                            <input name="firstClubType" value="5" type="radio" ${cmClubinfo.firstClubType == "5" ? "checked" : ""}/>其他
+                        </div>--%>
+                    </div>
+                    <span class="err-tip"></span>
+                    <div class="med-option the-oradio" style="display: none" id="ejf">
+                        <div class="med-beauty">
+                            <%--<c:if test="${cmClubinfo.secondClubType eq '1'}">-诊所</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '2'}">-门诊</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '3'}">-医院</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '4'}">-其他</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '5'}">-美容院</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '6'}">-养生馆</c:if>
+                            <c:if test="${cmClubinfo.secondClubType eq '7'}">-其他</c:if>--%>
+<%--                            <input name="secondClubType" value="1"--%>
+<%--                                                       type="radio"  ${cmClubinfo.secondClubType == "1" ? "checked" : ""}/>诊所--%>
+                        </div>
+                        <%--<div class="med-beauty"><input name="secondClubType" value="2"
+                                                       type="radio"  ${cmClubinfo.secondClubType == "2" ? "checked" : ""}/>门诊
+                        </div>
+                        <div class="med-beauty"><input name="secondClubType" value="3"
+                                                       type="radio" ${cmClubinfo.secondClubType == "3" ? "checked" : ""}/>医院
+                        </div>
+                        <div class="med-beauty"><input name="secondClubType" value="4"
+                                                       type="radio" ${cmClubinfo.secondClubType == "4" ? "checked" : ""}/>其他
+                        </div>
+                        <span class="err-tip"></span>--%>
+                    </div>
+                    <%--<div class="raw-option the-oradio" style="display: none" id="ej">
+                        <div class="med-beauty"><input name="secondClubType" value="5"
+                                                       type="radio"  ${cmClubinfo.secondClubType == "5" ? "checked" : ""}/>美容院
+                        </div>
+                        <div class="med-beauty"><input name="secondClubType" value="6"
+                                                       type="radio"  ${cmClubinfo.secondClubType == "6" ? "checked" : ""}/>养生馆
+                        </div>
+                        <div class="med-beauty"><input name="secondClubType" value="7"
+                                                       type="radio" ${cmClubinfo.secondClubType == "7" ? "checked" : ""}/>其他
+                        </div>
+                        <span class="err-tip"></span>
+                    </div>--%>
+                    <div class="qualification control-group" style="display: none">
+                        <label class="control-label"><b>医疗许可证:</b></label>
+                        <img width="100" height="100" src="${cmClubinfo.medicalPracticeLicenseImg}">
+                        <%--<div class="controls" style="margin-bottom: 10px">
+                            <form:hidden id="medicalPracticeLicenseImg" path="medicalPracticeLicenseImg"
+                                         htmlEscape="false" maxlength="255"
+                                         class="input-xlarge"/>
+                            <sys:ckfinder input="medicalPracticeLicenseImg" type="images" uploadPath="/photo"
+                                          maxWidth="100" maxHeight="100"/>
+                        </div>--%>
+                    </div>
+                </div>
+                <div class="control-group epart" style="display: none">
+                    <label class="control-label"><b>科室:</b></label>
+                    <input class="reg-input" type="text" name="department" id="Department"
+                           placeholder="请填写您的所经营的科室,用逗号隔开。(至少三个)" value="${cmClubinfo.department}"
+                           style="margin-left: 10px;"/>
+                    <span class="err-tip"></span>
+                </div>
+                <div class="control-group" >
+                    <label class="control-label"><b>主营内容:</b></label>
+<%--                    <div class="tags-area" id="clubArea"></div>--%>
+<%--                    <span class="err-tip" style="display: inline-block;margin-left:-55px;"></span>--%>
+                    <font size="3">${cmClubinfo.mainpro}</font>
+<%--                    <input type="hidden" name="mainpro" value="${cmClubinfo.mainpro}" id="cMainPro">--%>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td>
+                <div class="control-group">
+                    <label class="control-label"><b>固定电话:</b></label>
+                    <div class="controls">${cmClubinfo.contractPhone}</div>
+                </div>
+            </td>
+            <td>
+                <div class="control-group">
+                    <label class="control-label"><b>传真:</b></label>
+                    <div class="controls">${cmClubinfo.fax}</div>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td colspan="2">
+                <div class="control-group">
+                    <label class="control-label"><b>员工人数:</b></label>
+                    <div class="controls">${cmClubinfo.empnum}</div>
+                </div>
+            </td>
+        </tr>
+        <tr>
+            <td colspan="2">
+                <div class="control-group">
+                    <label class="control-label"><b>公司简介:</b></label>
+                    <div class="controls">${cmClubinfo.info}</div>
+                </div>
+            </td>
+        </tr>
+    </table>
+    <div>
+        <div class="clubInfo">
+            <div class="clubInfoTitle">基本信息</div>
+            <table border="0" cellspacing="0" cellpadding="0" width="100%">
+                <tr height="28">
+                    <th>机构面积:</th>
+                    <td>${cmClubinfo.area}<%--<form:input path="area" name="area" htmlEscape="false" class="input-medium" onkeyup="num(this)"/>--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>美容床数:</th>
+                    <td>${cmClubinfo.bedNums}<%--<form:input path="bedNums" name="bedNums" htmlEscape="false" maxlength="11" class="input-medium"
+                                    onkeyup="int(this)"/>--%>
+                            <%--<input type="text" name="bedNums" value="${clubInfo.bedNums}">--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>美容师数:</th>
+                    <td>${cmClubinfo.beauticians}<%--<form:input path="beauticians" name="beauticians" htmlEscape="false" maxlength="11" class="input-medium"
+                                    onkeyup="int(this)"/>--%>
+                    </td>
+                </tr>
+            </table>
+        </div>
+        <div class="clubInfo">
+            <div class="clubInfoTitle">业绩信息</div>
+            <table border="0" cellspacing="0" cellpadding="0" width="100%">
+                <tr height="28">
+                    <th>月业绩:</th>
+                    <td>${cmClubinfo.monthAchievement}<%--<form:input path="monthAchievement" name="monthAchievement" htmlEscape="false" maxlength="63" class="input-medium"
+                                    onkeyup="num(this)"/>--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>促销业绩:</th>
+                    <td>${cmClubinfo.promotionAchievement}<%--<form:input path="promotionAchievement" name="promotionAchievement" htmlEscape="false" maxlength="63" class="input-medium"
+                                    onkeyup="num(this)"/>--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>年业绩:</th>
+                    <td>${cmClubinfo.yearAchievement}<%--<form:input path="yearAchievement" name="yearAchievement" htmlEscape="false" maxlength="63" class="input-medium"
+                                    onkeyup="num(this)"/>--%>
+                    </td>
+                </tr>
+            </table>
+        </div>
+        <div class="clubInfo">
+            <div class="clubInfoTitle">会员信息及消费情况</div>
+            <table border="0" cellspacing="0" cellpadding="0" width="100%">
+                <tr height="28">
+                    <th>A类会员:</th>
+                    <td colspan="3" style="padding-top: 6px;">
+                        <%--<form:input path="cateA" name="cateA" htmlEscape="false" maxlength="11" class="cut-input-medium"
+                                    onkeyup="int(this)"/>--%>${cmClubinfo.cateA}人&nbsp;
+                        <%--<form:input path="consumeA" name="consumeA" htmlEscape="false" class="cut-input-medium" onkeyup="num(this)"/>--%>${cmClubinfo.consumeA}元
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>B类会员:</th>
+                    <td colspan="3" style="padding-top: 6px;">
+                        <%--<form:input path="cateB" name="cateB"  htmlEscape="false" maxlength="11" class="cut-input-medium"
+                                    onkeyup="int(this)"/>--%>${cmClubinfo.cateB}人&nbsp;
+                        <%--<form:input path="consumeB" name="consumeB" htmlEscape="false" class="cut-input-medium" onkeyup="num(this)"/>--%>${cmClubinfo.consumeB}元
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>C类会员:</th>
+                    <td colspan="3" style="padding-top: 6px;">
+                        <%--<form:input path="cateC" name="cateC" htmlEscape="false" maxlength="11" class="cut-input-medium"
+                                    onkeyup="int(this)"/>--%>${cmClubinfo.cateC}人&nbsp;
+                        <%--<form:input path="consumeC" name="consumeC" htmlEscape="false" class="cut-input-medium" onkeyup="num(this)"/>--%>${cmClubinfo.consumeC}元
+                    </td>
+                </tr>
+            </table>
+        </div>
+        <div class="clubInfo">
+            <div class="clubInfoTitle">活动业绩</div>
+            <table border="0" cellspacing="0" cellpadding="0" width="100%">
+                <tr height="28">
+                    <th>最高业绩:</th>
+                    <td>${cmClubinfo.highestAchievement}
+                        <%--<form:input path="highestAchievement" name="highestAchievement" htmlEscape="false" maxlength="63" class="input-medium"
+                                    onkeyup="num(this)"/>--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>到店人数:</th>
+                    <td>${cmClubinfo.reachPepole}
+                        <%--<form:input path="reachPepole" name="reachPepole" htmlEscape="false" maxlength="11" class="input-medium"
+                                    onkeyup="int(this)"/>--%>
+                    </td>
+                </tr>
+                <tr height="28">
+                    <th>成交人数:</th>
+                    <td>${cmClubinfo.clinchPepole}
+                        <%--<form:input path="clinchPepole" htmlEscape="false" maxlength="11" class="input-medium"
+                                    onkeyup="int(this)"/>--%>
+                    </td>
+                </tr>
+            </table>
+        </div>
+        <table border="0" cellspacing="0" cellpadding="0" width="100%">
+            <tr height="28">
+                <th>店内所经营品牌及推广优势:</th>
+                <td colspan="10" width="25%">${cmClubinfo.brandSuperiority}
+                    <%--<form:textarea rows="7" cols="80" path="brandSuperiority" htmlEscape="false" cssStyle="width:90%;"
+                                   maxlength="200"/>--%>
+                </td>
+                <th>临近一次促销的模式及达成业绩:</th>
+                <td colspan="10" width="25%">${cmClubinfo.lastPromotion}
+                    <%--<form:textarea rows="7" cols="80" path="lastPromotion" htmlEscape="false" cssStyle="width:90%;"
+                                   maxlength="200"/>--%>
+                </td>
+            </tr>
+        </table>
+    </div>
+    </form:form>
+</body>
+</html>

+ 51 - 21
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordDetailsList.jsp

@@ -6,6 +6,7 @@
   Time: 10:57
   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>
@@ -29,37 +30,31 @@
     <c:if test="${cmBehaviorRecord.behaviorType eq '1'}">
         <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">用户行为记录</a></li>
     </c:if>
-    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
 
 </ul>
-<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&behaviorType=${cmBehaviorRecord.behaviorType}" method="post" class="breadcrumb form-search">
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}" 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>
+    <c:if test="${cmBehaviorRecord.userIdentity == '2' or cmBehaviorRecord.userIdentity == '4'}">
+        <div class="ul-form">
+            <ul class="nav nav-tabs">
+                <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">访问详情</a></li>
+                <li><a href="${ctx}/user/behavior/record/recordAgency?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">机构信息</a></li>
+                <li><a href="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">咨询记录</a></li>
+                <li><a href="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">报备记录</a></li>
+                <li><a href="${ctx}/user/behavior/record/behaviorNewOrder?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">订单信息</a></li>
+            </ul>
+        </div>
+    </c:if>
 </form:form>
 <sys:message content="${message}"/>
 <table id="contentTable" class="table table-striped table-bordered table-condensed">
     <thead>
     <tr>
         <th style="width: 350px;">页面路径</th>
+        <th>访问来源</th>
+        <th>访问客户端</th>
         <th>页面类型</th>
         <th>页面标签</th>
         <th>商品图片</th>
@@ -80,6 +75,40 @@
                     <a href="${cmBehaviorRecord.pagePath}" target="_blank">${cmBehaviorRecord.pagePath}</a>
                 </c:if>
             </td>
+            <td>
+                <c:if test="${cmBehaviorRecord.accessSource == '0'}">
+                    直接访问
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '1'}">
+                    百度搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '2'}">
+                    360搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '3'}">
+                    谷歌搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '4'}">
+                    神马搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '5'}">
+                    头条搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '6'}">
+                    搜狗搜索
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessSource == '7'}">
+                    直接访问
+                </c:if>
+            </td>
+            <td>
+                <c:if test="${cmBehaviorRecord.accessClient == '0'}">
+                    网站
+                </c:if>
+                <c:if test="${cmBehaviorRecord.accessClient == '1'}">
+                    小程序
+                </c:if>
+            </td>
             <td>${cmBehaviorRecord.pageTypes}</td>
             <td>${cmBehaviorRecord.pageLabel}</td>
             <c:if test="${cmBehaviorRecord.productID == '0'}">
@@ -99,6 +128,7 @@
     </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);

+ 12 - 1
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordList.jsp

@@ -76,6 +76,7 @@
     <thead>
         <tr>
             <th>IP</th>
+            <th>地区</th>
             <th>公司类型</th>
             <th>公司名称</th>
             <th>联系人</th>
@@ -84,6 +85,7 @@
             <th>访问页面数量</th>
             <th>总时长</th>
             <th>访问日期</th>
+            <th>最后访问时间</th>
             <th>操作</th>
         </tr>
     </thead>
@@ -91,6 +93,14 @@
     <c:forEach items="${page.list}" var="cmBehaviorRecord" varStatus="index">
         <tr>
            <td>${cmBehaviorRecord.IP}</td>
+            <td>
+            <c:if test="${empty cmBehaviorRecord.region}">
+                ---
+            </c:if>
+            <c:if test="${not empty cmBehaviorRecord.region}">
+                ${cmBehaviorRecord.region}
+            </c:if>
+            </td>
            <td>
                <c:if test="${cmBehaviorRecord.userIdentity eq 2 || cmBehaviorRecord.userIdentity eq 4}">
                    机构
@@ -151,8 +161,9 @@
            <td>${cmBehaviorRecord.numbers}</td>
            <td>${cmBehaviorRecord.accessDuration}</td>
            <td>${cmBehaviorRecord.accessDate}</td>
+           <td>${cmBehaviorRecord.lastAccessTime}</td>
            <td>
-               <a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&behaviorType=1">查看详情</a>
+               <a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=1">查看详情</a>
            </td>
         </tr>
     </c:forEach>

+ 10 - 1
src/main/webapp/WEB-INF/views/modules/user/behaviorRecordRossList.jsp

@@ -76,6 +76,7 @@
     <thead>
     <tr>
         <th>IP</th>
+        <th>地区</th>
         <th>公司类型</th>
         <th>公司名称</th>
         <th>联系人</th>
@@ -93,6 +94,14 @@
     <c:forEach items="${page.list}" var="cmBehaviorRecord" varStatus="index">
         <tr>
             <td>${cmBehaviorRecord.IP}</td>
+            <td>
+                <c:if test="${empty cmBehaviorRecord.region}">
+                    ---
+                </c:if>
+                <c:if test="${not empty cmBehaviorRecord.region}">
+                    ${cmBehaviorRecord.region}
+                </c:if>
+            </td>
             <td>
                 <c:if test="${cmBehaviorRecord.userIdentity eq 2 || cmBehaviorRecord.userIdentity eq 4}">
                     机构
@@ -169,7 +178,7 @@
             <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}&behaviorType=2">查看详情</a>
+                <a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=2">查看详情</a>
             </td>
         </tr>
     </c:forEach>

+ 246 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorRemarks.jsp

@@ -0,0 +1,246 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/WEB-INF/views/include/taglib.jsp" %>
+<html>
+<head>
+    <title>咨询记录</title>
+    <meta name="decorator" content="default"/>
+    <script type="text/javascript">
+
+    </script>
+    <style>
+        .table th {
+            text-align: center
+        }
+
+        .table td {
+            text-align: center
+        }
+    </style>
+</head>
+<body>
+<ul class="nav nav-tabs">
+    <c:if test="${cmBehaviorRecord.behaviorType eq '2'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">ROSS页面统计</a></li>
+    </c:if>
+    <c:if test="${cmBehaviorRecord.behaviorType eq '1'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">用户行为记录</a></li>
+    </c:if>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
+</ul>
+<br/>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}" 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">
+        <ul class="nav nav-tabs">
+            <li><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">访问详情</a></li>
+            <li><a href="${ctx}/user/behavior/record/recordAgency?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">机构信息</a></li>
+            <li class="active"><a href="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">咨询记录</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">报备记录</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorNewOrder?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">订单信息</a></li>
+        </ul>
+    </div>
+</form:form>
+<form:form id="inputForm" modelAttribute="cmClubRemarks" action="#" method="post" class="form-horizontal">
+    <sys:message content="${message}"/>
+    <c:if test="${not empty page.list}">
+        <div style="overflow-x: hidden;word-break:break-all">
+            <c:forEach items="${page.list}" var="clubRemarks" varStatus="remark">
+                <div class="td clear" style="dashed:#0066CC;">
+                    <div style="font-weight: bold;width: 100%;float: left;">
+                            <%--                        <c:if test="${not empty clubRemarks.oldName}">--%>
+                            <%--                            <span style="float: left;">${clubRemarks.oldName}</span>--%>
+                            <%--                        </c:if>--%>
+                            <%--                        <c:if test="${empty clubRemarks.oldName}">--%>
+                            <%--                            <span style="float: left;">${clubRemarks.spName}</span>--%>
+                            <%--                        </c:if>--%>
+                        <span style="float: left;">${clubRemarks.spName}</span>
+                        <span style="float: left;margin-left:20px;"><fmt:formatDate value="${clubRemarks.addTime}"
+                                                                                    pattern="yyyy-MM-dd HH:mm"/></span>
+                        <span style="float: left;margin-left:120px;">管理员:${clubRemarks.leaderName}</span>
+                    </div>
+                    <div class="td-text" style="width: 100%;float: left;margin-top: 20px;">
+                        <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                            咨询人 :
+                        </div>
+                        <div style="width: 150px;float: left;margin: 10px 0;">${clubRemarks.questionMan}</div>
+                        <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                            机构名称:
+                        </div>
+                        <div style="width: 150px;float: left;margin: 10px 0;">${clubRemarks.clubName}<c:if test="${clubRemarks.newDeal eq 1}"><span style="color: red">(新分配)</span></c:if></div>
+                        <c:if test="${not empty clubRemarks.clubType}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                机构类型:
+                            </div>
+                            <div style=" width: 150px;float: left;margin: 10px 0;position: relative;">${clubRemarks.clubType}</div>
+                        </c:if>
+                    </div>
+                    <div class="td-text" style="width: 100%;float: left;margin-top: 20px;">
+                        <div style="width: 80px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                            咨询类别:
+                        </div>
+                        <div style="width: 300px;float: left;margin: 10px 0;">${clubRemarks.consultType}</div>
+                        <c:if test="${not empty clubRemarks.productName}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                咨询商品:
+                            </div>
+                            <div style="width: 300px;float: left;margin: 10px 0;"><img src="${clubRemarks.mainImage}"
+                                                                                       width="50"
+                                                                                       height="50"> ${clubRemarks.productName}
+                            </div>
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                供应商名称:${clubRemarks.shopName}
+
+                            </div>
+                            <%--                            <span style="width: 300px;float: left;margin: 10px 0;">${clubRemarks.shopName}</span>--%>
+                        </c:if>
+                    </div>
+                    <c:if test="${not empty clubRemarks.proName}">
+                        <table id="contentTable" class="table table-striped table-bordered table-condensed">
+                            <thead>
+                            <tr>
+                                <th>商品图片</th>
+                                <th>商品名称</th>
+                                <th>报备事由</th>
+                                <th>审核状态</th>
+                                <th>审核人</th>
+                                <th>审核时间</th>
+                            </tr>
+                            <td><img src="${clubRemarks.productMainImage}"
+                                     width="50"
+                                     height="50"></td>
+                            <td>${clubRemarks.proName}</td>
+                            <td>${clubRemarks.reportText}</td>
+                            <td><c:if test="${clubRemarks.reportStatus eq 1}">待审核</c:if>
+                                <c:if test="${clubRemarks.reportStatus eq 2}">已审核</c:if>
+                                <c:if test="${clubRemarks.reportStatus eq 3}">审核未通过</c:if>
+                            </td>
+                            <td>${clubRemarks.auditName}</td>
+                            <td>${clubRemarks.auditTime}</td>
+                            </thead>
+                        </table>
+                    </c:if>
+                    <div class="td-text" style="width: 100%;float: left;margin-top: 20px;">
+                        <c:if test="${not empty clubRemarks.pinceSensitve}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                价格敏感度 :
+                            </div>
+                            <c:if test="${clubRemarks.pinceSensitve eq 1}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">敏感</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.pinceSensitve eq 2}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">适中</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.pinceSensitve eq 3}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">不敏感</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.pinceSensitve eq 4}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">不明确</div>
+                            </c:if>
+
+                        </c:if>
+                        <c:if test="${not empty clubRemarks.satisfied}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                意向程度:
+                            </div>
+                            <c:if test="${clubRemarks.satisfied eq 1}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">意向强烈</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.satisfied eq 2}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">意向一般</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.satisfied eq 3}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">意向平淡</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.satisfied eq 4}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">随便看看</div>
+                            </c:if>
+
+                        </c:if>
+                        <c:if test="${not empty clubRemarks.followup}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                跟进状态:
+                            </div>
+                            <c:if test="${clubRemarks.followup eq 1}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">跟进中</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.followup eq 2}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">跟进完成</div>
+                            </c:if>
+                            <c:if test="${clubRemarks.followup eq 3}">
+                                <div style="width: 150px;float: left;margin: 10px 0;">已放弃</div>
+                            </c:if>
+
+                        </c:if>
+                    </div>
+                    <div class="td-text" style="width: 100%;float: left;margin-top: 20px;">
+                        <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                            关键词记录:
+                        </div>
+                        <div style="width: 800px;float: left;margin: 10px 0;">
+                                ${clubRemarks.remarks}
+                        </div>
+                    </div>
+                    <c:if test="${not empty clubRemarks.extra}">
+                        <div class="td-text" style="width: 100%;float: left;margin-top: 20px;">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                额外说明:
+                            </div>
+                            <div style="width: 800px;float: left;margin: 10px 0;">
+                                    ${clubRemarks.extra}
+                            </div>
+                        </div>
+                    </c:if>
+                    <div class="td-text" style="width: 100%;float: left;">
+                        <c:if test="${not empty clubRemarks.imageList}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                图片:
+                            </div>
+                            <div style="width: 1000px;float: left;">
+                                <c:forEach items="${clubRemarks.imageList}" var="imageUrl" varStatus="remarkImage">
+                                    <a href="${imageUrl}" target="_blank">
+                                        <img class="enlarge-pic" style="height: 150px;width: 150px;margin-top: 10px"
+                                             src="${imageUrl}">&nbsp;
+                                    </a>
+                                </c:forEach>
+                            </div>
+                        </c:if>
+                    </div>
+                    <div class="td-text"
+                         style="width: 100%;float: left;margin-top: 20px;border-bottom:1px dashed #999999;padding: 10px 0;">
+                        <c:if test="${not empty clubRemarks.fileList}">
+                            <div style="width: 100px;font-weight: bold;margin: 10px 0;float: left;text-align: right;margin-right: 10px;">
+                                文件:
+                            </div>
+                            <div style="width: 1000px;float: left;margin: 10px 0;">
+                                <c:forEach items="${clubRemarks.fileList}" var="item" varStatus="remarkFile">
+                                    <p>${item.fileName}&nbsp;&nbsp;&nbsp;&nbsp;
+                                        <a onclick="previewFile('${item.fileUrl}')" target="_blank">预览</a>&nbsp;&nbsp;&nbsp;&nbsp;
+                                        <a href="${ctx}/new/user/agency/remarks/download?fileName=${item.fileName}&ossName=${item.ossName}">下载</a>
+                                    </p>
+                                </c:forEach>
+                            </div>
+                        </c:if>
+                    </div>
+                </div>
+            </c:forEach>
+        </div>
+        <div class="pagination">${page}</div>
+    </c:if>
+    <%--    <c:if test="${empty page.list}">--%>
+    <%--        <font size="3" style="text-align: center;display: block;line-height: 80px;" color="#0066CC">暂无任何备注..</font>--%>
+    <%--    </c:if>--%>
+</form:form>
+<c:if test="${empty page.list}">
+    <p style="text-align: center;"><font color="#1e90ff">暂无咨询记录……</font></p>
+</c:if>
+<script type="text/javascript">
+    function page(n,s){
+        $("#pageNo").val(n);
+        $("#pageSize").val(s);
+        $("#searchForm").submit();
+        return false;
+    }
+</script>
+</body>
+</html>

+ 373 - 0
src/main/webapp/WEB-INF/views/modules/user/behaviorReport.jsp

@@ -0,0 +1,373 @@
+<%@ 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 type="text/css">
+        .reg-row .new-tag.active {
+            border: 1px solid #de5801
+        }
+
+        .reg-row {
+            margin-bottom: 20px
+        }
+
+        .reg-row .reg-label {
+            display: inline-block;
+            width: 120px;
+            text-align: right;
+            font-size: 13px
+        }
+
+        .the-oradio {
+            display: inline-block;
+            vertical-align: top
+        }
+
+        .the-oradio div {
+            width: 85px;
+            display: inline-block;
+            font-size: 12px;
+            color: #666
+        }
+
+        .the-oradio div input[type="radio"] {
+            width: 17px;
+            height: 17px;
+            margin-right: 5px;
+            vertical-align: text-top
+        }
+
+        .med-option {
+            display: block;
+            margin: 10px 0 0 125px
+        }
+
+        .reg-row .business-license {
+            position: relative;
+            display: inline-block;
+            width: 166px;
+            height: 123px;
+            border-radius: 6px;
+            margin: 18px 0 0 125px
+        }
+
+        #medicalPracticeLicenseImgPreview {
+            display: inline-block
+        }
+
+        .qualification {
+            margin-top: 20px
+        }
+
+        .reg-row .tags-area {
+            display: inline-block;
+            width: 420px
+        }
+
+        .reg-row .new-tag {
+            display: inline-block;
+            width: 70px;
+            border: 1px solid #e5e5e5;
+            border-radius: 6px;
+            padding: 5px;
+            margin-right: 14px;
+            margin-bottom: 14px;
+            text-align: center;
+            font-size: 10px;
+            overflow: hidden;
+            text-overflow: ellipsis;
+            white-space: nowrap;
+            cursor: pointer
+        }
+
+        .reg-row .tags-operate {
+            margin-left: 125px
+        }
+
+        .reg-row .reg-input {
+            width: 336px;
+            height: 32px;
+            padding: 0 8px;
+            margin-right: 20px;
+            border: 1px solid #dcdcdc;
+            border-radius: 6px
+        }
+
+        .reg-row .tags-operate .tag-input {
+            width: 159px;
+            margin-right: 13px;
+            display: none;
+            vertical-align: top
+        }
+
+        .reg-row .tags-operate .tag-add {
+            line-height: 20px;
+            vertical-align: middle;
+            margin-bottom: 0;
+            vertical-align: top
+        }
+
+        .reg-row .tags-area {
+            vertical-align: top
+        }
+
+        .tag-add {
+            display: none
+        }
+
+        .table th {
+            text-align: center
+        }
+
+        .table td {
+            text-align: center
+        }
+
+        .modal {
+            width: 700px;
+            margin-left: -350px
+        }
+
+        #myModal {
+            display: none
+        }
+
+        .modal-body {
+            max-height: 300px !important
+        }
+
+        .modal.fade.in {
+            top: 0 !important
+        }
+
+        #btnSubmit {
+            margin-left: 20px
+        }
+
+        .flex-wrap .item {
+            margin-right: 20px
+        }
+
+        #auditBox {
+            padding: 20px;
+            line-height: 30px
+        }
+
+        #auditBox .bd-row {
+            display: flex;
+            margin-bottom: 15px
+        }
+
+        #auditBox .bd-row > span {
+            display: inline-block;
+            width: 60px
+        }
+
+        #auditBox .auditCheckBox {
+            width: 250px
+        }
+
+        #auditBox .auditCheckBox label {
+            margin: 0 5px 5px 0
+        }
+
+        #auditBox .auditCheckBox input {
+            display: none
+        }
+
+        #auditBox .auditCheckBox input + span {
+            display: inline-block;
+            line-height: 24px;
+            padding: 0 12px;
+            border: 1px solid #666;
+            border-radius: 5px
+        }
+
+        #auditBox .auditCheckBox input:checked + span {
+            background-color: #E6633A
+        }
+
+        #alertModal {
+            width: 300px;
+            height: 200px;
+            border: 1px solid #ebebeb;
+            border-radius: 10px;
+            position: fixed;
+            top: 0;
+            bottom: 0;
+            left: 0;
+            right: 0;
+            margin: auto;
+            background: #FFFFFF;
+            display: none
+        }
+
+        #alertModal .title {
+            height: 50px;
+            line-height: 50px;
+            font-size: 14px;
+            font-weight: bold;
+            text-align: center;
+            position: relative;
+            border-bottom: 1px solid #EBEBEB
+        }
+
+        #alertModal .close {
+            width: 50px;
+            height: 50px;
+            display: block;
+            position: absolute;
+            right: 0;
+            top: 0;
+            line-height: 50px;
+            color: #000;
+            font-weight: bold;
+            text-align: center;
+            font-style: normal;
+            font-size: 18px
+        }
+
+        #alertModal .alert-content {
+            width: 260px;
+            height: 60px;
+            padding: 20px
+        }
+
+        #alertModal .alertModal-btn {
+            width: 260px;
+            height: 49px;
+            padding: 0 20px;
+            border-top: 1px solid #EBEBEB
+        }
+
+        #alertModal .alertModal-btn button {
+            float: right;
+            margin: 5px
+        }
+
+    </style>
+</head>
+<body>
+<ul class="nav nav-tabs">
+    <c:if test="${cmBehaviorRecord.behaviorType eq '2'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">ROSS页面统计</a></li>
+    </c:if>
+    <c:if test="${cmBehaviorRecord.behaviorType eq '1'}">
+        <li><a href="${ctx}/user/behavior/record/list?behaviorType=${cmBehaviorRecord.behaviorType}">用户行为记录</a></li>
+    </c:if>
+    <li class="active"><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">查看详情</a></li>
+
+</ul>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}" 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">
+        <ul class="nav nav-tabs">
+            <li><a href="${ctx}/user/behavior/record/recordList?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">访问详情</a></li>
+            <li><a href="${ctx}/user/behavior/record/recordAgency?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">机构信息</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorRemarks?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">咨询记录</a></li>
+            <li class="active"><a href="${ctx}/user/behavior/record/behaviorReport?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">报备记录</a></li>
+            <li><a href="${ctx}/user/behavior/record/behaviorNewOrder?IP=${cmBehaviorRecord.IP}&accessDate=${cmBehaviorRecord.accessDate}&userID=${cmBehaviorRecord.userID}&clubID=${cmBehaviorRecord.clubID}&userIdentity=${cmBehaviorRecord.userIdentity}&behaviorType=${cmBehaviorRecord.behaviorType}">订单信息</a></li>
+        </ul>
+    </div>
+</form:form>
+<sys:message content="${message}"/>
+<table id="contentTable" class="table table-striped table-bordered table-condensed">
+    <thead>
+    <tr>
+        <th>ID</th>
+        <th>商品图片</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="list">
+        <tr>
+            <td>
+                    ${list.reportId}
+            </td>
+            <td>
+                <c:if test="${not empty list.mainImage}">
+                    <img src="${list.mainImage}"
+                         width="50"
+                         height="50">
+                </c:if>
+                <c:if test="${empty list.mainImage}">
+                    -----
+                </c:if>
+            </td>
+            <td>
+                <c:if test="${not empty list.productName}">
+                    ${list.productName}
+                </c:if>
+                <c:if test="${empty list.productName}">
+                    -----
+                </c:if>
+            </td>
+
+            <td>
+                <c:if test="${not empty list.clubName}">
+                    ${list.clubName}<c:if test="${list.newDeal eq 1}"><span style="color: red">(新分配)</span></c:if>
+                </c:if>
+                <c:if test="${empty list.clubName}">
+                    -----
+                </c:if>
+
+            </td>
+            <td>
+                    ${list.reportName}
+            </td>
+            <td>
+                    ${list.reportText}
+            </td>
+            <td>
+                    ${list.addTime}
+            </td>
+            <td>
+                <c:if test="${empty list.auditText}">
+                    <c:if test="${list.status eq 1}"><span style="color: red">待审核</span></c:if>
+                    <c:if test="${list.status eq 2}"><span style="color: #00aa00">已审核 </span></c:if>
+                    <c:if test="${list.status eq 3}">审核未通过</c:if>
+                </c:if>
+                <c:if test="${not empty list.auditText}">
+                    <c:if test="${list.status eq 1}"><a href="javascript:void(0)" onclick="audit('${list.auditText}')" style="color: red;text-decoration: underline;">待审核</a></c:if>
+                    <c:if test="${list.status eq 2}"><a href="javascript:void(0)" onclick="audit('${list.auditText}')" style="color: #00aa00;text-decoration: underline;">已审核</a></c:if>
+                    <c:if test="${list.status eq 3}"><a href="javascript:void(0)" onclick="audit('${list.auditText}')" style="text-decoration: underline; color: #0d0d0d">审核未通过</a></c:if>
+                </c:if>
+
+            </td>
+            <td>${list.auditName} </td>
+            <td>${list.auditTime}</td>
+            <td>
+                <a href="${ctx}/new/user/agency/cmRegistReportList?reportID=${list.reportId}">查看</a>
+            </td>
+        </tr>
+    </c:forEach>
+
+    </tbody>
+
+</table>
+<div class="pagination">${page}</div>
+<c:if test="${empty page.list}">
+    <p style="text-align: center;"><font color="#1e90ff">暂无报备记录……</font></p>
+</c:if>
+<script type="text/javascript">
+    function page(n,s){
+        $("#pageNo").val(n);
+        $("#pageSize").val(s);
+        $("#searchForm").submit();
+        return false;
+    }
+</script>
+</body>
+</html>

+ 1 - 0
src/main/webapp/WEB-INF/views/modules/userNew/cmAgencyForm.jsp

@@ -532,6 +532,7 @@
                 <form:radiobutton path="linkManIdentity" name="linkManIdentity" class="required" value="1" label="老板"/>
                 <form:radiobutton path="linkManIdentity" name="linkManIdentity" class="required" value="2" label="采购"/>
                 <form:radiobutton path="linkManIdentity" name="linkManIdentity" class="required" value="3" label="运营"/>
+                <form:radiobutton path="linkManIdentity" name="linkManIdentity" class="required" value="4" label="其他"/>
             </td>
         </tr>
     </table>

+ 60 - 5
src/main/webapp/WEB-INF/views/modules/userNew/recordLinkageForm.jsp

@@ -1,3 +1,4 @@
+<%@ taglib prefix="C" uri="http://java.sun.com/jsp/jstl/core" %>
 <%@ page contentType="text/html;charset=UTF-8" %>
 <%@ include file="/WEB-INF/views/include/taglib.jsp"%>
 <html>
@@ -26,9 +27,6 @@
             text-align: center;
             white-space: nowrap;
         }
-        .controls{
-            font-size: 0;
-        }
         .controls .conList{
             display: inline-block;
             margin-right: 15px;
@@ -138,9 +136,66 @@
 			<input id="btnSubmit" class="btn btn-primary"  type="submit" value="确定并生成链接"/>
 		</div>
 	</form:form>
+<form:form id="searchForm" modelAttribute="cmBehaviorRecord" action="${ctx}/new/user/agency/recordLinkage?clubId=${clubId}" 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}"/>
+</form:form>
+<table id="contentTable" class="table table-striped table-bordered table-condensed">
+	<thead>
+	<tr>
+		<th style="width: 350px;">页面路径</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'}">
+				<c:if test="${empty page.list}">
+					<td></td>
+				</c:if>
+				<c:if test="${not empty page.list}">
+					<td><img src="${cmBehaviorRecord.productImage}" width="50" height="50"></td>
+				</c:if>
+				<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>
-
+	<script type="text/javascript">
+	function page(n,s){
+		$("#pageNo").val(n);
+		$("#pageSize").val(s);
+		$("#searchForm").submit();
+		return false;
+	}
 	function copylink(link){
 		console.log('link====>',link);
 		debugger