日期:2008-09-01  浏览次数:20501 次

上次发了一个加确认删除的方法,经过实践,发现效果并不很理想,所以又对该方法进行了剖析,做了一些调整,使其现在更加使用了,步骤如下:

1、老规矩,打开C:\Inetpub\wwwroot\webctrl_client\1_0下的toolbar.htc ,找到方法f_FireButtonClick(oCell)

2、对该方法其中的代码进行修改,具体修改内容如下:
// Modify Start
function f_FireButtonClick(oCell)
{
    //var oEvent= createEventObject();

    var bConfirm;
    bConfirm=false;          
    
    if (oCell != null)
    {
        //oEvent.srcNode = f_PublicMakeContract(oCell);  
                
        var doid;                                       //Oprate ID
        doid = oCell.id;
        
        if(id != null)
        {
            var sindex ;
            var strmsg ;
            sindex = doid.indexOf("DELETE");
            if(sindex != -1)
            {
                strmsg = "是否要进行删除操作?";
                bConfirm = true;
            }
            
            sindex = doid.indexOf("DELETECATALOG");
            if(sindex != -1)
            {
                strmsg = "对象分类删除后,分类下属分类及\r\n文档将同时被删除。是否删除?";
                bConfirm = true;
            }
            
            sindex = doid.indexOf("DELETEDOC");
            if(sindex != -1)
            {
                strmsg = "是否确实要删除选定文档?";
                bConfirm = true;
            }
            
            sindex = doid.indexOf("CLEARRECYCLE");
            if(sindex != -1)
            {
        &n