|
|
|
@ -30,6 +30,10 @@ import com.fr.design.mainframe.alphafine.search.manager.impl.ProductNewsSearchMa
|
|
|
|
|
import com.fr.design.mainframe.alphafine.search.manager.impl.SegmentationManager; |
|
|
|
|
import com.fr.design.utils.DesignUtils; |
|
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
|
import com.fr.json.JSON; |
|
|
|
|
import com.fr.json.JSONArray; |
|
|
|
|
import com.fr.json.JSONFactory; |
|
|
|
|
import com.fr.json.JSONObject; |
|
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
|
import java.awt.BorderLayout; |
|
|
|
|
import java.awt.CardLayout; |
|
|
|
@ -319,11 +323,7 @@ public class AlphaFineFrame extends JFrame {
|
|
|
|
|
readLabel.addMouseListener(new MouseAdapter() { |
|
|
|
|
@Override |
|
|
|
|
public void mousePressed(MouseEvent e) { |
|
|
|
|
List<ProductNews> productNewsList = ProductNewsSearchManager.getInstance().getCachedProductNewsList(); |
|
|
|
|
Set<Long> readSet = DesignerEnvManager.getEnvManager().getAlphaFineConfigManager().getReadSet(); |
|
|
|
|
for (ProductNews productNews : productNewsList) { |
|
|
|
|
readSet.add(productNews.getId()); |
|
|
|
|
} |
|
|
|
|
fireOneClickRead(); |
|
|
|
|
showPane.repaint(); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
@ -403,15 +403,21 @@ public class AlphaFineFrame extends JFrame {
|
|
|
|
|
return showPane; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// todo 暂无 先做测试
|
|
|
|
|
private void fireOneClickRead() { |
|
|
|
|
List<ProductNews> productNewsList = ProductNewsSearchManager.getInstance().getCachedProductNewsList(); |
|
|
|
|
Set<Long> readSet = DesignerEnvManager.getEnvManager().getAlphaFineConfigManager().getReadSet(); |
|
|
|
|
for (ProductNews productNews : productNewsList) { |
|
|
|
|
readSet.add(productNews.getId()); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private Map<String, String> generateMap() { |
|
|
|
|
JSONArray jsonArray = JSONFactory.createJSON(JSON.ARRAY, AlphaFineConstants.ALPHA_HELP_RECOMMEND); |
|
|
|
|
Map<String, String> linkMap = new LinkedHashMap<>(); |
|
|
|
|
linkMap.put("test", "https://www.baidu.com"); |
|
|
|
|
linkMap.put("test1", "https://www.baidu.com"); |
|
|
|
|
linkMap.put("test2", "https://www.baidu.com"); |
|
|
|
|
linkMap.put("test3", "https://www.baidu.com"); |
|
|
|
|
linkMap.put("test4", "https://www.baidu.com"); |
|
|
|
|
linkMap.put("test5", "https://www.baidu.com"); |
|
|
|
|
for (int i = 0, len = jsonArray.size(); i < len; i++) { |
|
|
|
|
JSONObject json = jsonArray.getJSONObject(i); |
|
|
|
|
linkMap.put(json.getString("name"), json.getString("link")); |
|
|
|
|
} |
|
|
|
|
return linkMap; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|