Пример #1
0
        protected static void CustomValidations(LaboratorySectionItem obj)
        {
            var acc = FFPresenterModel.Accessor.Instance(null);

            using (var manager = DbManagerFactory.Factory.Create(ModelUserContext.Instance))
            {
                acc.Validate(manager, obj.FFPresenter, true, false, true);
            }
        }
Пример #2
0
        public LaboratorySectionItem GetWithOriginal(LaboratorySectionItem o)
        {
            idfsSampleStatusOriginalIsSaved       = true;
            idfsSampleStatusOriginalSaved         = o.idfsSampleStatus_Original;
            idfsTestStatusOriginalIsSaved         = true;
            idfsTestStatusOriginalSaved           = o.idfsTestStatus_Original;
            idfsTestResultOriginalIsSaved         = true;
            idfsTestResultOriginalSaved           = o.idfsTestResult_Original;
            idfsAccessionConditionOriginalIsSaved = true;
            idfsAccessionConditionOriginalSaved   = o.idfsAccessionCondition_Original;
            idfSendToOfficeOutOriginalIsSaved     = true;
            idfSendToOfficeOutOriginalSaved       = o.idfSendToOfficeOut_Original;
            strBarcodeOriginalIsSaved             = true;
            strBarcodeOriginalSaved        = o.strBarcode_Original;
            idfsTestNamePreviousIsSaved    = true;
            idfsTestNamePreviousSaved      = o.idfsTestName_Previous;
            blnExternalTestPreviousIsSaved = true;
            blnExternalTestPreviousSaved   = o.blnExternalTest_Previous;

            _isValid = o._isValid;

            return(this);
        }
Пример #3
0
 public static void CheckSamplesForGroupAccesionInExists(DbManagerProxy manager, LaboratorySectionItem obj)
 {
     if (obj.intNewMode == LabNewModeEnum.GroupAccessionIn)
     {
         var idfMaterial = manager.SetSpCommand("dbo.spLaboratorySection_GetByFieldBarcodeCount",
                                                obj.strFieldBarcode,
                                                obj.bSendToCurrentOffice ? EidssSiteContext.Instance.OrganizationID : 0).ExecuteScalar <long>();
         if (idfMaterial == 0)
         {
             throw new ValidationModelException("msgSamplesForGroupAccesionInNotFound", "", "", new object[] { }, null, ValidationEventType.Error, obj);
         }
     }
 }