Example #1
0
        public ActionResult RevocationData(int udg_id, int ExperimentalId)
        {
            List <UpDownDataTable> list_udt         = dbDrive.GetUpDownDataTables(udg_id);
            UpDownExperiment       upDownExperiment = dbDrive.GetUpDownExperiment(ExperimentalId);
            var lr    = LiftingPublic.SelectState(upDownExperiment);
            var xAndV = LiftingPublic.GetXArrayAndVArray(list_udt, upDownExperiment);

            if (list_udt.Count == 1)
            {
                string[] value = { "false", list_udt.Count.ToString(), list_udt[list_udt.Count - 1].dtup_Initialstimulus.ToString(), lr.StepsNumber(xAndV.xArray, xAndV.vArray).ToString() };
                return(Json(value));
            }

            UpDownDataTable        upDownDataTable = list_udt[list_udt.Count - 1];
            var                    isTure          = dbDrive.Delete(upDownDataTable);
            List <UpDownDataTable> list_udtDelete  = dbDrive.GetUpDownDataTables(udg_id);
            var                    xAndVDelete     = LiftingPublic.GetXArrayAndVArray(list_udtDelete, upDownExperiment);

            string[] valueDelete = { isTure.ToString(), (list_udt.Count - 1).ToString(), list_udtDelete[list_udtDelete.Count - 1].dtup_Initialstimulus.ToString(), lr.StepsNumber(xAndVDelete.xArray, xAndVDelete.vArray).ToString() };
            return(Json(valueDelete));
        }