From ee5c8055b1c0dd7c67a9025a76b10bd287c93d9a Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期三, 15 四月 2020 09:52:27 +0800 Subject: [PATCH] 资金明细增加团队分红 --- fanli/src/main/java/com/yeshi/fanli/util/factory/msg/MsgAccountDetailFactory.java | 138 ++------------------------------------------- 1 files changed, 8 insertions(+), 130 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/util/factory/msg/MsgAccountDetailFactory.java b/fanli/src/main/java/com/yeshi/fanli/util/factory/msg/MsgAccountDetailFactory.java index 5081430..d365e90 100644 --- a/fanli/src/main/java/com/yeshi/fanli/util/factory/msg/MsgAccountDetailFactory.java +++ b/fanli/src/main/java/com/yeshi/fanli/util/factory/msg/MsgAccountDetailFactory.java @@ -14,9 +14,6 @@ import com.yeshi.fanli.vo.msg.CommonMsgItemVO; import com.yeshi.fanli.vo.msg.CommonMsgItemVOFactory; -import net.sf.json.JSONArray; -import net.sf.json.JSONObject; - public class MsgAccountDetailFactory { public final static int TYPE_WX = 1;// 寰俊 public final static int TYPE_TB = 2;// 娣樺疂 @@ -122,7 +119,7 @@ List<CommonMsgItemVO> listMsg = new ArrayList<>(); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("缁戝畾璇︽儏", ClientTextStyleVO.COLOR_TITLE), - new ClientTextStyleVO("鎭枩浣狅紒" + info +"-"+ way, ClientTextStyleVO.COLOR_CONTENT))); + new ClientTextStyleVO("寰堟姳姝夛紒" + info +"-"+ way, ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("缁戝畾璐﹀彿", ClientTextStyleVO.COLOR_TITLE), new ClientTextStyleVO(typeName, ClientTextStyleVO.COLOR_CONTENT))); if (!StringUtil.isNullOrEmpty(reason)) { @@ -159,7 +156,7 @@ new ClientTextStyleVO("閭�璇风爜淇敼", ClientTextStyleVO.COLOR_CONTENT))); List<ClientTextStyleVO> contentList2 = new ArrayList<>(); - contentList2.add(new ClientTextStyleVO(String.format("浣犲師閭�璇风爜:%s宸茬粡鎴愬姛淇敼涓烘柊閭�璇风爜:", oldCode), ClientTextStyleVO.COLOR_CONTENT)); + contentList2.add(new ClientTextStyleVO(String.format("浣犲師閭�璇风爜:%s 宸茬粡鎴愬姛淇敼涓烘柊閭�璇风爜:", oldCode), ClientTextStyleVO.COLOR_CONTENT)); contentList2.add(new ClientTextStyleVO(newCode, ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT)); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("淇敼璇︽儏", ClientTextStyleVO.COLOR_TITLE),contentList2)); @@ -181,134 +178,15 @@ return detail; } + + - /** - * 璐﹀彿瑙g粦鎴愬姛 - * - * @param uid - * @param type - * @return - */ - public static MsgAccountDetail createUnBindingAccount(Long uid, int type) { - String msg = ""; - if (type == TYPE_PHONE) { - msg = "<highlight>鎵嬫満鍙疯В缁戞垚鍔�</highlight>"; - } else if (type == TYPE_TB) { - msg = "<highlight>娣樺疂瑙g粦鎴愬姛</highlight>"; - } else if (type == TYPE_WX) { - msg = "<highlight>寰俊瑙g粦鎴愬姛</highlight>"; - } - if (StringUtil.isNullOrEmpty(msg)) - return null; - MsgAccountDetail detail = new MsgAccountDetail(); - detail.setBeiZhu("鏃�"); - detail.setContent(msg); - detail.setTitle("瑙g粦璐﹀彿"); - detail.setType(MsgTypeAccountTypeEnum.cancelBinding); - detail.setUser(new UserInfo(uid)); - detail.setCreateTime(new Date()); - detail.setRead(false); - return detail; - } - /** - * 璐﹀彿鏇存崲鎴愬姛 - * - * @param uid - * @param type - * @return - */ - public static MsgAccountDetail createChangeBindingAccount(Long uid, int type) { - String msg = ""; - if (type == TYPE_PHONE) { - msg = "<highlight>鎵嬫満鍙锋洿鎹㈢粦瀹氭垚鍔�</highlight>"; - } else if (type == TYPE_TB) { - msg = "<highlight>娣樺疂鏇存崲缁戝畾鎴愬姛</highlight>"; - } else if (type == TYPE_WX) { - msg = "<highlight>寰俊鏇存崲缁戝畾鎴愬姛</highlight>"; - } - if (StringUtil.isNullOrEmpty(msg)) - return null; - MsgAccountDetail detail = new MsgAccountDetail(); - detail.setBeiZhu("鏃�"); - detail.setContent(msg); - detail.setTitle("鏇存崲缁戝畾璐﹀彿"); - detail.setType(MsgTypeAccountTypeEnum.bingdingChange); - detail.setUser(new UserInfo(uid)); - detail.setCreateTime(new Date()); - detail.setRead(false); - return detail; - } - /** - * 璐﹀彿鎵撻�� - * - * @param mainUid - * @param lessUid - * @return - */ - public static MsgAccountDetail createConnectAccount(Long mainUid, Long lessUid) { - if (mainUid == null || lessUid == null) - return null; - String msg = String.format("鎭枩浣犺处鍙峰悎骞舵垚鍔燂紝鐢扁��<highlight>%s</highlight>鈥濆悎骞跺埌鈥�<highlight>%s</highlight>鈥�", lessUid + "", - mainUid + ""); - MsgAccountDetail detail = new MsgAccountDetail(); - detail.setBeiZhu("鏃�"); - detail.setContent(msg); - detail.setTitle("璐﹀彿鍚堝苟"); - detail.setType(MsgTypeAccountTypeEnum.connect); - detail.setUser(new UserInfo(mainUid)); - detail.setCreateTime(new Date()); - detail.setRead(false); - return detail; - } - // 璐﹀彿绛夌骇 - public static MsgAccountDetail createUserRank(Long uid, String orderType, int orderCount, String rankName) { - if (uid == null || rankName == null) - return null; + - String msg = String.format( - "鎭枩浣狅紝涓婃湀<highlight>%s</highlight>璁㈠崟杈惧埌<highlight>%s</highlight>鍗曪紝宸蹭负浣犲崌绾т负<highlight>%s</highlight>鐢ㄦ埛锛屽皢浼氳幏寰楀搴旂殑绂忓埄鍜岀壒鏉冦��", - orderType, orderCount + "", rankName); - MsgAccountDetail detail = new MsgAccountDetail(); - detail.setBeiZhu("鏃�"); - detail.setContent(msg); - detail.setTitle("璐﹀彿绛夌骇"); - detail.setType(MsgTypeAccountTypeEnum.level); - detail.setUser(new UserInfo(uid)); - detail.setCreateTime(new Date()); - detail.setRead(false); - return detail; - } - - // 娣樺疂鎺堟潈澶辫触 - public static MsgAccountDetail createTaoBaoAuthFail(Long uid, String taoBaoNickName, String reason) { - if (uid == null || reason == null) - return null; - - JSONArray msg = new JSONArray(); - JSONObject item = new JSONObject(); - item.put("name", "璐﹀彿"); - item.put("content", String.format("娣樺疂鏄电О[%s]", taoBaoNickName)); - msg.add(item); - - item = new JSONObject(); - item.put("name", "鍘熷洜"); - item.put("content", reason); - msg.add(item); - - MsgAccountDetail detail = new MsgAccountDetail(); - detail.setBeiZhu("鏃�"); - detail.setContent(msg.toString()); - detail.setTitle("娣樺疂璐﹀彿鎺堟潈澶辫触"); - detail.setType(MsgTypeAccountTypeEnum.taoBaoAuthFail); - detail.setUser(new UserInfo(uid)); - detail.setCreateTime(new Date()); - detail.setRead(false); - return detail; - } - + /** * 鏅�氫細鍛樸�侀珮绾т細鍛樿嚜鍔ㄦ彁鍗� @@ -480,7 +358,7 @@ listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("閭�绾﹀師鍥�", ClientTextStyleVO.COLOR_TITLE), new ClientTextStyleVO("灏婃暚鐨�"+ nickname+"锛屼綘宸茬鍚堟垚闀夸负涓�鍚嶈祫娣卞甯堢殑鏉′欢锛屽笇鏈涗綘鑳藉姞鍏ユ澘鏍楀揩鐪佽繍钀ュ洟闃燂紝涓庢垜浠叡鍒涜緣鐓�", ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("涓撳睘瀹㈡湇", ClientTextStyleVO.COLOR_TITLE), - new ClientTextStyleVO(kefuName + "-寰俊鍙凤細" +kefuWX, ClientTextStyleVO.COLOR_CONTENT))); + new ClientTextStyleVO(kefuName + "-寰俊鍙�:" +kefuWX, ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("瀵瑰簲鏉冪泭", ClientTextStyleVO.COLOR_TITLE), new ClientTextStyleVO("濡傛灉浣犳帴鍙楅個绾︼紝浣犲皢鑾峰緱璇ヨ处鎴风瓑绾у搴旂殑鍏ㄩ儴鏉冪泭聽", ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("澶囨敞", ClientTextStyleVO.COLOR_TITLE), @@ -523,7 +401,7 @@ listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("閭�绾﹀師鍥�", ClientTextStyleVO.COLOR_TITLE), new ClientTextStyleVO("浠庢敹鍒版湰娑堟伅璧凤紝浣犲皢鑾峰緱璇ヨ处鎴风瓑绾у搴旂殑鍏ㄩ儴鏉冪泭", ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("涓撳睘瀹㈡湇", ClientTextStyleVO.COLOR_TITLE), - new ClientTextStyleVO(kefuName + "-寰俊鍙凤細" +kefuWX, ClientTextStyleVO.COLOR_CONTENT))); + new ClientTextStyleVO(kefuName + "-寰俊鍙�:" +kefuWX, ClientTextStyleVO.COLOR_CONTENT))); listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("澶囨敞", ClientTextStyleVO.COLOR_TITLE), new ClientTextStyleVO("涓庝綘鍏卞垱杈夌厡", ClientTextStyleVO.COLOR_CONTENT))); -- Gitblit v1.8.0