⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 modifylogbean.java

📁 WAP PUSH后台源码,WAP PUSH后台源码
💻 JAVA
字号:
package com.sxit.wap.modifylog;import java.sql.*;import java.util.*;import com.sxit.wap.common.*;import com.sxit.wap.exception.*;import com.sxit.wap.admin.*;import com.sxit.wap.adminpurview.*;import com.sxit.wap.area.*;import com.sxit.wap.channel.*;import com.sxit.wap.channelfee.*;import com.sxit.wap.channeltype.*;import com.sxit.wap.common.*;import com.sxit.wap.cp.*;import com.sxit.wap.dacs.*;import com.sxit.wap.exception.*;import com.sxit.wap.feetype.*;import com.sxit.wap.group.*;import com.sxit.wap.groupuser.*;import com.sxit.wap.indexmenu.*;import com.sxit.wap.log.*;import com.sxit.wap.menu.*;import com.sxit.wap.menuimg.*;import com.sxit.wap.modifylog.*;import com.sxit.wap.netstat.*;import com.sxit.wap.netstatlog.*;import com.sxit.wap.sncs.*;import com.sxit.wap.systemparam.*;import com.sxit.wap.top.*;import com.sxit.wap.user.*;import com.sxit.wap.usersub.*;import com.sxit.wap.usersubhis.*;import com.sxit.wap.department.*;import com.sxit.wap.groupchannel.*;import com.sxit.wap.staff.*;public class ModifyLogBean extends ModifyLogDao{  public static String parseStaffModel(StaffModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseGroupChannelModel(GroupChannelModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseDepartmentModel(DepartmentModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseAdminModel(AdminModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseAdminPurviewModel(AdminPurviewModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseAreaModel(AreaModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseChannelModel(ChannelModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseChannelFeeModel(ChannelFeeModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseChannelTypeModel(ChannelTypeModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseCpModel(CpModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseFeeTypeModel(FeeTypeModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseGroupModel(GroupModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseGroupUserModel(GroupUserModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseIndexMenuModel(IndexMenuModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseMenuModel(MenuModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseMenuImgModel(MenuImgModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseNetstatModel(NetstatModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseSystemParamModel(SystemParamModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseTopModel(TopModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseUserModel(UserModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseUserSubModel(UserSubModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static String parseUserSubHisModel(UserSubHisModel model) throws SysException {    if (model == null) return "";    return model.toString();  }  public static int getRowCountLog(Timestamp beginDate, Timestamp endDate) throws SysException {    return getRowCountBySql("SELECT COUNT(*) FROM " + tableName + " WHERE " + DateUtil.getDateCompareSql(Database.dbType, "MODIFY_TIME", beginDate, DateUtil.getSomeDate(endDate, 1)));  }  public static Collection queryLog(Timestamp beginDate, Timestamp endDate, int beginRow, int endRow) throws SysException {    return queryBySql("SELECT * FROM " + tableName + " WHERE " + DateUtil.getDateCompareSql(Database.dbType, "MODIFY_TIME", beginDate, DateUtil.getSomeDate(endDate, 1)), beginRow, endRow);  }  public static ModifyLogModel insert(ModifyLogModel model) throws SysException,UpdateException,AppException {    return ModifyLogDao.insert(formatModel(model));  }  public static ModifyLogModel insert(ModifyLogModel model, Connection dbConnection) throws SysException,UpdateException,AppException {    return ModifyLogDao.insert(formatModel(model), dbConnection);  }  private static ModifyLogModel formatModel(ModifyLogModel model) {    String dataBeforeModify = model.getDataBeforeModify();    String dataAfterModify = model.getDataAfterModify();    if (dataBeforeModify.length() > 255) {      dataBeforeModify = dataBeforeModify.substring(0, 255);      model.setDataBeforeModify(dataBeforeModify);    }    if (dataAfterModify.length() > 255) {      dataAfterModify = dataAfterModify.substring(0, 255);      model.setDataAfterModify(dataAfterModify);    }    return model;  }  public static String formatNote(String s){    s=RemoveComment(s);    s=addBr(s);    s=addBlack(s);    return s;  }  private static String RemoveComment(String Content){    String makeContent=new String();    StringTokenizer strToken=new StringTokenizer(Content,"\n");    String tempToken=null;    while(strToken.hasMoreTokens()){      tempToken=strToken.nextToken();      if(tempToken.indexOf(":")!=0)        makeContent=makeContent+tempToken+"\n";    }    return makeContent;  }  //将/n转换成为回车<br>  private static String addBr(String Content){    String makeContent="";    StringTokenizer strToken=new StringTokenizer(Content,"\n");    while(strToken.hasMoreTokens()){      if (!"".equals(makeContent)){        makeContent+="   ";      }      makeContent+=strToken.nextToken();    }    return makeContent;  }  private static String addBlack(String Content){    String makeContent="";    for (int i=0;i<Content.length();i++){      if (Content.charAt(i)==' '){        makeContent+="&nbsp;";      }else{        makeContent+=Content.charAt(i);      }    }    return makeContent;  }  public static void clear(Timestamp beginDate, Timestamp endDate) throws SysException {    String sql = "DELETE FROM " + tableName + " WHERE " + DateUtil.getDateCompareSql(Database.dbType, "MODIFY_TIME", beginDate, DateUtil.getSomeDate(endDate, 1));    System.out.println(sql);    updateBySql(sql);  }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -