版权所有 2009-2016荆门泽优软件有限公司
保留所有权利
产品首页:http://www.ncmem.com/webapp/up6.2/index.asp
在线演示:http://www.ncmem.com/products/up6.2/index.htm
产品介绍:http://www.cnblogs.com/xproer/archive/2012/10/26/2741264.html
升级日志:http://www.cnblogs.com/xproer/archive/2012/10/26/2741268.html
开发文档-ASP:http://www.cnblogs.com/xproer/archive/2012/02/17/2355458.html
开发文档-PHP:http://www.cnblogs.com/xproer/archive/2012/02/17/2355467.html
开发文档-JSP:http://www.cnblogs.com/xproer/archive/2012/02/17/2355462.html
开发文档-ASP.NET:http://www.cnblogs.com/xproer/archive/2012/02/17/2355469.html
资源下载:cab安装包(x86),cab安装包(x64),crx安装包,crx(nat)安装包,xpi安装包,exe安装包,开发文档,VC运行库,Discuz!X2插件下载,
示例下载(.NET):SQL2005示例,
示例下载(JSP):Sql2005示例,MySQL示例,Oracle示例,
示例下载(PHP):MySQL示例
联系信箱:1085617561@qq.com
联系QQ:1085617561
更新fd_del.jsp
更新前:
更新后:
代码:
<%@ page language="java" import="up6.DBFolder" pageEncoding="UTF-8"%><%@
page contentType="text/html;charset=UTF-8"%><%@
page import="org.apache.commons.lang.StringUtils" %><%
/*
此页面主要用来执行删除文件夹逻辑。
只修改数据库中文件夹状态。
更新记录:
2014-07-24 创建
*/
String path = request.getContextPath();
String fid = request.getParameter("fid");
String fdid = request.getParameter("fd_id");
String uid = request.getParameter("uid");
String cbk = request.getParameter("callback");//jsonp
int ret = 0;
//参数为空
if ( !StringUtils.isBlank(fid)
&& !StringUtils.isBlank(fdid)
&& uid.length()>0 )
{
DBFolder.Remove(Integer.parseInt(fid),Integer.parseInt(fdid), Integer.parseInt(uid));
ret = 1;
}
out.write(cbk + "({"value":" + ret + "})");
%>
更新DBFolder.java
更新前:
更新后:
代码:
static public void Remove(int fid,int fdid,int uid)
{
StringBuilder sb = new StringBuilder();
sb.append("update up6_files set f_deleted=1 where f_id=? and f_uid=?;");
sb.append("update up6_files set f_deleted=1 where f_pidRoot=? and f_uid=?;");
sb.append("update up6_folders set fd_delete=1 where fd_id=? and fd_uid=?;");
DbHelper db = new DbHelper();
PreparedStatement cmd = db.GetCommand(sb.toString());
try
{
cmd.setInt(1, fid);
cmd.setInt(2, uid);
cmd.setInt(3, fdid);
cmd.setInt(4, uid);
cmd.setInt(5, fdid);
cmd.setInt(6, uid);
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
db.ExecuteNonQuery(cmd);
}
更新up6.js
更新前:
更新后:
代码:
, "RemoveFolder": function (fileSvr)
{
var ref = this;
var idSvr = fileSvr.idSvr;
var ui = this.filesUiMap[idSvr];
$.ajax({
type: "GET"
, dataType: 'jsonp'
, jsonp: "callback" //自定义的jsonp回调函数名称,默认为jQuery自动生成的随机函数名
, url: this.Config["UrlFdDel"]
, data: { uid: fileSvr.uid, fid: fileSvr.idSvr,fd_id:fileSvr.fdID, time: new Date().getTime() }
, success:function (msg){if (msg.value == 1){ui.empty();}}
, error: function () { alert("发送删除文件信息失败!"); }
, complete: function (req, sta) { req = null; }
});
}