예제 #1
0
        public async Task <ApplicationOlderVersionGrade> UpdateRC1GradeAndVersion(string version)
        {
            OlderVersionDal AppOldVersionDal = new OlderVersionDal();
            Version         oldVersionToSave = new Version();

            var gradeValues = await ReportsRepository.getGradeValues("Application%20Grade");

            double totalCalc = 100 - (5 * gradeValues.Item1) - (0.5 * gradeValues.Item2) - (0.1 * gradeValues.Item3);

            if (Version.TryParse(version, out oldVersionToSave))
            {
                return(AppOldVersionDal.SetApplictionOldVersionRC1(oldVersionToSave.ToString(), totalCalc));
            }

            return(default(ApplicationOlderVersionGrade));
        }
예제 #2
0
        public async Task <ApplicationOlderVersionGrade> UpdateGAGrade()
        {
            OlderVersionDal AppOldVersionDal = new OlderVersionDal();
            var             lastVersion      = AppOldVersionDal.GetLastApplicationOldGrade();
            var             targetVersion    = new Tuple <string, string, string>("Cx.TargetVersion", "=", lastVersion.ApplicationVersion);
            var             DateVersion      = new Tuple <string, string, string>("System.CreatedDate", ">=", lastVersion.RC1DateTime.ToString("yyyy-MM-dd'T'00:00:00.0000000"));
            var             parms            = new List <Tuple <string, string, string> >()
            {
                targetVersion, DateVersion
            };

            var gradeValues = await ReportsRepository.getGradeValuesByFilters("Application%20prev%20releases%20grades/GA%20assumed", parms);

            double totalCalc = lastVersion.RC1QuelityGrade - (5 * gradeValues.Item1) - (0.5 * gradeValues.Item2) - (0.1 * gradeValues.Item3);

            return(AppOldVersionDal.SetApplicationGaGrade(totalCalc));
        }