Exemplo n.º 1
0
        public void TestMethod1()
        {
            FormFieldController maths = new FormFieldController();

            //Act
            //  maths.SelectMethod();
        }
Exemplo n.º 2
0
        public JsonResult Fields()
        {
            FormFieldController formFieldController = new FormFieldController();
            FormRoleList        formrole            = formFieldController.AllFormFields();

            return(Json(new { Response = formrole }, JsonRequestBehavior.AllowGet));
        }
Exemplo n.º 3
0
        public JsonResult DropDownData(string FormId, string FieldId)
        {
            FormFieldController formFieldController = new FormFieldController();
            DropDownValueDoList dropdownvalue       = formFieldController.DropDownvaluebind(FormId, FieldId);

            return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
        }
Exemplo n.º 4
0
        public JsonResult AutoCompleteCountry(string Prefix, string Formid, string FieldId)
        {
            List <string>       CityName            = new List <string>();
            FormFieldController formFieldController = new FormFieldController();

            CityName = formFieldController.GetAutoComplet(Prefix, Formid, FieldId);
            return(Json(CityName, JsonRequestBehavior.AllowGet));
        }
Exemplo n.º 5
0
        public ActionResult TextBoxControl(string formName, FormCollection form)
        {
            TextBoxList textList = new TextBoxList();

            foreach (String key in form.AllKeys)
            {
                TextBoxViewModel textBoxList1 = new TextBoxViewModel();
                textBoxList1.FieldId = key;
                textBoxList1.Value   = form[key];

                textList.Add(textBoxList1);
            }
            RelianceController.FormFieldController formFieldController = new FormFieldController();
            formFieldController.InsertMetada(formName, "", textList);
            // TextList.Add(textBoxList1);
            return(View());
            // return Json(new { OnSuccess = "success" }, JsonRequestBehavior.AllowGet);
        }
Exemplo n.º 6
0
        public JsonResult DropDownDataIsRoleAssignMent(string FormId, string FieldId, string UserId, string RoleId, string Form)
        {
            IsRoleAssignmentController isRoleAssignmentController = new IsRoleAssignmentController();
            IsROleAssignmentDo         lsROleAssignmentDo         = isRoleAssignmentController.IsROleAssignment(FormId, FieldId, UserId, RoleId, Form);

            if (lsROleAssignmentDo.DocumentDataid == "")
            {
                FormFieldController formFieldController = new FormFieldController();
                DropDownValueDoList dropdownvalue       = formFieldController.DropDownvaluebind(FormId, FieldId);
                return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
            }
            else

            {
                if (lsROleAssignmentDo.IsEdit == 1 && lsROleAssignmentDo.IsCreate == 1 & lsROleAssignmentDo.Userid == Convert.ToInt32(Session["LOGGED_UserId"]))
                {
                    FormFieldController formFieldController = new FormFieldController();
                    DropDownValueDoList dropdownvalue       = formFieldController.DropDownvaluewithRole(FormId, FieldId, lsROleAssignmentDo.DocumentDataid);
                    return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
                }
                if (lsROleAssignmentDo.IsCreate == 1 & lsROleAssignmentDo.Userid == Convert.ToInt32(Session["LOGGED_UserId"]))
                {
                    FormFieldController formFieldController = new FormFieldController();
                    DropDownValueDoList dropdownvalue       = formFieldController.DropDownvaluewithRole(FormId, FieldId, lsROleAssignmentDo.DocumentDataid);
                    return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
                }
                if (lsROleAssignmentDo.IsEdit == 1 & lsROleAssignmentDo.Userid == Convert.ToInt32(Session["LOGGED_UserId"]))
                {
                    FormFieldController formFieldController = new FormFieldController();
                    DropDownValueDoList dropdownvalue       = formFieldController.DropDownvaluewithRole(FormId, FieldId, lsROleAssignmentDo.DocumentDataid);
                    return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
                }

                else
                {
                    FormFieldController formFieldController = new FormFieldController();

                    DropDownValueDoList dropdownvalue = formFieldController.DropDownvaluebind(FormId, FieldId);
                    return(Json(new { Responses = dropdownvalue }, JsonRequestBehavior.AllowGet));
                }
            }
        }