Beispiel #1
0
        public async Task ShouldNitaqatInformationInquiry()
        {
            //Arrange
            var model = new NitaqatInformationRequestModel {
                EstablishmentLaborOfficeId = "1", EstablishmentSequenceNumber = "290901"
            };
            //Act
            var result = await _YesserProxy.NitaqatInformationInquiry(model);

            //Assert
            Assert.NotNull(result);
        }
Beispiel #2
0
        public async Task <SupplierInfoStatusModel> NitaqatInformationInquiry(string EstablishmentLaborOfficeId, string EstablishmentSequenceNumber)
        {
            var parameter = new NitaqatInformationRequestModel {
                EstablishmentLaborOfficeId = EstablishmentLaborOfficeId, EstablishmentSequenceNumber = EstablishmentSequenceNumber
            };
            var result = await _IYasserproxy.NitaqatInformationInquiry(parameter);

            var res = new SupplierInfoStatusModel();

            if (result == null)
            {
                res.enSupplierInfoType = Enums.SupplierInfoType.Warnning;
                res.StatusName         = Resources.TenderResources.ErrorMessages.CantFindRecord;
            }
            else
            {
                res.enSupplierInfoType = Enums.SupplierInfoType.Success;
                res.StatusName         = Resources.TenderResources.Messages.Valid;
                res.CompanyName        = result.EstablishmentName;
                res.Notes           = result.EntityColor.EntityColorName;
                res.SaudiPercentage = result.SaudiPercentage;
            }
            return(res);
        }