public ActionResult InsertFirstResponderAnnotation(Event_Equipment_RootCauseModelView model, FormCollection collection)
        {
            using (MOMSEventFrameInterfaceEntities db = new MOMSEventFrameInterfaceEntities())
            {
                try
                {
                    var result = UpdateMasterDowntimeTable(model.eventModelView.uniqueID);

                    var annotation = new tbl_factMaintenanceAnnotations();
                    annotation.UniqueID = model.eventModelView.uniqueID;
                    annotation.FailureTypeDescription = model.rootCauseModelView.contType;
                    annotation.FailureDescription     = model.rootCauseModelView.contRootCause;
                    annotation.EquipmentType          = model.equipModelView.equipType;
                    annotation.EquipmentName          = model.equipModelView.equipName;
                    annotation.EquipmentNumber        = model.equipModelView.equipNumber;

                    annotation.ModifyStamp = DateTime.Now;

                    db.tbl_factMaintenanceAnnotations.Add(annotation);

                    db.SaveChanges();
                }
                catch (Exception ex)
                {
                    throw ex;
                }

                return(RedirectToAction("Events"));
            }
        }
        public int UpdateMasterDowntimeTable(string uniqueId)
        {
            using (MOMSEventFrameInterfaceEntities db = new MOMSEventFrameInterfaceEntities())
            {
                try
                {
                    var eventToUpdate = db.tbl_factFailureDowntimeCMMS.Find(uniqueId);

                    db.SaveChanges();
                }
                catch (Exception ex)
                {
                    throw ex;
                }

                return(0);
            }
        }