public string UnInstall()
        {
            string[] flowIds        = Request.Forms("flowid").Split(',');
            int      thoroughDelete = Request.Forms("thoroughdelete").ToInt(0);//是否彻底删除
            string   status         = Request.Forms("status");

            Business.Flow flow = new Business.Flow();
            foreach (var flowId in flowIds)
            {
                var flowModel = flow.Get(flowId.ToGuid());
                if (null == flowModel)
                {
                    continue;
                }
                if (0 == thoroughDelete)//作删除标记或卸载标记
                {
                    int status1 = status.ToInt(3);
                    Business.Log.Add(("2".Equals(status) ? "卸载" : "删除") + "了流程-" + flowModel.Name, flowModel.ToString(), Business.Log.Type.流程管理);
                    flowModel.Status = status1;
                    flow.Update(flowModel);
                }
                else//彻底删除
                {
                    flow.Delete(flowModel);
                    //删除应用程序库
                    Business.AppLibrary appLibrary = new Business.AppLibrary();
                    var appModel = appLibrary.GetByCode(flowModel.Id.ToString());
                    if (null != appModel)
                    {
                        new Business.AppLibrary().Delete(appModel.Id);
                    }
                    //删除流程实例
                    new Business.FlowTask().DeleteByFlowId(flowModel.Id);
                    Business.Log.Add("彻底删除了流程-" + flowModel.Name, flowModel.ToString(), Business.Log.Type.流程管理);
                }
                flow.ClearCache(flowModel.Id);
            }
            return("1");
        }