fs-danaus
2022-07-26 5783692a635adfdd330d23b4eb31df2eca5ceb77
抄送我的新增显示未读,已读
1个文件已修改
26 ■■■■■ 已修改文件
src/com/yc/ionic/service/AppImpl.java 26 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/com/yc/ionic/service/AppImpl.java
@@ -71,6 +71,10 @@
    @Override
    public List<Map<String, Object>> getMessageByUserCodeV2(MessageParameter messageParameter) {
        //String where=" where   UserCode = '"+messageParameter.getUserCode()+"'";
        String actionType="";
        if ("抄送我的".equals(messageParameter.getActionType())){
            actionType=messageParameter.getActionType();
        }
        if ("审核".equals(messageParameter.getActionType()) && messageParameter.getMsgType() == 2) {//我发起的
            messageParameter.setActionType("提交");
        } else if ("抄送我的".equals(messageParameter.getActionType())||("审核".equals(messageParameter.getActionType()) && messageParameter.getMsgType() == 3)) {//抄送我的
@@ -113,12 +117,12 @@
                " where UserCode = @UserCode     \n";
        if (messageParameter.getIsfinshed() == 1) {
            sql += " and curstatus = 'Undone'  \n";
            sql += " and curstatus = 'Undone'  and isnull(a.isRead,0) = 0\n";
        }
        if (messageParameter.getIsfinshed() == 2) {
            sql += " and curstatus = 'Finished'  \n";
        else  if (messageParameter.getIsfinshed() == 2) {
            sql += " and curstatus = 'Finished' and isnull(a.isRead,0) = 0 \n";
        }
        if (messageParameter.getIsfinshed() == 3) {
        else if (messageParameter.getIsfinshed() == 3||("抄送我的".equals(actionType)&&messageParameter.getIsfinshed()==0)) {
            //在线交流,通知
            if(messageParameter.getMsgType()==4) {
                //未读
@@ -129,7 +133,6 @@
                sql += "         and isnull(a.isRead,0) = 1  \n";
            }
        }
        sql +=
                "  and (isnull(@SearchKey,'') = ''\n" +
                        "  or a.QueryString like '%' + @SearchKey + '%' \n" +
@@ -212,7 +215,7 @@
                "   select  @ActionCount=count(1) \n" +
                "   from t219001 a with (nolock) \n" +
                "   where a.UserCode =@userCode\n" +
                "   and a.actiontype ='抄送' \n" +
                "   and a.actiontype ='抄送' and isnull(a.isRead,0)=0\n" +
                "  set @MsgCount=isnull(@MsgCount,0)+isnull(@ActionCount,0)\n" +
                "  set @todoCount=isnull(@todoCount,0)+isnull(@ActionCount,0)\n" +
                "  insert into @table(ActionType,ActionCount)values('抄送我的',@ActionCount)\n" +
@@ -271,6 +274,10 @@
    @Override
    public List<Map<String, Object>> getMessageByType(MessageParameter messageParameter) {
        //String where=" where   UserCode = '"+messageParameter.getUserCode()+"'";
        String actionType="";
        if ("抄送我的".equals(messageParameter.getActionType())){
            actionType=messageParameter.getActionType();
        }
        if ("审核".equals(messageParameter.getActionType()) && messageParameter.getMsgType() == 2) {//我发起的
            messageParameter.setActionType("提交");
            ;
@@ -299,10 +306,10 @@
                " and (isnull(@ActionType,'') = '' or a.ActionType in (select list from GetInStr( @ActionType)) )\n" +
                " and (isnull(@FilterFormId,0) = 0 or a.formid = isnull(@FilterFormId,0))\n";
        if (messageParameter.getIsfinshed() == 1) {
            sql += "        and curstatus = 'Undone'  \n";
            sql += "        and curstatus = 'Undone' and isnull(a.isRead,0) = 0 \n";
        }else if (messageParameter.getIsfinshed() == 2) {
            sql += "         and curstatus = 'Finished'  \n";
        }else {
            sql += "         and curstatus = 'Finished' and isnull(a.isRead,0) = 0 \n";
        }else if (messageParameter.getIsfinshed() == 3||("抄送我的".equals(actionType)&&messageParameter.getIsfinshed()==0)){
            //在线交流,通知
            if(messageParameter.getMsgType()==4) {
                //未读
@@ -312,7 +319,6 @@
                //已读
                sql += "         and isnull(isRead,0) = 1  \n";
            }
        }
        sql +="  group by a.FormId \n"+
                " ) a \n" +