예제 #1
0
        /// <summary>
        /// 获取表单数据
        /// </summary>
        public void GetFormJson()
        {
            int      id = Convert.ToInt32(ctx.Request["keyValue"]);
            workflow wf = IdalCommon.IworkflowEx.getEntityById(id);

            writeJsonBack(wf.ToJson());
        }
예제 #2
0
        public void WorkflowVisualization()
        {
            object wfid = ctx.Request["wfid"];

            if (wfid != null)
            {
                workflow wf = IdalCommon.IworkflowEx.getEntityById(Convert.ToInt32(wfid));
                tp.Put("workflow", wf.ToJson());
                string resutlt = "{}";
                if (!string.IsNullOrEmpty(wf.wfjsonstr))
                {
                    resutlt = wf.wfjsonstr.TrimStart('"').TrimEnd('"');
                }
                tp.Put("workflowjsonstr", resutlt);
                string actionliststr = wfselectoption.CreateList(IdalCommon.IactionEx.getActionListbywfid(Convert.ToInt32(wfid)), "id", "actiondescription").ToJson();
                tp.Put("actionlist", actionliststr);
                string roleliststr = wfselectoption.CreateList(IdalCommon.IroleEx.getEntityList(), "id", "rolename").ToJson();
                tp.Put("rolelist", roleliststr);
            }
            tp.Display(ctx, "/Html/WorkflowVisualization.html");
        }