public WasteCodesViewModel(NotificationApplication notification, WasteCodeInfoFormatter wasteCodeInfoFormatter)
        {
            this.wasteCodeInfoFormatter = wasteCodeInfoFormatter;
            InitializeAllCodesToEmptyString();

            SetBaselAndOecdCode(notification);

            Ewc = wasteCodeInfoFormatter.CodeListToString(notification.EwcCodes);
            Y = wasteCodeInfoFormatter.CodeListToString(notification.YCodes);
            H = wasteCodeInfoFormatter.CodeListToString(notification.HCodes);
            UnClass = wasteCodeInfoFormatter.CodeListToString(notification.UnClasses);

            Nce = wasteCodeInfoFormatter.GetCustomCodeValue(notification.ExportCode);
            Nci = wasteCodeInfoFormatter.GetCustomCodeValue(notification.ImportCode);
            Other = wasteCodeInfoFormatter.GetCustomCodeValue(notification.OtherCode);
            Customs = wasteCodeInfoFormatter.GetCustomCodeValue(notification.CustomsCode);

            SetUnNumbersAndShippingNames(notification);
            SetIsAnnexNeeded();
        }
Пример #2
0
        public WasteCodesViewModel(NotificationApplication notification, WasteCodeInfoFormatter wasteCodeInfoFormatter)
        {
            this.wasteCodeInfoFormatter = wasteCodeInfoFormatter;
            InitializeAllCodesToEmptyString();

            SetBaselAndOecdCode(notification);

            Ewc     = wasteCodeInfoFormatter.CodeListToString(notification.EwcCodes);
            Y       = wasteCodeInfoFormatter.CodeListToString(notification.YCodes);
            H       = wasteCodeInfoFormatter.CodeListToString(notification.HCodes);
            UnClass = wasteCodeInfoFormatter.CodeListToString(notification.UnClasses);

            Nce     = wasteCodeInfoFormatter.GetCustomCodeValue(notification.ExportCode);
            Nci     = wasteCodeInfoFormatter.GetCustomCodeValue(notification.ImportCode);
            Other   = wasteCodeInfoFormatter.GetCustomCodeValue(notification.OtherCode);
            Customs = wasteCodeInfoFormatter.GetCustomCodeValue(notification.CustomsCode);

            SetUnNumbersAndShippingNames(notification);
            SetIsAnnexNeeded();
        }
Пример #3
0
 public WasteCodeInfoFormatterTests()
 {
     formatter = new WasteCodeInfoFormatter();
 }
 public WasteCodeInfoFormatterTests()
 {
     formatter = new WasteCodeInfoFormatter();
 }